diff options
author | Simon Hausmann <simon.hausmann@qt.io> | 2019-05-29 16:05:52 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@qt.io> | 2019-05-29 14:21:48 +0000 |
commit | c9651374486e49a7bce40ac7fefef1ec74b1c1cc (patch) | |
tree | 1ffac22f5c76c41ddfac34b3912bc1cfbc35442b | |
parent | c9c5ca99973e5145f8ecd3759fa00994e41a4904 (diff) |
Fix build against sysroots
Toolchain files from sysroots (such as Yocto or Android) typically set
the CMAKE_FIND_ROOT_PATH_MODE_PACKAGE to ONLY to ensure that no external
packages are accidentally found. Similar to how we discover the Qt tools
packages for cross-compiling, we need to temporarily change the mode to
BOTH to locate our build internals.
Change-Id: Ib4374ee4a974379213218b7ec430637857ed02e7
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
-rw-r--r-- | CMakeLists.txt | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index f0a8ef2a96..d70beff2e9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,7 +18,7 @@ list(APPEND CMAKE_MODULE_PATH list(APPEND CMAKE_PREFIX_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake" ) -find_package(QtBuildInternals) +find_package(QtBuildInternals CMAKE_FIND_ROOT_PATH_BOTH) qt_build_repo_begin(SKIP_CMAKE_MODULE_PATH_ADDITION) |