[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 03/33] build-sys: Move the print-variable rule to rules.mak
From: |
Laurent Vivier |
Subject: |
[PULL 03/33] build-sys: Move the print-variable rule to rules.mak |
Date: |
Mon, 9 Mar 2020 16:08:07 +0100 |
From: Philippe Mathieu-Daudé <address@hidden>
Currently the print-variable rule can only be used in the
root directory:
$ make print-vhost-user-json-y
vhost-user-json-y= contrib/vhost-user-gpu/50-qemu-gpu.json
tools/virtiofsd/50-qemu-virtiofsd.json
$ make -C i386-softmmu print-obj-y
make: Entering directory 'build/i386-softmmu'
make: *** No rule to make target 'print-obj-y'. Stop.
make: Leaving directory 'build/i386-softmmu'
Move it to rules.mak so we can use it from other directories:
$ make -C i386-softmmu print-obj-y
make: Entering directory 'build/i386-softmmu'
obj-y=qapi-introspect.o qapi-types-machine-target.o qapi-types-misc-target.o
qapi-types.o qapi-visit-machine-target.o qapi-visit-misc-target.o qapi-visit.o
qapi-events-machine-target.o qapi-events-misc-target.o qapi-events.o
qapi-commands-machine-target.o qapi-commands-misc-target.o qapi-commands.o
qapi-init-commands.o
make: Leaving directory 'build/i386-softmmu'
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Marc-André Lureau <address@hidden>
Message-Id: <address@hidden>
Signed-off-by: Laurent Vivier <address@hidden>
---
Makefile | 3 ---
rules.mak | 3 +++
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index 2e930688942b..37aed4a24422 100644
--- a/Makefile
+++ b/Makefile
@@ -15,9 +15,6 @@ UNCHECKED_GOALS := %clean TAGS cscope ctags dist \
help check-help print-% \
docker docker-% vm-help vm-test vm-build-%
-print-%:
- @echo '$*=$($*)'
-
# All following code might depend on configuration variables
ifneq ($(wildcard config-host.mak),)
# Put the all: rule here so that config-host.mak can contain dependencies.
diff --git a/rules.mak b/rules.mak
index e39b073d4648..694865b63ee8 100644
--- a/rules.mak
+++ b/rules.mak
@@ -435,3 +435,6 @@ sentinel = .$(subst $(SPACE),_,$(subst /,_,$1)).sentinel.
atomic = $(eval $1: $(call sentinel,$1) ; @:) \
$(call sentinel,$1) : $2 ; @touch $$@ \
$(foreach t,$1,$(if $(wildcard $t),,$(shell rm -f $(call
sentinel,$1))))
+
+print-%:
+ @echo '$*=$($*)'
--
2.24.1
- [PULL 00/33] Trivial branch patches, Laurent Vivier, 2020/03/09
- [PULL 03/33] build-sys: Move the print-variable rule to rules.mak,
Laurent Vivier <=
- [PULL 08/33] vl: Add missing "hw/boards.h" include, Laurent Vivier, 2020/03/09
- [PULL 05/33] hw/net/e1000: Add readops/writeops typedefs, Laurent Vivier, 2020/03/09
- [PULL 06/33] hw/net/e1000: Move macreg[] arrays to .rodata to save 1MiB of .data, Laurent Vivier, 2020/03/09
- [PULL 04/33] hw/audio/fmopl: Fix a typo twice, Laurent Vivier, 2020/03/09
- [PULL 02/33] maint: Include top-level *.rst files early in git diff, Laurent Vivier, 2020/03/09
- [PULL 11/33] hw/timer: Remove unused "ui/console.h" header, Laurent Vivier, 2020/03/09
- [PULL 12/33] hw/usb/dev-storage: Remove unused "ui/console.h" header, Laurent Vivier, 2020/03/09
- [PULL 01/33] dp8393x: Mask EOL bit from descriptor addresses, take 2, Laurent Vivier, 2020/03/09
- [PULL 19/33] hw/pci-host/q35: Include "qemu/range.h", Laurent Vivier, 2020/03/09
- [PULL 13/33] hw/i386/intel_iommu: Remove unused includes, Laurent Vivier, 2020/03/09