summaryrefslogtreecommitdiffstats
path: root/src/tools/bootstrap/CMakeLists.txt
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2022-04-20 09:33:47 +0200
committerJoerg Bornemann <joerg.bornemann@qt.io>2022-04-21 20:35:24 +0200
commit80a8ead08d1fea926850d1da61f693dfe26ed5b0 (patch)
tree8a94e3ef3411050538c7c593f06956e600a149e9 /src/tools/bootstrap/CMakeLists.txt
parent86321a0debe2961f134a815c8f2ae82b075cc014 (diff)
Fix unresolved include in bootstraplib when using source copies
When QT_USE_BOOTSTRAP_SOURCE_COPY is ON, there are situations where includes like "../../3rdparty/sha1/sha1.cpp" in qcryptographichash.cpp cannot be resolved. For example, out-of-source MSVC builds are affected. In-source builds are working by accident, because we're adding the include path "<qtbase-build-dir>/src/corelib/global", and <qtbase-build-dir> is <qtbase-source-dir>. Linux/macOS builds are working by accident, because we're adding the include path "<qtbase-source-dir>/src/3rdparty/forkfd". Fix this by explicitly adding the directory where qcryptographichash.cpp resides to INCLUDE_DIRECTORIES. This amends commit 743bb66744e762d10754426e43d42b24cc7bff0f. Fixes: QTBUG-102720 Change-Id: I55fcc186ea4c81134c39023ced3f04458230109b Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'src/tools/bootstrap/CMakeLists.txt')
-rw-r--r--src/tools/bootstrap/CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/tools/bootstrap/CMakeLists.txt b/src/tools/bootstrap/CMakeLists.txt
index 51a8737860..be5c620646 100644
--- a/src/tools/bootstrap/CMakeLists.txt
+++ b/src/tools/bootstrap/CMakeLists.txt
@@ -154,6 +154,10 @@ qt_internal_extend_target(Bootstrap
## Scopes:
#####################################################################
+qt_internal_extend_target(Bootstrap CONDITION QT_USE_BOOTSTRAP_SOURCE_COPY
+ INCLUDE_DIRECTORIES "${QtBase_SOURCE_DIR}/src/corelib/tools" # for qcryptographichash.cpp
+)
+
qt_internal_extend_target(Bootstrap CONDITION UNIX
SOURCES
../../corelib/io/qfilesystemengine_unix.cpp