[gnome-photos] build: Update to the latest version of the sample template
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-photos] build: Update to the latest version of the sample template
- Date: Thu, 17 Aug 2017 10:54:06 +0000 (UTC)
commit 68f6dc98a76028a91afc69d030744810e690fe68
Author: Debarshi Ray <debarshir gnome org>
Date: Thu Aug 17 12:10:18 2017 +0200
build: Update to the latest version of the sample template
... given in:
https://wiki.gnome.org/Projects/GnomeCommon/Migration
Note that the suggestion to use aclocal before intltoolize and
autoreconf doesn't work with the LIBGD_INIT macro and breaks the build.
autogen.sh | 45 +++++++++++++++++++++------------------------
1 files changed, 21 insertions(+), 24 deletions(-)
---
diff --git a/autogen.sh b/autogen.sh
index 69c4827..d0c3afa 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,44 +1,41 @@
#!/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) || {
- echo "**Error**: Directory "\`$srcdir\'" does not look like the top-level project directory"
- exit 1
-}
-
-olddir=`pwd`
cd $srcdir
-PKG_NAME=`autoconf --trace "AC_INIT:$1" "$srcdir/configure.ac"`
-ACLOCAL_FLAGS="-I libgd $ACLOCAL_FLAGS"
+(test -f configure.ac) || {
+ echo "*** ERROR: Directory '$srcdir' does not look like the top-level project directory ***"
+ exit 1
+}
+
+# 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
+ 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
-git submodule update --init --recursive
-
-set -x
+git submodule update --init --recursive || exit 1
intltoolize --force --copy --automake || exit 1
-autoreconf --verbose --force --install -Wno-portability || exit 1
-
-cd $olddir
+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
+ if [ "$1" = "--help" ]; then
+ exit 0
+ else
+ echo "Now type 'make' to compile $PKG_NAME" || exit 1
fi
else
echo "Skipping configure process."
fi
-
-set +x
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]