# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1245146770 -3600
# Node ID 214ff2a7c9900f5d8bac55a569224a0029173a0f
# Parent ca12928cdafe3fcb024520c4fe2479448f2c5f46
Fix Makefile.xen generation when building external modules
Otherwise, the file will be (attempted to be) put in the (possibly
read-only) source tree.
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
scripts/Makefile.build | 4 +++-
1 files changed, 3 insertions(+), 1 deletion(-)
diff -r ca12928cdafe -r 214ff2a7c990 scripts/Makefile.build
--- a/scripts/Makefile.build Mon Jun 08 12:23:24 2009 +0100
+++ b/scripts/Makefile.build Tue Jun 16 11:06:10 2009 +0100
@@ -69,7 +69,8 @@ endif
endif
ifeq ($(CONFIG_XEN),y)
-$(objtree)/scripts/Makefile.xen: $(srctree)/scripts/Makefile.xen.awk
$(srctree)/scripts/Makefile.build
+Makefile.xen := $(if
$(KBUILD_EXTMOD),$(KBUILD_EXTMOD),$(objtree)/scripts)/Makefile.xen
+$(Makefile.xen): $(srctree)/scripts/Makefile.xen.awk
$(srctree)/scripts/Makefile.build
@echo ' Updating $@'
$(if $(shell echo a | $(AWK) '{ print gensub(/a/, "AA", "g"); }'),\
,$(error 'Your awk program does not define gensub. Use gawk or
another awk with gensub'))
@@ -79,7 +80,7 @@ xen-single-used-m := $(xen-src-single-us
xen-single-used-m := $(xen-src-single-used-m:-xen.c=.o)
single-used-m := $(filter-out $(xen-single-used-m),$(single-used-m))
--include $(objtree)/scripts/Makefile.xen
+-include $(Makefile.xen)
endif
# ===========================================================================
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|