Commit ddaa980c1a799fe79496927551f77fb9c207d116

Authored by Jay Berkenbilt
1 parent 18340b88

Update libtool and autoconf files

README-maintainer
... ... @@ -174,8 +174,8 @@ RELEASE PREPARATION
174 174  
175 175 * Other files copied as indicated:
176 176 ```
177   - cp /usr/share/automake-1.11/install-sh .
178   - cp /usr/share/automake-1.11/mkinstalldirs .
  177 + cp /usr/share/automake-1.16/install-sh .
  178 + cp /usr/share/automake-1.16/mkinstalldirs .
179 179 cp /usr/share/aclocal/pkg.m4 m4
180 180 ```
181 181  
... ...
autofiles.sums
... ... @@ -3,7 +3,7 @@ d3f9ee6f6f0846888d9a10fd3dad2e4b1258be84205426cf04d7cef02d61dad7 aclocal.m4
3 3 cf2c764639c4c94abc183a0976eca6ae500b80790ea25e3d0af97b23587363b7 libqpdf/qpdf/qpdf-config.h.in
4 4 5297971a0ef90bcd5563eb3f7127a032bb76d3ae2af7258bf13479caf8983a60 m4/ax_cxx_compile_stdcxx.m4
5 5 35bc5c645dc42d47f2daeea06f8f3e767c8a1aee6a35eb2b4854fd2ce66c3413 m4/ax_random_device.m4
6   -6a1e4f8aa2902d7993300660c43e6ee479b4b6781ed7d5ef9c9f9f1cc46623b7 m4/libtool.m4
  6 +1451e63710701b5f00a668f3a79b435015ef2e63547f0ad0ce8c8c062d53b599 m4/libtool.m4
7 7 e77ebba8361b36f14b4d0927173a034b98c5d05049697a9ded84d85eb99a7990 m4/ltoptions.m4
8 8 5a6735cda60e0ba0d1b706c0ef648f5d096298da46daefd9cdecdb6a0f4584d3 m4/ltsugar.m4
9 9 a27b754709de61575197bf5a980696c98ae49da3f92f0de8ee7f42dd543b7465 m4/ltversion.m4
... ...
config.guess
... ... @@ -2,7 +2,7 @@
2 2 # Attempt to guess a canonical system name.
3 3 # Copyright 1992-2020 Free Software Foundation, Inc.
4 4  
5   -timestamp='2020-01-01'
  5 +timestamp='2020-12-22'
6 6  
7 7 # This file is free software; you can redistribute it and/or modify it
8 8 # under the terms of the GNU General Public License as published by
... ... @@ -27,12 +27,12 @@ timestamp='2020-01-01'
27 27 # Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
28 28 #
29 29 # You can get the latest version of this script from:
30   -# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
  30 +# https://git.savannah.gnu.org/cgit/config.git/plain/config.guess
31 31 #
32 32 # Please send patches to <config-patches@gnu.org>.
33 33  
34 34  
35   -me=`echo "$0" | sed -e 's,.*/,,'`
  35 +me=$(echo "$0" | sed -e 's,.*/,,')
36 36  
37 37 usage="\
38 38 Usage: $0 [OPTION]
... ... @@ -103,7 +103,7 @@ set_cc_for_build() {
103 103 test "$tmp" && return 0
104 104 : "${TMPDIR=/tmp}"
105 105 # shellcheck disable=SC2039
106   - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
  106 + { tmp=$( (umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null) && test -n "$tmp" && test -d "$tmp" ; } ||
107 107 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } ||
108 108 { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } ||
109 109 { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; }
... ... @@ -131,16 +131,14 @@ if test -f /.attbin/uname ; then
131 131 PATH=$PATH:/.attbin ; export PATH
132 132 fi
133 133  
134   -UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
135   -UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
136   -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
137   -UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
  134 +UNAME_MACHINE=$( (uname -m) 2>/dev/null) || UNAME_MACHINE=unknown
  135 +UNAME_RELEASE=$( (uname -r) 2>/dev/null) || UNAME_RELEASE=unknown
  136 +UNAME_SYSTEM=$( (uname -s) 2>/dev/null) || UNAME_SYSTEM=unknown
  137 +UNAME_VERSION=$( (uname -v) 2>/dev/null) || UNAME_VERSION=unknown
138 138  
139 139 case "$UNAME_SYSTEM" in
140 140 Linux|GNU|GNU/*)
141   - # If the system lacks a compiler, then just pick glibc.
142   - # We could probably try harder.
143   - LIBC=gnu
  141 + LIBC=unknown
144 142  
145 143 set_cc_for_build
146 144 cat <<-EOF > "$dummy.c"
... ... @@ -149,17 +147,29 @@ Linux|GNU|GNU/*)
149 147 LIBC=uclibc
150 148 #elif defined(__dietlibc__)
151 149 LIBC=dietlibc
152   - #else
  150 + #elif defined(__GLIBC__)
153 151 LIBC=gnu
  152 + #else
  153 + #include <stdarg.h>
  154 + /* First heuristic to detect musl libc. */
  155 + #ifdef __DEFINED_va_list
  156 + LIBC=musl
  157 + #endif
154 158 #endif
155 159 EOF
156   - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`"
  160 + eval "$($CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g')"
157 161  
158   - # If ldd exists, use it to detect musl libc.
159   - if command -v ldd >/dev/null && \
160   - ldd --version 2>&1 | grep -q ^musl
161   - then
162   - LIBC=musl
  162 + # Second heuristic to detect musl libc.
  163 + if [ "$LIBC" = unknown ] &&
  164 + command -v ldd >/dev/null &&
  165 + ldd --version 2>&1 | grep -q ^musl; then
  166 + LIBC=musl
  167 + fi
  168 +
  169 + # If the system lacks a compiler, then just pick glibc.
  170 + # We could probably try harder.
  171 + if [ "$LIBC" = unknown ]; then
  172 + LIBC=gnu
163 173 fi
164 174 ;;
165 175 esac
... ... @@ -179,19 +189,20 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
179 189 # Note: NetBSD doesn't particularly care about the vendor
180 190 # portion of the name. We always set it to "unknown".
181 191 sysctl="sysctl -n hw.machine_arch"
182   - UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
  192 + UNAME_MACHINE_ARCH=$( (uname -p 2>/dev/null || \
183 193 "/sbin/$sysctl" 2>/dev/null || \
184 194 "/usr/sbin/$sysctl" 2>/dev/null || \
185   - echo unknown)`
  195 + echo unknown))
186 196 case "$UNAME_MACHINE_ARCH" in
  197 + aarch64eb) machine=aarch64_be-unknown ;;
187 198 armeb) machine=armeb-unknown ;;
188 199 arm*) machine=arm-unknown ;;
189 200 sh3el) machine=shl-unknown ;;
190 201 sh3eb) machine=sh-unknown ;;
191 202 sh5el) machine=sh5le-unknown ;;
192 203 earmv*)
193   - arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
194   - endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'`
  204 + arch=$(echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,')
  205 + endian=$(echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p')
195 206 machine="${arch}${endian}"-unknown
196 207 ;;
197 208 *) machine="$UNAME_MACHINE_ARCH"-unknown ;;
... ... @@ -222,7 +233,7 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
222 233 case "$UNAME_MACHINE_ARCH" in
223 234 earm*)
224 235 expr='s/^earmv[0-9]/-eabi/;s/eb$//'
225   - abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"`
  236 + abi=$(echo "$UNAME_MACHINE_ARCH" | sed -e "$expr")
226 237 ;;
227 238 esac
228 239 # The OS release
... ... @@ -235,7 +246,7 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
235 246 release='-gnu'
236 247 ;;
237 248 *)
238   - release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2`
  249 + release=$(echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2)
239 250 ;;
240 251 esac
241 252 # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
... ... @@ -244,15 +255,15 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
244 255 echo "$machine-${os}${release}${abi-}"
245 256 exit ;;
246 257 *:Bitrig:*:*)
247   - UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
  258 + UNAME_MACHINE_ARCH=$(arch | sed 's/Bitrig.//')
248 259 echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE"
249 260 exit ;;
250 261 *:OpenBSD:*:*)
251   - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
  262 + UNAME_MACHINE_ARCH=$(arch | sed 's/OpenBSD.//')
252 263 echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE"
253 264 exit ;;
254 265 *:LibertyBSD:*:*)
255   - UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'`
  266 + UNAME_MACHINE_ARCH=$(arch | sed 's/^.*BSD\.//')
256 267 echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE"
257 268 exit ;;
258 269 *:MidnightBSD:*:*)
... ... @@ -288,17 +299,17 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
288 299 alpha:OSF1:*:*)
289 300 case $UNAME_RELEASE in
290 301 *4.0)
291   - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
  302 + UNAME_RELEASE=$(/usr/sbin/sizer -v | awk '{print $3}')
292 303 ;;
293 304 *5.*)
294   - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
  305 + UNAME_RELEASE=$(/usr/sbin/sizer -v | awk '{print $4}')
295 306 ;;
296 307 esac
297 308 # According to Compaq, /usr/sbin/psrinfo has been available on
298 309 # OSF/1 and Tru64 systems produced since 1995. I hope that
299 310 # covers most systems running today. This code pipes the CPU
300 311 # types through head -n 1, so we only detect the type of CPU 0.
301   - ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
  312 + ALPHA_CPU_TYPE=$(/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1)
