For the purpose of quick compile testing of (namely smaller) changes,
provide a
means to build individual pieces underneath the xen dir (could equally
be applied
to tools, and the top level Makefile could also be made aware of this
logic to
make things even more consistent). At once, add a way to only
pre-process files
in case some of the more complicated macros need change and hence
inspection
of the results.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
.PHONY: MAP
MAP:
$(NM) $(TARGET) | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | sort > System.map
+
+.PHONY: FORCE
+FORCE:
+
+%.o %.i: %.c FORCE
+ $(MAKE) -f $(BASEDIR)/Rules.mk -C $(*D) $(@F)
+
+%.o %.s: %.S FORCE
+ $(MAKE) -f $(BASEDIR)/Rules.mk -C $(*D) $(@F)
+
+%/: FORCE
+ $(MAKE) -f $(BASEDIR)/Rules.mk -C $* built_in.o
%.o: %.S $(HDRS) Makefile
$(CC) $(CFLAGS) $(AFLAGS) -c $< -o $@
+
+%.i: %.c $(HDRS) Makefile
+ $(CPP) $(CFLAGS) $< -o $@
+
+%.s: %.S $(HDRS) Makefile
+ $(CPP) $(CFLAGS) $(AFLAGS) $< -o $@