From 692a4fc4124b7d674d7003732ec9299928043d16 Mon Sep 17 00:00:00 2001 From: Eric Blake Date: Wed, 14 Aug 2013 17:39:07 -0600 Subject: [PATCH] maint: update gnulib submodule Gnulib recently patched gcc warning detection so that it does not treat things like -Wno-unused-command-line-argument as supported in gcc (treating it as supported merely resulted in extra verbosity when an actual compile error occurred). It has also improved bootstrap to work with less hassle on OpenBSD. * .gnulib: Update to latest, in part for bootstrap and warnings improvements. * bootstrap: Resync from gnulib. Signed-off-by: Eric Blake --- .gnulib | 2 +- bootstrap | 37 ++++++++++++++++++------------------- 2 files changed, 19 insertions(+), 20 deletions(-) diff --git a/.gnulib b/.gnulib index 644c40496c..0ba087759d 160000 --- a/.gnulib +++ b/.gnulib @@ -1 +1 @@ -Subproject commit 644c40496cf7d5a705a73c9dd32b035fcecc2ab1 +Subproject commit 0ba087759d2797c8f7d3c34bef6268ba3fd212cb diff --git a/bootstrap b/bootstrap index a37fb8a039..cc7fc1b7dc 100755 --- a/bootstrap +++ b/bootstrap @@ -1,6 +1,6 @@ #! /bin/sh # Print a version string. -scriptversion=2013-07-03.20; # UTC +scriptversion=2013-08-15.22; # UTC # Bootstrap this package from checked-out sources. @@ -224,27 +224,21 @@ find_tool () find_tool_names=$@ eval "find_tool_res=\$$find_tool_envvar" if test x"$find_tool_res" = x; then - for i - do + for i; do if ($i --version /dev/null 2>&1; then - find_tool_res=$i - break + find_tool_res=$i + break fi done - else - find_tool_error_prefix="\$$find_tool_envvar: " fi - test x"$find_tool_res" != x \ - || die "one of these is required: $find_tool_names" - ($find_tool_res --version /dev/null 2>&1 \ - || die "${find_tool_error_prefix}cannot run $find_tool_res --version" + if test x"$find_tool_res" = x; then + warn_ "one of these is required: $find_tool_names;" + die "alternatively set $find_tool_envvar to a compatible tool" + fi eval "$find_tool_envvar=\$find_tool_res" eval "export $find_tool_envvar" } -# Find sha1sum, named gsha1sum on MacPorts, and shasum on Mac OS X 10.6. -find_tool SHA1SUM sha1sum gsha1sum shasum - # Override the default configuration, if necessary. # Make sure that bootstrap.conf is sourced from the current directory # if we were invoked as "sh bootstrap". @@ -326,7 +320,7 @@ insert_if_absent() { die "Error: Duplicate entries in $file: " $duplicate_entries fi linesold=$(gitignore_entries $file | wc -l) - linesnew=$(echo "$str" | gitignore_entries - $file | sort -u | wc -l) + linesnew=$( { echo "$str"; cat $file; } | gitignore_entries | sort -u | wc -l) if [ $linesold != $linesnew ] ; then { echo "$str" | cat - $file > $file.bak && mv $file.bak $file; } \ || die "insert_if_absent $file $str: failed" @@ -469,7 +463,7 @@ check_versions() { if [ "$req_ver" = "-" ]; then # Merely require app to exist; not all prereq apps are well-behaved # so we have to rely on $? rather than get_version. - $app --version >/dev/null 2>&1 + $app --version >/dev/null 2>&1 /dev/null; then + ! $SHA1SUM -c "$cksum_file" < "$new_po" > /dev/null 2>&1; then echo "$me: updated $po_dir/$po.po..." cp "$new_po" "$po_dir/$po.po" \ - && $SHA1SUM < "$new_po" > "$cksum_file" + && $SHA1SUM < "$new_po" > "$cksum_file" || return fi done } -- GitLab