1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-10-14 02:08:27 +08:00

Tests/RunCMake/CommandLine: Simplify --toolchain cases

This commit is contained in:
Brad King
2025-06-23 10:20:23 -04:00
parent a0fa70990e
commit cf0f46ed85
12 changed files with 4 additions and 10 deletions

View File

@@ -274,7 +274,6 @@ function(run_Toolchain)
# precedence over source dir
file(WRITE ${binary_dir}/toolchain.cmake [=[
set(CMAKE_SYSTEM_NAME Linux)
set(toolchain_file binary_dir)
]=])
run_cmake_with_options(toolchain-valid-rel-build-path -S ${source_dir} -B ${binary_dir} --toolchain toolchain.cmake)
endfunction()

View File

@@ -1,3 +1,3 @@
cmake_minimum_required(VERSION 3.20)
project(Toolchain LANGUAGES NONE)
message(FATAL_ERROR "${toolchain_file}")
message(STATUS "CMAKE_TOOLCHAIN_FILE='${CMAKE_TOOLCHAIN_FILE}'")

View File

@@ -1,2 +1 @@
set(CMAKE_SYSTEM_NAME Linux)
set(toolchain_file source_dir)

View File

@@ -1 +0,0 @@
^CMake Error.*source_dir

View File

@@ -0,0 +1 @@
CMAKE_TOOLCHAIN_FILE='[^']*/Tests/RunCMake/CommandLine/Toolchain/toolchain\.cmake'

View File

@@ -1,2 +0,0 @@
^CMake Error at CMakeLists.txt:[0-9] \(message\):
binary_dir$

View File

@@ -0,0 +1 @@
CMAKE_TOOLCHAIN_FILE='[^']*/Tests/RunCMake/CommandLine/Toolchain-build/toolchain\.cmake'

View File

@@ -1 +0,0 @@
^CMake Error.*source_dir

View File

@@ -0,0 +1 @@
CMAKE_TOOLCHAIN_FILE='[^']*/Tests/RunCMake/CommandLine/Toolchain/toolchain\.cmake'