summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2022-11-29 10:17:07 +0100
committerJoerg Bornemann <joerg.bornemann@qt.io>2022-12-01 08:53:28 +0100
commit34d7dd908e135ce2036c4fa7ce3e2099174d4e8c (patch)
tree392b4bfa6dd22a18bbb96cbe4147b0fb37f7d80d /src
parent84c76d6205c26e27a59bebcabb78d95a0891ce79 (diff)
CMake: Fix configuring Qt with CMake < 3.21 and missing patchelf
Turn the FATAL_ERROR into a WARNING and explain what patchelf would be used for. Also, store the patchelf executable just as "patchelf" if it could not be found. Now it's possible to install patchelf after configuring a project. Fixes: QTBUG-109004 Change-Id: I1e89b4c5851f341e000e563d1437398b454c68f7 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/corelib/Qt6CoreMacros.cmake6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/corelib/Qt6CoreMacros.cmake b/src/corelib/Qt6CoreMacros.cmake
index baf8fcb5784..bb7df5ed46a 100644
--- a/src/corelib/Qt6CoreMacros.cmake
+++ b/src/corelib/Qt6CoreMacros.cmake
@@ -2518,8 +2518,10 @@ function(_qt_internal_setup_deploy_support)
if(QT_DEPLOY_USE_PATCHELF)
find_program(QT_DEPLOY_PATCHELF_EXECUTABLE patchelf)
if(NOT QT_DEPLOY_PATCHELF_EXECUTABLE)
- message(FATAL_ERROR "The patchelf executable could not be located. "
- "Please install patchelf or upgrade CMake to 3.21 or newer.")
+ set(QT_DEPLOY_PATCHELF_EXECUTABLE "patchelf")
+ message(WARNING "The patchelf executable could not be located. "
+ "To use Qt's CMake deployment API, install patchelf or upgrade CMake to 3.21 "
+ "or newer.")
endif()
endif()
endif()