From nobody Sat May 18 17:15:56 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1531552817511748.1592671875881; Sat, 14 Jul 2018 00:20:17 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.25]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 27EB7C0587EA; Sat, 14 Jul 2018 07:20:14 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 358022010CAC; Sat, 14 Jul 2018 07:20:13 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id C031918037ED; Sat, 14 Jul 2018 07:20:10 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6E7K8Fg027637 for ; Sat, 14 Jul 2018 03:20:08 -0400 Received: by smtp.corp.redhat.com (Postfix) id 1676F2027047; Sat, 14 Jul 2018 07:20:08 +0000 (UTC) Received: from localhost.localdomain (ovpn-204-33.brq.redhat.com [10.40.204.33]) by smtp.corp.redhat.com (Postfix) with ESMTP id 72A862026D74 for ; Sat, 14 Jul 2018 07:20:07 +0000 (UTC) From: Michal Privoznik To: libvir-list@redhat.com Date: Sat, 14 Jul 2018 09:20:04 +0200 Message-Id: X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH] maint: update to latest gnulib X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.25 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Sat, 14 Jul 2018 07:20:16 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" The changelog is quite long because we haven't updated gnulib in a while. Anyway, among the new changes you'll find GCC 8 support, faster build time, mingw fixes and many others. Signed-off-by: Michal Privoznik --- Pushed under "gnulib update" rule. .gnulib | 2 +- bootstrap | 266 ++++++++++++++++++++++++++++++++++++----------------------= ---- 2 files changed, 155 insertions(+), 113 deletions(-) diff --git a/.gnulib b/.gnulib index d6397dde2e..5b78831df0 160000 --- a/.gnulib +++ b/.gnulib @@ -1 +1 @@ -Subproject commit d6397dde2e127e246e3eeb5254a21f42cac783c8 +Subproject commit 5b78831df03b49408676227604cf16f90dee07ac diff --git a/bootstrap b/bootstrap index 92be11439a..ed3b0a4b70 100755 --- a/bootstrap +++ b/bootstrap @@ -1,6 +1,6 @@ #! /bin/sh # Print a version string. -scriptversion=3D2018-03-07.03; # UTC +scriptversion=3D2018-07-01.02; # UTC =20 # Bootstrap this package from checked-out sources. =20 @@ -47,6 +47,8 @@ PERL=3D"${PERL-perl}" =20 me=3D$0 =20 +default_gnulib_url=3Dgit://git.sv.gnu.org/gnulib + usage() { cat </dev/null; then - echo "$0: getting gnulib files..." - git submodule init -- "$gnulib_path" || exit $? - git submodule update -- "$gnulib_path" || exit $? - - elif [ ! -d "$gnulib_path" ]; then - echo "$0: getting gnulib files..." - - trap cleanup_gnulib 1 2 13 15 - - shallow=3D - git clone -h 2>&1 | grep -- --depth > /dev/null && shallow=3D'--depth = 2' - git clone $shallow git://git.sv.gnu.org/gnulib "$gnulib_path" || - cleanup_gnulib - - trap - 1 2 13 15 +if $use_gnulib; then + if $use_git; then + gnulib_path=3D$(git_modules_config submodule.gnulib.path) + test -z "$gnulib_path" && gnulib_path=3Dgnulib fi - GNULIB_SRCDIR=3D$gnulib_path - ;; -*) - # Use GNULIB_SRCDIR directly or as a reference. - if $use_git && test -d "$GNULIB_SRCDIR"/.git && \ - git_modules_config submodule.gnulib.url >/dev/null; then - echo "$0: getting gnulib files..." - if git submodule -h|grep -- --reference > /dev/null; then - # Prefer the one-liner available in git 1.6.4 or newer. - git submodule update --init --reference "$GNULIB_SRCDIR" \ - "$gnulib_path" || exit $? - else - # This fallback allows at least git 1.5.5. - if test -f "$gnulib_path"/gnulib-tool; then - # Since file already exists, assume submodule init already complet= e. - git submodule update -- "$gnulib_path" || exit $? - else - # Older git can't clone into an empty directory. - rmdir "$gnulib_path" 2>/dev/null - git clone --reference "$GNULIB_SRCDIR" \ - "$(git_modules_config submodule.gnulib.url)" "$gnulib_path" \ - && git submodule init -- "$gnulib_path" \ - && git submodule update -- "$gnulib_path" \ - || exit $? + + # Get gnulib files. Populate $GNULIB_SRCDIR, possibly updating a + # submodule, for use in the rest of the script. + + case ${GNULIB_SRCDIR--} in + -) + # Note that $use_git is necessarily true in this case. + if git_modules_config submodule.gnulib.url >/dev/null; then + echo "$0: getting gnulib files..." + git submodule init -- "$gnulib_path" || exit $? + git submodule update -- "$gnulib_path" || exit $? + + elif [ ! -d "$gnulib_path" ]; then + echo "$0: getting gnulib files..." + + trap cleanup_gnulib 1 2 13 15 + + shallow=3D + if test -z "$GNULIB_REVISION"; then + git clone -h 2>&1 | grep -- --depth > /dev/null && shallow=3D'--de= pth 2' fi + git clone $shallow ${GNULIB_URL:-$default_gnulib_url} "$gnulib_path"= \ + || cleanup_gnulib + + trap - 1 2 13 15 fi GNULIB_SRCDIR=3D$gnulib_path + ;; + *) + # Use GNULIB_SRCDIR directly or as a reference. + if $use_git && test -d "$GNULIB_SRCDIR"/.git && \ + git_modules_config submodule.gnulib.url >/dev/null; then + echo "$0: getting gnulib files..." + if git submodule -h|grep -- --reference > /dev/null; then + # Prefer the one-liner available in git 1.6.4 or newer. + git submodule update --init --reference "$GNULIB_SRCDIR" \ + "$gnulib_path" || exit $? + else + # This fallback allows at least git 1.5.5. + if test -f "$gnulib_path"/gnulib-tool; then + # Since file already exists, assume submodule init already compl= ete. + git submodule update -- "$gnulib_path" || exit $? + else + # Older git can't clone into an empty directory. + rmdir "$gnulib_path" 2>/dev/null + git clone --reference "$GNULIB_SRCDIR" \ + "$(git_modules_config submodule.gnulib.url)" "$gnulib_path" \ + && git submodule init -- "$gnulib_path" \ + && git submodule update -- "$gnulib_path" \ + || exit $? + fi + fi + GNULIB_SRCDIR=3D$gnulib_path + fi + ;; + 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_gn= ulib fi - ;; -esac =20 -# $GNULIB_SRCDIR now points to the version of gnulib to use, and -# we no longer need to use git or $gnulib_path below here. + # $GNULIB_SRCDIR now points to the version of gnulib to use, and + # we no longer need to use git or $gnulib_path below here. + + if $bootstrap_sync; then + cmp -s "$0" "$GNULIB_SRCDIR/build-aux/bootstrap" || { + echo "$0: updating bootstrap and restarting..." + case $(sh -c 'echo "$1"' -- a) in + a) ignored=3D--;; + *) ignored=3Dignored;; + esac + exec sh -c \ + 'cp "$1" "$2" && shift && exec "${CONFIG_SHELL-/bin/sh}" "$@"' \ + $ignored "$GNULIB_SRCDIR/build-aux/bootstrap" \ + "$0" "$@" --no-bootstrap-sync + } + fi =20 -if $bootstrap_sync; then - cmp -s "$0" "$GNULIB_SRCDIR/build-aux/bootstrap" || { - echo "$0: updating bootstrap and restarting..." - case $(sh -c 'echo "$1"' -- a) in - a) ignored=3D--;; - *) ignored=3Dignored;; - esac - exec sh -c \ - 'cp "$1" "$2" && shift && exec "${CONFIG_SHELL-/bin/sh}" "$@"' \ - $ignored "$GNULIB_SRCDIR/build-aux/bootstrap" \ - "$0" "$@" --no-bootstrap-sync - } + gnulib_tool=3D$GNULIB_SRCDIR/gnulib-tool + <$gnulib_tool || exit $? fi =20 -gnulib_tool=3D$GNULIB_SRCDIR/gnulib-tool -<$gnulib_tool || exit $? - # Get translations. =20 download_po_files() { @@ -898,32 +939,33 @@ fi =20 # Import from gnulib. =20 -gnulib_tool_options=3D"\ - --import\ - --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\ - $gnulib_tool_option_extras\ -" -if test $use_libtool =3D 1; then - case "$gnulib_tool_options " in - *' --libtool '*) ;; - *) gnulib_tool_options=3D"$gnulib_tool_options --libtool" ;; - esac -fi -echo "$0: $gnulib_tool $gnulib_tool_options --import ..." -$gnulib_tool $gnulib_tool_options --import $gnulib_modules \ - || die "gnulib-tool failed" +if $use_gnulib; then + gnulib_tool_options=3D"\ + --no-changelog\ + --aux-dir=3D$build_aux\ + --doc-base=3D$doc_base\ + --lib=3D$gnulib_name\ + --m4-base=3D$m4_base/\ + --source-base=3D$source_base/\ + --tests-base=3D$tests_base\ + --local-dir=3D$local_gl_dir\ + $gnulib_tool_option_extras\ + " + if test $use_libtool =3D 1; then + case "$gnulib_tool_options " in + *' --libtool '*) ;; + *) gnulib_tool_options=3D"$gnulib_tool_options --libtool" ;; + esac + fi + echo "$0: $gnulib_tool $gnulib_tool_options --import ..." + $gnulib_tool $gnulib_tool_options --import $gnulib_modules \ + || die "gnulib-tool failed" =20 -for file in $gnulib_files; do - symlink_to_dir "$GNULIB_SRCDIR" $file \ - || die "failed to symlink $file" -done + for file in $gnulib_files; do + symlink_to_dir "$GNULIB_SRCDIR" $file \ + || die "failed to symlink $file" + done +fi =20 bootstrap_post_import_hook \ || die "bootstrap_post_import_hook failed" --=20 2.16.4 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list