summaryrefslogtreecommitdiffstats
path: root/Tests
diff options
context:
space:
mode:
Diffstat (limited to 'Tests')
-rw-r--r--Tests/RunCMake/ToolchainFile/RunCMakeTest.cmake1
-rw-r--r--Tests/RunCMake/ToolchainFile/SetCrossCompiling-stderr.txt8
-rw-r--r--Tests/RunCMake/ToolchainFile/SetCrossCompiling-toolchain.cmake1
-rw-r--r--Tests/RunCMake/ToolchainFile/SetCrossCompiling.cmake0
4 files changed, 10 insertions, 0 deletions
diff --git a/Tests/RunCMake/ToolchainFile/RunCMakeTest.cmake b/Tests/RunCMake/ToolchainFile/RunCMakeTest.cmake
index 7744ee8..b588ce0 100644
--- a/Tests/RunCMake/ToolchainFile/RunCMakeTest.cmake
+++ b/Tests/RunCMake/ToolchainFile/RunCMakeTest.cmake
@@ -14,6 +14,7 @@ run_cmake_toolchain(LinkFlagsInit)
run_cmake_toolchain(CMP0126-NEW)
run_cmake_toolchain(CMP0126-OLD)
run_cmake_toolchain(CMP0126-WARN)
+run_cmake_toolchain(SetCrossCompiling)
function(run_IncludeDirectories)
run_cmake_toolchain(IncludeDirectories)
diff --git a/Tests/RunCMake/ToolchainFile/SetCrossCompiling-stderr.txt b/Tests/RunCMake/ToolchainFile/SetCrossCompiling-stderr.txt
new file mode 100644
index 0000000..6642cf6
--- /dev/null
+++ b/Tests/RunCMake/ToolchainFile/SetCrossCompiling-stderr.txt
@@ -0,0 +1,8 @@
+^CMake Warning \(dev\) at [^
+]*/Modules/CMakeDetermineSystem.cmake:[0-9]+ \(message\):
+ CMAKE_CROSSCOMPILING has been set by the project, toolchain file, or user\.
+ CMake is resetting it to false because CMAKE_SYSTEM_NAME was not set\. To
+ indicate cross compilation, only CMAKE_SYSTEM_NAME needs to be set\.
+Call Stack \(most recent call first\):
+ CMakeLists\.txt:[0-9]+ \(project\)
+This warning is for project developers\. Use -Wno-dev to suppress it\.$
diff --git a/Tests/RunCMake/ToolchainFile/SetCrossCompiling-toolchain.cmake b/Tests/RunCMake/ToolchainFile/SetCrossCompiling-toolchain.cmake
new file mode 100644
index 0000000..170e26c
--- /dev/null
+++ b/Tests/RunCMake/ToolchainFile/SetCrossCompiling-toolchain.cmake
@@ -0,0 +1 @@
+set(CMAKE_CROSSCOMPILING TRUE)
diff --git a/Tests/RunCMake/ToolchainFile/SetCrossCompiling.cmake b/Tests/RunCMake/ToolchainFile/SetCrossCompiling.cmake
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/Tests/RunCMake/ToolchainFile/SetCrossCompiling.cmake