[json-glib] [build] Prefer automake-1.11 silent rules to shave



commit 6c20aae2b49a6d64db5e7d1ff3a82950ea9dc58a
Author: Emmanuele Bassi <ebassi gnome org>
Date:   Mon Sep 7 22:30:11 2009 +0100

    [build] Prefer automake-1.11 silent rules to shave
    
    If we have automake-1.11 installed then we should enable the
    AM_SILENT_RULES machinery instead of Shave - even though Shave's
    output is a lot cleaner.

 autogen.sh            |    2 +-
 configure.ac          |   20 ++++++++++++++++----
 json-glib/Makefile.am |    6 +++++-
 3 files changed, 22 insertions(+), 6 deletions(-)
---
diff --git a/autogen.sh b/autogen.sh
index af60db3..f10bc1b 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -18,7 +18,7 @@ which gnome-autogen.sh || {
         exit 1
 }
 
-REQUIRED_AUTOMAKE_VERSION=1.9 USE_GNOME2_MACROS=1 USE_COMMON_DOC_BUILD=yes . gnome-autogen.sh
+REQUIRED_AUTOMAKE_VERSION=1.10 USE_GNOME2_MACROS=1 USE_COMMON_DOC_BUILD=yes . gnome-autogen.sh
 
 # we need to patch gtk-doc.make to support pretty output with
 # libtool 1.x.  Should be fixed in the next version of gtk-doc.
diff --git a/configure.ac b/configure.ac
index 5709e32..c4b5306 100644
--- a/configure.ac
+++ b/configure.ac
@@ -13,7 +13,7 @@ m4_define([lt_age], [m4_eval(json_binary_age - json_interface_age)])
 
 m4_define([glib_req_version], [2.15])
 
-AC_PREREQ([2.59])
+AC_PREREQ([2.61])
 
 AC_INIT([json-glib],
         [json_version],
@@ -121,14 +121,26 @@ GTK_DOC_CHECK([1.11])
 
 GOBJECT_INTROSPECTION_CHECK([0.6.3])
 
-SHAVE_INIT([build/autotools], [enable])
+m4_ifdef([AM_SILENT_RULES],
+         [
+           AM_SILENT_RULES([yes])
+           use_shave=no
+         ],
+         [
+           SHAVE_INIT([build/autotools], [enable])
+           AC_CONFIG_FILES([
+                build/autotools/shave-libtool
+                build/autotools/shave
+           ])
+           use_shave=yes
+         ])
+
+AM_CONDITIONAL([USE_SHAVE], [test "x$use_shave" = "xyes"])
 
 AC_CONFIG_FILES([
         Makefile
         build/Makefile
         build/autotools/Makefile
-        build/autotools/shave-libtool
-        build/autotools/shave
         json-glib/Makefile
         json-glib/json-version.h
         json-glib/tests/Makefile
diff --git a/json-glib/Makefile.am b/json-glib/Makefile.am
index 586e027..5f29b94 100644
--- a/json-glib/Makefile.am
+++ b/json-glib/Makefile.am
@@ -1,6 +1,10 @@
 include $(top_srcdir)/Makefile.decl
 
+if USE_SHAVE
 QUIET_GEN = $(Q:@= echo '  GEN   '$@;)
+else
+QUIET_GEN = $(AM_V_GEN)
+endif # USE_SHAVE
 
 if ENABLE_GLIB_TEST
 SUBDIRS = . tests
@@ -129,7 +133,7 @@ if HAVE_INTROSPECTION
 BUILT_GIRSOURCES =
 
 Json-1.0.gir: $(INTROSPECTION_SCANNER) libjson-glib-1.0.la
-	$(INTROSPECTION_SCANNER) \
+	$(QUIET_GEN)$(INTROSPECTION_SCANNER) \
 		-v --namespace Json --nsversion=1.0 \
 		$(INCLUDES) \
 		--c-include='json-glib/json-object.h' \



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