From 346e339f5404bd04fa0fc5a8eacea17d68332538 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20R=C3=BChsen?= Date: Fri, 1 Mar 2019 20:13:38 +0100 Subject: Update ./bootstrap from latest gnulib MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Tim Rühsen --- bootstrap | 97 +++++++++++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 70 insertions(+), 27 deletions(-) diff --git a/bootstrap b/bootstrap index eddacfb64d..f80a56631e 100755 --- a/bootstrap +++ b/bootstrap @@ -1,10 +1,10 @@ #! /bin/sh # Print a version string. -scriptversion=2018-04-28.14; # UTC +scriptversion=2019-01-04.17; # UTC # Bootstrap this package from checked-out sources. -# Copyright (C) 2003-2018 Free Software Foundation, Inc. +# Copyright (C) 2003-2019 Free Software Foundation, Inc. # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -47,6 +47,8 @@ PERL="${PERL-perl}" me=$0 +default_gnulib_url=git://git.sv.gnu.org/gnulib + usage() { cat <&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:-$default_gnulib_url} "$gnulib_path" \ + || cleanup_gnulib trap - 1 2 13 15 fi @@ -671,6 +702,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. @@ -698,10 +734,7 @@ download_po_files() { subdir=$1 domain=$2 echo "$me: getting translations into $subdir for $domain..." - cmd=$(printf "$po_download_command_format" "$domain" "$subdir") - eval "$cmd" && return - # Fallback to HTTPS. - cmd=$(printf "$po_download_command_format2" "$subdir" "$domain") + cmd=$(printf "$po_download_command_format" "$subdir" "$domain") eval "$cmd" } @@ -902,13 +935,13 @@ fi if $use_gnulib; then gnulib_tool_options="\ --no-changelog\ - --aux-dir $build_aux\ - --doc-base $doc_base\ - --lib $gnulib_name\ - --m4-base $m4_base/\ - --source-base $source_base/\ - --tests-base $tests_base\ - --local-dir $local_gl_dir\ + --aux-dir=$build_aux\ + --doc-base=$doc_base\ + --lib=$gnulib_name\ + --m4-base=$m4_base/\ + --source-base=$source_base/\ + --tests-base=$tests_base\ + --local-dir=$local_gl_dir\ $gnulib_tool_option_extras\ " if test $use_libtool = 1; then @@ -930,6 +963,16 @@ fi bootstrap_post_import_hook \ || die "bootstrap_post_import_hook failed" +# Don't proceed if there are uninitialized submodules. In particular, +# the next step will remove dangling links, which might be links into +# uninitialized submodules. +# +# Uninitialized submodules are listed with an initial dash. +#if $use_git && git submodule | grep '^-' >/dev/null; then +# die "some git submodules are not initialized. " \ +# "Run 'git submodule init' and bootstrap again." +#fi + # Remove any dangling symlink matching "*.m4" or "*.[ch]" in some # gnulib-populated directories. Such .m4 files would cause aclocal to fail. # The following requires GNU find 4.2.3 or newer. Considering the usual -- cgit v1.2.1