Files
cmake/Tests/RunCMake/LinkerLauncher/C-special-args-build-check.cmake
Tyler Yankee 721eb8a5a2 cmCommonTargetGenerator: Improve launcher shell conversion
Encapsulate the shell escaping logic in `cmCommonTargetGenerator` and
represent launchers via a vector of strings (as is done with custom
commands, execute process commands, etc.) to make them easier to work
with.

This facilitates work in a future commit which will reuse this pathway.

Issue: #27598, #27402
2026-09-21 13:45:54 -04:00

13 lines
507 B
CMake

# Launcher invocations cannot be reliably verified via stdout, so it records to
# a log file instead. Verify by checking its content.
set(log_file "${RunCMake_TEST_BINARY_DIR}/special-args.log")
if(NOT EXISTS "${log_file}")
set(RunCMake_TEST_FAILED "special-args.log was not created by the wrapper")
else()
file(READ "${log_file}" log_content)
if(NOT log_content MATCHES "link")
set(RunCMake_TEST_FAILED
"special-args.log does not show link launcher ran:\n${log_content}")
endif()
endif()