xen/lto: if the makefile asks for binary, always build binary
authorTim Deegan <Tim.Deegan@citrix.com>
Thu, 7 Apr 2011 14:08:32 +0000 (15:08 +0100)
committerTim Deegan <Tim.Deegan@citrix.com>
Thu, 7 Apr 2011 14:08:32 +0000 (15:08 +0100)
even if the source is a C file.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Acked-by: Keir Fraser <keir@xen.org>
xen/Rules.mk

index f48ac56326aea39500f1fb3a51797255dd7c0677..fedda9181b3b6ad3421400c3b7f54c2b503493a8 100644 (file)
@@ -112,6 +112,9 @@ obj-y += $(obj-bin-y)
 obj-bin-y :=
 endif
 
+# Always build obj-bin files as binary even if they come from C source. 
+$(obj-bin-y): CFLAGS := $(filter-out -flto,$(CFLAGS))
+
 built_in.o: $(obj-y)
 ifeq ($(obj-y),)
        $(CC) $(CFLAGS) -c -x c /dev/null -o $@