aboutsummaryrefslogtreecommitdiff
path: root/llvm/runtimes/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/runtimes/CMakeLists.txt')
-rw-r--r--llvm/runtimes/CMakeLists.txt14
1 files changed, 9 insertions, 5 deletions
diff --git a/llvm/runtimes/CMakeLists.txt b/llvm/runtimes/CMakeLists.txt
index 77254b7..db50b6d 100644
--- a/llvm/runtimes/CMakeLists.txt
+++ b/llvm/runtimes/CMakeLists.txt
@@ -391,8 +391,17 @@ function(runtime_register_target name)
add_dependencies(runtimes-test-depends runtimes-test-depends-${name})
endif()
foreach(runtime_name ${runtime_names})
+ if(NOT TARGET ${runtime_name})
+ add_custom_target(${runtime_name})
+ endif()
add_dependencies(${runtime_name} ${runtime_name}-${name})
+ if(NOT TARGET install-${runtime_name})
+ add_custom_target(install-${runtime_name})
+ endif()
add_dependencies(install-${runtime_name} install-${runtime_name}-${name})
+ if(NOT TARGET install-${runtime_name}-stripped)
+ add_custom_target(install-${runtime_name}-stripped)
+ endif()
add_dependencies(install-${runtime_name}-stripped install-${runtime_name}-${name}-stripped)
endforeach()
foreach(component ${LLVM_RUNTIME_DISTRIBUTION_COMPONENTS})
@@ -459,11 +468,6 @@ if(runtimes)
add_custom_target(runtimes-test-depends)
set(test_targets "")
endif()
- foreach(runtime_name ${RUNTIME_NAMES})
- add_custom_target(${runtime_name})
- add_custom_target(install-${runtime_name})
- add_custom_target(install-${runtime_name}-stripped)
- endforeach()
if(LLVM_RUNTIME_DISTRIBUTION_COMPONENTS)
foreach(component ${LLVM_RUNTIME_DISTRIBUTION_COMPONENTS})
add_custom_target(${component})