From 2e52a1c1fb39d8460a91b910b746c3dfc3085d29 Mon Sep 17 00:00:00 2001
From: "Kirill A. Korinsky" <kirill@korins.ky>
Date: Sun, 20 Feb 2022 22:04:55 +0100
Subject: [PATCH] Darwin: Allow to using rpaths after darwin20

This issue was introduced at previous commit:
```
Author: Iain Sandoe <iain@codesourcery.com>
Date:   Tue Dec 18 13:00:04 2018 +0000

    Darwin : Allow for configuring Darwin to use embedded runpath.
```

Signed-off-by: Kirill A. Korinsky <kirill@korins.ky>
---
 gcc/configure                  | 8 ++++----
 gcc/configure.ac               | 4 ++--
 libatomic/configure            | 2 +-
 libbacktrace/configure         | 2 +-
 libcc1/configure               | 4 ++--
 libffi/configure               | 4 ++--
 libgfortran/configure          | 4 ++--
 libgomp/configure              | 4 ++--
 libhsail-rt/configure          | 4 ++--
 libitm/configure               | 4 ++--
 libobjc/configure              | 2 +-
 liboffloadmic/configure        | 4 ++--
 liboffloadmic/plugin/configure | 4 ++--
 libphobos/configure            | 4 ++--
 libquadmath/configure          | 2 +-
 libsanitizer/configure         | 4 ++--
 libssp/configure               | 2 +-
 libstdc++-v3/configure         | 4 ++--
 libtool.m4                     | 2 +-
 libvtv/configure               | 4 ++--
 zlib/configure                 | 2 +-
 21 files changed, 37 insertions(+), 37 deletions(-)

diff --git gcc/configure gcc/configure
index e9d06979ad3..3f269fb544f 100755
--- gcc/configure
+++ gcc/configure
@@ -17322,7 +17322,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -20179,7 +20179,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -29561,7 +29561,7 @@ if test "x$enable_darwin_at_rpath" = "xyes"; then
   #
   case "$target" in
     # It is valid for targets from Darwin9.
-    *-darwin20* | *-darwin1[0-9]* | *-darwin9*)
+    *-darwin2* | *-darwin1[0-9]* | *-darwin9*)
       tm_defines="$tm_defines USE_DEFAULT_RPATH "
       ;;
   esac
@@ -29569,7 +29569,7 @@ elif test "x$enable_darwin_at_rpath" = "x"; then
   # Match the default from libtool (we need the macro for tm.h)
   case "$target" in
     # It is default for targets from Darwin15.
-    *-darwin20* | *-darwin1[5-9]*)
+    *-darwin2* | *-darwin1[5-9]*)
       tm_defines="$tm_defines USE_DEFAULT_RPATH "
       ;;
   esac
diff --git gcc/configure.ac gcc/configure.ac
index cee0449d0d6..e570c95a28b 100644
--- gcc/configure.ac
+++ gcc/configure.ac
@@ -5844,7 +5844,7 @@ if test "x$enable_darwin_at_rpath" = "xyes"; then
   # 
   case "$target" in
     # It is valid for targets from Darwin9.
-    *-darwin20* | *-darwin1[[0-9]]* | *-darwin9*)
+    *-darwin2* | *-darwin1[[0-9]]* | *-darwin9*)
       tm_defines="$tm_defines USE_DEFAULT_RPATH "
       ;;
   esac
@@ -5852,7 +5852,7 @@ elif test "x$enable_darwin_at_rpath" = "x"; then
   # Match the default from libtool (we need the macro for tm.h)
   case "$target" in
     # It is default for targets from Darwin15.
-    *-darwin20* | *-darwin1[[5-9]]*)
+    *-darwin2* | *-darwin1[[5-9]]*)
       tm_defines="$tm_defines USE_DEFAULT_RPATH "
       ;;
   esac
