summaryrefslogtreecommitdiffstats
path: root/cmake
Commit message (Collapse)AuthorAgeFilesLines
* cmake: find gtk3 and build the gtk3 platformthemeAlbert Astals Cid2019-02-111-0/+3
| | | | | Change-Id: I7db7321a2fd5ea0eda1924f3dece3b1c86d87d10 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* cmake: Find tslib and build the tslib plugin if foundAlbert Astals Cid2019-02-111-0/+3
| | | | | Change-Id: I7119ddf473a3ede29bbfef23cffb08a4fcbd5681 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* cmake: QtFeature: Do not error out when using QtKevin Funk2019-02-111-2/+2
| | | | | | | | ... outside of qtbase.git Change-Id: I1895ef07c881766e2b28839d0422916b6916e10e Reviewed-by: Jean-Michaël Celerier <jean-michael.celerier@kdab.com> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* cmake: Make find_package(Qt5 ...) work properlyKevin Funk2019-02-114-45/+72
| | | | | | | | | | | | | Introduce a new cached variable INSTALL_CMAKE_NAMESPACE for defining the prefix used for CMake config files (c.f. "${PREFIX}Core/${PREFIX}CoreConfig.cmake") Also make sure to `find_dependency(...)` the required packages inside the individual CMake config files. I.e. in Qt5WidgetsConfig.cmake, search for Qt5Core, etc. pp.. Change-Id: Idc027925fe9d5323091c4853803ad5ce44b1afc6 Reviewed-by: Jean-Michaël Celerier <jean-michael.celerier@kdab.com> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* cmake: Parse SYNCQT.INJECTIONSKevin Funk2019-02-111-1/+28
| | | | | | | | | Allows to install headers such as QtCore/qtconfig.h, QtGui/qvulkanfunctions.h, etc. Change-Id: I93f384cdc8bbee07fab316d7e232aae1d209f33e Reviewed-by: Jean-Michaël Celerier <jean-michael.celerier@kdab.com> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: we need to find for libudev not udevAlbert Astals Cid2019-02-111-1/+1
| | | | | Change-Id: I36bac8c01d8de2b151c3d4d89607d26ac8add3d2 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: QtFeature add debugging aidKevin Funk2019-02-111-1/+1
| | | | | | | Persist the target name in the CMake cache description Change-Id: I124a8b89e5845d12301993b0546c8d5c91b8d8bb Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: Do not rerun try_compile invocationsKevin Funk2019-02-111-0/+4
| | | | | Change-Id: I5eccf9f810d7ee55a311884bd5cf483f8086bae6 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Allow passing libraries to qt_config_compile_testAlbert Astals Cid2019-02-111-2/+5
| | | | | | | | Fixes cxx11_future and ipc_posix tests Change-Id: I0f3a7b1a0452724c07198a87c2fc25344e7451eb Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* cmake: Only use the doubleconversion cmake config if "valid"Albert Astals Cid2019-02-011-1/+3
| | | | | | | | | And by "valid" i mean if it returns the double-conversion::double-conversion target that we are going to use later. Fedora rawhide has a doubleconversion cmake config file but it doesn't define any target Change-Id: Ib0360bc9fdf593a14510c9a2d59b47b32bc4b356 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: Introduce QT_HAS_NAMESPACETobias Hunger2019-01-311-0/+5
| | | | | | | This makes testing for Qt with namespace builds easier in extend_target. Change-Id: I58ab985a2ed39859fb65d35f8f69065fed2a5c9b Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add FindZSTD.cmake and wire it up in configurejson2cmake.pyTobias Hunger2019-01-311-0/+49
| | | | | | | Zstd is used in the dev branch, so prepare for it. Change-Id: I130d98e3888a1eb4c7444728fc5088c5dae9d911 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Use FindGLIB2 from cmake-extra-modulesTobias Hunger2019-01-312-3/+101
| | | | | | | Use FindGLIB2 from cmake-extra-modules over hand-rolled own version. Change-Id: I1f8e055bc12dd728c033fd88480690643d90159a Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add debugging support for extend_target(...) callsTobias Hunger2019-01-311-0/+9
| | | | | | | | Enable a flag so that cmake documents which extend_target calls it acts upon and which ones are skipped. Change-Id: I1e2d4da47b93d6b5d7b7ec25b7bc6341f38b3dca Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* CMake: pro2cmake.py: Pass QMAKE_MOC_OPTIONS on to CMakeTobias Hunger2019-01-311-1/+7
| | | | | Change-Id: I39c1b0aedbffaa29a34253e0c1c4bb4a4dddbe98 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* CMake: pro2cmake.py: Convert more settings from .pro-file to CMakeTobias Hunger2019-01-311-2/+18
| | | | | | | Convert QMAKE_USE, QMAKE_CXX_FLAGS and QMAKE_LFLAGS into CMake. Change-Id: I53a5b91664b6ab71892d4381c00f8d744d7d7abd Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* cmake: test: Enable the build of qdbusabstractinterfaceAlbert Astals Cid2019-01-301-8/+14
| | | | | | | | | | | Since the code wants pinger_interface.h as include name and the qt_create_qdbusxml2cpp_command function was using the filename as source for the next filename i introduced a new option DBUS_ADAPTOR_BASENAME/DBUS_INTERFACE_BASENAME to set the name of the resulting file Change-Id: I582d578b68275e4530e91a88631ae43fd1ae06fd Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* cmake: Add trivial FindLibproxy.cmakeAlbert Astals Cid2019-01-291-0/+3
| | | | | | | And fix link to it Change-Id: Ie4f29a35a83d19ab83933faf3bcd7d62cffa68b8 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Store Qt features in CMake CacheTobias Hunger2019-01-173-82/+34
| | | | | | | | | | This is less self-contained than what we have, but significantly speeds up cmake configure/generate runs. This patch also warns when a feature is already defined. Change-Id: I8cab63e208ba98756b47d362a39b462f5ec55e20 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: QtFeature optimizationTobias Hunger2019-01-171-2/+0
| | | | | | | Remove some unnecessary sorting, speeding up cmake by about 10s on my machine Change-Id: Ieafbd16f6dd8cfe6d1af3c739bfe58e8bf724441 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Error out on mis-use of qt_pull_features_into_current_scopeTobias Hunger2019-01-171-1/+4
| | | | | | | Make it a bit harder to mis-use qt_pull_features_into_current_scope. Change-Id: I2a6be28d7c0e6207217cb1908ec22cc757acd01a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Introduce Qt::GlobalConfig to hold the global featuresTobias Hunger2019-01-174-22/+37
| | | | | | | | This simplifies the handling of features a bit as it removes the special code to store two sets of features in Qt::Core. Change-Id: I536d41cfc76a02af054e3cfbad6bda50b1e9e49a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Check for visibility onceTobias Hunger2019-01-161-5/+6
| | | | | Change-Id: I5c729f4509eed16409df5eb048afb7f60c5ca57c Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: update README.mdLiang Qi2019-01-161-2/+3
| | | | | | | Because AUTOMOC/AUTOUIC/AUTORCC got merged into master. Change-Id: I0ddfd4443a9892fae1dca54d75b97af4c69ad7ef Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Remove one unnecessary feature push into parent scopeTobias Hunger2019-01-141-2/+0
| | | | | | | | During qt_feature_begin_module no features are changed, so there is no need to push features. Change-Id: Id7ebcfad373caa284e790b7eb0a178eaa72216e5 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Use AUTOMOC/AUTOUIC/AUTORCCTobias Hunger2018-12-1413-363/+31
| | | | | Change-Id: I0235ca4f227623e5937348b4b010637921dbf154 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Get rid of useless underscores in QtFeature.cmakeTobias Hunger2018-12-141-102/+101
| | | | | Change-Id: I87eb55ed2ce01ab136dac3e2a587b43bd3f8a98e Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: SimplifyTobias Hunger2018-12-141-94/+54
| | | | | | | | | | | * Only import features once * Move Core specific code into its CMakeLists.txt file * More consistently use target names like "Core" to refer to "Qt modules". We tend to require either "Core" or "QtCore" in places, which I find confusing. Change-Id: Id54161bc5468412750cb9eb7eeb15de3812e8a09 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Merge qt_internal_module_include_dir and qt_internal_module_infoTobias Hunger2018-12-143-48/+45
| | | | | | | | | ... and fix the fallout of this change. It results in more targets being passed overall (instead of a strange mix of targets and module names), so this is a good thing(TM). Change-Id: I1c4326b80e2c6675356587879ec8471ef7249a50 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: Unify creation of target aliasesTobias Hunger2018-12-141-11/+23
| | | | | | | | For Qt6 we want to have Qt6::foo and Qt::foo. Enable that consistently. Change-Id: I3cf05c4171b13029bf508d307945e8be4687e86b Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
* CMake: Refactor qt module name related codeTobias Hunger2018-12-141-22/+33
| | | | | Change-Id: Ib14c030ef6d2e988aaaebca354cf1a6881e05e25 Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
* Prefer qt_internal_ over _qt_ for internal functionsTobias Hunger2018-12-141-3/+2
| | | | | | Change-Id: Idb6f3d8f29890bb4d8f0d1d644c0d1103342946a Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io>
* CMake: Unify on variable names without _ in functionsTobias Hunger2018-12-141-141/+140
| | | | | | Change-Id: I28883775d8f9bd718de477c03628b291972f4590 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io>
* CMake: Do less feature-pushingTobias Hunger2018-11-221-2/+7
| | | | | | | | | | Do not try to push features up into the parent scope if none were added. This avoids a lot of iterations over all defined variables. Change-Id: Idb9a4c86643c0ca773584a05b3a0590cfab7514d Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Simplify registration of known Qt targetsTobias Hunger2018-11-221-4/+6
| | | | | Change-Id: Ibd7b5f628c0a1a3087bdfebb0c35242b42c5e938 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add simple test for moc handling and fix the implementationTobias Hunger2018-11-227-64/+88
| | | | | | | | Add a simple test for moc-file handling and fix the implementation to make the test pass. Change-Id: I34e8d65a5e01a6f557d3a3d8cb262fd147ad78e4 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add test for QRC and make it passTobias Hunger2018-11-225-21/+55
| | | | | | | | Add a test for QRC file handling in cmake and fix the qrc file handling to handle qrc files in subfolders properly. Change-Id: Iff4224e59e7ee1badacce5fc00dbf68aef69bffe Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add test for uic handlingTobias Hunger2018-11-227-20/+98
| | | | | | | Add a test for uic handling and make it pass. Change-Id: I7e11f9f1fba0e40c748e3590a0d0cbb72c9ebc28 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add macro to generate cmake build-only testsTobias Hunger2018-11-223-22/+40
| | | | | | | | | | | In addition to cmake tests that run cmake, build and then run the tests of that project, also add a macro for tests that only run cmake. Use this new kind of test for the existing tests. Change-Id: I465600974ed4114e724988b309404ccd3db2e0cb Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Simplify qt_make_output_fileTobias Hunger2018-11-223-24/+44
| | | | | | | Simplify qt_make_output_file and add a simple test for it. Change-Id: I87694291cd877545ade5d9c42d1424d7b3b7b567 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Fix cmake test for featuresTobias Hunger2018-11-223-5/+7
| | | | | | | | | Features are now always defined (to OFF) when they are not emitted. Adapt the test for that. Change-Id: Id5f662f07fea15c22027b9b00d1b53a288b4a0dc Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add option to run cmake build testsTobias Hunger2018-11-224-0/+37
| | | | | | | | Use "cmake -DBUILD_CMAKE_TESTING=ON" to enable running cmake build system tests with ctest. Change-Id: I0a32e2d1771c9bbb0df013d0d955a9b58b1d4b79 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add FindSlog2Tobias Hunger2018-11-061-0/+19
| | | | | | | Add FindSlog2 and use it in src/corelib/configure.cmake. Change-Id: I7e6a696a49df568a41ed1224228ab608db2dbb0e Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Improve handling of the different kinds of iconvTobias Hunger2018-11-061-1/+3
| | | | | | | | | Improve conditions/enable/disable conditions for iconv related features. These are detected a bit different from what qmake does, so adapt to that. Change-Id: I7b3e4baf05dc324507f370d7f651a62f29e42a98 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Add FindPPS and use it in src/corelib/configure.cmakeTobias Hunger2018-11-061-0/+19
| | | | | | | | Find the PPS library and use the result PPS_FOUND in configure.cmake where needed. Change-Id: I08d3ace421278dc0ae5c3128d4234e6bca906c05 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Find librtTobias Hunger2018-11-061-0/+27
| | | | | Change-Id: Ibc39ba7a385146cd0428b78e12a793f0ddbfae91 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Fix import of features while generating CMakeListsMikhail Svetkin2018-11-061-4/+7
| | | | | | | | | | extend_target does not import public and private features. For example: Qt::CorePrivate matches as ('CorePrivate'), but it should be ('Core', 'Private') Change-Id: I99144d42b7e0a8f7c4501d3e0eaf04b270c6b4d6 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: Fix import of featuresTobias Hunger2018-11-051-6/+6
| | | | | | | | | | | Make sure the features of Qt libraries are available when linking to that library via the add_qt_* functions. This was broken for any library that did not end with "Privat" or "Private". Change-Id: Iff0ad441b601e0d131b0e30f2069110806410297 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: Simplify Feature handlingTobias Hunger2018-11-052-50/+30
| | | | | | | | Simplify the scope handling of features by providing a function that just pushes all QT_FEATURES into the parent scope. Use it. Change-Id: Ic6552fe495394d73fcec6becf6852745ec2d6d59 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* QtFeature: (Re-)evaluate QT_FEATURES based on cached valuesTobias Hunger2018-11-051-5/+42
| | | | | | | | (Re-)evaluate QT_FEATURE_* based on the corresponding cache values named FEATURE_*. Change-Id: I57e76af90221937e45979a6d0c366923983ca7d5 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>