[PATCH app-xdm 4/5] config: move common headers into the include directory

Gaetan Nadon memsize at videotron.ca
Mon Nov 22 07:32:48 PST 2010


They provide interfaces to multiple executables

Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
---
 Makefile.am                        |   10 +++-------
 chooser/Makefile.am                |    2 +-
 configure.ac                       |    1 +
 greeter/Makefile.am                |    3 ++-
 include/Makefile.am                |    6 ++++++
 dm.h => include/dm.h               |    0
 dm_auth.h => include/dm_auth.h     |    0
 dm_error.h => include/dm_error.h   |    0
 dm_socket.h => include/dm_socket.h |    0
 greet.h => include/greet.h         |    0
 xdmshell/Makefile.am               |    2 +-
 11 files changed, 14 insertions(+), 10 deletions(-)
 create mode 100644 include/Makefile.am
 rename dm.h => include/dm.h (100%)
 rename dm_auth.h => include/dm_auth.h (100%)
 rename dm_error.h => include/dm_error.h (100%)
 rename dm_socket.h => include/dm_socket.h (100%)
 rename greet.h => include/greet.h (100%)

diff --git a/Makefile.am b/Makefile.am
index 42c58d1..c750ea5 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -19,9 +19,10 @@
 #  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 #  PERFORMANCE OF THIS SOFTWARE.
 
-SUBDIRS = chooser config greeter man xdmshell
+SUBDIRS = chooser config greeter include man xdmshell
 
 bin_PROGRAMS = xdm
+AM_CPPFLAGS = -I$(top_srcdir)/include
 AM_CFLAGS = $(CWARNFLAGS)
 
 #
@@ -55,12 +56,7 @@ xdm_SOURCES =	\
         mitauth.c \
         genauth.c \
         access.c \
-        choose.c \
-        dm_auth.h \
-        dm_error.h \
-        dm.h \
-        dm_socket.h \
-        greet.h
+        choose.c
 
 if HAS_XDM_AUTH
 xdm_CFLAGS +=  -DHASXDMAUTH
diff --git a/chooser/Makefile.am b/chooser/Makefile.am
index 8374bbe..12bb3ed 100644
--- a/chooser/Makefile.am
+++ b/chooser/Makefile.am
@@ -1,7 +1,7 @@
 xdmlibdir = $(XDMLIBDIR)
 xdmlib_PROGRAMS = chooser
 
-AM_CPPFLAGS = -I$(top_srcdir)
+AM_CPPFLAGS = -I$(top_srcdir)/include
 AM_CFLAGS = $(CWARNFLAGS) $(CHOOSER_CFLAGS)
 AM_LDFLAGS = $(CHOOSER_LIBS)
 
diff --git a/configure.ac b/configure.ac
index e3ac7a4..a690ff7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -540,6 +540,7 @@ AC_CONFIG_FILES([Makefile
 		chooser/Makefile
 		config/Makefile
 		greeter/Makefile
+		include/Makefile
 		man/Makefile
 		xdmshell/Makefile])
 AC_OUTPUT
diff --git a/greeter/Makefile.am b/greeter/Makefile.am
index 52c84b0..f0a8491 100644
--- a/greeter/Makefile.am
+++ b/greeter/Makefile.am
@@ -11,7 +11,8 @@ libXdmGreet_la_SOURCES = \
 
 libXdmGreet_la_LIBADD = $(XDMGREET_LIBS)
 
-AM_CFLAGS = $(CWARNFLAGS) $(XDMGREET_CFLAGS) -DGREET_LIB -I$(top_srcdir)
+AM_CPPFLAGS = -I$(top_srcdir)/include
+AM_CFLAGS = $(CWARNFLAGS) $(XDMGREET_CFLAGS) -DGREET_LIB
 
 libXdmGreet_la_LDFLAGS = -module -avoid-version
 
diff --git a/include/Makefile.am b/include/Makefile.am
new file mode 100644
index 0000000..88ed7b6
--- /dev/null
+++ b/include/Makefile.am
@@ -0,0 +1,6 @@
+noinst_HEADERS = 	\
+	dm.h		\
+	dm_auth.h	\
+	dm_error.h	\
+	dm_socket.h	\
+	greet.h
diff --git a/dm.h b/include/dm.h
similarity index 100%
rename from dm.h
rename to include/dm.h
diff --git a/dm_auth.h b/include/dm_auth.h
similarity index 100%
rename from dm_auth.h
rename to include/dm_auth.h
diff --git a/dm_error.h b/include/dm_error.h
similarity index 100%
rename from dm_error.h
rename to include/dm_error.h
diff --git a/dm_socket.h b/include/dm_socket.h
similarity index 100%
rename from dm_socket.h
rename to include/dm_socket.h
diff --git a/greet.h b/include/greet.h
similarity index 100%
rename from greet.h
rename to include/greet.h
diff --git a/xdmshell/Makefile.am b/xdmshell/Makefile.am
index 137d74a..ea49048 100644
--- a/xdmshell/Makefile.am
+++ b/xdmshell/Makefile.am
@@ -5,7 +5,7 @@ else
 noinst_PROGRAMS = xdmshell
 endif
 
-AM_CPPFLAGS = -I$(top_srcdir)
+AM_CPPFLAGS = -I$(top_srcdir)/include
 AM_CFLAGS = 			\
 	$(CWARNFLAGS)		\
 	$(XDMSHELL_CFLAGS)	\
-- 
1.6.0.4



More information about the xorg-devel mailing list