PDA

View Full Version : qmake release with debug info



rbp
15th May 2009, 07:38
hello,

I'm using QMake to generate a Visual Studio project file on Windows.
I want my release build to include debugging information, which I can set manually in properties with:
C++/General/Debug Information Format -> Program Database
Linker/Debugging/Generate Debug Info -> Yes

However each time I change my project configuration and run QMake these properties have to be manually reset.
So, does there happen to be a QMake flag to generate a release binary with debugging information?

I know this question is quite petty because manually setting those properties is not too much trouble. Still, I would like to make my development pipeline as clean as possible.

thanks,
Richard

talk2amulya
15th May 2009, 08:36
the debug information is something that the compiler would put, so i guess at most, you can try adding /DEBUG to the compiler flags in your make file.

rbp
18th May 2009, 04:41
which flag do you think would be relevant to add /DEBUG to? QMAKE_CXXFLAGS?

talk2amulya
18th May 2009, 07:46
QMAKE_CXXFLAGS or QMAKE_CXXFLAGS_RELEASE..either change them in your makefile or you can change your qmake.conf

rbp
18th May 2009, 08:57
hello talk2amulya,

thanks for the hint! I have got it working now and the exact flags I needed were:
QMAKE_CXXFLAGS_RELEASE += /Zi
QMAKE_LFLAGS_RELEASE += /DEBUG

Richard