]> git.ipfire.org Git - thirdparty/libnl.git/commitdiff
build: let autogen.sh script change into top source directory
authorThomas Haller <thaller@redhat.com>
Fri, 4 Jul 2014 17:58:03 +0000 (19:58 +0200)
committerThomas Haller <thaller@redhat.com>
Mon, 7 Jul 2014 09:12:38 +0000 (11:12 +0200)
Acked-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Thomas Haller <thaller@redhat.com>
autogen.sh

index c3538bb8292dee2c2e173bbce104c8aa60a353e7..e498fae1554c0d1802626f03807607e8a2c4a7b0 100755 (executable)
@@ -1,6 +1,15 @@
 #!/bin/bash
 
-autoreconf -fi;
+die() {
+    echo "$@" >&2
+    exit 1
+}
+
+BASEDIR="$(dirname "$0")"
+
+cd "$BASEDIR" || die "Could not change into base directory $BASEDIR"
+
+autoreconf -fi || die "Error during autoreconf"
 rm -Rf autom4te.cache;
 
-doc/autogen.sh
+doc/autogen.sh || die "Error during doc/autogen.sh"