summaryrefslogtreecommitdiffstats
path: root/mkspecs/features
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2020-05-05 19:51:50 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2020-05-05 19:51:50 +0200
commit025e88bfe5b2345dd09c173dc28a9d9a45ed11de (patch)
tree0180b9123e479d7114b1caf2022dd8ff69162a17 /mkspecs/features
parentae7e701074be97130aa45f780e2456981850b432 (diff)
parent538223d10d133d23133db1ec7a50cb2775aca657 (diff)
Merge remote-tracking branch 'origin/5.15' into dev
Diffstat (limited to 'mkspecs/features')
-rw-r--r--mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in16
1 files changed, 8 insertions, 8 deletions
diff --git a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
index 309798a767..db18dbece6 100644
--- a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+++ b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
@@ -419,14 +419,6 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
!!ENDIF
!!ENDIF
- # Add a versionless target, for compatibility with Qt6.
- if(NOT \"${QT_NO_CREATE_VERSIONLESS_TARGETS}\" AND NOT TARGET Qt::$${CMAKE_MODULE_NAME})
- add_library(Qt::$${CMAKE_MODULE_NAME} INTERFACE IMPORTED)
- set_target_properties(Qt::$${CMAKE_MODULE_NAME} PROPERTIES
- INTERFACE_LINK_LIBRARIES \"Qt5::$${CMAKE_MODULE_NAME}\"
- )
- endif()
-
!!IF !equals(TEMPLATE, aux)
!!IF !isEmpty(CMAKE_BUILD_IS_FRAMEWORK)
set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} PROPERTY FRAMEWORK 1)
@@ -648,3 +640,11 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
_qt5_$${CMAKE_MODULE_NAME}_check_file_exists(\"${CMAKE_CURRENT_LIST_DIR}/Qt5$${CMAKE_MODULE_NAME}ConfigVersion.cmake\")
endif()
+
+# Add a versionless target, for compatibility with Qt6.
+if(NOT \"${QT_NO_CREATE_VERSIONLESS_TARGETS}\" AND TARGET Qt5::$${CMAKE_MODULE_NAME} AND NOT TARGET Qt::$${CMAKE_MODULE_NAME})
+ add_library(Qt::$${CMAKE_MODULE_NAME} INTERFACE IMPORTED)
+ set_target_properties(Qt::$${CMAKE_MODULE_NAME} PROPERTIES
+ INTERFACE_LINK_LIBRARIES \"Qt5::$${CMAKE_MODULE_NAME}\"
+ )
+endif()