summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/Framework/RunCMakeTest.cmake
diff options
context:
space:
mode:
authorGregor Jasny <gjasny@googlemail.com>2015-11-13 11:59:18 (GMT)
committerGregor Jasny <gjasny@googlemail.com>2015-11-13 12:58:53 (GMT)
commitf6f03ed4cc4271384ec934fd5867ccbce4e798f2 (patch)
tree28d3548c23a1572aec158edde06b7b08149ce0bd /Tests/RunCMake/Framework/RunCMakeTest.cmake
parent9f053763d769780385fbc8e3e936f1c996d2e00a (diff)
downloadCMake-f6f03ed4cc4271384ec934fd5867ccbce4e798f2.zip
CMake-f6f03ed4cc4271384ec934fd5867ccbce4e798f2.tar.gz
CMake-f6f03ed4cc4271384ec934fd5867ccbce4e798f2.tar.bz2
Add test for OSX/iOS Framework directory structure (#15833)
Diffstat (limited to 'Tests/RunCMake/Framework/RunCMakeTest.cmake')
-rw-r--r--Tests/RunCMake/Framework/RunCMakeTest.cmake33
1 files changed, 33 insertions, 0 deletions
diff --git a/Tests/RunCMake/Framework/RunCMakeTest.cmake b/Tests/RunCMake/Framework/RunCMakeTest.cmake
new file mode 100644
index 0000000..d810283
--- /dev/null
+++ b/Tests/RunCMake/Framework/RunCMakeTest.cmake
@@ -0,0 +1,33 @@
+include(RunCMake)
+
+# iOS
+
+set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/iOSFrameworkLayout-build)
+set(RunCMake_TEST_NO_CLEAN 1)
+set(RunCMake_TEST_OPTIONS "-DCMAKE_TOOLCHAIN_FILE=${RunCMake_SOURCE_DIR}/ios.cmake")
+
+file(REMOVE_RECURSE "${RunCMake_TEST_BINARY_DIR}")
+file(MAKE_DIRECTORY "${RunCMake_TEST_BINARY_DIR}")
+
+run_cmake(FrameworkLayout)
+run_cmake_command(iOSFrameworkLayout-build ${CMAKE_COMMAND} --build .)
+
+unset(RunCMake_TEST_BINARY_DIR)
+unset(RunCMake_TEST_NO_CLEAN)
+unset(RunCMake_TEST_OPTIONS)
+
+# OSX
+
+set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/OSXFrameworkLayout-build)
+set(RunCMake_TEST_NO_CLEAN 1)
+set(RunCMake_TEST_OPTIONS "-DCMAKE_TOOLCHAIN_FILE=${RunCMake_SOURCE_DIR}/OSX.cmake")
+
+file(REMOVE_RECURSE "${RunCMake_TEST_BINARY_DIR}")
+file(MAKE_DIRECTORY "${RunCMake_TEST_BINARY_DIR}")
+
+run_cmake(FrameworkLayout)
+run_cmake_command(OSXFrameworkLayout-build ${CMAKE_COMMAND} --build .)
+
+unset(RunCMake_TEST_BINARY_DIR)
+unset(RunCMake_TEST_NO_CLEAN)
+unset(RunCMake_TEST_OPTIONS)