]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
all: update gnulib submodule to latest
authorPádraig Brady <P@draigBrady.com>
Tue, 22 Nov 2016 19:41:20 +0000 (19:41 +0000)
committerPádraig Brady <P@draigBrady.com>
Tue, 22 Nov 2016 20:10:24 +0000 (20:10 +0000)
Also sync these copies with gnulib:
* bootstrap: Sync missed part of AIX support.
* tests/init.sh: Support compare_ on AIX.

bootstrap
gnulib
tests/init.sh

index 1755d04ebbc9c31b10d8ea4b8a7e059dcbd91d9d..5d3c2898cf6156b32698d4907c5988c5b833174d 100755 (executable)
--- a/bootstrap
+++ b/bootstrap
@@ -420,21 +420,21 @@ sort_ver() { # sort -V is not generally available
 
 get_version_sed='
 # Move version to start of line.
-          s/.*[v ]\([0-9]\)/\1/
+s/.*[v ]\([0-9]\)/\1/
 
-          # Skip lines that do not start with version.
-          /^[0-9]/!d
+# Skip lines that do not start with version.
+/^[0-9]/!d
 
-          # Remove characters after the version.
-          s/[^.a-z0-9-].*//
+# Remove characters after the version.
+s/[^.a-z0-9-].*//
 
-          # The first component must be digits only.
-          s/^\([0-9]*\)[a-z-].*/\1/
+# The first component must be digits only.
+s/^\([0-9]*\)[a-z-].*/\1/
 
-          #the following essentially does s/5.005/5.5/
-          s/\.0*\([1-9]\)/.\1/g
-          p
-          q'
+#the following essentially does s/5.005/5.5/
+s/\.0*\([1-9]\)/.\1/g
+p
+q'
 
 get_version() {
   app=$1
diff --git a/gnulib b/gnulib
index 012262350494958b70da16b43ed9acf24ee7fbc1..6b26660a01125acb394e39ac71635c8df4c110c4 160000 (submodule)
--- a/gnulib
+++ b/gnulib
@@ -1 +1 @@
-Subproject commit 012262350494958b70da16b43ed9acf24ee7fbc1
+Subproject commit 6b26660a01125acb394e39ac71635c8df4c110c4
index 09b07394f9e90422f04e0d803cc651aef65d4748..da743c2ab0dd1f2e88dcf4ca7770b2c137b6a250 100755 (executable)
@@ -295,50 +295,24 @@ compare_dev_null_ ()
   return 2
 }
 
-if diff_out_=`exec 2>/dev/null; diff -u "$0" "$0" < /dev/null` \
-   && diff -u Makefile "$0" 2>/dev/null | grep '^[+]#!' >/dev/null; then
-  # diff accepts the -u option and does not (like AIX 7 'diff') produce an
-  # extra space on column 1 of every content line.
-  if test -z "$diff_out_"; then
-    compare_ () { diff -u "$@"; }
-  else
-    compare_ ()
-    {
-      if diff -u "$@" > diff.out; then
-        # No differences were found, but Solaris 'diff' produces output
-        # "No differences encountered". Hide this output.
-        rm -f diff.out
-        true
-      else
-        cat diff.out
-        rm -f diff.out
-        false
-      fi
-    }
-  fi
-elif
-  for diff_opt_ in -U3 -c '' no; do
-    test "$diff_opt_" = no && break
-    diff_out_=`exec 2>/dev/null; diff $diff_opt_ "$0" "$0" </dev/null` && break
-  done
-  test "$diff_opt_" != no
-then
+for diff_opt_ in -u -U3 -c '' no; do
+  test "$diff_opt_" != no &&
+    diff_out_=`exec 2>/dev/null; diff $diff_opt_ "$0" "$0" < /dev/null` &&
+    break
+done
+if test "$diff_opt_" != no; then
   if test -z "$diff_out_"; then
     compare_ () { diff $diff_opt_ "$@"; }
   else
     compare_ ()
     {
-      if diff $diff_opt_ "$@" > diff.out; then
-        # No differences were found, but AIX and HP-UX 'diff' produce output
-        # "No differences encountered" or "There are no differences between the
-        # files.". Hide this output.
-        rm -f diff.out
-        true
-      else
-        cat diff.out
-        rm -f diff.out
-        false
-      fi
+      # If no differences were found, AIX and HP-UX 'diff' produce output
+      # like "No differences encountered".  Hide this output.
+      diff $diff_opt_ "$@" > diff.out
+      diff_status_=$?
+      test $diff_status_ -eq 0 || cat diff.out || diff_status_=2
+      rm -f diff.out || diff_status_=2
+      return $diff_status_
     }
   fi
 elif cmp -s /dev/null /dev/null 2>/dev/null; then