[Qbs] QT_DEBUG defined on release builds

Christian Gagneraud chgans at gmail.com
Sat Dec 16 20:53:42 CET 2017


On 17/12/2017 2:21 am, "NIkolai Marchenko" <enmarantispam at gmail.com> wrote:

cpp.defines: base.concat(['SOMETHING', 'SOMETHING_ELSE'])


Could someone explain the rules as to when to use base.concat or not, eg is
it necessary here just because of the group? Or should this be always used?
(Project, Product, Module, ...)

The problem is that you don't get warning when you overwrite an array
property, so it's easy to loose information and potentially difficult to
trace.

Chris.




On Sat, Dec 16, 2017 at 4:14 PM, Ely <elyzabethvonreuenthal@
iserlohn-fortress.net> wrote:

> 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.
> _______________________________________________
> Qbs mailing list
> Qbs at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/qbs
>
>

_______________________________________________
Qbs mailing list
Qbs at qt-project.org
http://lists.qt-project.org/mailman/listinfo/qbs
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qbs/attachments/20171217/66c83155/attachment.html>


More information about the Qbs mailing list