mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-23 22:00:10 +00:00
[runtimes] Only depend on builtins for same target
We don't need to have built all the builtins before building the runtimes for a particular target, only the builtins for that target. While I'm here, rename the variable that stores the builtins dep to something less generic than `deps`, to minimize the chances of accidentally using a variable with the same name from an outer scope. Reviewed By: phosek Differential Revision: https://reviews.llvm.org/D139913
This commit is contained in:
parent
a73e0c306c
commit
72f3f6838f
@ -148,7 +148,7 @@ if(compiler_rt_path)
|
|||||||
add_dependencies(install-builtins-stripped install-builtins-${target}-stripped)
|
add_dependencies(install-builtins-stripped install-builtins-${target}-stripped)
|
||||||
endforeach()
|
endforeach()
|
||||||
endif()
|
endif()
|
||||||
set(deps builtins)
|
set(builtins_dep builtins)
|
||||||
# We don't need to depend on the builtins if we're building instrumented
|
# We don't need to depend on the builtins if we're building instrumented
|
||||||
# because the next stage will use the same compiler used to build this stage.
|
# because the next stage will use the same compiler used to build this stage.
|
||||||
if(NOT LLVM_BUILD_INSTRUMENTED AND CLANG_ENABLE_BOOTSTRAP)
|
if(NOT LLVM_BUILD_INSTRUMENTED AND CLANG_ENABLE_BOOTSTRAP)
|
||||||
@ -386,13 +386,13 @@ if(runtimes)
|
|||||||
endif()
|
endif()
|
||||||
if(NOT LLVM_RUNTIME_TARGETS)
|
if(NOT LLVM_RUNTIME_TARGETS)
|
||||||
runtime_default_target(
|
runtime_default_target(
|
||||||
DEPENDS ${deps} ${extra_deps}
|
DEPENDS ${builtins_dep} ${extra_deps}
|
||||||
PREFIXES ${prefixes})
|
PREFIXES ${prefixes})
|
||||||
set(test_targets check-runtimes)
|
set(test_targets check-runtimes)
|
||||||
else()
|
else()
|
||||||
if("default" IN_LIST LLVM_RUNTIME_TARGETS)
|
if("default" IN_LIST LLVM_RUNTIME_TARGETS)
|
||||||
runtime_default_target(
|
runtime_default_target(
|
||||||
DEPENDS ${deps} ${extra_deps}
|
DEPENDS ${builtins_dep} ${extra_deps}
|
||||||
PREFIXES ${prefixes})
|
PREFIXES ${prefixes})
|
||||||
list(REMOVE_ITEM LLVM_RUNTIME_TARGETS "default")
|
list(REMOVE_ITEM LLVM_RUNTIME_TARGETS "default")
|
||||||
else()
|
else()
|
||||||
@ -420,8 +420,11 @@ if(runtimes)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
foreach(name ${LLVM_RUNTIME_TARGETS})
|
foreach(name ${LLVM_RUNTIME_TARGETS})
|
||||||
|
if(builtins_dep)
|
||||||
|
set(builtins_dep_name "${builtins_dep}-${name}")
|
||||||
|
endif()
|
||||||
runtime_register_target(${name} ${name}
|
runtime_register_target(${name} ${name}
|
||||||
DEPENDS ${deps})
|
DEPENDS ${builtins_dep_name})
|
||||||
|
|
||||||
add_dependencies(runtimes runtimes-${name})
|
add_dependencies(runtimes runtimes-${name})
|
||||||
add_dependencies(runtimes-configure runtimes-${name}-configure)
|
add_dependencies(runtimes-configure runtimes-${name}-configure)
|
||||||
|
Loading…
Reference in New Issue
Block a user