From: Andrew Cooper Date: Thu, 7 Apr 2016 22:03:43 +0000 (+0200) Subject: build: fix build with Clang X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~1347 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=d5bdea59e789662071017ff119f99cd55a4a6425;p=xen.git build: fix build with Clang c/s 607044bf9 "build: avoid putting local absolute symbols in symbol tables" breaks the build with Clang, as the command line argument isn't understood. Clang does not appear to have any equivielent option, and already has outstanding issues with duplicate symbols. Excluding this option makes the problem no worse. Signed-off-by: Andrew Cooper Acked-by: Jan Beulich --- diff --git a/xen/Rules.mk b/xen/Rules.mk index d4dffde179..7183d6938c 100644 --- a/xen/Rules.mk +++ b/xen/Rules.mk @@ -50,9 +50,15 @@ ALL_OBJS-$(CONFIG_X86) += $(BASEDIR)/crypto/built_in.o CFLAGS += -nostdinc -fno-builtin -fno-common CFLAGS += -Werror -Wredundant-decls -Wno-pointer-arith CFLAGS += -pipe -g -D__XEN__ -include $(BASEDIR)/include/xen/config.h -CFLAGS += -Wa,--strip-local-absolute CFLAGS += '-D__OBJECT_FILE__="$@"' +ifneq ($(clang),y) +# Clang doesn't understand this command line argument, and doesn't appear to +# have an suitable alternative. The resulting compiled binary does function, +# but has an excessively large symbol table. +CFLAGS += -Wa,--strip-local-absolute +endif + CFLAGS-$(verbose) += -DVERBOSE CFLAGS-$(crash_debug) += -DCRASH_DEBUG CFLAGS-$(perfc) += -DPERF_COUNTERS