302 313 case "$ALPHA_CPU_TYPE" in
303 314 "EV4 (21064)")
304 315 UNAME_MACHINE=alpha ;;
... ... @@ -336,7 +347,7 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
336 347 # A Tn.n version is a released field test version.
337 348 # A Xn.n version is an unreleased experimental baselevel.
338 349 # 1.2 uses "1.2" for uname -r.
339   - echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`"
  350 + echo "$UNAME_MACHINE"-dec-osf"$(echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz)"
340 351 # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
341 352 exitcode=$?
342 353 trap '' 0
... ... @@ -370,7 +381,7 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
370 381 exit ;;
371 382 Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
372 383 # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
373   - if test "`(/bin/universe) 2>/dev/null`" = att ; then
  384 + if test "$( (/bin/universe) 2>/dev/null)" = att ; then
374 385 echo pyramid-pyramid-sysv3
375 386 else
376 387 echo pyramid-pyramid-bsd
... ... @@ -383,17 +394,17 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
383 394 echo sparc-icl-nx6
384 395 exit ;;
385 396 DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
386   - case `/usr/bin/uname -p` in
  397 + case $(/usr/bin/uname -p) in
387 398 sparc) echo sparc-icl-nx7; exit ;;
388 399 esac ;;
389 400 s390x:SunOS:*:*)
390   - echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
  401 + echo "$UNAME_MACHINE"-ibm-solaris2"$(echo "$UNAME_RELEASE" | sed -e 's/[^.]*//')"
391 402 exit ;;
392 403 sun4H:SunOS:5.*:*)
393   - echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
  404 + echo sparc-hal-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
394 405 exit ;;
395 406 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
396   - echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
  407 + echo sparc-sun-solaris2"$(echo "$UNAME_RELEASE" | sed -e 's/[^.]*//')"
397 408 exit ;;
398 409 i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
399 410 echo i386-pc-auroraux"$UNAME_RELEASE"
... ... @@ -404,7 +415,7 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
404 415 # If there is a compiler, see if it is configured for 64-bit objects.
405 416 # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
406 417 # This test works for both compilers.
407   - if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
  418 + if test "$CC_FOR_BUILD" != no_compiler_found; then
408 419 if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
409 420 (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
410 421 grep IS_64BIT_ARCH >/dev/null
... ... @@ -412,30 +423,30 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
412 423 SUN_ARCH=x86_64
413 424 fi
414 425 fi
415   - echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
  426 + echo "$SUN_ARCH"-pc-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
416 427 exit ;;
417 428 sun4*:SunOS:6*:*)
418 429 # According to config.sub, this is the proper way to canonicalize
419 430 # SunOS6. Hard to guess exactly what SunOS6 will be like, but
420 431 # it's likely to be more like Solaris than SunOS4.
421   - echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
  432 + echo sparc-sun-solaris3"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
422 433 exit ;;
423 434 sun4*:SunOS:*:*)
424   - case "`/usr/bin/arch -k`" in
  435 + case "$(/usr/bin/arch -k)" in
425 436 Series*|S4*)
426   - UNAME_RELEASE=`uname -v`
  437 + UNAME_RELEASE=$(uname -v)
427 438 ;;
428 439 esac
429 440 # Japanese Language versions have a version number like `4.1.3-JL'.
430   - echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`"
  441 + echo sparc-sun-sunos"$(echo "$UNAME_RELEASE"|sed -e 's/-/_/')"
431 442 exit ;;
432 443 sun3*:SunOS:*:*)
433 444 echo m68k-sun-sunos"$UNAME_RELEASE"
434 445 exit ;;
435 446 sun*:*:4.2BSD:*)
436   - UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
  447 + UNAME_RELEASE=$( (sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null)
437 448 test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3
438   - case "`/bin/arch`" in
  449 + case "$(/bin/arch)" in
439 450 sun3)
440 451 echo m68k-sun-sunos"$UNAME_RELEASE"
441 452 ;;
... ... @@ -515,8 +526,8 @@ case &quot;$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION&quot; in
515 526 }
516 527 EOF
517 528 $CC_FOR_BUILD -o "$dummy" "$dummy.c" &&
518   - dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` &&
519   - SYSTEM_NAME=`"$dummy" "$dummyarg"` &&
  529 + dummyarg=$(echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p') &&
  530 + SYSTEM_NAME=$("$dummy" "$dummyarg") &&
520 531 { echo "$SYSTEM_NAME"; exit; }
521 532 echo mips-mips-riscos"$UNAME_RELEASE"
522 533 exit ;;
... ... @@ -543,11 +554,11 @@ EOF
543 554 exit ;;
544 555 AViiON:dgux:*:*)
545 556 # DG/UX returns AViiON for all architectures
546   - UNAME_PROCESSOR=`/usr/bin/uname -p`
547   - if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ]
  557 + UNAME_PROCESSOR=$(/usr/bin/uname -p)
  558 + if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110
548 559 then
549   - if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \
550   - [ "$TARGET_BINARY_INTERFACE"x = x ]
  560 + if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \
  561 + test "$TARGET_BINARY_INTERFACE"x = x
551 562 then
552 563 echo m88k-dg-dgux"$UNAME_RELEASE"
553 564 else
... ... @@ -571,17 +582,17 @@ EOF
571 582 echo m68k-tektronix-bsd
572 583 exit ;;
573 584 *:IRIX*:*:*)
574   - echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`"
  585 + echo mips-sgi-irix"$(echo "$UNAME_RELEASE"|sed -e 's/-/_/g')"
575 586 exit ;;
576 587 ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
577 588 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
578   - exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
  589 + exit ;; # Note that: echo "'$(uname -s)'" gives 'AIX '
579 590 i*86:AIX:*:*)
580 591 echo i386-ibm-aix
581 592 exit ;;
582 593 ia64:AIX:*:*)
583   - if [ -x /usr/bin/oslevel ] ; then
584   - IBM_REV=`/usr/bin/oslevel`
  594 + if test -x /usr/bin/oslevel ; then
  595 + IBM_REV=$(/usr/bin/oslevel)
585 596 else
586 597 IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
587 598 fi
... ... @@ -601,7 +612,7 @@ EOF
601 612 exit(0);
602 613 }
603 614 EOF
604   - if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"`
  615 + if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=$("$dummy")
605 616 then
606 617 echo "$SYSTEM_NAME"
607 618 else
... ... @@ -614,15 +625,15 @@ EOF
614 625 fi
615 626 exit ;;
616 627 *:AIX:*:[4567])
617   - IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
  628 + IBM_CPU_ID=$(/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }')
618 629 if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then
619 630 IBM_ARCH=rs6000
620 631 else
621 632 IBM_ARCH=powerpc
622 633 fi
623   - if [ -x /usr/bin/lslpp ] ; then
624   - IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
625   - awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
  634 + if test -x /usr/bin/lslpp ; then
  635 + IBM_REV=$(/usr/bin/lslpp -Lqc bos.rte.libc |
  636 + awk -F: '{ print $3 }' | sed s/[0-9]*$/0/)
626 637 else
627 638 IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
628 639 fi
... ... @@ -650,14 +661,14 @@ EOF
650 661 echo m68k-hp-bsd4.4
651 662 exit ;;
652 663 9000/[34678]??:HP-UX:*:*)
653   - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
  664 + HPUX_REV=$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//')
654 665 case "$UNAME_MACHINE" in
655 666 9000/31?) HP_ARCH=m68000 ;;
656 667 9000/[34]??) HP_ARCH=m68k ;;
657 668 9000/[678][0-9][0-9])
658   - if [ -x /usr/bin/getconf ]; then
659   - sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
660   - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
  669 + if test -x /usr/bin/getconf; then
  670 + sc_cpu_version=$(/usr/bin/getconf SC_CPU_VERSION 2>/dev/null)
  671 + sc_kernel_bits=$(/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null)
661 672 case "$sc_cpu_version" in
662 673 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0
663 674 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1
... ... @@ -669,7 +680,7 @@ EOF
669 680 esac ;;
670 681 esac
671 682 fi
672   - if [ "$HP_ARCH" = "" ]; then
  683 + if test "$HP_ARCH" = ""; then
673 684 set_cc_for_build
674 685 sed 's/^ //' << EOF > "$dummy.c"
675 686  
... ... @@ -704,11 +715,11 @@ EOF
704 715 exit (0);
705 716 }
706 717 EOF
707   - (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"`
  718 + (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=$("$dummy")
708 719 test -z "$HP_ARCH" && HP_ARCH=hppa
709 720 fi ;;
710 721 esac
711   - if [ "$HP_ARCH" = hppa2.0w ]
  722 + if test "$HP_ARCH" = hppa2.0w
712 723 then
713 724 set_cc_for_build
714 725  
... ... @@ -732,7 +743,7 @@ EOF
732 743 echo "$HP_ARCH"-hp-hpux"$HPUX_REV"
733 744 exit ;;
734 745 ia64:HP-UX:*:*)
735   - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
  746 + HPUX_REV=$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//')
736 747 echo ia64-hp-hpux"$HPUX_REV"
737 748 exit ;;
738 749 3050*:HI-UX:*:*)
... ... @@ -762,7 +773,7 @@ EOF
762 773 exit (0);
763 774 }
764 775 EOF
765   - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` &&
  776 + $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=$("$dummy") &&
766 777 { echo "$SYSTEM_NAME"; exit; }
767 778 echo unknown-hitachi-hiuxwe2
768 779 exit ;;
... ... @@ -782,7 +793,7 @@ EOF
782 793 echo hppa1.0-hp-osf
783 794 exit ;;
784 795 i*86:OSF1:*:*)
785   - if [ -x /usr/sbin/sysversion ] ; then
  796 + if test -x /usr/sbin/sysversion ; then
786 797 echo "$UNAME_MACHINE"-unknown-osf1mk
787 798 else
788 799 echo "$UNAME_MACHINE"-unknown-osf1
... ... @@ -831,14 +842,14 @@ EOF
831 842 echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
832 843 exit ;;
833 844 F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
834   - FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
835   - FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
836   - FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'`
  845 + FUJITSU_PROC=$(uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz)
  846 + FUJITSU_SYS=$(uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///')
  847 + FUJITSU_REL=$(echo "$UNAME_RELEASE" | sed -e 's/ /_/')
837 848 echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
838 849 exit ;;
839 850 5000:UNIX_System_V:4.*:*)
840   - FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
841   - FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'`
  851 + FUJITSU_SYS=$(uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///')
  852 + FUJITSU_REL=$(echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/')
842 853 echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
843 854 exit ;;
844 855 i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
... ... @@ -851,25 +862,25 @@ EOF
851 862 echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE"
852 863 exit ;;
853 864 arm:FreeBSD:*:*)
854   - UNAME_PROCESSOR=`uname -p`
  865 + UNAME_PROCESSOR=$(uname -p)
855 866 set_cc_for_build
856 867 if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
857 868 | grep -q __ARM_PCS_VFP
858 869 then
859   - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi
  870 + echo "${UNAME_PROCESSOR}"-unknown-freebsd"$(echo ${UNAME_RELEASE}|sed -e 's/[-(].*//')"-gnueabi
860 871 else
861   - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf
  872 + echo "${UNAME_PROCESSOR}"-unknown-freebsd"$(echo ${UNAME_RELEASE}|sed -e 's/[-(].*//')"-gnueabihf
862 873 fi
863 874 exit ;;
864 875 *:FreeBSD:*:*)
865   - UNAME_PROCESSOR=`/usr/bin/uname -p`
  876 + UNAME_PROCESSOR=$(/usr/bin/uname -p)
866 877 case "$UNAME_PROCESSOR" in
867 878 amd64)
868 879 UNAME_PROCESSOR=x86_64 ;;
869 880 i386)
870 881 UNAME_PROCESSOR=i586 ;;
871 882 esac
872   - echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
  883 + echo "$UNAME_PROCESSOR"-unknown-freebsd"$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')"
873 884 exit ;;
874 885 i*:CYGWIN*:*)
875 886 echo "$UNAME_MACHINE"-pc-cygwin
... ... @@ -905,15 +916,15 @@ EOF
905 916 echo x86_64-pc-cygwin
906 917 exit ;;
907 918 prep*:SunOS:5.*:*)
908   - echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
  919 + echo powerpcle-unknown-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
909 920 exit ;;
910 921 *:GNU:*:*)
911 922 # the GNU system
912   - echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`"
  923 + echo "$(echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,')-unknown-$LIBC$(echo "$UNAME_RELEASE"|sed -e 's,/.*$,,')"
913 924 exit ;;
914 925 *:GNU/*:*:*)
915 926 # other systems with GNU libc and userland
916   - echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC"
  927 + echo "$UNAME_MACHINE-unknown-$(echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]")$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')-$LIBC"
917 928 exit ;;
918 929 *:Minix:*:*)
919 930 echo "$UNAME_MACHINE"-unknown-minix
... ... @@ -926,7 +937,7 @@ EOF
926 937 echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
927 938 exit ;;
928 939 alpha:Linux:*:*)
929   - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in
  940 + case $(sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null) in
930 941 EV5) UNAME_MACHINE=alphaev5 ;;
931 942 EV56) UNAME_MACHINE=alphaev56 ;;
932 943 PCA56) UNAME_MACHINE=alphapca56 ;;
... ... @@ -985,6 +996,9 @@ EOF
985 996 k1om:Linux:*:*)
986 997 echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
987 998 exit ;;
  999 + loongarch32:Linux:*:* | loongarch64:Linux:*:* | loongarchx32:Linux:*:*)
  1000 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
  1001 + exit ;;
988 1002 m32r*:Linux:*:*)
989 1003 echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
990 1004 exit ;;
... ... @@ -1035,7 +1049,7 @@ EOF
1035 1049 #endif
1036 1050 #endif
1037 1051 EOF
1038   - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`"
  1052 + eval "$($CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI')"
