| 1 |
|
#! /bin/sh |
| 2 |
|
# Attempt to guess a canonical system name. |
| 3 |
< |
# Copyright 1992-2018 Free Software Foundation, Inc. |
| 3 |
> |
# Copyright 1992-2019 Free Software Foundation, Inc. |
| 4 |
|
|
| 5 |
< |
timestamp='2018-03-08' |
| 5 |
> |
timestamp='2019-04-28' |
| 6 |
|
|
| 7 |
|
# This file is free software; you can redistribute it and/or modify it |
| 8 |
|
# under the terms of the GNU General Public License as published by |
| 50 |
|
GNU config.guess ($timestamp) |
| 51 |
|
|
| 52 |
|
Originally written by Per Bothner. |
| 53 |
< |
Copyright 1992-2018 Free Software Foundation, Inc. |
| 53 |
> |
Copyright 1992-2019 Free Software Foundation, Inc. |
| 54 |
|
|
| 55 |
|
This is free software; see the source for copying conditions. There is NO |
| 56 |
|
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." |
| 84 |
|
exit 1 |
| 85 |
|
fi |
| 86 |
|
|
| 87 |
– |
trap 'exit 1' 1 2 15 |
| 88 |
– |
|
| 87 |
|
# CC_FOR_BUILD -- compiler used by this script. Note that the use of a |
| 88 |
|
# compiler to aid in system detection is discouraged as it requires |
| 89 |
|
# temporary files to be created and, as you can see below, it is a |
| 94 |
|
|
| 95 |
|
# Portable tmp directory creation inspired by the Autoconf team. |
| 96 |
|
|
| 97 |
< |
set_cc_for_build=' |
| 98 |
< |
trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; |
| 99 |
< |
trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; |
| 100 |
< |
: ${TMPDIR=/tmp} ; |
| 101 |
< |
{ tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || |
| 102 |
< |
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || |
| 103 |
< |
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || |
| 104 |
< |
{ echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; |
| 105 |
< |
dummy=$tmp/dummy ; |
| 106 |
< |
tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; |
| 107 |
< |
case $CC_FOR_BUILD,$HOST_CC,$CC in |
| 108 |
< |
,,) echo "int x;" > "$dummy.c" ; |
| 109 |
< |
for c in cc gcc c89 c99 ; do |
| 110 |
< |
if ($c -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then |
| 111 |
< |
CC_FOR_BUILD="$c"; break ; |
| 112 |
< |
fi ; |
| 113 |
< |
done ; |
| 114 |
< |
if test x"$CC_FOR_BUILD" = x ; then |
| 115 |
< |
CC_FOR_BUILD=no_compiler_found ; |
| 116 |
< |
fi |
| 117 |
< |
;; |
| 118 |
< |
,,*) CC_FOR_BUILD=$CC ;; |
| 119 |
< |
,*,*) CC_FOR_BUILD=$HOST_CC ;; |
| 120 |
< |
esac ; set_cc_for_build= ;' |
| 97 |
> |
tmp= |
| 98 |
> |
# shellcheck disable=SC2172 |
| 99 |
> |
trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15 |
| 100 |
> |
|
| 101 |
> |
set_cc_for_build() { |
| 102 |
> |
: "${TMPDIR=/tmp}" |
| 103 |
> |
# shellcheck disable=SC2039 |
| 104 |
> |
{ tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || |
| 105 |
> |
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || |
| 106 |
> |
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || |
| 107 |
> |
{ echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } |
| 108 |
> |
dummy=$tmp/dummy |
| 109 |
> |
case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in |
| 110 |
> |
,,) echo "int x;" > "$dummy.c" |
| 111 |
> |
for driver in cc gcc c89 c99 ; do |
| 112 |
> |
if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then |
| 113 |
> |
CC_FOR_BUILD="$driver" |
| 114 |
> |
break |
| 115 |
> |
fi |
| 116 |
> |
done |
| 117 |
> |
if test x"$CC_FOR_BUILD" = x ; then |
| 118 |
> |
CC_FOR_BUILD=no_compiler_found |
| 119 |
> |
fi |
| 120 |
> |
;; |
| 121 |
> |
,,*) CC_FOR_BUILD=$CC ;; |
| 122 |
> |
,*,*) CC_FOR_BUILD=$HOST_CC ;; |
| 123 |
> |
esac |
| 124 |
> |
} |
| 125 |
|
|
| 126 |
|
# This is needed to find uname on a Pyramid OSx when run in the BSD universe. |
| 127 |
|
# (ghazi@noc.rutgers.edu 1994-08-24) |
| 128 |
< |
if (test -f /.attbin/uname) >/dev/null 2>&1 ; then |
| 128 |
> |
if test -f /.attbin/uname ; then |
| 129 |
|
PATH=$PATH:/.attbin ; export PATH |
| 130 |
|
fi |
| 131 |
|
|
| 140 |
|
# We could probably try harder. |
| 141 |
|
LIBC=gnu |
| 142 |
|
|
| 143 |
< |
eval "$set_cc_for_build" |
| 143 |
> |
set_cc_for_build |
| 144 |
|
cat <<-EOF > "$dummy.c" |
| 145 |
|
#include <features.h> |
| 146 |
|
#if defined(__UCLIBC__) |
| 201 |
|
os=netbsdelf |
| 202 |
|
;; |
| 203 |
|
arm*|i386|m68k|ns32k|sh3*|sparc|vax) |
| 204 |
< |
eval "$set_cc_for_build" |
| 204 |
> |
set_cc_for_build |
| 205 |
|
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ |
| 206 |
|
| grep -q __ELF__ |
| 207 |
|
then |
| 239 |
|
# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: |
| 240 |
|
# contains redundant information, the shorter form: |
| 241 |
|
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. |
| 242 |
< |
echo "$machine-${os}${release}${abi}" |
| 242 |
> |
echo "$machine-${os}${release}${abi-}" |
| 243 |
|
exit ;; |
| 244 |
|
*:Bitrig:*:*) |
| 245 |
|
UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` |
| 391 |
|
echo i386-pc-auroraux"$UNAME_RELEASE" |
| 392 |
|
exit ;; |
| 393 |
|
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) |
| 394 |
< |
eval "$set_cc_for_build" |
| 394 |
> |
set_cc_for_build |
| 395 |
|
SUN_ARCH=i386 |
| 396 |
|
# If there is a compiler, see if it is configured for 64-bit objects. |
| 397 |
|
# Note that the Sun cc does not turn __LP64__ into 1 like gcc does. |
| 484 |
|
echo clipper-intergraph-clix"$UNAME_RELEASE" |
| 485 |
|
exit ;; |
| 486 |
|
mips:*:*:UMIPS | mips:*:*:RISCos) |
| 487 |
< |
eval "$set_cc_for_build" |
| 487 |
> |
set_cc_for_build |
| 488 |
|
sed 's/^ //' << EOF > "$dummy.c" |
| 489 |
|
#ifdef __cplusplus |
| 490 |
|
#include <stdio.h> /* for printf() prototype */ |
| 581 |
|
exit ;; |
| 582 |
|
*:AIX:2:3) |
| 583 |
|
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then |
| 584 |
< |
eval "$set_cc_for_build" |
| 584 |
> |
set_cc_for_build |
| 585 |
|
sed 's/^ //' << EOF > "$dummy.c" |
| 586 |
|
#include <sys/systemcfg.h> |
| 587 |
|
|
| 662 |
|
esac |
| 663 |
|
fi |
| 664 |
|
if [ "$HP_ARCH" = "" ]; then |
| 665 |
< |
eval "$set_cc_for_build" |
| 665 |
> |
set_cc_for_build |
| 666 |
|
sed 's/^ //' << EOF > "$dummy.c" |
| 667 |
|
|
| 668 |
|
#define _HPUX_SOURCE |
| 702 |
|
esac |
| 703 |
|
if [ "$HP_ARCH" = hppa2.0w ] |
| 704 |
|
then |
| 705 |
< |
eval "$set_cc_for_build" |
| 705 |
> |
set_cc_for_build |
| 706 |
|
|
| 707 |
|
# hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating |
| 708 |
|
# 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler |
| 728 |
|
echo ia64-hp-hpux"$HPUX_REV" |
| 729 |
|
exit ;; |
| 730 |
|
3050*:HI-UX:*:*) |
| 731 |
< |
eval "$set_cc_for_build" |
| 731 |
> |
set_cc_for_build |
| 732 |
|
sed 's/^ //' << EOF > "$dummy.c" |
| 733 |
|
#include <unistd.h> |
| 734 |
|
int |
| 842 |
|
*:BSD/OS:*:*) |
| 843 |
|
echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" |
| 844 |
|
exit ;; |
| 845 |
+ |
arm:FreeBSD:*:*) |
| 846 |
+ |
UNAME_PROCESSOR=`uname -p` |
| 847 |
+ |
set_cc_for_build |
| 848 |
+ |
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ |
| 849 |
+ |
| grep -q __ARM_PCS_VFP |
| 850 |
+ |
then |
| 851 |
+ |
echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi |
| 852 |
+ |
else |
| 853 |
+ |
echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf |
| 854 |
+ |
fi |
| 855 |
+ |
exit ;; |
| 856 |
|
*:FreeBSD:*:*) |
| 857 |
|
UNAME_PROCESSOR=`/usr/bin/uname -p` |
| 858 |
|
case "$UNAME_PROCESSOR" in |
| 894 |
|
echo "$UNAME_MACHINE"-pc-uwin |
| 895 |
|
exit ;; |
| 896 |
|
amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) |
| 897 |
< |
echo x86_64-unknown-cygwin |
| 897 |
> |
echo x86_64-pc-cygwin |
| 898 |
|
exit ;; |
| 899 |
|
prep*:SunOS:5.*:*) |
| 900 |
|
echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" |
| 907 |
|
# other systems with GNU libc and userland |
| 908 |
|
echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC" |
| 909 |
|
exit ;; |
| 910 |
< |
i*86:Minix:*:*) |
| 911 |
< |
echo "$UNAME_MACHINE"-pc-minix |
| 910 |
> |
*:Minix:*:*) |
| 911 |
> |
echo "$UNAME_MACHINE"-unknown-minix |
| 912 |
|
exit ;; |
| 913 |
|
aarch64:Linux:*:*) |
| 914 |
|
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" |
| 935 |
|
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" |
| 936 |
|
exit ;; |
| 937 |
|
arm*:Linux:*:*) |
| 938 |
< |
eval "$set_cc_for_build" |
| 938 |
> |
set_cc_for_build |
| 939 |
|
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ |
| 940 |
|
| grep -q __ARM_EABI__ |
| 941 |
|
then |
| 984 |
|
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" |
| 985 |
|
exit ;; |
| 986 |
|
mips:Linux:*:* | mips64:Linux:*:*) |
| 987 |
< |
eval "$set_cc_for_build" |
| 987 |
> |
set_cc_for_build |
| 988 |
> |
IS_GLIBC=0 |
| 989 |
> |
test x"${LIBC}" = xgnu && IS_GLIBC=1 |
| 990 |
|
sed 's/^ //' << EOF > "$dummy.c" |
| 991 |
|
#undef CPU |
| 992 |
< |
#undef ${UNAME_MACHINE} |
| 993 |
< |
#undef ${UNAME_MACHINE}el |
| 992 |
> |
#undef mips |
| 993 |
> |
#undef mipsel |
| 994 |
> |
#undef mips64 |
| 995 |
> |
#undef mips64el |
| 996 |
> |
#if ${IS_GLIBC} && defined(_ABI64) |
| 997 |
> |
LIBCABI=gnuabi64 |
| 998 |
> |
#else |
| 999 |
> |
#if ${IS_GLIBC} && defined(_ABIN32) |
| 1000 |
> |
LIBCABI=gnuabin32 |
| 1001 |
> |
#else |
| 1002 |
> |
LIBCABI=${LIBC} |
| 1003 |
> |
#endif |
| 1004 |
> |
#endif |
| 1005 |
> |
|
| 1006 |
> |
#if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 |
| 1007 |
> |
CPU=mipsisa64r6 |
| 1008 |
> |
#else |
| 1009 |
> |
#if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 |
| 1010 |
> |
CPU=mipsisa32r6 |
| 1011 |
> |
#else |
| 1012 |
> |
#if defined(__mips64) |
| 1013 |
> |
CPU=mips64 |
| 1014 |
> |
#else |
| 1015 |
> |
CPU=mips |
| 1016 |
> |
#endif |
| 1017 |
> |
#endif |
| 1018 |
> |
#endif |
| 1019 |
> |
|
| 1020 |
|
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) |
| 1021 |
< |
CPU=${UNAME_MACHINE}el |
| 1021 |
> |
MIPS_ENDIAN=el |
| 1022 |
|
#else |
| 1023 |
|
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) |
| 1024 |
< |
CPU=${UNAME_MACHINE} |
| 1024 |
> |
MIPS_ENDIAN= |
| 1025 |
|
#else |
| 1026 |
< |
CPU= |
| 1026 |
> |
MIPS_ENDIAN= |
| 1027 |
|
#endif |
| 1028 |
|
#endif |
| 1029 |
|
EOF |
| 1030 |
< |
eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`" |
| 1031 |
< |
test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; } |
| 1030 |
> |
eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`" |
| 1031 |
> |
test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } |
| 1032 |
|
;; |
| 1033 |
|
mips64el:Linux:*:*) |
| 1034 |
|
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" |
| 1141 |
|
*Pentium) UNAME_MACHINE=i586 ;; |
| 1142 |
|
*Pent*|*Celeron) UNAME_MACHINE=i686 ;; |
| 1143 |
|
esac |
| 1144 |
< |
echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}" |
| 1144 |
> |
echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}" |
| 1145 |
|
exit ;; |
| 1146 |
|
i*86:*:3.2:*) |
| 1147 |
|
if test -f /usr/options/cb.name; then |
| 1326 |
|
exit ;; |
| 1327 |
|
*:Darwin:*:*) |
| 1328 |
|
UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown |
| 1329 |
< |
eval "$set_cc_for_build" |
| 1329 |
> |
set_cc_for_build |
| 1330 |
|
if test "$UNAME_PROCESSOR" = unknown ; then |
| 1331 |
|
UNAME_PROCESSOR=powerpc |
| 1332 |
|
fi |
| 1399 |
|
# "uname -m" is not consistent, so use $cputype instead. 386 |
| 1400 |
|
# is converted to i386 for consistency with other x86 |
| 1401 |
|
# operating systems. |
| 1402 |
+ |
# shellcheck disable=SC2154 |
| 1403 |
|
if test "$cputype" = 386; then |
| 1404 |
|
UNAME_MACHINE=i386 |
| 1405 |
|
else |
| 1456 |
|
amd64:Isilon\ OneFS:*:*) |
| 1457 |
|
echo x86_64-unknown-onefs |
| 1458 |
|
exit ;; |
| 1459 |
+ |
*:Unleashed:*:*) |
| 1460 |
+ |
echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE" |
| 1461 |
+ |
exit ;; |
| 1462 |
|
esac |
| 1463 |
|
|
| 1464 |
+ |
# No uname command or uname output not recognized. |
| 1465 |
+ |
set_cc_for_build |
| 1466 |
+ |
cat > "$dummy.c" <<EOF |
| 1467 |
+ |
#ifdef _SEQUENT_ |
| 1468 |
+ |
#include <sys/types.h> |
| 1469 |
+ |
#include <sys/utsname.h> |
| 1470 |
+ |
#endif |
| 1471 |
+ |
#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) |
| 1472 |
+ |
#if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) |
| 1473 |
+ |
#include <signal.h> |
| 1474 |
+ |
#if defined(_SIZE_T_) || defined(SIGLOST) |
| 1475 |
+ |
#include <sys/utsname.h> |
| 1476 |
+ |
#endif |
| 1477 |
+ |
#endif |
| 1478 |
+ |
#endif |
| 1479 |
+ |
main () |
| 1480 |
+ |
{ |
| 1481 |
+ |
#if defined (sony) |
| 1482 |
+ |
#if defined (MIPSEB) |
| 1483 |
+ |
/* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, |
| 1484 |
+ |
I don't know.... */ |
| 1485 |
+ |
printf ("mips-sony-bsd\n"); exit (0); |
| 1486 |
+ |
#else |
| 1487 |
+ |
#include <sys/param.h> |
| 1488 |
+ |
printf ("m68k-sony-newsos%s\n", |
| 1489 |
+ |
#ifdef NEWSOS4 |
| 1490 |
+ |
"4" |
| 1491 |
+ |
#else |
| 1492 |
+ |
"" |
| 1493 |
+ |
#endif |
| 1494 |
+ |
); exit (0); |
| 1495 |
+ |
#endif |
| 1496 |
+ |
#endif |
| 1497 |
+ |
|
| 1498 |
+ |
#if defined (NeXT) |
| 1499 |
+ |
#if !defined (__ARCHITECTURE__) |
| 1500 |
+ |
#define __ARCHITECTURE__ "m68k" |
| 1501 |
+ |
#endif |
| 1502 |
+ |
int version; |
| 1503 |
+ |
version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; |
| 1504 |
+ |
if (version < 4) |
| 1505 |
+ |
printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); |
| 1506 |
+ |
else |
| 1507 |
+ |
printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); |
| 1508 |
+ |
exit (0); |
| 1509 |
+ |
#endif |
| 1510 |
+ |
|
| 1511 |
+ |
#if defined (MULTIMAX) || defined (n16) |
| 1512 |
+ |
#if defined (UMAXV) |
| 1513 |
+ |
printf ("ns32k-encore-sysv\n"); exit (0); |
| 1514 |
+ |
#else |
| 1515 |
+ |
#if defined (CMU) |
| 1516 |
+ |
printf ("ns32k-encore-mach\n"); exit (0); |
| 1517 |
+ |
#else |
| 1518 |
+ |
printf ("ns32k-encore-bsd\n"); exit (0); |
| 1519 |
+ |
#endif |
| 1520 |
+ |
#endif |
| 1521 |
+ |
#endif |
| 1522 |
+ |
|
| 1523 |
+ |
#if defined (__386BSD__) |
| 1524 |
+ |
printf ("i386-pc-bsd\n"); exit (0); |
| 1525 |
+ |
#endif |
| 1526 |
+ |
|
| 1527 |
+ |
#if defined (sequent) |
| 1528 |
+ |
#if defined (i386) |
| 1529 |
+ |
printf ("i386-sequent-dynix\n"); exit (0); |
| 1530 |
+ |
#endif |
| 1531 |
+ |
#if defined (ns32000) |
| 1532 |
+ |
printf ("ns32k-sequent-dynix\n"); exit (0); |
| 1533 |
+ |
#endif |
| 1534 |
+ |
#endif |
| 1535 |
+ |
|
| 1536 |
+ |
#if defined (_SEQUENT_) |
| 1537 |
+ |
struct utsname un; |
| 1538 |
+ |
|
| 1539 |
+ |
uname(&un); |
| 1540 |
+ |
if (strncmp(un.version, "V2", 2) == 0) { |
| 1541 |
+ |
printf ("i386-sequent-ptx2\n"); exit (0); |
| 1542 |
+ |
} |
| 1543 |
+ |
if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ |
| 1544 |
+ |
printf ("i386-sequent-ptx1\n"); exit (0); |
| 1545 |
+ |
} |
| 1546 |
+ |
printf ("i386-sequent-ptx\n"); exit (0); |
| 1547 |
+ |
#endif |
| 1548 |
+ |
|
| 1549 |
+ |
#if defined (vax) |
| 1550 |
+ |
#if !defined (ultrix) |
| 1551 |
+ |
#include <sys/param.h> |
| 1552 |
+ |
#if defined (BSD) |
| 1553 |
+ |
#if BSD == 43 |
| 1554 |
+ |
printf ("vax-dec-bsd4.3\n"); exit (0); |
| 1555 |
+ |
#else |
| 1556 |
+ |
#if BSD == 199006 |
| 1557 |
+ |
printf ("vax-dec-bsd4.3reno\n"); exit (0); |
| 1558 |
+ |
#else |
| 1559 |
+ |
printf ("vax-dec-bsd\n"); exit (0); |
| 1560 |
+ |
#endif |
| 1561 |
+ |
#endif |
| 1562 |
+ |
#else |
| 1563 |
+ |
printf ("vax-dec-bsd\n"); exit (0); |
| 1564 |
+ |
#endif |
| 1565 |
+ |
#else |
| 1566 |
+ |
#if defined(_SIZE_T_) || defined(SIGLOST) |
| 1567 |
+ |
struct utsname un; |
| 1568 |
+ |
uname (&un); |
| 1569 |
+ |
printf ("vax-dec-ultrix%s\n", un.release); exit (0); |
| 1570 |
+ |
#else |
| 1571 |
+ |
printf ("vax-dec-ultrix\n"); exit (0); |
| 1572 |
+ |
#endif |
| 1573 |
+ |
#endif |
| 1574 |
+ |
#endif |
| 1575 |
+ |
#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) |
| 1576 |
+ |
#if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) |
| 1577 |
+ |
#if defined(_SIZE_T_) || defined(SIGLOST) |
| 1578 |
+ |
struct utsname *un; |
| 1579 |
+ |
uname (&un); |
| 1580 |
+ |
printf ("mips-dec-ultrix%s\n", un.release); exit (0); |
| 1581 |
+ |
#else |
| 1582 |
+ |
printf ("mips-dec-ultrix\n"); exit (0); |
| 1583 |
+ |
#endif |
| 1584 |
+ |
#endif |
| 1585 |
+ |
#endif |
| 1586 |
+ |
|
| 1587 |
+ |
#if defined (alliant) && defined (i860) |
| 1588 |
+ |
printf ("i860-alliant-bsd\n"); exit (0); |
| 1589 |
+ |
#endif |
| 1590 |
+ |
|
| 1591 |
+ |
exit (1); |
| 1592 |
+ |
} |
| 1593 |
+ |
EOF |
| 1594 |
+ |
|
| 1595 |
+ |
$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`$dummy` && |
| 1596 |
+ |
{ echo "$SYSTEM_NAME"; exit; } |
| 1597 |
+ |
|
| 1598 |
+ |
# Apollos put the system type in the environment. |
| 1599 |
+ |
test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; } |
| 1600 |
+ |
|
| 1601 |
|
echo "$0: unable to guess system type" >&2 |
| 1602 |
|
|
| 1603 |
|
case "$UNAME_MACHINE:$UNAME_SYSTEM" in |