ANDROID: Makefile: Properly resolve 4.9.169 merge
The merge removed commit4dcb0afde6("ANDROID: Kbuild, LLVMLinux: allow overriding clang target triple"). This keeps commit1347aa2a4d("kbuild: clang: choose GCC_TOOLCHAIN_DIR not on LD"), which caused the conflict. Change-Id: I72b7f69204a801ff6ef6405e24317a7b08428901 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
This commit is contained in:
parent
50db17e52b
commit
5d68df3299
1 changed files with 5 additions and 1 deletions
6
Makefile
6
Makefile
|
|
@ -507,7 +507,11 @@ endif
|
|||
|
||||
ifeq ($(cc-name),clang)
|
||||
ifneq ($(CROSS_COMPILE),)
|
||||
CLANG_FLAGS := --target=$(notdir $(CROSS_COMPILE:%-=%))
|
||||
CLANG_TRIPLE ?= $(CROSS_COMPILE)
|
||||
CLANG_FLAGS := --target=$(notdir $(CLANG_TRIPLE:%-=%))
|
||||
ifeq ($(shell $(srctree)/scripts/clang-android.sh $(CC) $(CLANG_FLAGS)), y)
|
||||
$(error "Clang with Android --target detected. Did you specify CLANG_TRIPLE?")
|
||||
endif
|
||||
GCC_TOOLCHAIN_DIR := $(dir $(shell which $(CROSS_COMPILE)elfedit))
|
||||
CLANG_FLAGS += --prefix=$(GCC_TOOLCHAIN_DIR)
|
||||
GCC_TOOLCHAIN := $(realpath $(GCC_TOOLCHAIN_DIR)/..)
|
||||
|
|
|
|||
Loading…
Reference in a new issue