qt5base-lts/qmake
Francois Ferrand fabedd399e Introduce OBJECTIVE_HEADERS
When a ObjC++ QObject subclass is listed in the regular HEADERS, qmake
creates a .cpp file. The moc file will then fail to compile, as it
requries ObjC++ headers. Using Q_FORWARD_DECLARE_OBJC_CLASS() can be
used to let the class be parsed by The compiler, but link will still
fail, as the generated methods (e.g. signals) must be built with ObjC++
compiler, in case they have ObjC parameters:

 Q_FORWARD_DECLARE_OBJC_CLASS(NSString);

 class MyClass: public QObject {
     Q_OBJECT
 signals:
     void objcSignal(NSString * myObj);
 };

The canonical workaround for that is including the .cpp file into the
corresponding .mm file. This also offers a compilation speed advantage,
but is somewhat counter-intuitive.

Therefore, we introduce a separate variable which instructs moc to create
.mm files directly.

Task-number: QTBUG-1581
Change-Id: Ia98af58006efd168ea37f3a63c396979e7e81baa
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2017-08-25 12:15:36 +00:00
..
doc Introduce OBJECTIVE_HEADERS 2017-08-25 12:15:36 +00:00
generators Merge remote-tracking branch 'origin/5.9' into dev 2017-08-15 16:31:48 +02:00
library Merge remote-tracking branch 'origin/5.9' into dev 2017-08-15 16:31:48 +02:00
cachekeys.h Updated license headers 2016-01-21 18:55:18 +00:00
main.cpp Simplify built-in qmake install command 2017-05-04 09:40:48 +00:00
Makefile.unix Move the readlink(2) wrapper to qcore_unix.cpp 2017-07-08 02:18:16 +00:00
Makefile.unix.macos Merge remote-tracking branch 'origin/5.8' into dev 2016-12-13 09:39:20 +01:00
Makefile.unix.mingw configure: put more of the makefile contents into template files 2016-11-23 09:38:14 +00:00
Makefile.unix.unix Move the readlink(2) wrapper to qcore_unix.cpp 2017-07-08 02:18:16 +00:00
Makefile.unix.win32 QFileSystemEngine: Remove the remainder of Windows XP functions 2017-07-25 01:01:02 +00:00
Makefile.win32 QFileSystemEngine: Remove the remainder of Windows XP functions 2017-07-25 01:01:02 +00:00
meta.cpp qmake: eradicate Q_FOREACH loops [needing qAsConst()] 2016-01-28 20:25:18 +00:00
meta.h Updated license headers 2016-01-21 18:55:18 +00:00
option.cpp Mark an unlikely test as such and condition in positive order 2017-07-07 18:09:44 +00:00
option.h bump qmake version 2016-11-15 22:43:51 +00:00
project.cpp qmake: use new QString::arg(QStringView) overload 2017-04-07 18:33:23 +00:00
project.h Merge remote-tracking branch 'origin/5.7' into dev 2016-07-19 20:14:40 +02:00
property.cpp move generation of qconfig.cpp (and qt.conf) to qmake-based configure 2016-12-13 18:56:12 +00:00
property.h move generation of qconfig.cpp (and qt.conf) to qmake-based configure 2016-12-13 18:56:12 +00:00
qmake_pch.h Updated license headers 2016-01-21 18:55:18 +00:00
qmake-aux.pro revert to building qmake with qconfig.cpp 2017-01-06 20:09:08 +00:00
qmake.pri QFileSystemEngine: Remove the remainder of Windows XP functions 2017-07-25 01:01:02 +00:00
qmake.pro configure: delete some dead code and outdated comments 2016-11-23 09:38:09 +00:00