summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CXXModules
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2023-09-26 13:40:25 (GMT)
committerBen Boeckel <ben.boeckel@kitware.com>2023-09-26 14:40:09 (GMT)
commit3b632f32fae72ab70f752dd1e22ced40b7a81537 (patch)
treed3bfe5b49f4c8533a4f20e5acdaffe8bae1262e7 /Tests/RunCMake/CXXModules
parent5ab6b09691ecd082e385493cdc6c24304d195150 (diff)
downloadCMake-3b632f32fae72ab70f752dd1e22ced40b7a81537.zip
CMake-3b632f32fae72ab70f752dd1e22ced40b7a81537.tar.gz
CMake-3b632f32fae72ab70f752dd1e22ced40b7a81537.tar.bz2
Tests/CXXModules: forward the default build type
Windows defaults the build type to `Debug` while other platforms have an empty string.
Diffstat (limited to 'Tests/RunCMake/CXXModules')
-rw-r--r--Tests/RunCMake/CXXModules/NinjaDependInfoBMIInstall-check.cmake3
-rw-r--r--Tests/RunCMake/CXXModules/NinjaDependInfoExport-check.cmake3
-rw-r--r--Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake3
-rw-r--r--Tests/RunCMake/CXXModules/compiler_introspection.cmake1
4 files changed, 10 insertions, 0 deletions
diff --git a/Tests/RunCMake/CXXModules/NinjaDependInfoBMIInstall-check.cmake b/Tests/RunCMake/CXXModules/NinjaDependInfoBMIInstall-check.cmake
index 222cb6b..6de2e1e 100644
--- a/Tests/RunCMake/CXXModules/NinjaDependInfoBMIInstall-check.cmake
+++ b/Tests/RunCMake/CXXModules/NinjaDependInfoBMIInstall-check.cmake
@@ -24,6 +24,9 @@ if (RunCMake_GENERATOR_IS_MULTI_CONFIG)
"No recognized build configurations found.")
endif ()
else ()
+ set(CXXModules_config "${CXXModules_default_build_type}")
+ set(CMAKE_BUILD_TYPE "${CXXModules_default_build_type}")
+
file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-bmi-install-public.dir/CXXDependInfo.json" actual_contents)
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoBMIInstall-public.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
diff --git a/Tests/RunCMake/CXXModules/NinjaDependInfoExport-check.cmake b/Tests/RunCMake/CXXModules/NinjaDependInfoExport-check.cmake
index 4e20782..0c933c9 100644
--- a/Tests/RunCMake/CXXModules/NinjaDependInfoExport-check.cmake
+++ b/Tests/RunCMake/CXXModules/NinjaDependInfoExport-check.cmake
@@ -24,6 +24,9 @@ if (RunCMake_GENERATOR_IS_MULTI_CONFIG)
"No recognized build configurations found.")
endif ()
else ()
+ set(CXXModules_config "${CXXModules_default_build_type}")
+ set(CMAKE_BUILD_TYPE "${CXXModules_default_build_type}")
+
file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-exports-public.dir/CXXDependInfo.json" actual_contents)
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoExport-public.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
diff --git a/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake b/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
index f0005ce..4eaa891 100644
--- a/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
+++ b/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
@@ -24,6 +24,9 @@ if (RunCMake_GENERATOR_IS_MULTI_CONFIG)
"No recognized build configurations found.")
endif ()
else ()
+ set(CXXModules_config "${CXXModules_default_build_type}")
+ set(CMAKE_BUILD_TYPE "${CXXModules_default_build_type}")
+
file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-public.dir/CXXDependInfo.json" actual_contents)
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoFileSet-public.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
diff --git a/Tests/RunCMake/CXXModules/compiler_introspection.cmake b/Tests/RunCMake/CXXModules/compiler_introspection.cmake
index 50644ff..8c74940 100644
--- a/Tests/RunCMake/CXXModules/compiler_introspection.cmake
+++ b/Tests/RunCMake/CXXModules/compiler_introspection.cmake
@@ -22,6 +22,7 @@ set(CMAKE_MAKE_PROGRAM \"${CMAKE_MAKE_PROGRAM}\")
set(forced_cxx_standard \"${forced_cxx_standard}\")
set(CMAKE_CXX_COMPILER_VERSION \"${CMAKE_CXX_COMPILER_VERSION}\")
set(CMAKE_CXX_OUTPUT_EXTENSION \"${CMAKE_CXX_OUTPUT_EXTENSION}\")
+set(CXXModules_default_build_type \"${CMAKE_BUILD_TYPE}\")
")
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/info.cmake" "${info}")