diff options
author | Joerg Bornemann <joerg.bornemann@qt.io> | 2019-09-12 10:27:16 +0200 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@qt.io> | 2019-09-18 08:24:38 +0200 |
commit | 1456b8091a681316f0e6256554fd138c6399f564 (patch) | |
tree | 240b0abad07e80f1aea92a36fd31727dba99e32a /qmake/doc | |
parent | 983cfc773d1f24badbdeafd6fbbb2a5940c6f614 (diff) |
Make it possible to undefine NDEBUG for nmake and VS projects
For nmake and VS projects we added the NDEBUG define for the release
configuration unconditionally within the qmake generators. To undefine
it, users had to use a nasty work-around.
Now, define NDEBUG within the MSVC mkspecs. In order to do that we
introduce the DEFINES_RELEASE and DEFINES_DEBUG variables that are
merged into DEFINES in default_pre.prf.
Users can unset NDEBUG by writing
DEFINES -= NDEBUG
in their .pro file.
Note that DEFINES_RELEASE and DEFINES_DEBUG are merged in
default_pre.prf in order to give extra compilers (like moc) the chance
to see the fully resolved DEFINES variable. This is different from the
QMAKE_CFLAGS_(DEBUG|RELEASE) variables that get merged in default_post.prf.
Fixes: QTBUG-78071
Change-Id: I381770a1d2f974fbae9b09a2254e3f2fc7842b68
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Diffstat (limited to 'qmake/doc')
-rw-r--r-- | qmake/doc/src/qmake-manual.qdoc | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/qmake/doc/src/qmake-manual.qdoc b/qmake/doc/src/qmake-manual.qdoc index 3495f97b2c..a388b89477 100644 --- a/qmake/doc/src/qmake-manual.qdoc +++ b/qmake/doc/src/qmake-manual.qdoc @@ -1144,6 +1144,26 @@ \snippet code/doc_src_qmake-manual.pro 27 + \target DEFINES_DEBUG + \section1 DEFINES_DEBUG + + Specifies preprocessor defines for the debug configuration. The values of + this variable get added to \l{DEFINES} before the project is loaded. This + variable is typically set in \l{#QMAKESPEC}{qmake.conf} and rarely needs + to be modified. + + This variable was introduced in Qt 5.13.2. + + \target DEFINES_RELEASE + \section1 DEFINES_RELEASE + + Specifies preprocessor defines for the release configuration. The values of + this variable get added to \l{DEFINES} before the project is loaded. This + variable is typically set in \l{#QMAKESPEC}{qmake.conf} and rarely needs + to be modified. + + This variable was introduced in Qt 5.13.2. + \target DEF_FILE \section1 DEF_FILE |