From 8a03376544b046a84301847d1594f6c3674983ff Mon Sep 17 00:00:00 2001 From: Lucas De Marchi Date: Wed, 5 Dec 2012 09:22:50 -0200 Subject: Ensure config.h is included by using CPPFLAGS Instead of trying to include config.h in each file over the tree and possibly forgetting to include it, give a "-include config.h" argument to the compiler so it's guaranteed that a) it will be included for all source files and b) it will be the first header included. gdbus/ directory is left out, since it would break other projects using it. --- Makefile.obexd | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Makefile.obexd') diff --git a/Makefile.obexd b/Makefile.obexd index cbcd65db8..f8798f6b1 100644 --- a/Makefile.obexd +++ b/Makefile.obexd @@ -29,7 +29,8 @@ obexd_src_obexd_CFLAGS = @GLIB_CFLAGS@ @DBUS_CFLAGS@ \ -DPLUGINDIR=\""$(obex_plugindir)"\" \ -fPIC -D_FILE_OFFSET_BITS=64 -obexd_src_obexd_CPPFLAGS = -I$(builddir)/lib -I$(builddir)/obexd/src \ +obexd_src_obexd_CPPFLAGS = -include $(top_builddir)/config.h -I$(builddir)/lib \ + -I$(builddir)/obexd/src \ -I$(srcdir)/obexd/src -I$(srcdir)/btio \ -I$(srcdir)/gobex -I$(srcdir)/gdbus @@ -76,7 +77,8 @@ obexd_client_obex_client_LDADD = lib/libbluetooth-private.la \ obexd_client_obex_client_CFLAGS = @GLIB_CFLAGS@ @DBUS_CFLAGS@ \ -fPIC -D_FILE_OFFSET_BITS=64 -obexd_client_obex_client_CPPFLAGS = -I$(builddir)/lib -I$(srcdir)/obexd/src \ +obexd_client_obex_client_CPPFLAGS = -include $(top_builddir)/config.h \ + -I$(builddir)/lib -I$(srcdir)/obexd/src \ -I$(srcdir)/btio -I$(srcdir)/gobex \ -I$(srcdir)/gdbus -- cgit v1.2.1