summaryrefslogtreecommitdiffstats
path: root/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2020-04-16 20:30:03 +0200
committerAlexandru Croitor <alexandru.croitor@qt.io>2020-04-17 15:59:33 +0200
commitd6272d774c7415186aa398e59f234d0073458072 (patch)
tree5c052e54d31f48f1f58dfd0eb96a4a6b1fe2b684 /cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
parentf4cd66ff0a4da3a9d8a54bc33ecf8bff4002497e (diff)
CMake: Make sure not to use the Qt prefix for standalone tests
We don't want people accidentally installing tests into the Qt prefix. Change-Id: Ic99492559875f753897a83af162253cac846a8a5 Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt')
-rw-r--r--cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt b/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
index a486d1a722..d77192d563 100644
--- a/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
+++ b/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
@@ -6,6 +6,9 @@ find_package(Qt6 REQUIRED COMPONENTS BuildInternals)
# Includes QtSetup and friends for private CMake API.
qt_build_internals_set_up_private_api()
+# Restore original install prefix.
+qt_restore_backed_up_install_prefix()
+
# Find all StandaloneTestsConfig.cmake files, and include them
# This will find all Qt packages that are required for standalone tests.
# It will find more packages that needed for a certain test, but will ensure any test can