the options may need to take effect before the regular test processing
commences (which is actually going to be the case in the next commit).
the indirection via the callback only obfuscated the code anyway.
Change-Id: I5307b0be15cf4cc2c2db391ce5b5a93f81076b5c
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
this makes it consistent with the determination of the default
include/library paths. this makes sense, as it's possible to switch the
sdk/toolchain after building qt (within reason).
a side effect of this change is that for compilers which emulate other
compilers, both the real and the emulated version are now made
available.
Change-Id: Icfcc672c0d2e3d1b5e622993c366063d70ad327c
Started-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
... where it actually belongs, as it should work in each repo in a
modular build.
Change-Id: I5463f0bcacb239900bed0b0f7be9cf32a3eab04e
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
the qmake bootstrap uses some of the options, so the configures still
read config.opt for their own purposes, but the general handling is
entirely in the new system now.
Change-Id: I2c6c657d4da01c8d520ac74795454747bb224bdd
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
You can place the export macros in the namespace declarations on ELF
systems and that will apply to all declarations inside that scope. If a
namespace is exported like that, then we should mark it for versioning
too.
Note that the exporting doesn't happen for declarations in other scopes
of the same namespace, even though the findclasslist.pl script will mark
everything in that namespace. This should not be a problem.
Task-number: QTBUG-55897
Change-Id: I371f5b01e24a4d56b304fffd147274778b980ad2
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
The feature is enabled by CONFIG += unsupported/objc_namespace,
but can be easily integrated into other build systems such as
CMake or native Xcode by modifying the LD and LDFLAGS equivalent
for each build system.
This is a less resource-intensive alternative to using multiple
Qt builds with different -qtnamespace settings.
Note: The feature is not supported in any way, and should be
used with care.
Change-Id: Ibb8ba1159db36efd7106c117cc2210c7e2e24784
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Not that we require it, but since The Qt Company did it for all files
they have copyright, even if they haven't touched the file in years
(especially not in 2016), I'm doing the same.
Change-Id: I7a9e11d7b64a4cc78e24ffff142b4c9d53039846
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see
http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/
Updated license headers to use new LGPL header instead of LGPL21 one
(in those files which will be under LGPL v3)
Change-Id: I046ec3e47b1876cd7b4b0353a576b352e3a946d9
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
It only needs stdin now, instead of stdin plus a separate file containing
a list of file names.
Change-Id: I9f3db030001e47e4a4e5ffff1425b76884cc7ca0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
CMP0054 changes CMake behavior wrt. interpreting quoted arguments in
if() statements. This change ensures that CMP0054 dev warnings are
never emitted no matter how polluted the environment, e.g. even
if the variable ${5.5.1} is defined and no matter whether CMP0054
is set to OLD, NEW or undefined.
Change-Id: Iee008497b333e2db23fb1adbf8b02252314ffa8a
Reviewed-by: Kevin Funk <kfunk@kde.org>
Reviewed-by: Stephen Kelly <steveire@gmail.com>
Recent versions of Qt have apparently added sufficient numbers of
headers that the command lines used to spawn a custom header-
parsing tool, started overflowing Windows' maximum command-line
length.
This change restructures the mechanism to use a GCC-style command-
line arguments file rather than passing filenames all directly
in the argv[] vector.
Although QNX is the usual ELF target whose cross-build is supported
on Windows, the mechanics introduced in this patch happen to affect
all other ELF Unix systems' builds too.
Change-Id: I5a7383cf9f2ebf9dffde8dbfdcdeca888265e085
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
This way, it's possible to tell which applications and libraries depend
on the Qt private API and of which Qt library. Linux distributions can
use this information to decide which applications need to be recompiled
every time Qt itself is rebuilt.
This is done by scanning all class and struct definitions in the private
headers (we've already got the list from syncqt). I opted to add a new
script instead of modifying syncqt because then this can run in parallel
with the rest of the compilation, as opposed to during qmake
time. Another advantage is that it catches modifications to the headers
in between qmake executions.
Since this is already Unix specific, it should be no problem to use Perl.
This solution is limited to use of non-inline symbols of classes
declared in private headers. It will not catch free variables (such as
qsimd_p.h's qt_cpu_features), use of inlined functions or just plain use
of a class/struct for accessing its data members. However, this is
already better than nothing and should help Linux distributions quite a
lot. And there's no way to catch the latter issue anyway.
Change-Id: I049a653beeb5454c9539ffff13e3fff36400ebbd
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
CMake INTERFACE targets may only have whitelisted properties, and
FRAMEWORK is not in the whitelist in released CMake versions.
Change-Id: I27cd0cfbe1b52f25c91bf1b3c0d55879bed91bdf
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Stephen Kelly <steveire@gmail.com>
As these are a new type, there is no legacy code to support.
Change-Id: Ie5abd353563d68d0449a07e06065f34db805f710
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Test each include file directly, instead of doing a large #include. This
verifies that each header is compilable on its own. One big advantage of
doing it via a special compiler in qmake is that we skip pre-compiled
headers, which has hidden build errors in the past.
This solution is implemented by making syncqt produce a second list of
headers. This list is the same as the list of headers in the source
code to be installed, minus the headers that declare themselves to be
unclean, via the pragma:
#pragma qt_sync_skip_header_check
This mechanism is applied only for public libraries (skipping
QtPlatformSupport, an internal_module).
This test is enabled only for -developer-builds of Qt because it
increases the compilation time.
On QtTest: the library only links to QtCore, but it has two headers that
provide inline-only functionality by including QtGui and QtWidgets
headers (namely, qtest_gui.h and qtest_widget.h). If those two modules
aren't getting compiled due to -no-gui or -no-widgets to configure, we
need to remove the respective headers from the list of headers to be
checked. If they are being built, then we need to make QtTest's build
wait for the headers to be generated and that happens when qmake is
first run inside the src/gui and src/widgets directories.
Change-Id: I57d64bd697a92367c8464c073a42e4d142a9a15f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Require CMake 3.0 if an attempt is made to use a cmake file containing
an INTERFACE library.
If the user is using a CMake version older than 3.0, then exclude INTERFACE
libraries from dependencies of Qt modules. The Qt CI system is running
CMake versions as old as 2.8.11, which makes that the current minimum version.
The only header-only module existing so far is the QtUiPlugin module, which
has been split out from the QtDesigner module. If using CMake 2.8, the
forwarding headers in the QtDesigner module will be used, and the effect
of the split out library will not be seen. If using CMake 3.0, the
split out library is listed as a dependency and its transitive usage
requirements such as the QT_UIPLUGIN_LIB definition are made available.
Change-Id: Iecee3bbc440842dca27dc067f2a31e3526efa01b
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
We have configure -headersclean now
Change-Id: Iaf576b16d7c756a08ec5c3dfa32deaa343e5e029
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Qt copyrights are now in The Qt Company, so we could update the source
code headers accordingly. In the same go we should also fix the links to
point to qt.io.
Outdated header.LGPL removed (use header.LGPL21 instead)
Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing
combination. New header.LGPL-COMM taken in the use file which were
using old header.LGPL3 (src/plugins/platforms/android/extract.cpp)
Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license
combination
Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe
Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
This is needed to ensure that list(REMOVE_DUPLICATES) can work.
Change-Id: I3d992aa244fcdfbda7e3b48ce416e0ba5ffcde96
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
This is necessary so that list(REMOVE_DUPLICATES) works properly.
Change-Id: Id268637d76b1a8785c9ff0c6e09e9ad8a62bbfb6
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
The source includes shouldn't be used by installations, so
don't install the extra file, but only use it if the package
is used from the build-dir.
Task-number: QTBUG-33970
Change-Id: I08f91b8a716e935cb04d1233d44cf5c092e240ce
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
The cmake directory may not be $PREFIX/lib/cmake, but
instead $PREFIX/lib/<arch>/cmake. Getting the PATH of such a
directory will not lead us to $PREFIX/, but to $PREFIX/lib.
Use a relative calculation instead.
Task-number: QTBUG-33223
Change-Id: Ice4e0f859ab1df238bad4eb942f073e84dd86cc3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
This is new in CMake 2.8.12 and replaces the old properties
matching IMPORTED_INTERFACE_LINK_LIBRARIES_<CONFIG>.
Change-Id: I5d4c454972f2535f6792e95718c73d80c56ac24c
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Change-Id: I68d087b15839418008db5bf1c0c76ca303245519
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Some packagers don't want to install the private headers.
Check the existence of private headers only if the 'Private' component
is specified when finding the package.
Task-number: QTBUG-32466
Change-Id: I1fdbfb25e8ce485cd051564b937f766b2733741a
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Google moved dx.bat into a new build-tools/VERSION folder
meaning our dx.bat no longer found dx.jar. Fix this by
passing into our dx.bat, the location of the real dx.bat
Removed hardcoded 17.0.0 and %ANDROID_BUILD_TOOLS_REVISION%
path searches.
Change-Id: I91c12c01745d6f12edbd126102b8f06eba291402
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Change-Id: I840f963c3648d123b31f79aa2c8902c0ad74e982
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
These directories are not currently part of the Qt installation for mac
frameworks.
Task-number: QTBUG-31641
Change-Id: Ifef372cc2ebb692f9ae5a7b1f8dba5f683d1e7eb
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Since the dx tool has moved in the SDK, we need to update our copy
of it to also search in the new location for dx.jar.
Task-number: QTBUG-31405
Change-Id: If093a9f51f33c5d8666919f516a3b336322a7169
Reviewed-by: Ray Donnelly <mingw.android@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Change-Id: If7c724daa85df5e29e410b8deb4e69beb43ee8ea
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Change-Id: I1d745adfbae371f8f1f76e954be98f4c2fd962e0
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
In qtbase commit 7ac58d1ff0 (Make cmake
packages installed to /usr non-relocatable., 2013-02-11), we made
cmake config files non-relocatable if they were installed to
the /usr prefix. That was assumed to mean that this was a distro
or platform package, and was a workaround for the usr-move problem
on Fedora and ArchLinux.
However, cmake bug http://public.kitware.com/Bug/view.php?id=14041
showed that forcing absolute paths in this situation is not desirable
in cross compiling scenarios. CMake commit 6c613b433c45efb0bb013a6bd668cbb8ac740259
(Handle usr-move without forcing absolute paths (#14041), 2013-04-03)
addressed the problem in CMake, and this commit is an equivalent.
Change-Id: I065a6230bc618aa980fae6ca511ae10df4cd62c2
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
The property only needs to contain the direct include dirs of
a target. For example, Qt5::Gui does not need to contain the
include/QtCore directory because it already has Qt5::Core in
its LINK_INTERFACE_LIBRARIES.
Change-Id: I69612f42c29e6056b3d15399498d041d43a0dd6b
Reviewed-by: Brad King <brad.king@kitware.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
These variables are set by the ConfigVersion.cmake file already,
so no need to maintain them manually in the Config file too.
Change-Id: I73d949fb22052f4f6acbc1f70518e73f8fbf7c9c
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Fedora uses configure options to set the install prefix to a location
which does not contain the cmake config files. Rather than finding
dependencies from the installation prefix, find them in sibling directories
instead.
Change-Id: I06974e9655d0dda2a18064d0f9a33997cf2cb2d3
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Need to look in <android-sdk>/platform-tools/lib for dx.jar
Change-Id: I104cf157ce1795e907cca31b37c62163248b8d77
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
There is a bug in dx.bat in the Google Android SDK tool where
relative paths do not work correctly. We need to use our own
version of this tool until:
https://android-review.googlesource.com/#/c/52680/
..is merged.
Change-Id: I451a3239590919d014a673f3e8e17244e96676ab
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Used by features in CMake 2.8.11.
This matches the features in FindQt4 in that version of CMake,
namely that the IMPORTED targets contain the appropriate
INTERFACE_INCLUDE_DIRECTORIES and INTERFACE_COMPILE_DEFINITIONS
and that the qtmain.lib static library is automatically linked to
on Windows by executables. Additionally, the
INTERFACE_POSITION_INDEPENDENT_CODE property is set appropriately
if Qt requires users to use position independent code.
Change-Id: Ide341f43fcaf7d722a7bdf1a12b1071c7e548ccc
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
This will likely fix some odd cmake related tests in the CI.
This reverts commit 316d8ececa.
Conflicts:
mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
src/corelib/Qt5CoreConfigExtras.cmake.in
Change-Id: Ib7714746f96bf12061d92242a42296d200c56c00
Reviewed-by: David Faure (KDE) <faure@kde.org>
This way find_package(Qt5Svg 5.1.0) will require Qt5Core 5.1.0 or later, for
example.
Additionally, forward the EXACT keyword to find_package dependencies
so that find_package(Qt5Svg 5.1.0 EXACT) will reject Qt5Core 5.2.0, for
example.
Change-Id: I302f5a3a683e6c36ef42f1e81c5f7e6258cf5624
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>