Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b318f050 authored by Alistair Strachan's avatar Alistair Strachan
Browse files

Merge fixes for android-mainline



This should fix builds with clang.

Change-Id: If3cf37d4d3e17db1d907472889ee430d0467fe66
Signed-off-by: default avatarAlistair Strachan <astrachan@google.com>
parent 23562ad3
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -506,12 +506,12 @@ endif
ifneq ($(shell $(CC) --version 2>&1 | head -n 1 | grep clang),)
ifneq ($(CROSS_COMPILE),)
CLANG_TRIPLE	?= $(CROSS_COMPILE)
CLANG_TARGET	:= --target=$(notdir $(CLANG_TRIPLE:%-=%))
ifeq ($(shell $(srctree)/scripts/clang-android.sh $(CC) $(CLANG_TARGET)), y)
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 $(LD)))
CLANG_PREFIX	:= --prefix=$(GCC_TOOLCHAIN_DIR)
GCC_TOOLCHAIN_DIR := $(dir $(shell which $(CROSS_COMPILE)elfedit))
CLANG_FLAGS	+= --prefix=$(GCC_TOOLCHAIN_DIR)
GCC_TOOLCHAIN	:= $(realpath $(GCC_TOOLCHAIN_DIR)/..)
endif
ifneq ($(GCC_TOOLCHAIN),)