[Qt-creator] Fwd: Qt-creator can't find the location of the executable it built

Mildred Ki'Lya ml.mildred593 at gmail.com
Fri May 15 04:48:20 CEST 2009


On 05/05/2009 03:35 PM, Daniel Teske wrote:
> On Tuesday 05 May 2009 13:22:45 ext Mildred Ki'Lya wrote:
>    
>> Hi,
>>
>> I have a problem with QtCreator. When I try to start the executable,
>> it can't find it. On Windows, I get:
>>
>>
>>
>> Starting C:/Project/configurator.shanti/main/debug/configurator.exe...
>>
>> The process could not be started!
>>
>>
>>
>> In fact, the executable is located in
>> C:/Project/configurator.shanti/debug/configurator.exe. The project
>> main.pro looks like:
>>
>> # -------------------------------------------------
>> # Project created by QtCreator 2009-03-24T16:23:40
>> # -------------------------------------------------
>> QT += xml
>> TARGET = configurator
>> TEMPLATE = app
>> SOURCES += main.cpp
>> RESOURCES += ../resources.qrc
>> debug {
>>      DESTDIR=../debug
>>      LIBS += -L../debug
>> } else:release {
>>      DESTDIR=../release
>>      LIBS += -L../release
>> }
>> LIBS += -lcontroler -lglobalihm
>> INCLUDEPATH += ..
>> DEPENDPATH += ..
>>
>>
>> I modified the DESTDIR variable because i needed the executable to be
>> in the same directory as the dynamic libraries it needs.
>>      
>
> We should parse that .pro file correctly, but I'll check what goes wrong there.
>    
I guess what goes wrong is that it doesn't read DESTDIR if it's inside 
of the condition. If you remove the condition (you get the same DESTDIR 
for both debug and release mode) QtCreator finds the executable. It also 
works if you set a DESTDIR variable before the condition. It is 
overridden at the qmake level but QtCreator uses it.

Also does any of you knows if there is a variable that contains either 
"release" or "debug" that we could use to set the DESTDIR path, that may 
be a neat workaround. But of course, QtCreator would have to understand 
that as well :/

Mildred


-- 
Mildred Ki'Lya
╭───────── mildred593@online.fr ──────────
│ Jabber, GoogleTalk:<mildred at jabber.fr>
│ Website:<http://ki.lya.online.fr>            GPG ID: 9A7D 2E2B
│ Fingerprint: 197C A7E6 645B 4299 6D37 684B 6F9D A8D6 9A7D 2E2B

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-creator-old/attachments/20090515/1f9f8ae1/attachment.html 


More information about the Qt-creator-old mailing list