From 10c4a4b4bdfdd468e52ae0fbbf84c77b64df2f8f Mon Sep 17 00:00:00 2001 From: Ahmad Samir Date: Fri, 3 Dec 2021 22:33:28 +0200 Subject: WIP: Change the build system to enable building with Qt 6 This was built with: -DQT_MAJOR_VERSION=6 \ -DEXCLUDE_DEPRECATED_BEFORE_AND_AT=5.90.0 \ -DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055a00 Move the include(KDEInstallDirs) call before the first find_package(Qt*, the former is what auto-detects the Qt version, and defaults to 5. This is needed to be able to build against Qt5 by default. All unit tests still pass. --- src/qml/CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/qml') diff --git a/src/qml/CMakeLists.txt b/src/qml/CMakeLists.txt index 1cdae88a..17f90ad0 100644 --- a/src/qml/CMakeLists.txt +++ b/src/qml/CMakeLists.txt @@ -16,7 +16,7 @@ ecm_generate_export_header(KF5ConfigQml target_link_libraries(KF5ConfigQml PUBLIC KF5::ConfigCore # KCoreConfigSkeleton, in ConfigPropertyMap - Qt5::Qml + Qt${QT_MAJOR_VERSION}::Qml ) set_target_properties(KF5ConfigQml PROPERTIES VERSION ${KCONFIG_VERSION} SOVERSION ${KCONFIG_SOVERSION} @@ -29,11 +29,11 @@ ecm_generate_headers(KConfigQml_HEADERS REQUIRED_HEADERS KConfigQml_HEADERS ) -target_include_directories(KF5ConfigQml INTERFACE "$") +target_include_directories(KF5ConfigQml INTERFACE "$") install(TARGETS KF5ConfigQml EXPORT KF5ConfigTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kconfigqml_export.h ${KConfigQml_HEADERS} - DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KConfigQml COMPONENT Devel + DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/KConfigQml COMPONENT Devel ) -- cgit v1.2.1