[gnome-calculator] Fix non-srcdir builds
- From: Robert Roth <robertroth src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calculator] Fix non-srcdir builds
- Date: Tue, 30 Jan 2018 17:03:39 +0000 (UTC)
commit 1a887c8122b16269f3151317bfa64999b559d712
Author: Robert Roth <robert roth off gmail com>
Date: Tue Jan 30 19:03:25 2018 +0200
Fix non-srcdir builds
autogen.sh | 21 +++++++++------------
1 files changed, 9 insertions(+), 12 deletions(-)
---
diff --git a/autogen.sh b/autogen.sh
index 2f4d7e6..4f419f9 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,7 +1,11 @@
#!/bin/sh
# Run this to generate all the initial makefiles, etc.
-srcdir=`dirname $0`
-test -z "$srcdir" && srcdir=.
+
+test -n "$srcdir" || srcdir=`dirname "$0"`
+test -n "$srcdir" || srcdir=.
+
+olddir=`pwd`
+cd "$srcdir"
(test -f $srcdir/configure.ac) || {
echo "**Error**: Directory "\`$srcdir\'" does not look like the top-level project directory"
@@ -23,14 +27,7 @@ intltoolize --force --copy --automake || exit 1
autoreconf --verbose --force --install -Wno-portability || exit 1
{ set +x; } 2>/dev/null
-if [ "$NOCONFIGURE" = "" ]; then
- set -x
- $srcdir/configure "$@" || exit 1
- { set +x; } 2>/dev/null
+cd "$olddir"
+test -n "$NOCONFIGURE" || "$srcdir/configure" "$@"
+
- if [ "$1" = "--help" ]; then exit 0 else
- echo "Now type \`make\' to compile $PKG_NAME" || exit 1
- fi
-else
- echo "Skipping configure process."
-fi
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]