diff options
Diffstat (limited to 'Tests/RunCMake/XcodeProject/XcodePreserveNonOptimizationFlags-check.cmake')
-rw-r--r-- | Tests/RunCMake/XcodeProject/XcodePreserveNonOptimizationFlags-check.cmake | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Tests/RunCMake/XcodeProject/XcodePreserveNonOptimizationFlags-check.cmake b/Tests/RunCMake/XcodeProject/XcodePreserveNonOptimizationFlags-check.cmake new file mode 100644 index 0000000..2f6c03d --- /dev/null +++ b/Tests/RunCMake/XcodeProject/XcodePreserveNonOptimizationFlags-check.cmake @@ -0,0 +1,8 @@ +file(STRINGS ${RunCMake_TEST_BINARY_DIR}/XcodePreserveNonOptimizationFlags.xcodeproj/project.pbxproj actual + REGEX "OTHER_CPLUSPLUSFLAGS = [^;]*;") +foreach(expect "-DA" "-DB +-DC" "-DD") + if(NOT "${actual}" MATCHES "${expect}") + message(SEND_ERROR "The actual project contains the lines:\n ${actual}\n" + "which do not match expected regex:\n ${expect}\n") + endif() +endforeach() |