RunCMakeTest.cmake 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327
  1. include(RunCMake)
  2. if(RunCMake_GENERATOR STREQUAL "Xcode")
  3. set(maybe_ios_catalyst "")
  4. else()
  5. set(maybe_ios_catalyst ios-catalyst)
  6. endif()
  7. function(create_library type platform system_name archs sysroot)
  8. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/create-${type}-${platform}-build)
  9. run_cmake_with_options(create-${type}-${platform} -DCMAKE_SYSTEM_NAME=${system_name} -DCMAKE_OSX_ARCHITECTURES=${archs} -DCMAKE_OSX_SYSROOT=${sysroot} -DCMAKE_INSTALL_PREFIX=${RunCMake_TEST_BINARY_DIR}/install)
  10. set(RunCMake_TEST_NO_CLEAN 1)
  11. run_cmake_command(create-${type}-${platform}-build ${CMAKE_COMMAND} --build . --config Release)
  12. run_cmake_command(create-${type}-${platform}-install ${CMAKE_COMMAND} --install . --config Release)
  13. endfunction()
  14. function(create_libraries type)
  15. create_library(${type} macos Darwin "${macos_archs_2}" macosx)
  16. create_library(${type} ios iOS "arm64" iphoneos)
  17. if(maybe_ios_catalyst)
  18. create_library(${type} ios-catalyst iOS "${macos_archs_2}" macosx)
  19. endif()
  20. create_library(${type} tvos tvOS "arm64" appletvos)
  21. create_library(${type} watchos watchOS "armv7k\\\\;arm64_32" watchos)
  22. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15.2)
  23. create_library(${type} visionos visionOS "arm64" xros)
  24. endif()
  25. create_library(${type} ios-simulator iOS "${macos_archs_2}" iphonesimulator)
  26. create_library(${type} tvos-simulator tvOS "${macos_archs_2}" appletvsimulator)
  27. create_library(${type} watchos-simulator watchOS "${watch_sim_archs_2}" watchsimulator)
  28. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15.2)
  29. create_library(${type} visionos-simulator visionOS "${macos_archs_2}" xrsimulator)
  30. endif()
  31. endfunction()
  32. function(create_xcframework name type platforms)
  33. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/create-xcframework-${name}-build)
  34. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15)
  35. # 'xcodebuild -create-xcframework' fails on symlinked paths.
  36. file(REAL_PATH "${RunCMake_SOURCE_DIR}" src_dir)
  37. file(REAL_PATH "${RunCMake_BINARY_DIR}" bld_dir)
  38. else()
  39. set(src_dir "${RunCMake_SOURCE_DIR}")
  40. set(bld_dir "${RunCMake_BINARY_DIR}")
  41. endif()
  42. set(args)
  43. foreach(platform IN LISTS platforms)
  44. set(lib_dir "${bld_dir}/create-${type}-${platform}-build/install/lib")
  45. if(type STREQUAL "framework")
  46. list(APPEND args -framework ${lib_dir}/mylib.framework)
  47. else()
  48. list(APPEND args -library ${lib_dir}/libmylib.a -headers ${src_dir}/mylib/include)
  49. endif()
  50. endforeach()
  51. run_cmake_command(create-xcframework-${name} xcodebuild -create-xcframework ${args} -output ${RunCMake_TEST_BINARY_DIR}/mylib.xcframework)
  52. endfunction()
  53. function(create_executable name xcfname system_name archs sysroot)
  54. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/create-executable-${name}-build)
  55. run_cmake_with_options(create-executable-${name} -DCMAKE_SYSTEM_NAME=${system_name} -DCMAKE_OSX_ARCHITECTURES=${archs} -DCMAKE_OSX_SYSROOT=${sysroot} -DMYLIB_LIBRARY=${RunCMake_BINARY_DIR}/create-xcframework-${xcfname}-build/mylib.xcframework)
  56. set(RunCMake_TEST_NO_CLEAN 1)
  57. run_cmake_command(create-executable-${name}-build ${CMAKE_COMMAND} --build . --config Release)
  58. endfunction()
  59. function(create_executables name type)
  60. create_executable(${name}-macos ${type} Darwin "${macos_archs_2}" macosx)
  61. create_executable(${name}-ios ${type} iOS "arm64" iphoneos)
  62. if(maybe_ios_catalyst)
  63. create_executable(${name}-ios-catalyst ${type} iOS "${macos_archs_2}" macosx)
  64. endif()
  65. create_executable(${name}-tvos ${type} tvOS "arm64" appletvos)
  66. create_executable(${name}-watchos ${type} watchOS "armv7k\\\\;arm64_32" watchos)
  67. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15.2)
  68. create_executable(${name}-visionos ${type} visionOS "arm64" xros)
  69. endif()
  70. create_executable(${name}-ios-simulator ${type} iOS "${macos_archs_2}" iphonesimulator)
  71. create_executable(${name}-tvos-simulator ${type} tvOS "${macos_archs_2}" appletvsimulator)
  72. create_executable(${name}-watchos-simulator ${type} watchOS "${watch_sim_archs_2}" watchsimulator)
  73. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15.2)
  74. create_executable(${name}-visionos-simulator ${type} visionOS "${macos_archs_2}" xrsimulator)
  75. endif()
  76. endfunction()
  77. set(xcframework_platforms macos ios ${maybe_ios_catalyst} tvos watchos ios-simulator tvos-simulator watchos-simulator)
  78. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15.2)
  79. list(APPEND xcframework_platforms visionos visionos-simulator)
  80. endif()
  81. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 12 AND NOT RunCMake_GENERATOR STREQUAL "FASTBuild")
  82. set(macos_archs_1 "x86_64\\;arm64")
  83. set(macos_archs_2 "x86_64\\\\;arm64")
  84. set(watch_sim_archs_2 "x86_64")
  85. else()
  86. set(macos_archs_1 "x86_64")
  87. set(macos_archs_2 "x86_64")
  88. set(watch_sim_archs_2 "i386")
  89. endif()
  90. create_libraries(library)
  91. create_libraries(framework)
  92. create_xcframework(library library "${xcframework_platforms}")
  93. create_xcframework(framework framework "${xcframework_platforms}")
  94. create_xcframework(incomplete framework "tvos;watchos")
  95. create_executables(library library)
  96. create_executables(framework framework)
  97. run_cmake_with_options(create-executable-incomplete -DCMAKE_SYSTEM_NAME=Darwin "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_1}" -DCMAKE_OSX_SYSROOT=macosx -DMYLIB_LIBRARY=${RunCMake_BINARY_DIR}/create-xcframework-incomplete-build/mylib.xcframework)
  98. create_executables(target-library library)
  99. create_executables(target-framework framework)
  100. run_cmake_with_options(create-executable-target-incomplete -DCMAKE_SYSTEM_NAME=Darwin "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_1}" -DCMAKE_OSX_SYSROOT=macosx -DMYLIB_LIBRARY=${RunCMake_BINARY_DIR}/create-xcframework-incomplete-build/mylib.xcframework)
  101. if(RunCMake_GENERATOR STREQUAL "Xcode" AND CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 12)
  102. create_executables(library-link-phase library)
  103. create_executables(framework-link-phase framework)
  104. run_cmake_with_options(create-executable-incomplete-link-phase -DCMAKE_SYSTEM_NAME=Darwin "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_1}" -DCMAKE_OSX_SYSROOT=macosx -DMYLIB_LIBRARY=${RunCMake_BINARY_DIR}/create-xcframework-incomplete-build/mylib.xcframework)
  105. create_executables(target-library-link-phase library)
  106. create_executables(target-framework-link-phase framework)
  107. run_cmake_with_options(create-executable-target-incomplete-link-phase -DCMAKE_SYSTEM_NAME=Darwin "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_1}" -DCMAKE_OSX_SYSROOT=macosx -DMYLIB_LIBRARY=${RunCMake_BINARY_DIR}/create-xcframework-incomplete-build/mylib.xcframework)
  108. endif()
  109. # Ensure that .xcframework is found before .framework
  110. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/create-xcframework-framework-build)
  111. set(RunCMake_TEST_NO_CLEAN 1)
  112. run_cmake_command(copy-framework ${CMAKE_COMMAND} -E copy_directory ${RunCMake_BINARY_DIR}/create-framework-macos-build/install/lib/mylib.framework ${RunCMake_TEST_BINARY_DIR}/mylib.framework)
  113. unset(RunCMake_TEST_NO_CLEAN)
  114. unset(RunCMake_TEST_BINARY_DIR)
  115. run_cmake(find-library)
  116. run_cmake_command(find-library-script ${CMAKE_COMMAND} -P ${RunCMake_SOURCE_DIR}/find-library.cmake)
  117. file(REMOVE_RECURSE ${RunCMake_BINARY_DIR}/export-install)
  118. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/export-macos-build)
  119. run_cmake_with_options(export-macos -DCMAKE_SYSTEM_NAME=Darwin -DCMAKE_INSTALL_PREFIX=${RunCMake_BINARY_DIR}/export-install)
  120. set(RunCMake_TEST_NO_CLEAN 1)
  121. set(_config_arg)
  122. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  123. set(_config_arg --config Release)
  124. endif()
  125. run_cmake_command(export-macos-build ${CMAKE_COMMAND} --build . ${_config_arg})
  126. run_cmake_command(export-macos-install ${CMAKE_COMMAND} --install . ${_config_arg})
  127. unset(RunCMake_TEST_NO_CLEAN)
  128. unset(RunCMake_TEST_BINARY_DIR)
  129. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/export-ios-build)
  130. run_cmake_with_options(export-ios -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphoneos "-DCMAKE_OSX_ARCHITECTURES=arm64" -DCMAKE_INSTALL_PREFIX=${RunCMake_BINARY_DIR}/export-install)
  131. set(RunCMake_TEST_NO_CLEAN 1)
  132. set(_config_arg)
  133. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  134. set(_config_arg --config Release)
  135. endif()
  136. run_cmake_command(export-ios-build ${CMAKE_COMMAND} --build . ${_config_arg})
  137. run_cmake_command(export-ios-install ${CMAKE_COMMAND} --install . ${_config_arg})
  138. unset(RunCMake_TEST_NO_CLEAN)
  139. unset(RunCMake_TEST_BINARY_DIR)
  140. if(maybe_ios_catalyst)
  141. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/export-ios-catalyst-build)
  142. run_cmake_with_options(export-ios-catalyst -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=macosx "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_1}" -DCMAKE_INSTALL_PREFIX=${RunCMake_BINARY_DIR}/export-install)
  143. set(RunCMake_TEST_NO_CLEAN 1)
  144. set(_config_arg)
  145. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  146. set(_config_arg --config Release)
  147. endif()
  148. run_cmake_command(export-ios-catalyst-build ${CMAKE_COMMAND} --build . ${_config_arg})
  149. run_cmake_command(export-ios-catalyst-install ${CMAKE_COMMAND} --install . ${_config_arg})
  150. unset(RunCMake_TEST_NO_CLEAN)
  151. unset(RunCMake_TEST_BINARY_DIR)
  152. endif()
  153. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/export-ios-simulator-build)
  154. run_cmake_with_options(export-ios-simulator -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphonesimulator "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_1}" -DCMAKE_INSTALL_PREFIX=${RunCMake_BINARY_DIR}/export-install)
  155. set(RunCMake_TEST_NO_CLEAN 1)
  156. set(_config_arg)
  157. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  158. set(_config_arg --config Release)
  159. endif()
  160. run_cmake_command(export-ios-simulator-build ${CMAKE_COMMAND} --build . ${_config_arg})
  161. run_cmake_command(export-ios-simulator-install ${CMAKE_COMMAND} --install . ${_config_arg})
  162. unset(RunCMake_TEST_NO_CLEAN)
  163. unset(RunCMake_TEST_BINARY_DIR)
  164. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-install-specific-no-xcframework-build)
  165. run_cmake_with_options(import-macos-install-specific-no-xcframework -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-install/lib/macos/cmake/mylib)
  166. set(RunCMake_TEST_NO_CLEAN 1)
  167. set(_config_arg)
  168. set(_config_dir)
  169. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  170. set(_config_arg --config Release)
  171. set(_config_dir /Release)
  172. endif()
  173. run_cmake_command(import-macos-install-specific-no-xcframework-build ${CMAKE_COMMAND} --build . ${_config_arg})
  174. unset(RunCMake_TEST_NO_CLEAN)
  175. unset(RunCMake_TEST_BINARY_DIR)
  176. set(RunCMake_TEST_NO_CLEAN 1)
  177. if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 15)
  178. # 'xcodebuild -create-xcframework' fails on symlinked paths.
  179. file(REAL_PATH "${RunCMake_SOURCE_DIR}" src_dir)
  180. file(REAL_PATH "${RunCMake_BINARY_DIR}" bld_dir)
  181. else()
  182. set(src_dir "${RunCMake_SOURCE_DIR}")
  183. set(bld_dir "${RunCMake_BINARY_DIR}")
  184. endif()
  185. if(maybe_ios_catalyst)
  186. set(maybe_ios_catalyst_mylib
  187. -library ${bld_dir}/export-install/lib/ios-catalyst/libmylib.a
  188. -headers ${src_dir}/mylib/include
  189. )
  190. set(maybe_ios_catalyst_mylib_genex
  191. -library ${bld_dir}/export-install/lib/ios-catalyst/libmylib-genex.a
  192. -headers ${src_dir}/mylib/include
  193. )
  194. else()
  195. set(maybe_ios_catalyst_mylib "")
  196. set(maybe_ios_catalyst_mylib_genex "")
  197. endif()
  198. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/export-install)
  199. run_cmake_command(export-install-xcframework xcodebuild -create-xcframework
  200. -output ${bld_dir}/export-install/lib/mylib.xcframework
  201. -library ${bld_dir}/export-install/lib/macos/libmylib.a
  202. -headers ${src_dir}/mylib/include
  203. -library ${bld_dir}/export-install/lib/ios/libmylib.a
  204. -headers ${src_dir}/mylib/include
  205. ${maybe_ios_catalyst_mylib}
  206. -library ${bld_dir}/export-install/lib/ios-simulator/libmylib.a
  207. -headers ${src_dir}/mylib/include
  208. )
  209. run_cmake_command(export-install-xcframework-genex xcodebuild -create-xcframework
  210. -output ${bld_dir}/export-install/lib2/mylib-genex.xcframework
  211. -library ${bld_dir}/export-install/lib/macos/libmylib-genex.a
  212. -headers ${src_dir}/mylib/include
  213. -library ${bld_dir}/export-install/lib/ios/libmylib-genex.a
  214. -headers ${src_dir}/mylib/include
  215. ${maybe_ios_catalyst_mylib_genex}
  216. -library ${bld_dir}/export-install/lib/ios-simulator/libmylib-genex.a
  217. -headers ${src_dir}/mylib/include
  218. )
  219. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/export-macos-build)
  220. run_cmake_command(export-build-macos-xcframework xcodebuild -create-xcframework
  221. -output ${bld_dir}/export-macos-build/lib/mylib.xcframework
  222. -library ${bld_dir}/export-macos-build/lib/macos${_config_dir}/libmylib.a
  223. -headers ${src_dir}/mylib/include
  224. )
  225. run_cmake_command(export-build-macos-xcframework-genex xcodebuild -create-xcframework
  226. -output ${bld_dir}/export-macos-build/lib/mylib-genex.xcframework
  227. -library ${bld_dir}/export-macos-build/lib/macos${_config_dir}/libmylib-genex.a
  228. -headers ${src_dir}/mylib/include
  229. )
  230. unset(RunCMake_TEST_NO_CLEAN)
  231. unset(RunCMake_TEST_BINARY_DIR)
  232. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-install-specific-build)
  233. run_cmake_with_options(import-macos-install-specific -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-install/lib/macos/cmake/mylib)
  234. set(RunCMake_TEST_NO_CLEAN 1)
  235. set(_config_arg)
  236. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  237. set(_config_arg --config Release)
  238. endif()
  239. run_cmake_command(import-macos-install-specific-build ${CMAKE_COMMAND} --build . ${_config_arg})
  240. unset(RunCMake_TEST_NO_CLEAN)
  241. unset(RunCMake_TEST_BINARY_DIR)
  242. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-build-specific-build)
  243. run_cmake_with_options(import-macos-build-specific -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-macos-build/lib/macos/cmake/mylib)
  244. set(RunCMake_TEST_NO_CLEAN 1)
  245. set(_config_arg)
  246. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  247. set(_config_arg --config Release)
  248. endif()
  249. run_cmake_command(import-macos-build-specific-build ${CMAKE_COMMAND} --build . ${_config_arg})
  250. unset(RunCMake_TEST_NO_CLEAN)
  251. unset(RunCMake_TEST_BINARY_DIR)
  252. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-install-specific-genex-build)
  253. run_cmake_with_options(import-macos-install-specific-genex -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-install/lib/macos/cmake/mylib)
  254. set(RunCMake_TEST_NO_CLEAN 1)
  255. set(_config_arg)
  256. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  257. set(_config_arg --config Release)
  258. endif()
  259. run_cmake_command(import-macos-install-specific-genex-build ${CMAKE_COMMAND} --build . ${_config_arg})
  260. unset(RunCMake_TEST_NO_CLEAN)
  261. unset(RunCMake_TEST_BINARY_DIR)
  262. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-build-specific-genex-build)
  263. run_cmake_with_options(import-macos-build-specific-genex -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-macos-build/lib/macos/cmake/mylib)
  264. set(RunCMake_TEST_NO_CLEAN 1)
  265. set(_config_arg)
  266. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  267. set(_config_arg --config Release)
  268. endif()
  269. run_cmake_command(import-macos-build-specific-genex-build ${CMAKE_COMMAND} --build . ${_config_arg})
  270. unset(RunCMake_TEST_NO_CLEAN)
  271. unset(RunCMake_TEST_BINARY_DIR)
  272. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-install-general-build)
  273. run_cmake_with_options(import-macos-install-general -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-install/lib/cmake/mylib)
  274. set(RunCMake_TEST_NO_CLEAN 1)
  275. set(_config_arg)
  276. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  277. set(_config_arg --config Release)
  278. endif()
  279. run_cmake_command(import-macos-install-general-build ${CMAKE_COMMAND} --build . ${_config_arg})
  280. unset(RunCMake_TEST_NO_CLEAN)
  281. unset(RunCMake_TEST_BINARY_DIR)
  282. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-macos-build-general-build)
  283. run_cmake_with_options(import-macos-build-general -DCMAKE_SYSTEM_NAME=Darwin -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-macos-build/lib/cmake/mylib)
  284. set(RunCMake_TEST_NO_CLEAN 1)
  285. set(_config_arg)
  286. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  287. set(_config_arg --config Release)
  288. endif()
  289. run_cmake_command(import-macos-build-general-build ${CMAKE_COMMAND} --build . ${_config_arg})
  290. unset(RunCMake_TEST_NO_CLEAN)
  291. unset(RunCMake_TEST_BINARY_DIR)
  292. set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/import-ios-install-general-build)
  293. run_cmake_with_options(import-ios-install-general -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphoneos -DCMAKE_OSX_ARCHITECTURES=arm64 -Dmylib_DIR=${RunCMake_BINARY_DIR}/export-install/lib/cmake/mylib)
  294. set(RunCMake_TEST_NO_CLEAN 1)
  295. set(_config_arg)
  296. if(RunCMake_GENERATOR_IS_MULTI_CONFIG)
  297. set(_config_arg --config Release)
  298. endif()
  299. run_cmake_command(import-ios-install-general-build ${CMAKE_COMMAND} --build . ${_config_arg})
  300. unset(RunCMake_TEST_NO_CLEAN)
  301. unset(RunCMake_TEST_BINARY_DIR)