1039 1053 test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; }
1040 1054 ;;
1041 1055 mips64el:Linux:*:*)
... ... @@ -1055,7 +1069,7 @@ EOF
1055 1069 exit ;;
1056 1070 parisc:Linux:*:* | hppa:Linux:*:*)
1057 1071 # Look for CPU level
1058   - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
  1072 + case $(grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2) in
1059 1073 PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;;
1060 1074 PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;;
1061 1075 *) echo hppa-unknown-linux-"$LIBC" ;;
... ... @@ -1095,7 +1109,17 @@ EOF
1095 1109 echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
1096 1110 exit ;;
1097 1111 x86_64:Linux:*:*)
1098   - echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
  1112 + set_cc_for_build
  1113 + LIBCABI=$LIBC
  1114 + if test "$CC_FOR_BUILD" != no_compiler_found; then
  1115 + if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \
  1116 + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
  1117 + grep IS_X32 >/dev/null
  1118 + then
  1119 + LIBCABI="$LIBC"x32
  1120 + fi
  1121 + fi
  1122 + echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI"
1099 1123 exit ;;
1100 1124 xtensa*:Linux:*:*)
1101 1125 echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
... ... @@ -1135,7 +1159,7 @@ EOF
1135 1159 echo "$UNAME_MACHINE"-pc-msdosdjgpp
1136 1160 exit ;;
1137 1161 i*86:*:4.*:*)
1138   - UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'`
  1162 + UNAME_REL=$(echo "$UNAME_RELEASE" | sed 's/\/MP$//')
1139 1163 if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
1140 1164 echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL"
1141 1165 else
... ... @@ -1144,7 +1168,7 @@ EOF
1144 1168 exit ;;
1145 1169 i*86:*:5:[678]*)
1146 1170 # UnixWare 7.x, OpenUNIX and OpenServer 6.
1147   - case `/bin/uname -X | grep "^Machine"` in
  1171 + case $(/bin/uname -X | grep "^Machine") in
1148 1172 *486*) UNAME_MACHINE=i486 ;;
1149 1173 *Pentium) UNAME_MACHINE=i586 ;;
1150 1174 *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
... ... @@ -1153,10 +1177,10 @@ EOF
1153 1177 exit ;;
1154 1178 i*86:*:3.2:*)
1155 1179 if test -f /usr/options/cb.name; then
1156   - UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
  1180 + UNAME_REL=$(sed -n 's/.*Version //p' </usr/options/cb.name)
1157 1181 echo "$UNAME_MACHINE"-pc-isc"$UNAME_REL"
1158 1182 elif /bin/uname -X 2>/dev/null >/dev/null ; then
1159   - UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
  1183 + UNAME_REL=$( (/bin/uname -X|grep Release|sed -e 's/.*= //'))
1160 1184 (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
1161 1185 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
1162 1186 && UNAME_MACHINE=i586
... ... @@ -1206,7 +1230,7 @@ EOF
1206 1230 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
1207 1231 OS_REL=''
1208 1232 test -r /etc/.relid \
1209   - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
  1233 + && OS_REL=.$(sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid)
1210 1234 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1211 1235 && { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
1212 1236 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
... ... @@ -1217,7 +1241,7 @@ EOF
1217 1241 NCR*:*:4.2:* | MPRAS*:*:4.2:*)
1218 1242 OS_REL='.3'
1219 1243 test -r /etc/.relid \
1220   - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
  1244 + && OS_REL=.$(sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid)
1221 1245 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1222 1246 && { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
1223 1247 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
... ... @@ -1250,7 +1274,7 @@ EOF
1250 1274 exit ;;
1251 1275 *:SINIX-*:*:*)
1252 1276 if uname -p 2>/dev/null >/dev/null ; then
1253   - UNAME_MACHINE=`(uname -p) 2>/dev/null`
  1277 + UNAME_MACHINE=$( (uname -p) 2>/dev/null)
1254 1278 echo "$UNAME_MACHINE"-sni-sysv4
1255 1279 else
1256 1280 echo ns32k-sni-sysv
... ... @@ -1284,7 +1308,7 @@ EOF
1284 1308 echo mips-sony-newsos6
1285 1309 exit ;;
1286 1310 R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
1287   - if [ -d /usr/nec ]; then
  1311 + if test -d /usr/nec; then
1288 1312 echo mips-nec-sysv"$UNAME_RELEASE"
1289 1313 else
1290 1314 echo mips-unknown-sysv"$UNAME_RELEASE"
... ... @@ -1332,8 +1356,11 @@ EOF
1332 1356 *:Rhapsody:*:*)
1333 1357 echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE"
1334 1358 exit ;;
  1359 + arm64:Darwin:*:*)
  1360 + echo aarch64-apple-darwin"$UNAME_RELEASE"
  1361 + exit ;;
1335 1362 *:Darwin:*:*)
1336   - UNAME_PROCESSOR=`uname -p`
  1363 + UNAME_PROCESSOR=$(uname -p)
1337 1364 case $UNAME_PROCESSOR in
1338 1365 unknown) UNAME_PROCESSOR=powerpc ;;
1339 1366 esac
... ... @@ -1346,7 +1373,7 @@ EOF
1346 1373 else
1347 1374 set_cc_for_build
1348 1375 fi
1349   - if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
  1376 + if test "$CC_FOR_BUILD" != no_compiler_found; then
1350 1377 if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
1351 1378 (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
1352 1379 grep IS_64BIT_ARCH >/dev/null
... ... @@ -1370,7 +1397,7 @@ EOF
1370 1397 echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE"
1371 1398 exit ;;
1372 1399 *:procnto*:*:* | *:QNX:[0123456789]*:*)
1373   - UNAME_PROCESSOR=`uname -p`
  1400 + UNAME_PROCESSOR=$(uname -p)
1374 1401 if test "$UNAME_PROCESSOR" = x86; then
1375 1402 UNAME_PROCESSOR=i386
1376 1403 UNAME_MACHINE=pc
... ... @@ -1438,10 +1465,10 @@ EOF
1438 1465 echo mips-sei-seiux"$UNAME_RELEASE"
1439 1466 exit ;;
1440 1467 *:DragonFly:*:*)
1441   - echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
  1468 + echo "$UNAME_MACHINE"-unknown-dragonfly"$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')"
1442 1469 exit ;;
1443 1470 *:*VMS:*:*)
1444   - UNAME_MACHINE=`(uname -p) 2>/dev/null`
  1471 + UNAME_MACHINE=$( (uname -p) 2>/dev/null)
1445 1472 case "$UNAME_MACHINE" in
1446 1473 A*) echo alpha-dec-vms ; exit ;;
1447 1474 I*) echo ia64-dec-vms ; exit ;;
... ... @@ -1451,7 +1478,7 @@ EOF
1451 1478 echo i386-pc-xenix
1452 1479 exit ;;
1453 1480 i*86:skyos:*:*)
1454   - echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`"
  1481 + echo "$UNAME_MACHINE"-pc-skyos"$(echo "$UNAME_RELEASE" | sed -e 's/ .*$//')"
1455 1482 exit ;;
1456 1483 i*86:rdos:*:*)
1457 1484 echo "$UNAME_MACHINE"-pc-rdos
... ... @@ -1509,7 +1536,7 @@ main ()
1509 1536 #define __ARCHITECTURE__ "m68k"
1510 1537 #endif
1511 1538 int version;
1512   - version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
  1539 + version=$( (hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null);
1513 1540 if (version < 4)
1514 1541 printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
1515 1542 else
... ... @@ -1601,7 +1628,7 @@ main ()
1601 1628 }
1602 1629 EOF
1603 1630  
1604   -$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`$dummy` &&
  1631 +$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=$($dummy) &&
1605 1632 { echo "$SYSTEM_NAME"; exit; }
1606 1633  
1607 1634 # Apollos put the system type in the environment.
... ... @@ -1626,9 +1653,15 @@ This script (version $timestamp), has failed to recognize the
1626 1653 operating system you are using. If your script is old, overwrite *all*
1627 1654 copies of config.guess and config.sub with the latest versions from:
1628 1655  
1629   - https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
  1656 + https://git.savannah.gnu.org/cgit/config.git/plain/config.guess
1630 1657 and
1631   - https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
  1658 + https://git.savannah.gnu.org/cgit/config.git/plain/config.sub
  1659 +EOF
  1660 +
  1661 +year=$(echo $timestamp | sed 's,-.*,,')
  1662 +# shellcheck disable=SC2003
  1663 +if test "$(expr "$(date +%Y)" - "$year")" -lt 3 ; then
  1664 + cat >&2 <<EOF
1632 1665  
1633 1666 If $0 has already been updated, send the following data and any
1634 1667 information you think might be pertinent to config-patches@gnu.org to
... ... @@ -1636,26 +1669,27 @@ provide the necessary information to handle your system.
1636 1669  
1637 1670 config.guess timestamp = $timestamp
1638 1671  
1639   -uname -m = `(uname -m) 2>/dev/null || echo unknown`
1640   -uname -r = `(uname -r) 2>/dev/null || echo unknown`
1641   -uname -s = `(uname -s) 2>/dev/null || echo unknown`
1642   -uname -v = `(uname -v) 2>/dev/null || echo unknown`
  1672 +uname -m = $( (uname -m) 2>/dev/null || echo unknown)
  1673 +uname -r = $( (uname -r) 2>/dev/null || echo unknown)
  1674 +uname -s = $( (uname -s) 2>/dev/null || echo unknown)
  1675 +uname -v = $( (uname -v) 2>/dev/null || echo unknown)
1643 1676  
1644   -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
1645   -/bin/uname -X = `(/bin/uname -X) 2>/dev/null`
  1677 +/usr/bin/uname -p = $( (/usr/bin/uname -p) 2>/dev/null)
  1678 +/bin/uname -X = $( (/bin/uname -X) 2>/dev/null)
1646 1679  
1647   -hostinfo = `(hostinfo) 2>/dev/null`
1648   -/bin/universe = `(/bin/universe) 2>/dev/null`
1649   -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null`
1650   -/bin/arch = `(/bin/arch) 2>/dev/null`
1651   -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
1652   -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
  1680 +hostinfo = $( (hostinfo) 2>/dev/null)
  1681 +/bin/universe = $( (/bin/universe) 2>/dev/null)
  1682 +/usr/bin/arch -k = $( (/usr/bin/arch -k) 2>/dev/null)
  1683 +/bin/arch = $( (/bin/arch) 2>/dev/null)
  1684 +/usr/bin/oslevel = $( (/usr/bin/oslevel) 2>/dev/null)
  1685 +/usr/convex/getsysinfo = $( (/usr/convex/getsysinfo) 2>/dev/null)
1653 1686  
1654 1687 UNAME_MACHINE = "$UNAME_MACHINE"
1655 1688 UNAME_RELEASE = "$UNAME_RELEASE"
1656 1689 UNAME_SYSTEM = "$UNAME_SYSTEM"
1657 1690 UNAME_VERSION = "$UNAME_VERSION"
1658 1691 EOF
  1692 +fi
