diff options
author | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2016-10-24 21:04:37 +0200 |
---|---|---|
committer | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2016-10-26 10:44:56 +0000 |
commit | dde20de1baa682237acd98aec22ca22e469b9a91 (patch) | |
tree | 63fa00d43da684aabde76c1bb544ca0e2cc3c3bb /qmake/generators/projectgenerator.cpp | |
parent | aa60e2d7778ff353db17b5d2d6899d3088e1f507 (diff) |
qmake project generator: enable deprecation warnings
Following the discussion at QtCS 2016 about deprecated APIs,
let's enable the warnings by default.
Change-Id: I73fe63de3e4f755067100320d7497b6b227549b6
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Diffstat (limited to 'qmake/generators/projectgenerator.cpp')
-rw-r--r-- | qmake/generators/projectgenerator.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/qmake/generators/projectgenerator.cpp b/qmake/generators/projectgenerator.cpp index e45217cb45..790de30a0c 100644 --- a/qmake/generators/projectgenerator.cpp +++ b/qmake/generators/projectgenerator.cpp @@ -344,6 +344,17 @@ ProjectGenerator::writeMakefile(QTextStream &t) << getWritableVar("CONFIG_REMOVE", false) << getWritableVar("INCLUDEPATH") << endl; + t << "# The following define makes your compiler emit warnings if you use\n" + "# any feature of Qt which as been marked as deprecated (the exact warnings\n" + "# depend on your compiler). Please consult the documentation of the\n" + "# deprecated API in order to know how to port your code away from it.\n" + "DEFINES += QT_DEPRECATED_WARNINGS\n" + "\n" + "# You can also make your code fail to compile if you use deprecated APIs.\n" + "# In order to do so, uncomment the following line.\n" + "# You can also select to disable deprecated APIs only up to a certain version of Qt.\n" + "#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0\n\n"; + t << "# Input" << "\n"; t << getWritableVar("HEADERS") << getWritableVar("FORMS") |