From: Julio Montes <julio.mon...@intel.com> v2: generate config-devices.h which contains the list of devices enabled
Message-Id: <20190705143554.10295-1-julio.mon...@intel.com> Signed-off-by: Paolo Bonzini <pbonz...@redhat.com> --- Makefile.target | 5 +++++ scripts/clean-includes | 2 +- scripts/create_config | 2 ++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Makefile.target b/Makefile.target index 72c267f..25383f5 100644 --- a/Makefile.target +++ b/Makefile.target @@ -45,6 +45,9 @@ include $(SRC_PATH)/tests/tcg/Makefile.include config-target.h: config-target.h-timestamp config-target.h-timestamp: config-target.mak +config-devices.h: config-devices.h-timestamp +config-devices.h-timestamp: config-devices.mak + ifdef CONFIG_TRACE_SYSTEMTAP stap: $(QEMU_PROG).stp-installed $(QEMU_PROG).stp $(QEMU_PROG)-simpletrace.stp $(QEMU_PROG)-log.stp @@ -171,6 +174,8 @@ generated-files-y += hmp-commands.h hmp-commands-info.h endif # CONFIG_SOFTMMU +generated-files-y += config-devices.h + dummy := $(call unnest-vars,,obj-y) all-obj-y := $(obj-y) diff --git a/scripts/clean-includes b/scripts/clean-includes index dd938da..fb05a63 100755 --- a/scripts/clean-includes +++ b/scripts/clean-includes @@ -161,7 +161,7 @@ for f in "$@"; do # Remove includes that osdep.h already provides perl -n -i -e 'print if !/\s*#\s*include\s*(["<][^>"]*[">])/ || ! (grep { $_ eq $1 } qw ( - "config-host.h" "config-target.h" "qemu/compiler.h" + "config-host.h" "config-target.h" "config-devices.h" "qemu/compiler.h" <setjmp.h> <stdarg.h> <stddef.h> <stdbool.h> <stdint.h> <sys/types.h> <stdlib.h> <stdio.h> <string.h> <strings.h> <inttypes.h> <limits.h> <unistd.h> <time.h> <ctype.h> <errno.h> <fcntl.h> diff --git a/scripts/create_config b/scripts/create_config index d727e5e..00e86c8 100755 --- a/scripts/create_config +++ b/scripts/create_config @@ -58,6 +58,8 @@ case $line in name=${line%=*} echo "#define $name 1" ;; + CONFIG_*=n) # configuration + ;; CONFIG_*=*) # configuration name=${line%=*} value=${line#*=} -- 1.8.3.1