summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorJonas Kvinge <jonas@jkvinge.net>2022-04-06 21:09:17 +0200
committerJonas Kvinge <jonas@jkvinge.net>2022-04-08 13:03:30 +0200
commit1007aac63a378c1b09f221f9b58b65bb56f9e9e8 (patch)
treed23a5efabe14be89bdf97ff8aa4cf04f7757b0b6 /cmake
parent9ab06e61858e3fb718eb1023f819b8490804f1a1 (diff)
Fix check for pcre2 using cmake
When PCRE2 is compiled using cmake, a pcre2 cmake file is installed and Qt fails to configure because components isn't specified for find_package. In recent PCRE2 releases components needs to be specified for find_package. Fixes: QTBUG-102358 Pick-to: 6.2 6.3 Change-Id: Ib842b2c4b1c0bf38aa5da5475eaa2b3c56c6b822 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/FindWrapSystemPCRE2.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmake/FindWrapSystemPCRE2.cmake b/cmake/FindWrapSystemPCRE2.cmake
index f8ed5ff7a0..92c6e2a167 100644
--- a/cmake/FindWrapSystemPCRE2.cmake
+++ b/cmake/FindWrapSystemPCRE2.cmake
@@ -4,7 +4,7 @@ if(TARGET WrapSystemPCRE2::WrapSystemPCRE2)
endif()
set(WrapSystemPCRE2_REQUIRED_VARS __pcre2_found)
-find_package(PCRE2 ${${CMAKE_FIND_PACKAGE_NAME}_FIND_VERSION} CONFIG QUIET)
+find_package(PCRE2 COMPONENTS 16BIT ${${CMAKE_FIND_PACKAGE_NAME}_FIND_VERSION} CONFIG QUIET)
set(__pcre2_target_name "PCRE2::pcre2-16")
if(PCRE2_FOUND AND TARGET "${__pcre2_target_name}")