1659 1693  
1660 1694 exit 1
1661 1695  
... ...
config.sub
... ... @@ -2,7 +2,7 @@
2 2 # Configuration validation subroutine script.
3 3 # Copyright 1992-2020 Free Software Foundation, Inc.
4 4  
5   -timestamp='2020-01-01'
  5 +timestamp='2020-12-22'
6 6  
7 7 # This file is free software; you can redistribute it and/or modify it
8 8 # under the terms of the GNU General Public License as published by
... ... @@ -33,7 +33,7 @@ timestamp=&#39;2020-01-01&#39;
33 33 # Otherwise, we print the canonical config type on stdout and succeed.
34 34  
35 35 # You can get the latest version of this script from:
36   -# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
  36 +# https://git.savannah.gnu.org/cgit/config.git/plain/config.sub
37 37  
38 38 # This file is supposed to be the same for all GNU packages
39 39 # and recognize all the CPU types, system types and aliases
... ... @@ -50,7 +50,7 @@ timestamp=&#39;2020-01-01&#39;
50 50 # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
51 51 # It is wrong to echo any other type of specification.
52 52  
53   -me=`echo "$0" | sed -e 's,.*/,,'`
  53 +me=$(echo "$0" | sed -e 's,.*/,,')
54 54  
55 55 usage="\
56 56 Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS
... ... @@ -124,28 +124,27 @@ case $1 in
124 124 ;;
125 125 *-*-*-*)
126 126 basic_machine=$field1-$field2
127   - os=$field3-$field4
  127 + basic_os=$field3-$field4
128 128 ;;
129 129 *-*-*)
130 130 # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two
131 131 # parts
132 132 maybe_os=$field2-$field3
133 133 case $maybe_os in
134   - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc \
135   - | linux-newlib* | linux-musl* | linux-uclibc* | uclinux-uclibc* \
  134 + nto-qnx* | linux-* | uclinux-uclibc* \
136 135 | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \
137 136 | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \
138 137 | storm-chaos* | os2-emx* | rtmk-nova*)
139 138 basic_machine=$field1
140   - os=$maybe_os
  139 + basic_os=$maybe_os
141 140 ;;
142 141 android-linux)
143 142 basic_machine=$field1-unknown
144   - os=linux-android
  143 + basic_os=linux-android
145 144 ;;
146 145 *)
147 146 basic_machine=$field1-$field2
148   - os=$field3
  147 + basic_os=$field3
149 148 ;;
150 149 esac
151 150 ;;
... ... @@ -154,7 +153,7 @@ case $1 in
154 153 case $field1-$field2 in
155 154 decstation-3100)
156 155 basic_machine=mips-dec
157   - os=
  156 + basic_os=
158 157 ;;
159 158 *-*)
160 159 # Second component is usually, but not always the OS
... ... @@ -162,7 +161,7 @@ case $1 in
162 161 # Prevent following clause from handling this valid os
163 162 sun*os*)
164 163 basic_machine=$field1
165   - os=$field2
  164 + basic_os=$field2
166 165 ;;
167 166 # Manufacturers
168 167 dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \
... ... @@ -175,11 +174,11 @@ case $1 in
175 174 | microblaze* | sim | cisco \
176 175 | oki | wec | wrs | winbond)
177 176 basic_machine=$field1-$field2
178   - os=
  177 + basic_os=
179 178 ;;
180 179 *)
181 180 basic_machine=$field1
182   - os=$field2
  181 + basic_os=$field2
183 182 ;;
184 183 esac
185 184 ;;
... ... @@ -191,447 +190,451 @@ case $1 in
191 190 case $field1 in
192 191 386bsd)
193 192 basic_machine=i386-pc
194   - os=bsd
  193 + basic_os=bsd
195 194 ;;
196 195 a29khif)
197 196 basic_machine=a29k-amd
198   - os=udi
  197 + basic_os=udi
199 198 ;;
200 199 adobe68k)
201 200 basic_machine=m68010-adobe
202   - os=scout
  201 + basic_os=scout
203 202 ;;
204 203 alliant)
205 204 basic_machine=fx80-alliant
206   - os=
  205 + basic_os=
207 206 ;;
208 207 altos | altos3068)
209 208 basic_machine=m68k-altos
210   - os=
  209 + basic_os=
211 210 ;;
212 211 am29k)
213 212 basic_machine=a29k-none
214   - os=bsd
  213 + basic_os=bsd
215 214 ;;
216 215 amdahl)
217 216 basic_machine=580-amdahl
218   - os=sysv
  217 + basic_os=sysv
219 218 ;;
220 219 amiga)
221 220 basic_machine=m68k-unknown
222   - os=
  221 + basic_os=
223 222 ;;
224 223 amigaos | amigados)
225 224 basic_machine=m68k-unknown
226   - os=amigaos
  225 + basic_os=amigaos
227 226 ;;
228 227 amigaunix | amix)
229 228 basic_machine=m68k-unknown
230   - os=sysv4
  229 + basic_os=sysv4
231 230 ;;
232 231 apollo68)
233 232 basic_machine=m68k-apollo
234   - os=sysv
  233 + basic_os=sysv
235 234 ;;
236 235 apollo68bsd)
237 236 basic_machine=m68k-apollo
238   - os=bsd
  237 + basic_os=bsd
239 238 ;;
240 239 aros)
241 240 basic_machine=i386-pc
242   - os=aros
  241 + basic_os=aros
243 242 ;;
244 243 aux)
245 244 basic_machine=m68k-apple
246   - os=aux
  245 + basic_os=aux
247 246 ;;
248 247 balance)
249 248 basic_machine=ns32k-sequent
250   - os=dynix
  249 + basic_os=dynix
251 250 ;;
252 251 blackfin)
253 252 basic_machine=bfin-unknown
254   - os=linux
  253 + basic_os=linux
255 254 ;;
256 255 cegcc)
257 256 basic_machine=arm-unknown
258   - os=cegcc
  257 + basic_os=cegcc
259 258 ;;
260 259 convex-c1)
261 260 basic_machine=c1-convex
262   - os=bsd
  261 + basic_os=bsd
263 262 ;;
264 263 convex-c2)
265 264 basic_machine=c2-convex
266   - os=bsd
  265 + basic_os=bsd
267 266 ;;
268 267 convex-c32)
269 268 basic_machine=c32-convex
270   - os=bsd
  269 + basic_os=bsd
271 270 ;;
272 271 convex-c34)
273 272 basic_machine=c34-convex
274   - os=bsd
  273 + basic_os=bsd
275 274 ;;
276 275 convex-c38)
277 276 basic_machine=c38-convex
278   - os=bsd
  277 + basic_os=bsd
279 278 ;;
280 279 cray)
281 280 basic_machine=j90-cray
282   - os=unicos
  281 + basic_os=unicos
283 282 ;;
284 283 crds | unos)
285 284 basic_machine=m68k-crds
286   - os=
  285 + basic_os=
287 286 ;;
288 287 da30)
289 288 basic_machine=m68k-da30
290   - os=
  289 + basic_os=
291 290 ;;
292 291 decstation | pmax | pmin | dec3100 | decstatn)
293 292 basic_machine=mips-dec
294   - os=
  293 + basic_os=
295 294 ;;
296 295 delta88)
297 296 basic_machine=m88k-motorola
298   - os=sysv3
  297 + basic_os=sysv3
299 298 ;;
300 299 dicos)
301 300 basic_machine=i686-pc
302   - os=dicos
  301 + basic_os=dicos
303 302 ;;
304 303 djgpp)
305 304 basic_machine=i586-pc
306   - os=msdosdjgpp
  305 + basic_os=msdosdjgpp
307 306 ;;
308 307 ebmon29k)
309 308 basic_machine=a29k-amd
310   - os=ebmon
  309 + basic_os=ebmon
311 310 ;;
312 311 es1800 | OSE68k | ose68k | ose | OSE)
313 312 basic_machine=m68k-ericsson
314   - os=ose
  313 + basic_os=ose
315 314 ;;
316 315 gmicro)
317 316 basic_machine=tron-gmicro
318   - os=sysv
  317 + basic_os=sysv
319 318 ;;
320 319 go32)
321 320 basic_machine=i386-pc
322   - os=go32
  321 + basic_os=go32
323 322 ;;
324 323 h8300hms)
325 324 basic_machine=h8300-hitachi
326   - os=hms
  325 + basic_os=hms
327 326 ;;
328 327 h8300xray)
329 328 basic_machine=h8300-hitachi
330   - os=xray
  329 + basic_os=xray
331 330 ;;
332 331 h8500hms)
333 332 basic_machine=h8500-hitachi
334   - os=hms
  333 + basic_os=hms
335 334 ;;
336 335 harris)
337 336 basic_machine=m88k-harris
338   - os=sysv3
  337 + basic_os=sysv3
339 338 ;;
340 339 hp300 | hp300hpux)
341 340 basic_machine=m68k-hp
342   - os=hpux
  341 + basic_os=hpux
343 342 ;;
344 343 hp300bsd)
345 344 basic_machine=m68k-hp
346   - os=bsd
  345 + basic_os=bsd
347 346 ;;
348 347 hppaosf)
349 348 basic_machine=hppa1.1-hp
350   - os=osf
  349 + basic_os=osf
351 350 ;;
352 351 hppro)
353 352 basic_machine=hppa1.1-hp
354   - os=proelf
  353 + basic_os=proelf
355 354 ;;
356 355 i386mach)
357 356 basic_machine=i386-mach
358   - os=mach
  357 + basic_os=mach
359 358 ;;
360 359 isi68 | isi)
361 360 basic_machine=m68k-isi
362   - os=sysv
  361 + basic_os=sysv
363 362 ;;
364 363 m68knommu)
365 364 basic_machine=m68k-unknown
366   - os=linux
  365 + basic_os=linux
367 366 ;;
368 367 magnum | m3230)
369 368 basic_machine=mips-mips
370   - os=sysv
  369 + basic_os=sysv
371 370 ;;
372 371 merlin)
373 372 basic_machine=ns32k-utek
374   - os=sysv
  373 + basic_os=sysv
375 374 ;;
376 375 mingw64)
377 376 basic_machine=x86_64-pc
378   - os=mingw64
  377 + basic_os=mingw64
379 378 ;;
380 379 mingw32)
381 380 basic_machine=i686-pc
382   - os=mingw32
  381 + basic_os=mingw32
383 382 ;;
384 383 mingw32ce)
385 384 basic_machine=arm-unknown
386   - os=mingw32ce
  385 + basic_os=mingw32ce
387 386 ;;
388 387 monitor)
389 388 basic_machine=m68k-rom68k
390   - os=coff
  389 + basic_os=coff
391 390 ;;
392 391 morphos)
393 392 basic_machine=powerpc-unknown
394   - os=morphos
  393 + basic_os=morphos
395 394 ;;
396 395 moxiebox)
397 396 basic_machine=moxie-unknown
398   - os=moxiebox
  397 + basic_os=moxiebox
399 398 ;;
400 399 msdos)
401 400 basic_machine=i386-pc
402   - os=msdos
  401 + basic_os=msdos
403 402 ;;
404 403 msys)
405 404 basic_machine=i686-pc
406   - os=msys
  405 + basic_os=msys
407 406 ;;
408 407 mvs)
409 408 basic_machine=i370-ibm
410   - os=mvs
  409 + basic_os=mvs
411 410 ;;
412 411 nacl)
413 412 basic_machine=le32-unknown
414   - os=nacl
  413 + basic_os=nacl
415 414 ;;
416 415 ncr3000)
417 416 basic_machine=i486-ncr
418   - os=sysv4
  417 + basic_os=sysv4
