[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 07/31] Generate config-devices.h
From: |
Juan Quintela |
Subject: |
[Qemu-devel] [PATCH 07/31] Generate config-devices.h |
Date: |
Wed, 7 Oct 2009 02:41:03 +0200 |
Generate config-devices.h for each target and config-all-devices.h for
common library. We don't want to name both config-devices.h to avoid
path problems
Signed-off-by: Juan Quintela <address@hidden>
---
Makefile | 7 +++++--
Makefile.target | 5 ++++-
config.h | 10 ++++++++++
3 files changed, 19 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index c3df3b2..1f71057 100644
--- a/Makefile
+++ b/Makefile
@@ -40,15 +40,18 @@ config-all-devices.mak: $(SUBDIR_DEVICES_MAK)
include config-all-devices.mak
-build-all: config-host.h
+build-all: config-host.h config-all-devices.h
$(call quiet-command, $(MAKE) $(SUBDIR_MAKEFLAGS) $(TOOLS) $(DOCS)
recurse-all,)
config-host.h: config-host.h-timestamp
config-host.h-timestamp: config-host.mak
+config-all-devices.h: config-all-devices.h-timestamp
+config-all-devices.h-timestamp: config-all-devices.mak
+
SUBDIR_RULES=$(patsubst %,subdir-%, $(TARGET_DIRS))
-subdir-%: config-host.h
+subdir-%: config-host.h config-all-devices.h
$(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $* V="$(V)"
TARGET_DIR="$*/" all,)
$(filter %-softmmu,$(SUBDIR_RULES)): libqemu_common.a
diff --git a/Makefile.target b/Makefile.target
index 1f2f9bc..191d979 100644
--- a/Makefile.target
+++ b/Makefile.target
@@ -30,7 +30,10 @@ kvm.o kvm-all.o: QEMU_CFLAGS+=$(KVM_CFLAGS)
config-target.h: config-target.h-timestamp
config-target.h-timestamp: config-target.mak
-all: config-target.h
+config-devices.h: config-devices.h-timestamp
+config-devices.h-timestamp: config-devices.mak
+
+all: config-target.h config-devices.h
$(call quiet-command, $(MAKE) $(PROGS),)
# Dummy command so that make thinks it has done something
diff --git a/config.h b/config.h
index 516acee..07d79d4 100644
--- a/config.h
+++ b/config.h
@@ -1,3 +1,13 @@
#include "config-host.h"
#include "config-target.h"
+
+/* We want to include different config files for specific targets
+ And for the common library. They need a different name because
+ we don't want to rely in paths */
+
+#if defined(NEED_CPU_H)
+#include "config-devices.h"
+#else
+#include "config-all-devices.h"
+#endif
--
1.6.2.5
- [Qemu-devel] [PATCH v5 00/31] Compile only devices that are used, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 01/31] Don't include config-host.mak from inside config.mak, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 02/31] Move generation of config-host.h to Makefile from configure, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 03/31] Remove useless check for config-host.mak, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 04/31] Rename config.{h, mak} config-target.{h, mak}, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 07/31] Generate config-devices.h,
Juan Quintela <=
- [Qemu-devel] [PATCH 05/31] Move generation of config-target.h to Makefile from configure, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 06/31] Add new config-devices.mak for each target, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 08/31] Generate gdbstub-xml.c only when needed, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 09/31] Only compile usb_ohci when one target uses it, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 10/31] Only compile isa_mmio when one target uses it, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 11/31] Only compile qdev_addr when one target uses it, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 13/31] Only compile ecc when one target uses it, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 12/31] Only compile nand when one target uses it, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 16/31] Only compile m48t59 when one target uses it, Juan Quintela, 2009/10/06
- [Qemu-devel] [PATCH 15/31] Only compile escc when one target uses it, Juan Quintela, 2009/10/06