diff --git libatomic/configure libatomic/configure
index d9d4da230a8..0080453380c 100755
--- libatomic/configure
+++ libatomic/configure
@@ -9607,7 +9607,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libbacktrace/configure libbacktrace/configure
index 3bb2ac002e3..82083e5d0f7 100755
--- libbacktrace/configure
+++ libbacktrace/configure
@@ -9719,7 +9719,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libcc1/configure libcc1/configure
index b3312070ca5..2cdbf11c123 100755
--- libcc1/configure
+++ libcc1/configure
@@ -9002,7 +9002,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -12265,7 +12265,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libffi/configure libffi/configure
index 4d432635a30..c846f05ac84 100755
--- libffi/configure
+++ libffi/configure
@@ -9781,7 +9781,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -12638,7 +12638,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libgfortran/configure libgfortran/configure
index c6da3450947..6e32860fa16 100755
--- libgfortran/configure
+++ libgfortran/configure
@@ -10918,7 +10918,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -14824,7 +14824,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libgomp/configure libgomp/configure
index 3a939e6c1b3..fbc8ed8fedc 100755
--- libgomp/configure
+++ libgomp/configure
@@ -9652,7 +9652,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -13569,7 +13569,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libhsail-rt/configure libhsail-rt/configure
index 22a5060284c..29fd87a5f76 100755
--- libhsail-rt/configure
+++ libhsail-rt/configure
@@ -9459,7 +9459,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -12316,7 +12316,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libitm/configure libitm/configure
index 7736f8c5647..af259b37188 100755
--- libitm/configure
+++ libitm/configure
@@ -10284,7 +10284,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -13141,7 +13141,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libobjc/configure libobjc/configure
index 2f8c7ec71c2..f940cdbe7b1 100755
--- libobjc/configure
+++ libobjc/configure
@@ -8984,7 +8984,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git liboffloadmic/configure liboffloadmic/configure
index 881ad0ed968..e279a4a440a 100644
--- liboffloadmic/configure
+++ liboffloadmic/configure
@@ -9650,7 +9650,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -12507,7 +12507,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git liboffloadmic/plugin/configure liboffloadmic/plugin/configure
index 4afa3abc6e3..890d95df00c 100644
--- liboffloadmic/plugin/configure
+++ liboffloadmic/plugin/configure
@@ -9297,7 +9297,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -12154,7 +12154,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libphobos/configure libphobos/configure
index 60cb59ed94f..8b46619435c 100755
--- libphobos/configure
+++ libphobos/configure
@@ -9867,7 +9867,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -13373,7 +13373,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libquadmath/configure libquadmath/configure
index d9790a25cd9..7087c56158e 100755
--- libquadmath/configure
+++ libquadmath/configure
@@ -9014,7 +9014,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libsanitizer/configure libsanitizer/configure
index ed3f2645a7b..a830d0f85a2 100755
--- libsanitizer/configure
+++ libsanitizer/configure
@@ -10581,7 +10581,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -13438,7 +13438,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libssp/configure libssp/configure
index 5c02b4945a2..a85bdd9907f 100755
--- libssp/configure
+++ libssp/configure
@@ -9195,7 +9195,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libstdc++-v3/configure libstdc++-v3/configure
index 94bd3590e92..1d1bef3ba5a 100755
--- libstdc++-v3/configure
+++ libstdc++-v3/configure
@@ -10258,7 +10258,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -13142,7 +13142,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git libtool.m4 libtool.m4
index 2d247273b0a..5b905206cad 100644
--- libtool.m4
+++ libtool.m4
@@ -1068,7 +1068,7 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[[56789]]*|UNSET,darwin20*|10.1[[123456789]][[,.]]*|11.*[[,.]]* )
+      UNSET,darwin1[[56789]]*|UNSET,darwin2*|10.1[[123456789]][[,.]]*|11.*[[,.]]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&AS_MESSAGE_LOG_FD
       enable_darwin_at_rpath=yes
       ;;
diff --git libvtv/configure libvtv/configure
index 43f8e09b562..b8383a10372 100755
--- libvtv/configure
+++ libvtv/configure
@@ -10482,7 +10482,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
@@ -13339,7 +13339,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
diff --git zlib/configure zlib/configure
index fdd8e89973e..89ea0b22647 100755
--- zlib/configure
+++ zlib/configure
@@ -8851,7 +8851,7 @@ else
     # We cannot build and test reliably on macOS 10.11+ (Darwin15+) without use
     # of rpaths, since runpaths set via DYLD_LIBRARY_PATH are elided by key
     # system executables (e.g. /bin/sh).  Force rpaths on for these systems.
-      UNSET,darwin1[56789]*|UNSET,darwin20*|10.1[123456789][,.]*|11.*[,.]* )
+      UNSET,darwin1[56789]*|UNSET,darwin2*|10.1[123456789][,.]*|11.*[,.]* )
       echo "@rpath library names are needed on macOS versions later than 10.11 (rpaths enabled)" 1>&5
       enable_darwin_at_rpath=yes
       ;;
-- 
2.42.1

