Commit 28c699a2b650caa3bf7410b7960198572c9ddf3c

Authored by aliguori
1 parent bdb19571

build system: Further improve quiet mode (Jan Kiszka)

Derived from Stuart Brady's patch: Show the target directory as prefix
to the current module when building in quiet mode. This helps to gain
overview of the current build progress, specifically when running
parallelized builds.

Furthermore, suppress make command echoing when entering subdirs and
replace $(subst subdir-,,$@) with $* in the related rule.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6447 c046a42c-6fe2-441c-8c8c-71466251a162
Showing 2 changed files with 7 additions and 7 deletions
Makefile
... ... @@ -39,7 +39,7 @@ all: $(TOOLS) $(DOCS) recurse-all
39 39 SUBDIR_RULES=$(patsubst %,subdir-%, $(TARGET_DIRS))
40 40  
41 41 subdir-%:
42   - $(MAKE) -C $(subst subdir-,,$@) V="$(V)" all
  42 + $(call quiet-command,$(MAKE) -C $* V="$(V)" TARGET_DIR="$*/" all,)
43 43  
44 44 $(filter %-softmmu,$(SUBDIR_RULES)): libqemu_common.a
45 45 $(filter %-user,$(SUBDIR_RULES)): libqemu_user.a
... ...
rules.mak
1 1  
2 2 %.o: %.c
3   - $(call quiet-command,$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<," CC $@")
  3 + $(call quiet-command,$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<," CC $(TARGET_DIR)$@")
4 4  
5 5 %.o: %.S
6   - $(call quiet-command,$(CC) $(CPPFLAGS) -c -o $@ $<," AS $@")
  6 + $(call quiet-command,$(CC) $(CPPFLAGS) -c -o $@ $<," AS $(TARGET_DIR)$@")
7 7  
8 8 %.o: %.m
9   - $(call quiet-command,$(CC) $(CFLAGS) $(CPPFLAGS) -c -o $@ $<," OBJC $@")
  9 + $(call quiet-command,$(CC) $(CFLAGS) $(CPPFLAGS) -c -o $@ $<," OBJC $(TARGET_DIR)$@")
10 10  
11   -LINK = $(call quiet-command,$(CC) $(LDFLAGS) -o $@ $^ $(LIBS)," LINK $@")
  11 +LINK = $(call quiet-command,$(CC) $(LDFLAGS) -o $@ $^ $(LIBS)," LINK $(TARGET_DIR)$@")
12 12  
13 13 %$(EXESUF): %.o
14 14 $(LINK)
15 15  
16 16 %.a:
17   - $(call quiet-command,rm -f $@ && $(AR) rcs $@ $^," AR $@")
  17 + $(call quiet-command,rm -f $@ && $(AR) rcs $@ $^," AR $(TARGET_DIR)$@")
18 18  
19   -quiet-command = $(if $(V),$1,@echo $2 && $1)
  19 +quiet-command = $(if $(V),$1,$(if $(2),@echo $2 && $1, @$1))
... ...