419 418 ;;
420 419 netbsd386)
421 420 basic_machine=i386-pc
422   - os=netbsd
  421 + basic_os=netbsd
423 422 ;;
424 423 netwinder)
425 424 basic_machine=armv4l-rebel
426   - os=linux
  425 + basic_os=linux
427 426 ;;
428 427 news | news700 | news800 | news900)
429 428 basic_machine=m68k-sony
430   - os=newsos
  429 + basic_os=newsos
431 430 ;;
432 431 news1000)
433 432 basic_machine=m68030-sony
434   - os=newsos
  433 + basic_os=newsos
435 434 ;;
436 435 necv70)
437 436 basic_machine=v70-nec
438   - os=sysv
  437 + basic_os=sysv
439 438 ;;
440 439 nh3000)
441 440 basic_machine=m68k-harris
442   - os=cxux
  441 + basic_os=cxux
443 442 ;;
444 443 nh[45]000)
445 444 basic_machine=m88k-harris
446   - os=cxux
  445 + basic_os=cxux
447 446 ;;
448 447 nindy960)
449 448 basic_machine=i960-intel
450   - os=nindy
  449 + basic_os=nindy
451 450 ;;
452 451 mon960)
453 452 basic_machine=i960-intel
454   - os=mon960
  453 + basic_os=mon960
455 454 ;;
456 455 nonstopux)
457 456 basic_machine=mips-compaq
458   - os=nonstopux
  457 + basic_os=nonstopux
459 458 ;;
460 459 os400)
461 460 basic_machine=powerpc-ibm
462   - os=os400
  461 + basic_os=os400
463 462 ;;
464 463 OSE68000 | ose68000)
465 464 basic_machine=m68000-ericsson
466   - os=ose
  465 + basic_os=ose
467 466 ;;
468 467 os68k)
469 468 basic_machine=m68k-none
470   - os=os68k
  469 + basic_os=os68k
471 470 ;;
472 471 paragon)
473 472 basic_machine=i860-intel
474   - os=osf
  473 + basic_os=osf
475 474 ;;
476 475 parisc)
477 476 basic_machine=hppa-unknown
478   - os=linux
  477 + basic_os=linux
  478 + ;;
  479 + psp)
  480 + basic_machine=mipsallegrexel-sony
  481 + basic_os=psp
479 482 ;;
480 483 pw32)
481 484 basic_machine=i586-unknown
482   - os=pw32
  485 + basic_os=pw32
483 486 ;;
484 487 rdos | rdos64)
485 488 basic_machine=x86_64-pc
486   - os=rdos
  489 + basic_os=rdos
487 490 ;;
488 491 rdos32)
489 492 basic_machine=i386-pc
490   - os=rdos
  493 + basic_os=rdos
491 494 ;;
492 495 rom68k)
493 496 basic_machine=m68k-rom68k
494   - os=coff
  497 + basic_os=coff
495 498 ;;
496 499 sa29200)
497 500 basic_machine=a29k-amd
498   - os=udi
  501 + basic_os=udi
499 502 ;;
500 503 sei)
501 504 basic_machine=mips-sei
502   - os=seiux
  505 + basic_os=seiux
503 506 ;;
504 507 sequent)
505 508 basic_machine=i386-sequent
506   - os=
  509 + basic_os=
507 510 ;;
508 511 sps7)
509 512 basic_machine=m68k-bull
510   - os=sysv2
  513 + basic_os=sysv2
511 514 ;;
512 515 st2000)
513 516 basic_machine=m68k-tandem
514   - os=
  517 + basic_os=
515 518 ;;
516 519 stratus)
517 520 basic_machine=i860-stratus
518   - os=sysv4
  521 + basic_os=sysv4
519 522 ;;
520 523 sun2)
521 524 basic_machine=m68000-sun
522   - os=
  525 + basic_os=
523 526 ;;
524 527 sun2os3)
525 528 basic_machine=m68000-sun
526   - os=sunos3
  529 + basic_os=sunos3
527 530 ;;
528 531 sun2os4)
529 532 basic_machine=m68000-sun
530   - os=sunos4
  533 + basic_os=sunos4
531 534 ;;
532 535 sun3)
533 536 basic_machine=m68k-sun
534   - os=
  537 + basic_os=
535 538 ;;
536 539 sun3os3)
537 540 basic_machine=m68k-sun
538   - os=sunos3
  541 + basic_os=sunos3
539 542 ;;
540 543 sun3os4)
541 544 basic_machine=m68k-sun
542   - os=sunos4
  545 + basic_os=sunos4
543 546 ;;
544 547 sun4)
545 548 basic_machine=sparc-sun
546   - os=
  549 + basic_os=
547 550 ;;
548 551 sun4os3)
549 552 basic_machine=sparc-sun
550   - os=sunos3
  553 + basic_os=sunos3
551 554 ;;
552 555 sun4os4)
553 556 basic_machine=sparc-sun
554   - os=sunos4
  557 + basic_os=sunos4
555 558 ;;
556 559 sun4sol2)
557 560 basic_machine=sparc-sun
558   - os=solaris2
  561 + basic_os=solaris2
559 562 ;;
560 563 sun386 | sun386i | roadrunner)
561 564 basic_machine=i386-sun
562   - os=
  565 + basic_os=
563 566 ;;
564 567 sv1)
565 568 basic_machine=sv1-cray
566   - os=unicos
  569 + basic_os=unicos
567 570 ;;
568 571 symmetry)
569 572 basic_machine=i386-sequent
570   - os=dynix
  573 + basic_os=dynix
571 574 ;;
572 575 t3e)
573 576 basic_machine=alphaev5-cray
574   - os=unicos
  577 + basic_os=unicos
575 578 ;;
576 579 t90)
577 580 basic_machine=t90-cray
578   - os=unicos
  581 + basic_os=unicos
579 582 ;;
580 583 toad1)
581 584 basic_machine=pdp10-xkl
582   - os=tops20
  585 + basic_os=tops20
583 586 ;;
584 587 tpf)
585 588 basic_machine=s390x-ibm
586   - os=tpf
  589 + basic_os=tpf
587 590 ;;
588 591 udi29k)
589 592 basic_machine=a29k-amd
590   - os=udi
  593 + basic_os=udi
591 594 ;;
592 595 ultra3)
593 596 basic_machine=a29k-nyu
594   - os=sym1
  597 + basic_os=sym1
595 598 ;;
596 599 v810 | necv810)
597 600 basic_machine=v810-nec
598   - os=none
  601 + basic_os=none
599 602 ;;
600 603 vaxv)
601 604 basic_machine=vax-dec
602   - os=sysv
  605 + basic_os=sysv
603 606 ;;
604 607 vms)
605 608 basic_machine=vax-dec
606   - os=vms
  609 + basic_os=vms
607 610 ;;
608 611 vsta)
609 612 basic_machine=i386-pc
610   - os=vsta
  613 + basic_os=vsta
611 614 ;;
612 615 vxworks960)
613 616 basic_machine=i960-wrs
614   - os=vxworks
  617 + basic_os=vxworks
615 618 ;;
616 619 vxworks68)
617 620 basic_machine=m68k-wrs
618   - os=vxworks
  621 + basic_os=vxworks
619 622 ;;
620 623 vxworks29k)
621 624 basic_machine=a29k-wrs
622   - os=vxworks
  625 + basic_os=vxworks
623 626 ;;
624 627 xbox)
625 628 basic_machine=i686-pc
626   - os=mingw32
  629 + basic_os=mingw32
627 630 ;;
628 631 ymp)
629 632 basic_machine=ymp-cray
630   - os=unicos
  633 + basic_os=unicos
631 634 ;;
632 635 *)
633 636 basic_machine=$1
634   - os=
  637 + basic_os=
635 638 ;;
636 639 esac
637 640 ;;
... ... @@ -683,17 +686,17 @@ case $basic_machine in
683 686 bluegene*)
684 687 cpu=powerpc
685 688 vendor=ibm
686   - os=cnk
  689 + basic_os=cnk
687 690 ;;
688 691 decsystem10* | dec10*)
689 692 cpu=pdp10
690 693 vendor=dec
691   - os=tops10
  694 + basic_os=tops10
692 695 ;;
693 696 decsystem20* | dec20*)
694 697 cpu=pdp10
695 698 vendor=dec
696   - os=tops20
  699 + basic_os=tops20
697 700 ;;
698 701 delta | 3300 | motorola-3300 | motorola-delta \
699 702 | 3300-motorola | delta-motorola)
... ... @@ -703,7 +706,7 @@ case $basic_machine in
703 706 dpx2*)
704 707 cpu=m68k
705 708 vendor=bull
706   - os=sysv3
  709 + basic_os=sysv3
707 710 ;;
708 711 encore | umax | mmax)
709 712 cpu=ns32k
... ... @@ -712,7 +715,7 @@ case $basic_machine in
712 715 elxsi)
713 716 cpu=elxsi
714 717 vendor=elxsi
715   - os=${os:-bsd}
  718 + basic_os=${basic_os:-bsd}
716 719 ;;
717 720 fx2800)
718 721 cpu=i860
... ... @@ -725,7 +728,7 @@ case $basic_machine in
725 728 h3050r* | hiux*)
726 729 cpu=hppa1.1
727 730 vendor=hitachi
728   - os=hiuxwe2
  731 + basic_os=hiuxwe2
729 732 ;;
730 733 hp3k9[0-9][0-9] | hp9[0-9][0-9])
731 734 cpu=hppa1.0
... ... @@ -766,38 +769,38 @@ case $basic_machine in
766 769 vendor=hp
767 770 ;;
768 771 i*86v32)
769   - cpu=`echo "$1" | sed -e 's/86.*/86/'`
  772 + cpu=$(echo "$1" | sed -e 's/86.*/86/')
770 773 vendor=pc
771   - os=sysv32
  774 + basic_os=sysv32
772 775 ;;
773 776 i*86v4*)
774   - cpu=`echo "$1" | sed -e 's/86.*/86/'`
  777 + cpu=$(echo "$1" | sed -e 's/86.*/86/')
775 778 vendor=pc
776   - os=sysv4
  779 + basic_os=sysv4
777 780 ;;
778 781 i*86v)
779   - cpu=`echo "$1" | sed -e 's/86.*/86/'`
  782 + cpu=$(echo "$1" | sed -e 's/86.*/86/')
780 783 vendor=pc
781   - os=sysv
  784 + basic_os=sysv
782 785 ;;
783 786 i*86sol2)
784   - cpu=`echo "$1" | sed -e 's/86.*/86/'`
  787 + cpu=$(echo "$1" | sed -e 's/86.*/86/')
785 788 vendor=pc
786   - os=solaris2
  789 + basic_os=solaris2
787 790 ;;
788 791 j90 | j90-cray)
789 792 cpu=j90
790 793 vendor=cray
791   - os=${os:-unicos}
  794 + basic_os=${basic_os:-unicos}
792 795 ;;
793 796 iris | iris4d)
794 797 cpu=mips
795 798 vendor=sgi
796   - case $os in
  799 + case $basic_os in
797 800 irix*)
798 801 ;;
799 802 *)
800   - os=irix4
  803 + basic_os=irix4
801 804 ;;
802 805 esac
803 806 ;;
... ... @@ -808,26 +811,26 @@ case $basic_machine in
808 811 *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*)
809 812 cpu=m68k
810 813 vendor=atari
811   - os=mint
  814 + basic_os=mint
