autogen: Support being called from external build dir

Building libusb from another build directory doesn't properly work right
now, as calling autogen.sh from there won't work.

An example is when using jhbuild to build it.

So always use absolute paths to call configure and bootstrap scripts

Signed-off-by: Ludovic Rousseau <ludovic.rousseau@free.fr>
This commit is contained in:
Marco Trevisan (Treviño) 2021-04-13 19:07:46 +02:00 committed by Ludovic Rousseau
parent bda2344f5e
commit 1001cb5558
3 changed files with 7 additions and 3 deletions

View file

@ -2,7 +2,9 @@
set -e
./bootstrap.sh
srcdir="$(dirname "$0")"
"$srcdir"/bootstrap.sh
if [ -z "$NOCONFIGURE" ]; then
exec ./configure --enable-examples-build --enable-tests-build "$@"
exec "$srcdir"/configure --enable-examples-build --enable-tests-build "$@"
fi

View file

@ -2,6 +2,8 @@
set -e
cd "$(dirname "$0")"
if [ ! -d m4 ]; then
mkdir m4
fi

View file

@ -1 +1 @@
#define LIBUSB_NANO 11608
#define LIBUSB_NANO 11609