[Qbs] QT_DEBUG defined on release builds

Ely elyzabethvonreuenthal at iserlohn-fortress.net
Sat Dec 16 14:14:14 CET 2017


I have a project roughly specified like this:

> Project {
>     CppApplication {
>         Depends { name: "Qt.core" ... }
>         Group {
>             file: ['main.cpp']
>             cpp.defines: ['SOMETHING', 'SOMETHING_ELSE']
>         }
>    }
> }

With this setup, I get the following defines on a release build:
> -DNDEBUG -DSOMETHING -DSOMETHING_ELSE

But when the cpp.defines are not placed in a group, I get these:
> -DNDEBUG -DSOMETHING -DSOMETHING_ELSE -DQT_CORE_LIB -DQT_NO_DEBUG

This is a problem, because without QT_NO_DEBUG, all code in checking for 
QT_DEBUG compiles.

I'm using qbs 1.10.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/qbs/attachments/20171216/78d14755/attachment.sig>


More information about the Qbs mailing list