From: Ian Campbell Date: Tue, 7 Jul 2015 15:40:32 +0000 (+0100) Subject: tools: Do not add top-level tools dir to include path X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~2893 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=89483dc2b3eca29b9b104019bda1883c08150dc9;p=xen.git tools: Do not add top-level tools dir to include path Instead switch to an explicit -include $(XEN_ROOT)/tools/config.h to pickup config.h. Most places already do this, fixup the rest. Signed-off-by: Ian Campbell Acked-by: Wei Liu Acked-by: Ian Jackson --- diff --git a/tools/libfsimage/ext2fs-lib/Makefile b/tools/libfsimage/ext2fs-lib/Makefile index 671fbffd73..0e00fde0e1 100644 --- a/tools/libfsimage/ext2fs-lib/Makefile +++ b/tools/libfsimage/ext2fs-lib/Makefile @@ -6,8 +6,8 @@ FS = ext2fs-lib FS_LIBDEPS = $(EXTFS_LIBS) -# Include configure output (config.h) to headers search path -CFLAGS += -I$(XEN_ROOT)/tools +# Include configure output (config.h) +CFLAGS += -include $(XEN_ROOT)/tools/config.h .PHONY: all all: fs-all diff --git a/tools/libfsimage/ext2fs-lib/ext2fs-lib.c b/tools/libfsimage/ext2fs-lib/ext2fs-lib.c index ed471465f9..84b6d1e9c3 100644 --- a/tools/libfsimage/ext2fs-lib/ext2fs-lib.c +++ b/tools/libfsimage/ext2fs-lib/ext2fs-lib.c @@ -21,9 +21,6 @@ * Use is subject to license terms. */ -/* Include output from configure */ -#include - #include #include INCLUDE_EXTFS_H #include diff --git a/tools/misc/Makefile b/tools/misc/Makefile index 82c361f285..c4490f33da 100644 --- a/tools/misc/Makefile +++ b/tools/misc/Makefile @@ -1,7 +1,9 @@ XEN_ROOT=$(CURDIR)/../.. include $(XEN_ROOT)/tools/Rules.mk -CFLAGS += -Werror -I$(XEN_ROOT)/tools +CFLAGS += -Werror +# Include configure output (config.h) +CFLAGS += -include $(XEN_ROOT)/tools/config.h CFLAGS += $(CFLAGS_libxenctrl) CFLAGS += $(CFLAGS_xeninclude) CFLAGS += $(CFLAGS_libxenstore) diff --git a/tools/misc/gtraceview.c b/tools/misc/gtraceview.c index 501f86ab0f..d9f1185332 100644 --- a/tools/misc/gtraceview.c +++ b/tools/misc/gtraceview.c @@ -16,9 +16,6 @@ * Place - Suite 330, Boston, MA 02111-1307 USA. */ -/* Include output from configure */ -#include - #include #include #include diff --git a/tools/ocaml/xenstored/Makefile b/tools/ocaml/xenstored/Makefile index bcf09d487e..d861f11315 100644 --- a/tools/ocaml/xenstored/Makefile +++ b/tools/ocaml/xenstored/Makefile @@ -2,7 +2,8 @@ XEN_ROOT = $(CURDIR)/../../.. OCAML_TOPLEVEL = $(CURDIR)/.. include $(OCAML_TOPLEVEL)/common.make -CFLAGS += -I$(XEN_ROOT)/tools/ +# Include configure output (config.h) +CFLAGS += -include $(XEN_ROOT)/tools/config.h CFLAGS-$(CONFIG_SYSTEMD) += $(SYSTEMD_CFLAGS) LDFLAGS-$(CONFIG_SYSTEMD) += $(SYSTEMD_LIBS) diff --git a/tools/ocaml/xenstored/systemd_stubs.c b/tools/ocaml/xenstored/systemd_stubs.c index 623592c95f..d924ff1bd7 100644 --- a/tools/ocaml/xenstored/systemd_stubs.c +++ b/tools/ocaml/xenstored/systemd_stubs.c @@ -22,7 +22,6 @@ #include #include #include -#include #if defined(HAVE_SYSTEMD) diff --git a/tools/xenstat/xentop/Makefile b/tools/xenstat/xentop/Makefile index 97950b970b..e67c9ab5ba 100644 --- a/tools/xenstat/xentop/Makefile +++ b/tools/xenstat/xentop/Makefile @@ -22,8 +22,8 @@ CFLAGS += -DGCC_PRINTF -Werror $(CFLAGS_libxenstat) LDLIBS += $(LDLIBS_libxenstat) $(CURSES_LIBS) $(TINFO_LIBS) $(SOCKET_LIBS) -lm -lyajl CFLAGS += -DHOST_$(XEN_OS) -# Include configure output (config.h) to headers search path -CFLAGS += -I$(XEN_ROOT)/tools +# Include configure output (config.h) +CFLAGS += -include $(XEN_ROOT)/tools/config.h LDFLAGS += $(APPEND_LDFLAGS) .PHONY: all diff --git a/tools/xenstat/xentop/xentop.c b/tools/xenstat/xentop/xentop.c index 23b57f18e3..8173886d43 100644 --- a/tools/xenstat/xentop/xentop.c +++ b/tools/xenstat/xentop/xentop.c @@ -19,9 +19,6 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -/* Include output from configure */ -#include - /* get curses header from configure */ #include INCLUDE_CURSES_H diff --git a/tools/xenstore/Makefile b/tools/xenstore/Makefile index 30f3b46313..1b4a4942be 100644 --- a/tools/xenstore/Makefile +++ b/tools/xenstore/Makefile @@ -6,7 +6,8 @@ MINOR = 3 CFLAGS += -Werror CFLAGS += -I. -CFLAGS += -I$(XEN_ROOT)/tools/ +# Include configure output (config.h) +CFLAGS += -include $(XEN_ROOT)/tools/config.h CFLAGS += -I./include CFLAGS += $(CFLAGS_libxenctrl) CFLAGS += -DXEN_LIB_STORED="\"$(XEN_LIB_STORED)\"" diff --git a/tools/xenstore/xenstored_core.c b/tools/xenstore/xenstored_core.c index 3fd9a20b53..b18000da93 100644 --- a/tools/xenstore/xenstored_core.c +++ b/tools/xenstore/xenstored_core.c @@ -40,7 +40,6 @@ #include #include #include -#include #include "utils.h" #include "list.h"