812 815 ;;
813 816 news-3600 | risc-news)
814 817 cpu=mips
815 818 vendor=sony
816   - os=newsos
  819 + basic_os=newsos
817 820 ;;
818 821 next | m*-next)
819 822 cpu=m68k
820 823 vendor=next
821   - case $os in
  824 + case $basic_os in
822 825 openstep*)
823 826 ;;
824 827 nextstep*)
825 828 ;;
826 829 ns2*)
827   - os=nextstep2
  830 + basic_os=nextstep2
828 831 ;;
829 832 *)
830   - os=nextstep3
  833 + basic_os=nextstep3
831 834 ;;
832 835 esac
833 836 ;;
... ... @@ -838,12 +841,12 @@ case $basic_machine in
838 841 op50n-* | op60c-*)
839 842 cpu=hppa1.1
840 843 vendor=oki
841   - os=proelf
  844 + basic_os=proelf
842 845 ;;
843 846 pa-hitachi)
844 847 cpu=hppa1.1
845 848 vendor=hitachi
846   - os=hiuxwe2
  849 + basic_os=hiuxwe2
847 850 ;;
848 851 pbd)
849 852 cpu=sparc
... ... @@ -880,12 +883,12 @@ case $basic_machine in
880 883 sde)
881 884 cpu=mipsisa32
882 885 vendor=sde
883   - os=${os:-elf}
  886 + basic_os=${basic_os:-elf}
884 887 ;;
885 888 simso-wrs)
886 889 cpu=sparclite
887 890 vendor=wrs
888   - os=vxworks
  891 + basic_os=vxworks
889 892 ;;
890 893 tower | tower-32)
891 894 cpu=m68k
... ... @@ -902,7 +905,7 @@ case $basic_machine in
902 905 w89k-*)
903 906 cpu=hppa1.1
904 907 vendor=winbond
905   - os=proelf
  908 + basic_os=proelf
906 909 ;;
907 910 none)
908 911 cpu=none
... ... @@ -914,7 +917,7 @@ case $basic_machine in
914 917 ;;
915 918 leon-*|leon[3-9]-*)
916 919 cpu=sparc
917   - vendor=`echo "$basic_machine" | sed 's/-.*//'`
  920 + vendor=$(echo "$basic_machine" | sed 's/-.*//')
918 921 ;;
919 922  
920 923 *-*)
... ... @@ -955,11 +958,11 @@ case $cpu-$vendor in
955 958 # some cases the only manufacturer, in others, it is the most popular.
956 959 craynv-unknown)
957 960 vendor=cray
958   - os=${os:-unicosmp}
  961 + basic_os=${basic_os:-unicosmp}
959 962 ;;
960 963 c90-unknown | c90-cray)
961 964 vendor=cray
962   - os=${os:-unicos}
  965 + basic_os=${Basic_os:-unicos}
963 966 ;;
964 967 fx80-unknown)
965 968 vendor=alliant
... ... @@ -1003,7 +1006,7 @@ case $cpu-$vendor in
1003 1006 dpx20-unknown | dpx20-bull)
1004 1007 cpu=rs6000
1005 1008 vendor=bull
1006   - os=${os:-bosx}
  1009 + basic_os=${basic_os:-bosx}
1007 1010 ;;
1008 1011  
1009 1012 # Here we normalize CPU types irrespective of the vendor
... ... @@ -1012,7 +1015,7 @@ case $cpu-$vendor in
1012 1015 ;;
1013 1016 blackfin-*)
1014 1017 cpu=bfin
1015   - os=linux
  1018 + basic_os=linux
1016 1019 ;;
1017 1020 c54x-*)
1018 1021 cpu=tic54x
... ... @@ -1025,7 +1028,7 @@ case $cpu-$vendor in
1025 1028 ;;
1026 1029 e500v[12]-*)
1027 1030 cpu=powerpc
1028   - os=$os"spe"
  1031 + basic_os=${basic_os}"spe"
1029 1032 ;;
1030 1033 mips3*-*)
1031 1034 cpu=mips64
... ... @@ -1035,7 +1038,7 @@ case $cpu-$vendor in
1035 1038 ;;
1036 1039 m68knommu-*)
1037 1040 cpu=m68k
1038   - os=linux
  1041 + basic_os=linux
1039 1042 ;;
1040 1043 m9s12z-* | m68hcs12z-* | hcs12z-* | s12z-*)
1041 1044 cpu=s12z
... ... @@ -1045,7 +1048,7 @@ case $cpu-$vendor in
1045 1048 ;;
1046 1049 parisc-*)
1047 1050 cpu=hppa
1048   - os=linux
  1051 + basic_os=linux
1049 1052 ;;
1050 1053 pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
1051 1054 cpu=i586
... ... @@ -1081,7 +1084,7 @@ case $cpu-$vendor in
1081 1084 cpu=mipsisa64sb1el
1082 1085 ;;
1083 1086 sh5e[lb]-*)
1084   - cpu=`echo "$cpu" | sed 's/^\(sh.\)e\(.\)$/\1\2e/'`
  1087 + cpu=$(echo "$cpu" | sed 's/^\(sh.\)e\(.\)$/\1\2e/')
1085 1088 ;;
1086 1089 spur-*)
1087 1090 cpu=spur
... ... @@ -1099,13 +1102,16 @@ case $cpu-$vendor in
1099 1102 cpu=x86_64
1100 1103 ;;
1101 1104 xscale-* | xscalee[bl]-*)
1102   - cpu=`echo "$cpu" | sed 's/^xscale/arm/'`
  1105 + cpu=$(echo "$cpu" | sed 's/^xscale/arm/')
  1106 + ;;
  1107 + arm64-*)
  1108 + cpu=aarch64
1103 1109 ;;
1104 1110  
1105 1111 # Recognize the canonical CPU Types that limit and/or modify the
1106 1112 # company names they are paired with.
1107 1113 cr16-*)
1108   - os=${os:-elf}
  1114 + basic_os=${basic_os:-elf}
1109 1115 ;;
1110 1116 crisv32-* | etraxfs*-*)
1111 1117 cpu=crisv32
... ... @@ -1116,7 +1122,7 @@ case $cpu-$vendor in
1116 1122 vendor=axis
1117 1123 ;;
1118 1124 crx-*)
1119   - os=${os:-elf}
  1125 + basic_os=${basic_os:-elf}
1120 1126 ;;
1121 1127 neo-tandem)
1122 1128 cpu=neo
... ... @@ -1138,16 +1144,12 @@ case $cpu-$vendor in
1138 1144 cpu=nsx
1139 1145 vendor=tandem
1140 1146 ;;
1141   - s390-*)
1142   - cpu=s390
1143   - vendor=ibm
1144   - ;;
1145   - s390x-*)
1146   - cpu=s390x
1147   - vendor=ibm
  1147 + mipsallegrexel-sony)
  1148 + cpu=mipsallegrexel
  1149 + vendor=sony
1148 1150 ;;
1149 1151 tile*-*)
1150   - os=${os:-linux-gnu}
  1152 + basic_os=${basic_os:-linux-gnu}
1151 1153 ;;
1152 1154  
1153 1155 *)
... ... @@ -1164,7 +1166,7 @@ case $cpu-$vendor in
1164 1166 | am33_2.0 \
1165 1167 | amdgcn \
1166 1168 | arc | arceb \
1167   - | arm | arm[lb]e | arme[lb] | armv* \
  1169 + | arm | arm[lb]e | arme[lb] | armv* \
1168 1170 | avr | avr32 \
1169 1171 | asmjs \
1170 1172 | ba \
... ... @@ -1183,6 +1185,7 @@ case $cpu-$vendor in
1183 1185 | k1om \
1184 1186 | le32 | le64 \
1185 1187 | lm32 \
  1188 + | loongarch32 | loongarch64 | loongarchx32 \
1186 1189 | m32c | m32r | m32rle \
1187 1190 | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k \
1188 1191 | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \
... ... @@ -1229,6 +1232,7 @@ case $cpu-$vendor in
1229 1232 | pyramid \
1230 1233 | riscv | riscv32 | riscv64 \
1231 1234 | rl78 | romp | rs6000 | rx \
  1235 + | s390 | s390x \
1232 1236 | score \
1233 1237 | sh | shl \
1234 1238 | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \
... ... @@ -1238,6 +1242,7 @@ case $cpu-$vendor in
1238 1242 | sparcv8 | sparcv9 | sparcv9b | sparcv9v | sv1 | sx* \
1239 1243 | spu \
1240 1244 | tahoe \
  1245 + | thumbv7* \
1241 1246 | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \
1242 1247 | tron \
1243 1248 | ubicom32 \
... ... @@ -1275,8 +1280,47 @@ esac
1275 1280  
1276 1281 # Decode manufacturer-specific aliases for certain operating systems.
1277 1282  
1278   -if [ x$os != x ]
  1283 +if test x$basic_os != x
1279 1284 then
  1285 +
  1286 +# First recognize some ad-hoc caes, or perhaps split kernel-os, or else just
  1287 +# set os.
  1288 +case $basic_os in
  1289 + gnu/linux*)
  1290 + kernel=linux
  1291 + os=$(echo $basic_os | sed -e 's|gnu/linux|gnu|')
  1292 + ;;
  1293 + os2-emx)
  1294 + kernel=os2
  1295 + os=$(echo $basic_os | sed -e 's|os2-emx|emx|')
  1296 + ;;
  1297 + nto-qnx*)
  1298 + kernel=nto
  1299 + os=$(echo $basic_os | sed -e 's|nto-qnx|qnx|')
  1300 + ;;
  1301 + *-*)
  1302 + # shellcheck disable=SC2162
  1303 + IFS="-" read kernel os <<EOF
  1304 +$basic_os
  1305 +EOF
  1306 + ;;
  1307 + # Default OS when just kernel was specified
  1308 + nto*)
  1309 + kernel=nto
  1310 + os=$(echo $basic_os | sed -e 's|nto|qnx|')
  1311 + ;;
  1312 + linux*)
  1313 + kernel=linux
  1314 + os=$(echo $basic_os | sed -e 's|linux|gnu|')
  1315 + ;;
  1316 + *)
  1317 + kernel=
  1318 + os=$basic_os
  1319 + ;;
  1320 +esac
  1321 +
  1322 +# Now, normalize the OS (knowing we just have one component, it's not a kernel,
  1323 +# etc.)
1280 1324 case $os in
1281 1325 # First match some system type aliases that might get confused
1282 1326 # with valid system types.
... ... @@ -1288,7 +1332,7 @@ case $os in
1288 1332 os=cnk
1289 1333 ;;
1290 1334 solaris1 | solaris1.*)
1291   - os=`echo $os | sed -e 's|solaris1|sunos4|'`
  1335 + os=$(echo $os | sed -e 's|solaris1|sunos4|')
1292 1336 ;;
1293 1337 solaris)
1294 1338 os=solaris2
... ... @@ -1296,9 +1340,6 @@ case $os in
1296 1340 unixware*)
1297 1341 os=sysv4.2uw
1298 1342 ;;
1299   - gnu/linux*)
1300   - os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
1301   - ;;
1302 1343 # es1800 is here to avoid being matched by es* (a different OS)
1303 1344 es1800*)
1304 1345 os=ose
... ... @@ -1320,12 +1361,9 @@ case $os in
1320 1361 os=sco3.2v4
1321 1362 ;;
1322 1363 sco3.2.[4-9]*)
1323   - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
1324   - ;;
1325   - sco3.2v[4-9]* | sco5v6*)
1326   - # Don't forget version if it is 3.2v4 or newer.
  1364 + os=$(echo $os | sed -e 's/sco3.2./sco3.2v/')
