summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/spec_pre.prf
Commit message (Collapse)AuthorAgeFilesLines
* Distinguish between Objective-C and Objective-C++ sourcesTor Arne Vestbø2015-10-091-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of lumping both Objective-C (.m) and Objective-C++ (.mm) sources into the same pile, passing them on to the same compiler as for C++ (CXX), with the C++ flags (CXXFLAGS), we follow Apple's lead and treat them as variants of the C and C++ languages separately, so that Objective-C sources are built with CC and with CFLAGS, and Objective-C++ sources with CXX, and CXXFLAGS. This lets us remove a lot of duplicated flags and definitions from the QMAKE_OBJECTIVE_CFLAGS variable, which in 99% of the cases just matched the C++ equivalent. The remaining Objective-C/C++ flags are added to CFLAGS/CXXFLAGS, as the compiler will just ignore them when running in C/C++ mode. This matches Xcode, which also doesn't have a separate build setting for Objective-C/C++ flags. The Makefile qmake generator has been rewritten to support Objective-C/C++ fully, by not assuming that we're just iterating over the C and C++ extensions when dealing with compilation rules, precompiled headers, etc. There's some duplicated logic in this code, as inherent by qmake's already duplicated code paths, but this can be cleaned up when C++11 support is mandatory and we can use lambda functions. Task-number: QTBUG-36575 Change-Id: I4f06576d5f49e939333a2e03d965da54119e5e31 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
* make QMAKE_CXX/CROSS_COMPILE verification work under windowsOswald Buddenhagen2015-04-211-4/+10
| | | | | | | | | | | | | | | automatically append the .exe extension. this is done unconditionally, which means that providing it in the spec is wrong by definition. don't use system("which") (which won't do what we want in a windows shell), but scan PATH ourselves. as a bonus, this is also faster. to avoid fetching and splitting the path multiple times, factor out a function in spec_pre.prf. Change-Id: I95f0fa285c158b347d45422111f91540e3a595fd Reviewed-by: Jochen Seemann <seemann.jochen@gmail.com> Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
* add some docu about the project loading sequenceOswald Buddenhagen2012-12-131-0/+4
| | | | | Change-Id: Icb6bb58247724aeb6b9433a8d032718f1ba4babe Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* centralize initialization of CONFIG in mkspecsOswald Buddenhagen2012-09-081-0/+1
| | | | | | | | "CONFIG += qt warn_on release link_prl" is in every single spec (though for link_prl there is one genuine exception and two apparent omissions). Change-Id: I72e1e315586af828eefa3b0b70998ab892ec3c1a Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* centralize initialization of QT in specsOswald Buddenhagen2012-09-081-0/+2
| | | | | | | | there is no reason whatsoever to duplicate this so many times, and even less reason to have specs with a deviating default. Change-Id: Ia25836c079580adebc373697b8bd03598f79c69b Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* fix splitting of $PATH when looking for sh.exeOswald Buddenhagen2012-07-121-1/+2
| | | | | | Change-Id: I1ec0a48879d6ba7c0e2e7fdc0939980d0f817a68 Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* move initialization of numerous variables to spec_pre.prfOswald Buddenhagen2012-06-271-0/+39
this is cleaner by design and allows removing some hacks. Change-Id: I3270195b5d62caa476ffde7c1e1ef43cec99c565 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>