diff options
Diffstat (limited to 'Tests/RunCMake/XcodeProject/RunCMakeTest.cmake')
-rw-r--r-- | Tests/RunCMake/XcodeProject/RunCMakeTest.cmake | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake b/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake index 7eb624c..1313cb5 100644 --- a/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake +++ b/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake @@ -216,3 +216,21 @@ endfunction() if(NOT XCODE_VERSION VERSION_LESS 7) XcodeSchemaGeneration() endif() + +if(XCODE_VERSION VERSION_GREATER_EQUAL 8) + function(deploymeny_target_test SDK) + set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/DeploymentTarget-${SDK}-build) + set(RunCMake_TEST_NO_CLEAN 1) + set(RunCMake_TEST_OPTIONS "-DSDK=${SDK}") + + file(REMOVE_RECURSE "${RunCMake_TEST_BINARY_DIR}") + file(MAKE_DIRECTORY "${RunCMake_TEST_BINARY_DIR}") + + run_cmake(DeploymentTarget) + run_cmake_command(DeploymentTarget-${SDK} ${CMAKE_COMMAND} --build .) + endfunction() + + foreach(SDK macosx iphoneos iphonesimulator appletvos appletvsimulator watchos watchsimulator) + deploymeny_target_test(${SDK}) + endforeach() +endif() |