1327 1365 ;;
1328   - scout)
  1366 + sco*v* | scout)
1329 1367 # Don't match below
1330 1368 ;;
1331 1369 sco*)
... ... @@ -1334,79 +1372,26 @@ case $os in
1334 1372 psos*)
1335 1373 os=psos
1336 1374 ;;
1337   - # Now accept the basic system types.
1338   - # The portable systems comes first.
1339   - # Each alternative MUST end in a * to match a version number.
1340   - # sysv* is not here because it comes later, after sysvr4.
1341   - gnu* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
1342   - | *vms* | esix* | aix* | cnk* | sunos | sunos[34]*\
1343   - | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
1344   - | sym* | kopensolaris* | plan9* \
1345   - | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
1346   - | aos* | aros* | cloudabi* | sortix* | twizzler* \
1347   - | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \
1348   - | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \
1349   - | knetbsd* | mirbsd* | netbsd* \
1350   - | bitrig* | openbsd* | solidbsd* | libertybsd* | os108* \
1351   - | ekkobsd* | kfreebsd* | freebsd* | riscix* | lynxos* \
1352   - | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \
1353   - | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \
1354   - | udi* | eabi* | lites* | ieee* | go32* | aux* | hcos* \
1355   - | chorusrdb* | cegcc* | glidix* \
1356   - | cygwin* | msys* | pe* | moss* | proelf* | rtems* \
1357   - | midipix* | mingw32* | mingw64* | linux-gnu* | linux-android* \
1358   - | linux-newlib* | linux-musl* | linux-uclibc* \
1359   - | uxpv* | beos* | mpeix* | udk* | moxiebox* \
1360   - | interix* | uwin* | mks* | rhapsody* | darwin* \
1361   - | openstep* | oskit* | conix* | pw32* | nonstopux* \
1362   - | storm-chaos* | tops10* | tenex* | tops20* | its* \
1363   - | os2* | vos* | palmos* | uclinux* | nucleus* \
1364   - | morphos* | superux* | rtmk* | windiss* \
1365   - | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \
1366   - | skyos* | haiku* | rdos* | toppers* | drops* | es* \
1367   - | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
1368   - | midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \
1369   - | nsk* | powerunix)
1370   - # Remember, each alternative MUST END IN *, to match a version number.
1371   - ;;
1372 1375 qnx*)
1373   - case $cpu in
1374   - x86 | i*86)
1375   - ;;
1376   - *)
1377   - os=nto-$os
1378   - ;;
1379   - esac
  1376 + os=qnx
1380 1377 ;;
1381 1378 hiux*)
1382 1379 os=hiuxwe2
1383 1380 ;;
1384   - nto-qnx*)
1385   - ;;
1386   - nto*)
1387   - os=`echo $os | sed -e 's|nto|nto-qnx|'`
1388   - ;;
1389   - sim | xray | os68k* | v88r* \
1390   - | windows* | osx | abug | netware* | os9* \
1391   - | macos* | mpw* | magic* | mmixware* | mon960* | lnews*)
1392   - ;;
1393   - linux-dietlibc)
1394   - os=linux-dietlibc
1395   - ;;
1396   - linux*)
1397   - os=`echo $os | sed -e 's|linux|linux-gnu|'`
1398   - ;;
1399 1381 lynx*178)
1400 1382 os=lynxos178
1401 1383 ;;
1402 1384 lynx*5)
1403 1385 os=lynxos5
1404 1386 ;;
  1387 + lynxos*)
  1388 + # don't get caught up in next wildcard
  1389 + ;;
1405 1390 lynx*)
1406 1391 os=lynxos
1407 1392 ;;
1408   - mac*)
1409   - os=`echo "$os" | sed -e 's|mac|macos|'`
  1393 + mac[0-9]*)
  1394 + os=$(echo "$os" | sed -e 's|mac|macos|')
1410 1395 ;;
1411 1396 opened*)
1412 1397 os=openedition
... ... @@ -1415,10 +1400,10 @@ case $os in
1415 1400 os=os400
1416 1401 ;;
1417 1402 sunos5*)
1418   - os=`echo "$os" | sed -e 's|sunos5|solaris2|'`
  1403 + os=$(echo "$os" | sed -e 's|sunos5|solaris2|')
1419 1404 ;;
1420 1405 sunos6*)
1421   - os=`echo "$os" | sed -e 's|sunos6|solaris3|'`
  1406 + os=$(echo "$os" | sed -e 's|sunos6|solaris3|')
1422 1407 ;;
1423 1408 wince*)
1424 1409 os=wince
... ... @@ -1452,7 +1437,7 @@ case $os in
1452 1437 ;;
1453 1438 # Preserve the version number of sinix5.
1454 1439 sinix5.*)
1455   - os=`echo $os | sed -e 's|sinix|sysv|'`
  1440 + os=$(echo $os | sed -e 's|sinix|sysv|')
1456 1441 ;;
1457 1442 sinix*)
1458 1443 os=sysv4
... ... @@ -1475,18 +1460,12 @@ case $os in
1475 1460 sysvr4)
1476 1461 os=sysv4
1477 1462 ;;
1478   - # This must come after sysvr4.
1479   - sysv*)
1480   - ;;
1481 1463 ose*)
1482 1464 os=ose
1483 1465 ;;
1484 1466 *mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
1485 1467 os=mint
1486 1468 ;;
1487   - zvmoe)
1488   - os=zvmoe
1489   - ;;
1490 1469 dicos*)
1491 1470 os=dicos
1492 1471 ;;
... ... @@ -1503,19 +1482,11 @@ case $os in
1503 1482 ;;
1504 1483 esac
1505 1484 ;;
1506   - nacl*)
1507   - ;;
1508   - ios)
1509   - ;;
1510   - none)
1511   - ;;
1512   - *-eabi)
1513   - ;;
1514 1485 *)
1515   - echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2
1516   - exit 1
  1486 + # No normalization, but not necessarily accepted, that comes below.
1517 1487 ;;
1518 1488 esac
  1489 +
1519 1490 else
1520 1491  
1521 1492 # Here we handle the default operating systems that come with various machines.
... ... @@ -1528,6 +1499,7 @@ else
1528 1499 # will signal an error saying that MANUFACTURER isn't an operating
1529 1500 # system, and we'll never get to this point.
1530 1501  
  1502 +kernel=
1531 1503 case $cpu-$vendor in
1532 1504 score-*)
1533 1505 os=elf
... ... @@ -1539,7 +1511,8 @@ case $cpu-$vendor in
1539 1511 os=riscix1.2
1540 1512 ;;
1541 1513 arm*-rebel)
1542   - os=linux
  1514 + kernel=linux
  1515 + os=gnu
1543 1516 ;;
1544 1517 arm*-semi)
1545 1518 os=aout
... ... @@ -1705,84 +1678,173 @@ case $cpu-$vendor in
1705 1678 os=none
1706 1679 ;;
1707 1680 esac
  1681 +
