From 26373b334889f5ae2e2737ff447eb25b1700fa2f Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Fri, 15 Sep 2017 16:18:50 +0200 Subject: build: Fix autogen.sh with srcdir != builddir --- autogen.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/autogen.sh b/autogen.sh index 3292973..f45d20f 100755 --- a/autogen.sh +++ b/autogen.sh @@ -1,4 +1,11 @@ #!/bin/sh + +olddir=`pwd` +srcdir=`dirname $0` +test -z "$srcdir" && srcdir=. + +cd "$srcdir" + gprefix=`which glibtoolize 2>&1 >/dev/null` if [ $? -eq 0 ]; then glibtoolize --force @@ -10,6 +17,8 @@ autoheader automake --add-missing autoconf +cd "$olddir" + if [ -z "$NOCONFIGURE" ]; then - ./configure "$@" + $srcdir/configure "$@" fi -- cgit v1.1-32-gdbae