summaryrefslogtreecommitdiff
path: root/build-aux/bootstrap
diff options
context:
space:
mode:
Diffstat (limited to 'build-aux/bootstrap')
-rwxr-xr-xbuild-aux/bootstrap15
1 files changed, 11 insertions, 4 deletions
diff --git a/build-aux/bootstrap b/build-aux/bootstrap
index eddacfb64d..747946abdb 100755
--- a/build-aux/bootstrap
+++ b/build-aux/bootstrap
@@ -1,6 +1,6 @@
#! /bin/sh
# Print a version string.
-scriptversion=2018-04-28.14; # UTC
+scriptversion=2018-05-27.20; # UTC
# Bootstrap this package from checked-out sources.
@@ -634,9 +634,11 @@ if $use_gnulib; then
trap cleanup_gnulib 1 2 13 15
shallow=
- git clone -h 2>&1 | grep -- --depth > /dev/null && shallow='--depth 2'
- git clone $shallow git://git.sv.gnu.org/gnulib "$gnulib_path" ||
- cleanup_gnulib
+ if test -z "$GNULIB_REVISION"; then
+ git clone -h 2>&1 | grep -- --depth > /dev/null && shallow='--depth 2'
+ fi
+ git clone $shallow ${GNULIB_URL:-git://git.sv.gnu.org/gnulib} \
+ "$gnulib_path" || cleanup_gnulib
trap - 1 2 13 15
fi
@@ -671,6 +673,11 @@ if $use_gnulib; then
;;
esac
+ if test -d "$GNULIB_SRCDIR"/.git && test -n "$GNULIB_REVISION" \
+ && ! git_modules_config submodule.gnulib.url >/dev/null; then
+ (cd "$GNULIB_SRCDIR" && git checkout "$GNULIB_REVISION") || cleanup_gnulib
+ fi
+
# $GNULIB_SRCDIR now points to the version of gnulib to use, and
# we no longer need to use git or $gnulib_path below here.