summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErnestas Kulik <ernestask@src.gnome.org>2016-07-31 17:08:32 +0300
committerErnestas Kulik <ernestask@src.gnome.org>2016-08-01 16:57:24 +0300
commitda85fcebaee5bababc270643d7931ea264f22d03 (patch)
treea5ac99a5c898dbe3bf15d53e8b3d0a7df8b8480b
parente9fe639b20c14c97ef64ec6730839eac4e211f4f (diff)
downloadnautilus-da85fcebaee5bababc270643d7931ea264f22d03.tar.gz
Port from gnome-common
gnome-common has been deprecated for quite some time now and using upstream autoconf-archive macros is now recommended. This commit makes changes to the project files as per the GNOME migration guide. https://bugzilla.gnome.org/show_bug.cgi?id=769362
-rwxr-xr-xautogen.sh46
-rw-r--r--configure.ac2
2 files changed, 35 insertions, 13 deletions
diff --git a/autogen.sh b/autogen.sh
index a0159087b..e931e2bcd 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,20 +1,42 @@
#!/bin/sh
# Run this to generate all the initial makefiles, etc.
+test -n "$srcdir" || srcdir=$(dirname "$0")
+test -n "$srcdir" || srcdir=.
-srcdir=`dirname $0`
-test -z "$srcdir" && srcdir=.
+olddir=$(pwd)
-(test -f $srcdir/configure.ac \
- && test -f $srcdir/README) || {
- echo -n "**Error**: Directory "\`$srcdir\'" does not look like the"
- echo " top-level $PKG_NAME directory"
- exit 1
+cd $srcdir
+
+(test -f configure.ac) || {
+ echo "*** ERROR: Directory '$srcdir' does not look like the top-level project directory ***"
+ exit 1
}
git submodule update --init --recursive
-which gnome-autogen.sh || {
- echo "gnome-autogen.sh not found, you need to install gnome-common"
- exit 1
-}
-REQUIRED_AUTOMAKE_VERSION=1.9 . gnome-autogen.sh
+# shellcheck disable=SC2016
+PKG_NAME=$(autoconf --trace 'AC_INIT:$1' configure.ac)
+
+if [ "$#" = 0 -a "x$NOCONFIGURE" = "x" ]; then
+ echo "*** WARNING: I am going to run 'configure' with no arguments." >&2
+ echo "*** If you wish to pass any to it, please specify them on the" >&2
+ echo "*** '$0' command line." >&2
+ echo "" >&2
+fi
+
+aclocal --install || exit 1
+glib-gettextize --force --copy || exit 1
+gtkdocize --copy || exit 1
+intltoolize --force --copy --automake || exit 1
+autoreconf --verbose --force --install || exit 1
+
+cd "$olddir"
+if [ "$NOCONFIGURE" = "" ]; then
+ $srcdir/configure "$@" || exit 1
+
+ if [ "$1" = "--help" ]; then exit 0 else
+ echo "Now type 'make' to compile $PKG_NAME" || exit 1
+ fi
+else
+ echo "Skipping configure process."
+fi
diff --git a/configure.ac b/configure.ac
index 38ead2ec2..d204b885c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -29,7 +29,6 @@ AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([1.11 dist-xz no-dist-gzip tar-ustar foreign])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
AM_MAINTAINER_MODE([enable])
-GNOME_MAINTAINER_MODE_DEFINES
dnl We need to decrement current by one in the calculation of the age because
dnl the library was started with version "1:0:0" instead of "0:0:0"
@@ -66,6 +65,7 @@ IT_PROG_INTLTOOL([0.50])
dnl ==========================================================================
+AX_REQUIRE_DEFINED([GTK_DOC_CHECK])
GTK_DOC_CHECK([1.10],[--flavour no-tmpl])
dnl ==========================================================================