[json-glib] [build] Fixes for passing distcheck



commit 182ca9cd9a3fabaa2533d841154856c61c570d08
Author: Emmanuele Bassi <ebassi linux intel com>
Date:   Thu Jun 18 11:14:13 2009 +0100

    [build] Fixes for passing distcheck

 Makefile.am                 |   17 ++++++++++++-----
 build/Makefile.am           |    2 ++
 build/autotools/Makefile.am |    4 +++-
 doc/reference/Makefile.am   |   20 +++++++++++---------
 json-glib/Makefile.am       |   27 ++++++++++++++-------------
 5 files changed, 42 insertions(+), 28 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index 88aea79..3d9b9df 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2,13 +2,13 @@ include $(top_srcdir)/Makefile.decl
 
 ACLOCAL_AMFLAGS = -I build/autotools
 
-SUBDIRS = json-glib doc
+SUBDIRS = build json-glib doc
 
 if ENABLE_GLIB_TEST
 SUBDIRS += tests
 endif
 
-DIST_SUBDIRS = json-glib doc tests
+DIST_SUBDIRS = build json-glib doc tests
 
 pcfiles = json-glib-1.0.pc
 
@@ -25,6 +25,13 @@ CLEANFILES = $(pcfiles) test-report.xml
 DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-maintainer-flags
 
 dist-hook:
-	git-log --stat > ChangeLog.in && \
-	cp -f ChangeLog.in $(distdir)/ChangeLog && \
-	rm -f ChangeLog.in
+	@if test -d "$(srcdir)/.git"; then \
+	  echo Generating ChangeLog ; \
+	  ( cd "$(srcdir)" \
+	    && $(top_srcdir)/missing --run git log --stat ) > ChangeLog.tmp \
+	  && mv -f ChangeLog.tmp $(top_distdir)/ChangeLog \
+	  || ( rm -f ChangeLog.tmp; \
+	       echo Failed to generate ChangeLog >&2 ); \
+	else \
+	  echo A git checkout is required to generate a ChangeLog >&2; \
+	fi
diff --git a/build/Makefile.am b/build/Makefile.am
index 8c90237..3606b71 100644
--- a/build/Makefile.am
+++ b/build/Makefile.am
@@ -1 +1,3 @@
+include $(top_srcdir)/Makefile.decl
+
 SUBDIRS = autotools
diff --git a/build/autotools/Makefile.am b/build/autotools/Makefile.am
index d0035d1..3d18d93 100644
--- a/build/autotools/Makefile.am
+++ b/build/autotools/Makefile.am
@@ -1,4 +1,6 @@
-EXTRA_DIST = \
+include $(top_srcdir)/Makefile.decl
+
+EXTRA_DIST += \
 	shave-libtool.in 	\
 	shave.in 		\
 	shave.m4 		\
diff --git a/doc/reference/Makefile.am b/doc/reference/Makefile.am
index 7fbfe85..5aa6ca5 100644
--- a/doc/reference/Makefile.am
+++ b/doc/reference/Makefile.am
@@ -1,16 +1,10 @@
-## Process this file with automake to produce Makefile.in
-include $(top_srcdir)/Makefile.decl
-
-# We require automake 1.6 at least.
-AUTOMAKE_OPTIONS = 1.6
-
 # This is a blank Makefile.am for using gtk-doc.
 # Copy this to your project's API docs directory and modify the variables to
 # suit your project. See the GTK+ Makefiles in gtk+/docs/reference for examples
 # of using the various options.
 
 # The name of the module, e.g. 'glib'.
-DOC_MODULE=json-glib
+DOC_MODULE = json-glib
 
 # The top-level SGML file. You can change this if you want to.
 DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.sgml
@@ -45,7 +39,7 @@ FIXXREF_OPTIONS=\
 # Used for dependencies. The docs will be rebuilt if any of these change.
 # e.g. HFILE_GLOB=$(top_srcdir)/gtk/*.h
 # e.g. CFILE_GLOB=$(top_srcdir)/gtk/*.c
-HFILE_GLOB=$(top_srcdir)/json-glib/*.h
+HFILE_GLOB=$(top_srcdir)/json-glib/*.h $(top_builddir)/json-glib/*.h
 CFILE_GLOB=$(top_srcdir)/json-glib/*.c
 
 # Header files to ignore when scanning.
@@ -81,9 +75,17 @@ expand_content_files=
 # e.g. INCLUDES=-I$(top_srcdir) -I$(top_builddir) $(GTK_DEBUG_FLAGS)
 # e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib)
 
-INCLUDES=-I$(top_srcdir) $(JSON_CFLAGS)
+INCLUDES=-I$(top_srcdir) -I$(top_builddir) $(JSON_CFLAGS)
 GTKDOC_LIBS=$(top_builddir)/json-glib/libjson-glib-1.0.la $(JSON_LIBS)
 
+test-report:
+	@true
+
+test:
+	@true
+
+check-local: test
+
 # This includes the standard gtk-doc make rules, copied by gtkdocize.
 include $(top_srcdir)/gtk-doc.make
 
diff --git a/json-glib/Makefile.am b/json-glib/Makefile.am
index 7726f3a..bb89cf6 100644
--- a/json-glib/Makefile.am
+++ b/json-glib/Makefile.am
@@ -32,25 +32,25 @@ BUILT_SOURCES = json-marshal.h json-marshal.c json-enum-types.h json-enum-types.
 STAMP_FILES = stamp-json-marshal.h stamp-json-enum-types.h
 
 source_h = \
-	$(srcdir)/json-generator.h 	\
-	$(srcdir)/json-gobject.h 	\
-	$(srcdir)/json-parser.h 	\
-	$(srcdir)/json-types.h 		\
+	$(top_srcdir)/json-glib/json-generator.h 	\
+	$(top_srcdir)/json-glib/json-gobject.h 		\
+	$(top_srcdir)/json-glib/json-parser.h 		\
+	$(top_srcdir)/json-glib/json-types.h 		\
 	$(NULL)
 
 source_h_private = \
-	$(srcdir)/json-scanner.h 	\
-	$(srcdir)/json-types-private.h	\
+	$(top_srcdir)/json-glib/json-scanner.h 		\
+	$(top_srcdir)/json-glib/json-types-private.h	\
 	$(NULL)
 
 source_c = \
-	json-array.c 		\
-	json-generator.c 	\
-	json-gobject.c 		\
-	json-node.c 		\
-	json-object.c 		\
-	json-parser.c 		\
-	json-scanner.c 		\
+	$(srcdir)/json-array.c 		\
+	$(srcdir)/json-generator.c 	\
+	$(srcdir)/json-gobject.c 	\
+	$(srcdir)/json-node.c 		\
+	$(srcdir)/json-object.c 	\
+	$(srcdir)/json-parser.c 	\
+	$(srcdir)/json-scanner.c 	\
 	$(NULL)
 
 json-marshal.h: stamp-json-marshal.h
@@ -115,6 +115,7 @@ DISTCLEANFILES = json-version.h
 
 EXTRA_DIST += \
 	json-version.h.in 	\
+	json-types-private.h	\
 	json-scanner.h 		\
 	json-glib.h 		\
 	json-marshal.list 	\



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]