Files
cmake/Tests/RunCMake/CommandLine/C_buildsrcdir/src/PreLoad.cmake
T
Peter Waller 4ca0526f8a cmake: Pass -S and -B into PreLoad.cmake and -C scripts
Before this, it was not possible to see what the source or build directories
were set to on the command line.

Fixes: #19619
2019-08-27 10:51:40 -04:00

7 lines
425 B
CMake

# Used to verify that the values match what is passed via -S and -B, and are retained in cache.
message("PreLoad.cmake: CMAKE_SOURCE_DIR: ${CMAKE_SOURCE_DIR}")
message("PreLoad.cmake: CMAKE_BINARY_DIR: ${CMAKE_BINARY_DIR}")
set(PRELOAD_BINARY_DIR "${CMAKE_BINARY_DIR}" CACHE PATH "value of cmake_binary_dir during preload")
set(PRELOAD_SOURCE_DIR "${CMAKE_SOURCE_DIR}" CACHE PATH "value of cmake_source_dir during preload")