Commit Graph

12 Commits

Author SHA1 Message Date
Stephen Kelly
91720b5bc2 Move the macros for invoking ctest to a shared location.
They are still internal, but all Qt5 modules will be able to use
them then.

Change-Id: I42ab656115b0976ca959293dfd664ec071f35dbf
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-07-03 01:08:25 +02:00
Stephen Kelly
3d2a8d09d1 Add a variable for the private includes for modules.
This is required to use QPA for example in 5.0.

Change-Id: I44bfc6987d778370e55c05c591f63ff84c482d0a
Reviewed-by: David Faure <faure@kde.org>
2012-06-23 14:16:24 +02:00
Stephen Kelly
2af438a6ce Give the CMake unit tests more meaningful names.
Change-Id: I0a54d32ec62ff6daf7672d0aabdeb038f4c7c78f
Reviewed-by: David Faure <faure@kde.org>
2012-06-23 11:37:49 +02:00
Stephen Kelly
ddf5226bd7 Forward-port change to QT4_ADD_RESOURCES macro for missing rcc files.
Forward-port of commit 9ce67d30011db4528d3d0bbee36412e13cfb80cc in
cmake.git.

Change-Id: I2d6c14f68f1630fc0835b3103e5058f52c2d0d13
Reviewed-by: David Faure <faure@kde.org>
2012-06-23 11:37:39 +02:00
Stephen Kelly
f16a77d783 Use IF(NOT TARGET ...) before creating imported targets.
Initially we didn't do this because someone could accidentally create
another target of a conflicting name, and used a variable to store whether we
have created the target already or not.

That wasn't adequeate to deal with finding the package in a scope
like a function, so we used a directory property. However, the directory
property is not valid in the same scopes as the defined target. For
example, finding a Qt module in both a directory and a subdirectory causes
a conflict.

As it is already unlikely that a target would be accidentally created with
a name like Qt5::Core, we should simply use the IF(TARGET) form.

Change-Id: If64f25d45f51edcd1edb0d4bfb5ed3bb2479bd27
Reviewed-by: David Faure <faure@kde.org>
2012-05-15 23:03:23 +02:00
Stephen Kelly
c2f8fe64f1 Make the qt5_use_modules public API.
This cmake function handles all of the necessary logic for using the
include directories of Qt modules, linking to Qt modules, adding
the required definitions, and most importantly, adding the position
independent flags required on UNIX systems to use Qt by default.

The function relies on functionality available in CMake 2.8.8, so it
is only available if that version of CMake or greater is used.

Change-Id: Ibe698e06819129479348c240844264c41553b5fb
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-05-10 23:15:56 +02:00
Stephen Kelly
b4dabb9e50 Revert "Don't use the pri depends line for link dependencies."
This reverts commit df43b9a06a.

Using the same depends information as QMake provides adds a lot of
convenience for users, and is mostly 'correct' from a CMake
point of view anyway.

Change-Id: I8f2a2f74a687c25a0dedcc491ef72ddb5b136090
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-05-03 16:11:58 +02:00
Stephen Kelly
aa17350eb6 Never attempt to run the dbus tests on APPLE.
The Qt buildsystem is creating the config files for it even
when it is not building QtDBus, so Qt5DBus_FOUND = True.

Re-enable the CI testing on mac with this change.

Task-number: QTBUG-25522

Change-Id: I5d2690d17fde6c5aabcbdd3e2eef9f0846edd97d
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-05-01 07:10:23 +02:00
Stephen Kelly
eddb8bc3e5 Simplify the cmake version check.
Change-Id: Ifdd89397f88b090a6b43d40636dbeac029faaed8
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-29 14:05:39 +02:00
Stephen Kelly
4490681459 Add some more useful output when about the cmake version
Change-Id: I58efa1f295dbc652b1882937ca27ea52d9f4a923
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-29 11:48:02 +02:00
Stephen Kelly
4deaef6979 Run DBus tests only if QtDBus is found.
It's not enough to check for UNIX because Qt may have been configured
without dbus, or we could be running on APPLE (on which DBus is not
commonly installed).

Change-Id: Ic57200dad42c0c12b292d1066f799c827294fe9a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-04-24 17:29:42 +02:00
Stephen Kelly
61c433785e Move the CMake unit tests to auto/
This will allow the CI system to run the tests. The tests are only
run if cmake is found.

Change-Id: Ie73a56114c151871160bafcbf0b90b2d54620855
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
2012-04-23 17:03:56 +02:00