diff --git a/bin/qt-cmake-standalone-test.in b/bin/qt-cmake-standalone-test.in index fce287ac946..91413b21ebb 100755 --- a/bin/qt-cmake-standalone-test.in +++ b/bin/qt-cmake-standalone-test.in @@ -1 +1,3 @@ +@__qt_cmake_standalone_test_os_prelude@ + @__qt_cmake_private_path@ @__qt_cmake_standalone_test_path@ -DQT_STANDALONE_TEST_PATH=@__qt_cmake_standalone_passed_args@ diff --git a/cmake/QtBaseGlobalTargets.cmake b/cmake/QtBaseGlobalTargets.cmake index 355a24eaed7..ec171641533 100644 --- a/cmake/QtBaseGlobalTargets.cmake +++ b/cmake/QtBaseGlobalTargets.cmake @@ -239,9 +239,11 @@ if(QT_WILL_INSTALL) "${__qt_cmake_standalone_test_path}") endif() if(UNIX) + set(__qt_cmake_standalone_test_os_prelude "#!/bin/sh") string(PREPEND __qt_cmake_private_path "exec ") set(__qt_cmake_standalone_passed_args "\"$@\" -DPWD=\"$PWD\"") else() + set(__qt_cmake_standalone_test_os_prelude "@echo off") string(APPEND __qt_cmake_standalone_test_bin_name ".bat") string(APPEND __qt_cmake_private_path ".bat") set(__qt_cmake_standalone_passed_args "%* -DPWD=\"%CD%\"")