changeset 33478:31ec057261fb bytecode-interpreter

maint: Merge default to bytecode-interpreter
author Arun Giridhar <arungiridhar@gmail.com>
date Sun, 28 Apr 2024 11:14:38 -0400
parents 7451f7f896d3 (current diff) 3362e398d702 (diff)
children 787937817a64
files
diffstat 3 files changed, 25 insertions(+), 35 deletions(-) [+]
line wrap: on
line diff
--- a/bootstrap-funclib.sh	Fri Apr 26 17:23:52 2024 -0400
+++ b/bootstrap-funclib.sh	Sun Apr 28 11:14:38 2024 -0400
@@ -1,6 +1,6 @@
 # A library of shell functions for autopull.sh, autogen.sh, and bootstrap.
 
-scriptlibversion=2024-04-13.15; # UTC
+scriptlibversion=2024-04-28.09; # UTC
 
 # Copyright (C) 2003-2024 Free Software Foundation, Inc.
 #
@@ -462,7 +462,17 @@
       || die "Error: --gnulib-srcdir or \$GNULIB_SRCDIR is specified," \
              "but does not contain gnulib-tool"
     if test -n "$GNULIB_REVISION" && $use_git; then
-      (cd "$GNULIB_SRCDIR" && git checkout "$GNULIB_REVISION") || exit $?
+      # The 'git checkout "$GNULIB_REVISION"' command succeeds if the
+      # GNULIB_REVISION is a commit hash that exists locally, or if it is
+      # branch name that can be fetched from origin. It fails, however,
+      # if the GNULIB_REVISION is a commit hash that only exists in
+      # origin. In this case, we need a 'git fetch' and then retry
+      # 'git checkout "$GNULIB_REVISION"'.
+      (cd "$GNULIB_SRCDIR" \
+       && { git checkout "$GNULIB_REVISION" 2>/dev/null \
+            || { git fetch origin && git checkout "$GNULIB_REVISION"; }
+          }
+      ) || exit $?
     fi
   else
     if ! $use_git; then
@@ -532,11 +542,17 @@
         # The subdirectory 'gnulib' already exists.
         if test -n "$GNULIB_REVISION"; then
           if test -d "$gnulib_path/.git"; then
-            if ! git --git-dir="$gnulib_path"/.git cat-file \
-                 commit "$GNULIB_REVISION"; then
-              git --git-dir="$gnulib_path"/.git fetch
-            fi
-            (cd "$gnulib_path" && git checkout "$GNULIB_REVISION") || exit 1
+            # The 'git checkout "$GNULIB_REVISION"' command succeeds if the
+            # GNULIB_REVISION is a commit hash that exists locally, or if it is
+            # branch name that can be fetched from origin. It fails, however,
+            # if the GNULIB_REVISION is a commit hash that only exists in
+            # origin. In this case, we need a 'git fetch' and then retry
+            # 'git checkout "$GNULIB_REVISION"'.
+            (cd "$gnulib_path" \
+             && { git checkout "$GNULIB_REVISION" 2>/dev/null \
+                  || { git fetch origin && git checkout "$GNULIB_REVISION"; }
+                }
+            ) || exit $?
           else
             die "Error: GNULIB_REVISION is specified in bootstrap.conf," \
                 "but '$gnulib_path' contains no git history"
--- a/bootstrap.conf	Fri Apr 26 17:23:52 2024 -0400
+++ b/bootstrap.conf	Sun Apr 28 11:14:38 2024 -0400
@@ -200,19 +200,11 @@
 #
 #   ./bootstrap --bootstrap-sync
 #
-# to update the ./bootstrap file from the selected gnulib revision,
-# followed by
-#
-#   patch -p1 -u < ./build-aux/gnulib-bootstrap-git-fetch.diff
-#
-# to apply local changes from build-aux/gnulib-bootstrap-git-fetch.diff
-#
-# The patch is needed to automatically update gnulib repos that have not
-# been updated to contain $GNULIB_REVISION.
+# to update the ./bootstrap file from the selected gnulib revision.
 #
 # See also: https://lists.gnu.org/archive/html/bug-gnulib/2020-08/msg00150.html
 
-: ${GNULIB_REVISION=d4ec02b3cc70cddaaa5183cc5a45814e0afb2292}
+: ${GNULIB_REVISION=92d80242ad1344b5364ca9bd1d995d68c3a73ef7}
 
 # Don't check for translations since we don't have any in Octave yet.
 # This avoids the need for sha1sum or compatible utility in bootstrap.
--- a/build-aux/gnulib-bootstrap-git-fetch.diff	Fri Apr 26 17:23:52 2024 -0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,18 +0,0 @@
-Update bootstrap script from upstream gnulib to automatically fetch from repository if needed
-
-See also: https://lists.gnu.org/archive/html/bug-gnulib/2020-08/msg00150.html
-
-diff -r c51b07a71421 bootstrap-funclib.sh
---- a/bootstrap-funclib.sh	Fri Apr 26 13:33:37 2024 -0400
-+++ b/bootstrap-funclib.sh	Fri Apr 26 20:00:21 2024 +0200
-@@ -532,6 +532,10 @@
-         # The subdirectory 'gnulib' already exists.
-         if test -n "$GNULIB_REVISION"; then
-           if test -d "$gnulib_path/.git"; then
-+            if ! git --git-dir="$gnulib_path"/.git cat-file \
-+                 commit "$GNULIB_REVISION"; then
-+              git --git-dir="$gnulib_path"/.git fetch
-+            fi
-             (cd "$gnulib_path" && git checkout "$GNULIB_REVISION") || exit 1
-           else
-             die "Error: GNULIB_REVISION is specified in bootstrap.conf," \