summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xautogen.sh11
1 files changed, 9 insertions, 2 deletions
diff --git a/autogen.sh b/autogen.sh
index 0fb6c4f..916169a 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,2 +1,9 @@
-#!/bin/sh
-autoreconf --install
+#! /bin/sh
+
+test -n "$srcdir" || srcdir=`dirname "$0"`
+test -n "$srcdir" || srcdir=.
+(
+ cd "$srcdir" &&
+ autoreconf --force -v --install
+) || exit
+test -n "$NOCONFIGURE" || "$srcdir/configure" "$@"