2018-04-12 19:55:54 +02:00
|
|
|
#############################################################
|
2018-10-22 04:46:36 +02:00
|
|
|
## Set up flags based on LOCAL_USE_CLANG_LLD.
|
|
|
|
## Input variables: LOCAL_USE_CLANG_LLD
|
2018-04-12 19:55:54 +02:00
|
|
|
## Output variables: my_use_clang_lld
|
|
|
|
#############################################################
|
|
|
|
|
2018-06-12 19:50:10 +02:00
|
|
|
# Use LLD by default.
|
2018-10-22 04:46:36 +02:00
|
|
|
# Do not use LLD if LOCAL_USE_CLANG_LLD is false or 0
|
2018-06-12 19:50:10 +02:00
|
|
|
my_use_clang_lld := true
|
|
|
|
ifneq (,$(LOCAL_USE_CLANG_LLD))
|
|
|
|
ifneq (,$(filter 0 false,$(LOCAL_USE_CLANG_LLD)))
|
|
|
|
my_use_clang_lld := false
|
|
|
|
endif
|
2018-04-12 19:55:54 +02:00
|
|
|
endif
|
2018-04-24 01:20:10 +02:00
|
|
|
|
2018-06-27 19:35:42 +02:00
|
|
|
# Do not use LLD for Darwin host executables or shared libraries. See
|
|
|
|
# https://lld.llvm.org/AtomLLD.html for status of lld for Mach-O.
|
|
|
|
ifeq ($($(my_prefix)OS),darwin)
|
|
|
|
my_use_clang_lld := false
|
|
|
|
endif
|
|
|
|
# http://b/110800681 - lld cannot link Android's Windows modules yet.
|
|
|
|
ifeq ($($(my_prefix)OS),windows)
|
|
|
|
my_use_clang_lld := false
|
2018-04-24 01:20:10 +02:00
|
|
|
endif
|