build: let autogen.sh script change into top source directory

Acked-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
Thomas Haller 2014-07-04 19:58:03 +02:00
parent 9c2dbdfba5
commit c62cda91f7
1 changed files with 11 additions and 2 deletions

View File

@ -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"