mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-01 20:00:51 -05:00
Tests: Avoid duplicate custom commands for Xcode "new build system"
This commit is contained in:
@@ -514,6 +514,14 @@ add_custom_target(UseConsoleTarget ALL
|
|||||||
USES_TERMINAL
|
USES_TERMINAL
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if(CMAKE_XCODE_BUILD_SYSTEM VERSION_GREATER_EQUAL 12)
|
||||||
|
# Xcode's "new build system" does not support multiple targets
|
||||||
|
# producing the same custom command output.
|
||||||
|
add_custom_target(GenPath DEPENDS "${gen_path}")
|
||||||
|
add_dependencies(NormDepends GenPath)
|
||||||
|
add_dependencies(UseConsole GenPath)
|
||||||
|
endif()
|
||||||
|
|
||||||
# Test COMMAND_EXPAND_LISTS
|
# Test COMMAND_EXPAND_LISTS
|
||||||
set(cmp_args "1ARG=COMMAND_EXPAND_LISTS" "2ARG=test" "3ARG=outfile"
|
set(cmp_args "1ARG=COMMAND_EXPAND_LISTS" "2ARG=test" "3ARG=outfile"
|
||||||
"4ARG=content")
|
"4ARG=content")
|
||||||
|
|||||||
@@ -6,6 +6,13 @@ ExternalData_Add_Test(Data5.A
|
|||||||
-P ${CMAKE_CURRENT_SOURCE_DIR}/Data5Check.cmake
|
-P ${CMAKE_CURRENT_SOURCE_DIR}/Data5Check.cmake
|
||||||
)
|
)
|
||||||
ExternalData_Add_Target(Data5.A)
|
ExternalData_Add_Target(Data5.A)
|
||||||
|
|
||||||
|
if(CMAKE_XCODE_BUILD_SYSTEM VERSION_GREATER_EQUAL 12)
|
||||||
|
# Xcode's "new build system" does not support multiple targets
|
||||||
|
# producing the same custom command output.
|
||||||
|
return()
|
||||||
|
endif()
|
||||||
|
|
||||||
ExternalData_Add_Test(Data5.B
|
ExternalData_Add_Test(Data5.B
|
||||||
NAME Data5Check.B
|
NAME Data5Check.B
|
||||||
COMMAND ${CMAKE_COMMAND}
|
COMMAND ${CMAKE_COMMAND}
|
||||||
|
|||||||
Reference in New Issue
Block a user