1708 1682 fi
1709 1683  
  1684 +# Now, validate our (potentially fixed-up) OS.
  1685 +case $os in
  1686 + # Sometimes we do "kernel-abi", so those need to count as OSes.
  1687 + musl* | newlib* | uclibc*)
  1688 + ;;
  1689 + # Likewise for "kernel-libc"
  1690 + eabi | eabihf | gnueabi | gnueabihf)
  1691 + ;;
  1692 + # Now accept the basic system types.
  1693 + # The portable systems comes first.
  1694 + # Each alternative MUST end in a * to match a version number.
  1695 + gnu* | android* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
  1696 + | *vms* | esix* | aix* | cnk* | sunos | sunos[34]* \
  1697 + | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
  1698 + | sym* | plan9* | psp* | sim* | xray* | os68k* | v88r* \
  1699 + | hiux* | abug | nacl* | netware* | windows* \
  1700 + | os9* | macos* | osx* | ios* \
  1701 + | mpw* | magic* | mmixware* | mon960* | lnews* \
  1702 + | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
  1703 + | aos* | aros* | cloudabi* | sortix* | twizzler* \
  1704 + | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \
  1705 + | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \
  1706 + | mirbsd* | netbsd* | dicos* | openedition* | ose* \
  1707 + | bitrig* | openbsd* | solidbsd* | libertybsd* | os108* \
  1708 + | ekkobsd* | freebsd* | riscix* | lynxos* | os400* \
  1709 + | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \
  1710 + | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \
  1711 + | udi* | lites* | ieee* | go32* | aux* | hcos* \
  1712 + | chorusrdb* | cegcc* | glidix* \
  1713 + | cygwin* | msys* | pe* | moss* | proelf* | rtems* \
  1714 + | midipix* | mingw32* | mingw64* | mint* \
  1715 + | uxpv* | beos* | mpeix* | udk* | moxiebox* \
  1716 + | interix* | uwin* | mks* | rhapsody* | darwin* \
  1717 + | openstep* | oskit* | conix* | pw32* | nonstopux* \
  1718 + | storm-chaos* | tops10* | tenex* | tops20* | its* \
  1719 + | os2* | vos* | palmos* | uclinux* | nucleus* | morphos* \
  1720 + | scout* | superux* | sysv* | rtmk* | tpf* | windiss* \
  1721 + | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \
  1722 + | skyos* | haiku* | rdos* | toppers* | drops* | es* \
  1723 + | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
  1724 + | midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \
  1725 + | nsk* | powerunix* | genode* | zvmoe* | qnx* | emx*)
  1726 + ;;
  1727 + # This one is extra strict with allowed versions
  1728 + sco3.2v2 | sco3.2v[4-9]* | sco5v6*)
  1729 + # Don't forget version if it is 3.2v4 or newer.
  1730 + ;;
  1731 + none)
  1732 + ;;
  1733 + *)
  1734 + echo Invalid configuration \`"$1"\': OS \`"$os"\' not recognized 1>&2
  1735 + exit 1
  1736 + ;;
  1737 +esac
  1738 +
  1739 +# As a final step for OS-related things, validate the OS-kernel combination
  1740 +# (given a valid OS), if there is a kernel.
  1741 +case $kernel-$os in
  1742 + linux-gnu* | linux-dietlibc* | linux-android* | linux-newlib* | linux-musl* | linux-uclibc* )
  1743 + ;;
  1744 + uclinux-uclibc* )
  1745 + ;;
  1746 + -dietlibc* | -newlib* | -musl* | -uclibc* )
  1747 + # These are just libc implementations, not actual OSes, and thus
  1748 + # require a kernel.
  1749 + echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2
  1750 + exit 1
  1751 + ;;
  1752 + kfreebsd*-gnu* | kopensolaris*-gnu*)
  1753 + ;;
  1754 + nto-qnx*)
  1755 + ;;
  1756 + os2-emx)
  1757 + ;;
  1758 + *-eabi* | *-gnueabi*)
  1759 + ;;
  1760 + -*)
  1761 + # Blank kernel with real OS is always fine.
  1762 + ;;
  1763 + *-*)
  1764 + echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2
  1765 + exit 1
  1766 + ;;
  1767 +esac
  1768 +
1710 1769 # Here we handle the case where we know the os, and the CPU type, but not the
1711 1770 # manufacturer. We pick the logical manufacturer.
1712 1771 case $vendor in
1713 1772 unknown)
1714   - case $os in
1715   - riscix*)
  1773 + case $cpu-$os in
  1774 + *-riscix*)
1716 1775 vendor=acorn
1717 1776 ;;
1718   - sunos*)
  1777 + *-sunos*)
1719 1778 vendor=sun
1720 1779 ;;
1721   - cnk*|-aix*)
  1780 + *-cnk* | *-aix*)
1722 1781 vendor=ibm
1723 1782 ;;
1724   - beos*)
  1783 + *-beos*)
1725 1784 vendor=be
1726 1785 ;;
1727   - hpux*)
  1786 + *-hpux*)
1728 1787 vendor=hp
1729 1788 ;;
1730   - mpeix*)
  1789 + *-mpeix*)
1731 1790 vendor=hp
1732 1791 ;;
1733   - hiux*)
  1792 + *-hiux*)
1734 1793 vendor=hitachi
1735 1794 ;;
1736   - unos*)
  1795 + *-unos*)
1737 1796 vendor=crds
1738 1797 ;;
1739   - dgux*)
  1798 + *-dgux*)
1740 1799 vendor=dg
1741 1800 ;;
1742   - luna*)
  1801 + *-luna*)
1743 1802 vendor=omron
1744 1803 ;;
1745   - genix*)
  1804 + *-genix*)
1746 1805 vendor=ns
1747 1806 ;;
1748   - clix*)
  1807 + *-clix*)
1749 1808 vendor=intergraph
1750 1809 ;;
1751   - mvs* | opened*)
  1810 + *-mvs* | *-opened*)
  1811 + vendor=ibm
  1812 + ;;
  1813 + *-os400*)
1752 1814 vendor=ibm
1753 1815 ;;
1754   - os400*)
  1816 + s390-* | s390x-*)
1755 1817 vendor=ibm
1756 1818 ;;
1757   - ptx*)
  1819 + *-ptx*)
1758 1820 vendor=sequent
1759 1821 ;;
1760   - tpf*)
  1822 + *-tpf*)
1761 1823 vendor=ibm
1762 1824 ;;
1763   - vxsim* | vxworks* | windiss*)
  1825 + *-vxsim* | *-vxworks* | *-windiss*)
1764 1826 vendor=wrs
1765 1827 ;;
1766   - aux*)
  1828 + *-aux*)
1767 1829 vendor=apple
1768 1830 ;;
1769   - hms*)
  1831 + *-hms*)
1770 1832 vendor=hitachi
1771 1833 ;;
1772   - mpw* | macos*)
  1834 + *-mpw* | *-macos*)
1773 1835 vendor=apple
1774 1836 ;;
1775   - *mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
  1837 + *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*)
1776 1838 vendor=atari
1777 1839 ;;
1778   - vos*)
  1840 + *-vos*)
1779 1841 vendor=stratus
1780 1842 ;;
1781 1843 esac
1782 1844 ;;
1783 1845 esac
1784 1846  
1785   -echo "$cpu-$vendor-$os"
  1847 +echo "$cpu-$vendor-${kernel:+$kernel-}$os"
1786 1848 exit
1787 1849  
1788 1850 # Local variables:
... ...
configure
... ... @@ -6360,7 +6360,7 @@ esac
6360 6360 fi
6361 6361  
6362 6362 : ${AR=ar}
6363   -: ${AR_FLAGS=cru}
  6363 +: ${AR_FLAGS=cr}
6364 6364  
6365 6365  
6366 6366  
... ... @@ -8123,8 +8123,8 @@ int forced_loaded() { return 2;}
8123 8123 _LT_EOF
8124 8124 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
8125 8125 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
8126   - echo "$AR cru libconftest.a conftest.o" >&5
8127   - $AR cru libconftest.a conftest.o 2>&5
  8126 + echo "$AR cr libconftest.a conftest.o" >&5
  8127 + $AR cr libconftest.a conftest.o 2>&5
8128 8128 echo "$RANLIB libconftest.a" >&5
8129 8129 $RANLIB libconftest.a 2>&5
8130 8130 cat > conftest.c << _LT_EOF
... ...
install-sh
1 1 #!/bin/sh
2 2 # install - install a program, script, or datafile
3 3  
4   -scriptversion=2014-09-12.12; # UTC
  4 +scriptversion=2018-03-11.20; # UTC
5 5  
6 6 # This originates from X11R5 (mit/util/scripts/install.sh), which was
7 7 # later released in X11R6 (xc/config/util/install.sh) with the
... ... @@ -271,15 +271,18 @@ do
271 271 fi
272 272 dst=$dst_arg
273 273  
274   - # If destination is a directory, append the input filename; won't work
275   - # if double slashes aren't ignored.
  274 + # If destination is a directory, append the input filename.
276 275 if test -d "$dst"; then
277 276 if test "$is_target_a_directory" = never; then
278 277 echo "$0: $dst_arg: Is a directory" >&2
279 278 exit 1
280 279 fi
281 280 dstdir=$dst
282   - dst=$dstdir/`basename "$src"`
  281 + dstbase=`basename "$src"`
  282 + case $dst in
  283 + */) dst=$dst$dstbase;;
  284 + *) dst=$dst/$dstbase;;
  285 + esac
283 286 dstdir_status=0
284 287 else
285 288 dstdir=`dirname "$dst"`
... ... @@ -288,6 +291,11 @@ do
288 291 fi
289 292 fi
290 293  
  294 + case $dstdir in
  295 + */) dstdirslash=$dstdir;;
  296 + *) dstdirslash=$dstdir/;;
  297 + esac
  298 +
291 299 obsolete_mkdir_used=false
292 300  
293 301 if test $dstdir_status != 0; then
... ... @@ -324,14 +332,16 @@ do
324 332 # is incompatible with FreeBSD 'install' when (umask & 300) != 0.
325 333 ;;
326 334 *)
327   - # $RANDOM is not portable (e.g. dash); use it when possible to
328   - # lower collision chance
  335 + # Note that $RANDOM variable is not portable (e.g. dash); Use it
  336 + # here however when possible just to lower collision chance.
329 337 tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
  338 +
330 339 trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0
331 340  
332   - # As "mkdir -p" follows symlinks and we work in /tmp possibly; so
333   - # create the $tmpdir first (and fail if unsuccessful) to make sure
334   - # that nobody tries to guess the $tmpdir name.
  341 + # Because "mkdir -p" follows existing symlinks and we likely work
  342 + # directly in world-writeable /tmp, make sure that the '$tmpdir'
  343 + # directory is successfully created first before we actually test
  344 + # 'mkdir -p' feature.
335 345 if (umask $mkdir_umask &&
336 346 $mkdirprog $mkdir_mode "$tmpdir" &&
337 347 exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
... ... @@ -434,8 +444,8 @@ do
434 444 else
435 445  
436 446 # Make a couple of temp file names in the proper directory.
437   - dsttmp=$dstdir/_inst.$$_
438   - rmtmp=$dstdir/_rm.$$_
  447 + dsttmp=${dstdirslash}_inst.$$_
  448 + rmtmp=${dstdirslash}_rm.$$_
439 449  
440 450 # Trap to clean up those temp files at exit.
441 451 trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
... ... @@ -500,9 +510,9 @@ do
500 510 done
501 511  
502 512 # Local variables:
503   -# eval: (add-hook 'write-file-hooks 'time-stamp)
  513 +# eval: (add-hook 'before-save-hook 'time-stamp)
504 514 # time-stamp-start: "scriptversion="
505 515 # time-stamp-format: "%:y-%02m-%02d.%02H"
506   -# time-stamp-time-zone: "UTC"
  516 +# time-stamp-time-zone: "UTC0"
507 517 # time-stamp-end: "; # UTC"
508 518 # End:
... ...
ltmain.sh
... ... @@ -31,7 +31,7 @@
31 31  
32 32 PROGRAM=libtool
33 33 PACKAGE=libtool
34   -VERSION="2.4.6 Debian-2.4.6-11"
  34 +VERSION="2.4.6 Debian-2.4.6-14"
35 35 package_revision=2.4.6
36 36  
37 37  
... ... @@ -387,7 +387,7 @@ EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake.
387 387 # putting '$debug_cmd' at the start of all your functions, you can get
388 388 # bash to show function call trace with:
389 389 #
390   -# debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name
  390 +# debug_cmd='echo "${FUNCNAME[0]} $*" >&2' bash your-script-name
391 391 debug_cmd=${debug_cmd-":"}
392 392 exit_cmd=:
393 393  
... ... @@ -2141,7 +2141,7 @@ include the following information:
2141 2141 compiler: $LTCC
2142 2142 compiler flags: $LTCFLAGS
2143 2143 linker: $LD (gnu? $with_gnu_ld)
2144   - version: $progname $scriptversion Debian-2.4.6-11
  2144 + version: $progname $scriptversion Debian-2.4.6-14
2145 2145 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q`
2146 2146 autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q`
2147 2147  
... ... @@ -7368,10 +7368,12 @@ func_mode_link ()
7368 7368 # -stdlib=* select c++ std lib with clang
7369 7369 # -fsanitize=* Clang/GCC memory and address sanitizer
7370 7370 # -fuse-ld=* Linker select flags for GCC
  7371 + # -static-* direct GCC to link specific libraries statically
  7372 + # -fcilkplus Cilk Plus language extension features for C/C++
7371 7373 -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
7372 7374 -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
7373 7375 -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
7374   - -specs=*|-fsanitize=*|-fuse-ld=*)
  7376 + -specs=*|-fsanitize=*|-fuse-ld=*|-static-*|-fcilkplus)
7375 7377 func_quote_for_eval "$arg"
7376 7378 arg=$func_quote_for_eval_result
7377 7379 func_append compile_command " $arg"
... ...
m4/libtool.m4
... ... @@ -1041,8 +1041,8 @@ int forced_loaded() { return 2;}
1041 1041 _LT_EOF
1042 1042 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
1043 1043 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
1044   - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
1045   - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
  1044 + echo "$AR cr libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
  1045 + $AR cr libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
1046 1046 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
1047 1047 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
1048 1048 cat > conftest.c << _LT_EOF
... ... @@ -1492,7 +1492,7 @@ need_locks=$enable_libtool_lock
1492 1492 m4_defun([_LT_PROG_AR],
1493 1493 [AC_CHECK_TOOLS(AR, [ar], false)
1494 1494 : ${AR=ar}
1495   -: ${AR_FLAGS=cru}
  1495 +: ${AR_FLAGS=cr}
1496 1496 _LT_DECL([], [AR], [1], [The archiver])
1497 1497 _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
1498 1498  
... ...
mkinstalldirs
1 1 #! /bin/sh
2 2 # mkinstalldirs --- make directory hierarchy
3 3  
4   -scriptversion=2009-04-28.21; # UTC
  4 +scriptversion=2018-03-07.03; # UTC
5 5  
6 6 # Original author: Noah Friedman <friedman@prep.ai.mit.edu>
7 7 # Created: 1993-05-16
... ... @@ -154,9 +154,9 @@ exit $errstatus
154 154 # Local Variables:
155 155 # mode: shell-script
156 156 # sh-indentation: 2
157   -# eval: (add-hook 'write-file-hooks 'time-stamp)
  157 +# eval: (add-hook 'before-save-hook 'time-stamp)
158 158 # time-stamp-start: "scriptversion="
159 159 # time-stamp-format: "%:y-%02m-%02d.%02H"
160   -# time-stamp-time-zone: "UTC"
  160 +# time-stamp-time-zone: "UTC0"
161 161 # time-stamp-end: "; # UTC"
162 162 # End:
... ...