summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheppitak Karoonboonyanan <thep@linux.thai.net>2012-08-22 11:52:21 +0700
committerJens Georg <mail@jensge.org>2012-11-30 14:21:02 +0100
commit1622cb1ce28768a8029cbb635d0925351e530ee3 (patch)
tree225ec39f42d137793076bc86abc46878b7647cdd
parentbc3e87b01bf90d10845dc3146404c5fbe20f1f78 (diff)
downloadgssdp-1622cb1ce28768a8029cbb635d0925351e530ee3.tar.gz
Allow non-sourcedir build
https://bugzilla.gnome.org/show_bug.cgi?id=682576
-rwxr-xr-xautogen.sh12
1 files changed, 11 insertions, 1 deletions
diff --git a/autogen.sh b/autogen.sh
index b9f6b87..2227774 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -21,6 +21,16 @@
# Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
+test -n "$srcdir" || srcdir=`dirname "$0"`
+test -n "$srcdir" || srcdir=.
+
+olddir=`pwd`
+cd "$srcdir"
+
gtkdocize || exit 1
ACLOCAL="${ACLOCAL-aclocal} $ACLOCAL_FLAGS" autoreconf -v --install || exit 1
-./configure --enable-maintainer-mode --enable-debug "$@"
+
+cd "$olddir"
+if test -z "$NOCONFIGURE"; then
+ "$srcdir/configure" --enable-maintainer-mode --enable-debug "$@"
+fi