https://github.com/Kitware/CMake
Raw File
Tip revision: fed67fa40d7b6e34ee7c8565694bd54af61aed73 authored by Brad King on 12 November 2021, 14:15:07 UTC
CMake 3.22.0-rc3
Tip revision: fed67fa
ImportMultiArch-check.cmake
set(xcProjectFile "${RunCMake_TEST_BINARY_DIR}/ImportMultiArch.xcodeproj/project.pbxproj")
if(NOT EXISTS "${xcProjectFile}")
  set(RunCMake_TEST_FAILED "Project file ${xcProjectFile} does not exist.")
  return()
endif()

file(READ ${xcProjectFile} pbxFileContents)
foreach(config IN ITEMS Debug Release RelWithDebInfo MinSizeRel)
  set(regex "--findconfig-${config}[^
]*\\$\\(CURRENT_ARCH\\)")
  if(NOT pbxFileContents MATCHES "${regex}")
    set(RunCMake_TEST_FAILED "$(CURRENT_ARCH) not preserved for config ${config}")
    return()
  endif()
endforeach()
back to top