Home | History | Annotate | Line # | Download | only in dist
config.guess revision 1.10
      1   1.1  christos #! /bin/sh
      2   1.1  christos # Attempt to guess a canonical system name.
      3   1.9     sevan #   Copyright 1992-2017 Free Software Foundation, Inc.
      4   1.1  christos 
      5  1.10  christos timestamp='2017-03-22'
      6   1.1  christos 
      7   1.1  christos # This file is free software; you can redistribute it and/or modify it
      8   1.1  christos # under the terms of the GNU General Public License as published by
      9   1.3  christos # the Free Software Foundation; either version 3 of the License, or
     10   1.1  christos # (at your option) any later version.
     11   1.1  christos #
     12   1.1  christos # This program is distributed in the hope that it will be useful, but
     13   1.1  christos # WITHOUT ANY WARRANTY; without even the implied warranty of
     14   1.1  christos # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
     15   1.1  christos # General Public License for more details.
     16   1.1  christos #
     17   1.1  christos # You should have received a copy of the GNU General Public License
     18   1.3  christos # along with this program; if not, see <http://www.gnu.org/licenses/>.
     19   1.1  christos #
     20   1.1  christos # As a special exception to the GNU General Public License, if you
     21   1.1  christos # distribute this file as part of a program that contains a
     22   1.1  christos # configuration script generated by Autoconf, you may include it under
     23   1.3  christos # the same distribution terms that you use for the rest of that
     24   1.3  christos # program.  This Exception is an additional permission under section 7
     25   1.3  christos # of the GNU General Public License, version 3 ("GPLv3").
     26   1.1  christos #
     27   1.5  christos # Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
     28   1.1  christos #
     29   1.1  christos # You can get the latest version of this script from:
     30   1.7     skrll # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
     31   1.3  christos #
     32   1.5  christos # Please send patches to <config-patches (at] gnu.org>.
     33   1.3  christos 
     34   1.1  christos 
     35   1.1  christos me=`echo "$0" | sed -e 's,.*/,,'`
     36   1.1  christos 
     37   1.1  christos usage="\
     38   1.1  christos Usage: $0 [OPTION]
     39   1.1  christos 
     40   1.1  christos Output the configuration name of the system \`$me' is run on.
     41   1.1  christos 
     42   1.1  christos Operation modes:
     43   1.1  christos   -h, --help         print this help, then exit
     44   1.1  christos   -t, --time-stamp   print date of last modification, then exit
     45   1.1  christos   -v, --version      print version number, then exit
     46   1.1  christos 
     47   1.1  christos Report bugs and patches to <config-patches (at] gnu.org>."
     48   1.1  christos 
     49   1.1  christos version="\
     50   1.1  christos GNU config.guess ($timestamp)
     51   1.1  christos 
     52   1.1  christos Originally written by Per Bothner.
     53   1.9     sevan Copyright 1992-2017 Free Software Foundation, Inc.
     54   1.1  christos 
     55   1.1  christos This is free software; see the source for copying conditions.  There is NO
     56   1.1  christos warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
     57   1.1  christos 
     58   1.1  christos help="
     59   1.1  christos Try \`$me --help' for more information."
     60   1.1  christos 
     61   1.1  christos # Parse command line
     62   1.1  christos while test $# -gt 0 ; do
     63   1.1  christos   case $1 in
     64   1.1  christos     --time-stamp | --time* | -t )
     65   1.1  christos        echo "$timestamp" ; exit ;;
     66   1.1  christos     --version | -v )
     67   1.1  christos        echo "$version" ; exit ;;
     68   1.1  christos     --help | --h* | -h )
     69   1.1  christos        echo "$usage"; exit ;;
     70   1.1  christos     -- )     # Stop option processing
     71   1.1  christos        shift; break ;;
     72   1.1  christos     - )	# Use stdin as input.
     73   1.1  christos        break ;;
     74   1.1  christos     -* )
     75   1.1  christos        echo "$me: invalid option $1$help" >&2
     76   1.1  christos        exit 1 ;;
     77   1.1  christos     * )
     78   1.1  christos        break ;;
     79   1.1  christos   esac
     80   1.1  christos done
     81   1.1  christos 
     82   1.1  christos if test $# != 0; then
     83   1.1  christos   echo "$me: too many arguments$help" >&2
     84   1.1  christos   exit 1
     85   1.1  christos fi
     86   1.1  christos 
     87   1.1  christos trap 'exit 1' 1 2 15
     88   1.1  christos 
     89   1.1  christos # CC_FOR_BUILD -- compiler used by this script. Note that the use of a
     90   1.1  christos # compiler to aid in system detection is discouraged as it requires
     91   1.1  christos # temporary files to be created and, as you can see below, it is a
     92   1.1  christos # headache to deal with in a portable fashion.
     93   1.1  christos 
     94   1.1  christos # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
     95   1.1  christos # use `HOST_CC' if defined, but it is deprecated.
     96   1.1  christos 
     97   1.1  christos # Portable tmp directory creation inspired by the Autoconf team.
     98   1.1  christos 
     99   1.1  christos set_cc_for_build='
    100   1.1  christos trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
    101   1.1  christos trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
    102   1.1  christos : ${TMPDIR=/tmp} ;
    103   1.1  christos  { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
    104   1.1  christos  { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
    105   1.1  christos  { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
    106   1.1  christos  { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
    107   1.1  christos dummy=$tmp/dummy ;
    108   1.1  christos tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
    109   1.1  christos case $CC_FOR_BUILD,$HOST_CC,$CC in
    110   1.1  christos  ,,)    echo "int x;" > $dummy.c ;
    111   1.1  christos 	for c in cc gcc c89 c99 ; do
    112   1.1  christos 	  if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
    113   1.1  christos 	     CC_FOR_BUILD="$c"; break ;
    114   1.1  christos 	  fi ;
    115   1.1  christos 	done ;
    116   1.1  christos 	if test x"$CC_FOR_BUILD" = x ; then
    117   1.1  christos 	  CC_FOR_BUILD=no_compiler_found ;
    118   1.1  christos 	fi
    119   1.1  christos 	;;
    120   1.1  christos  ,,*)   CC_FOR_BUILD=$CC ;;
    121   1.1  christos  ,*,*)  CC_FOR_BUILD=$HOST_CC ;;
    122   1.1  christos esac ; set_cc_for_build= ;'
    123   1.1  christos 
    124   1.1  christos # This is needed to find uname on a Pyramid OSx when run in the BSD universe.
    125   1.1  christos # (ghazi (at] noc.rutgers.edu 1994-08-24)
    126   1.1  christos if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
    127   1.1  christos 	PATH=$PATH:/.attbin ; export PATH
    128   1.1  christos fi
    129   1.1  christos 
    130   1.1  christos UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
    131   1.1  christos UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
    132   1.1  christos UNAME_SYSTEM=`(uname -s) 2>/dev/null`  || UNAME_SYSTEM=unknown
    133   1.1  christos UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
    134   1.1  christos 
    135   1.4  christos case "${UNAME_SYSTEM}" in
    136   1.4  christos Linux|GNU|GNU/*)
    137   1.4  christos 	# If the system lacks a compiler, then just pick glibc.
    138   1.4  christos 	# We could probably try harder.
    139   1.4  christos 	LIBC=gnu
    140   1.4  christos 
    141   1.4  christos 	eval $set_cc_for_build
    142   1.4  christos 	cat <<-EOF > $dummy.c
    143   1.4  christos 	#include <features.h>
    144   1.4  christos 	#if defined(__UCLIBC__)
    145   1.4  christos 	LIBC=uclibc
    146   1.4  christos 	#elif defined(__dietlibc__)
    147   1.4  christos 	LIBC=dietlibc
    148   1.4  christos 	#else
    149   1.4  christos 	LIBC=gnu
    150   1.4  christos 	#endif
    151   1.4  christos 	EOF
    152   1.5  christos 	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`
    153   1.4  christos 	;;
    154   1.4  christos esac
    155   1.4  christos 
    156   1.1  christos # Note: order is significant - the case branches are not exclusive.
    157   1.1  christos 
    158   1.1  christos case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
    159   1.1  christos     *:NetBSD:*:*)
    160   1.1  christos 	# NetBSD (nbsd) targets should (where applicable) match one or
    161   1.3  christos 	# more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
    162   1.1  christos 	# *-*-netbsdecoff* and *-*-netbsd*.  For targets that recently
    163   1.1  christos 	# switched to ELF, *-*-netbsd* would select the old
    164   1.1  christos 	# object file format.  This provides both forward
    165   1.1  christos 	# compatibility and a consistent mechanism for selecting the
    166   1.1  christos 	# object file format.
    167   1.1  christos 	#
    168   1.1  christos 	# Note: NetBSD doesn't particularly care about the vendor
    169   1.1  christos 	# portion of the name.  We always set it to "unknown".
    170   1.1  christos 	sysctl="sysctl -n hw.machine_arch"
    171   1.6  christos 	UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
    172   1.6  christos 	    /sbin/$sysctl 2>/dev/null || \
    173   1.6  christos 	    /usr/sbin/$sysctl 2>/dev/null || \
    174   1.6  christos 	    echo unknown)`
    175   1.1  christos 	case "${UNAME_MACHINE_ARCH}" in
    176   1.1  christos 	    armeb) machine=armeb-unknown ;;
    177   1.1  christos 	    arm*) machine=arm-unknown ;;
    178   1.1  christos 	    sh3el) machine=shl-unknown ;;
    179   1.1  christos 	    sh3eb) machine=sh-unknown ;;
    180   1.1  christos 	    sh5el) machine=sh5le-unknown ;;
    181   1.6  christos 	    earmv*)
    182   1.6  christos 		arch=`echo ${UNAME_MACHINE_ARCH} | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
    183   1.6  christos 		endian=`echo ${UNAME_MACHINE_ARCH} | sed -ne 's,^.*\(eb\)$,\1,p'`
    184   1.6  christos 		machine=${arch}${endian}-unknown
    185   1.6  christos 		;;
    186   1.1  christos 	    *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
    187   1.1  christos 	esac
    188   1.1  christos 	# The Operating System including object format, if it has switched
    189   1.9     sevan 	# to ELF recently (or will in the future) and ABI.
    190   1.1  christos 	case "${UNAME_MACHINE_ARCH}" in
    191   1.2      matt 	    earm*)
    192   1.7     skrll 		os=netbsdelf
    193   1.2      matt 		;;
    194   1.1  christos 	    arm*|i386|m68k|ns32k|sh3*|sparc|vax)
    195   1.1  christos 		eval $set_cc_for_build
    196   1.1  christos 		if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
    197   1.1  christos 			| grep -q __ELF__
    198   1.1  christos 		then
    199   1.1  christos 		    # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
    200   1.1  christos 		    # Return netbsd for either.  FIX?
    201   1.1  christos 		    os=netbsd
    202   1.1  christos 		else
    203   1.1  christos 		    os=netbsdelf
    204   1.1  christos 		fi
    205   1.1  christos 		;;
    206   1.1  christos 	    *)
    207   1.1  christos 		os=netbsd
    208   1.1  christos 		;;
    209   1.1  christos 	esac
    210   1.6  christos 	# Determine ABI tags.
    211   1.6  christos 	case "${UNAME_MACHINE_ARCH}" in
    212   1.6  christos 	    earm*)
    213   1.9     sevan 		expr='s/^earmv[0-9]/-eabi/;s/eb$//'
    214   1.9     sevan 		abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"`
    215   1.6  christos 		;;
    216   1.6  christos 	esac
    217   1.1  christos 	# The OS release
    218   1.1  christos 	# Debian GNU/NetBSD machines have a different userland, and
    219   1.1  christos 	# thus, need a distinct triplet. However, they do not need
    220   1.1  christos 	# kernel version information, so it can be replaced with a
    221   1.1  christos 	# suitable tag, in the style of linux-gnu.
    222   1.1  christos 	case "${UNAME_VERSION}" in
    223   1.1  christos 	    Debian*)
    224   1.1  christos 		release='-gnu'
    225   1.1  christos 		;;
    226   1.1  christos 	    *)
    227   1.7     skrll 		release=`echo ${UNAME_RELEASE} | sed -e 's/[-_].*//' | cut -d. -f1,2`
    228   1.1  christos 		;;
    229   1.1  christos 	esac
    230   1.1  christos 	# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
    231   1.1  christos 	# contains redundant information, the shorter form:
    232   1.1  christos 	# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
    233   1.6  christos 	echo "${machine}-${os}${release}${abi}"
    234   1.1  christos 	exit ;;
    235   1.3  christos     *:Bitrig:*:*)
    236   1.3  christos 	UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
    237   1.3  christos 	echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE}
    238   1.3  christos 	exit ;;
    239   1.1  christos     *:OpenBSD:*:*)
    240   1.1  christos 	UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
    241   1.1  christos 	echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
    242   1.1  christos 	exit ;;
    243   1.7     skrll     *:LibertyBSD:*:*)
    244   1.7     skrll 	UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'`
    245   1.7     skrll 	echo ${UNAME_MACHINE_ARCH}-unknown-libertybsd${UNAME_RELEASE}
    246   1.7     skrll 	exit ;;
    247   1.1  christos     *:ekkoBSD:*:*)
    248   1.1  christos 	echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
    249   1.1  christos 	exit ;;
    250   1.1  christos     *:SolidBSD:*:*)
    251   1.1  christos 	echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
    252   1.1  christos 	exit ;;
    253   1.1  christos     macppc:MirBSD:*:*)
    254   1.1  christos 	echo powerpc-unknown-mirbsd${UNAME_RELEASE}
    255   1.1  christos 	exit ;;
    256   1.1  christos     *:MirBSD:*:*)
    257   1.1  christos 	echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
    258   1.1  christos 	exit ;;
    259   1.7     skrll     *:Sortix:*:*)
    260   1.7     skrll 	echo ${UNAME_MACHINE}-unknown-sortix
    261   1.7     skrll 	exit ;;
    262   1.1  christos     alpha:OSF1:*:*)
    263   1.1  christos 	case $UNAME_RELEASE in
    264   1.1  christos 	*4.0)
    265   1.1  christos 		UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
    266   1.1  christos 		;;
    267   1.1  christos 	*5.*)
    268   1.1  christos 		UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
    269   1.1  christos 		;;
    270   1.1  christos 	esac
    271   1.1  christos 	# According to Compaq, /usr/sbin/psrinfo has been available on
    272   1.1  christos 	# OSF/1 and Tru64 systems produced since 1995.  I hope that
    273   1.1  christos 	# covers most systems running today.  This code pipes the CPU
    274   1.1  christos 	# types through head -n 1, so we only detect the type of CPU 0.
    275   1.1  christos 	ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^  The alpha \(.*\) processor.*$/\1/p' | head -n 1`
    276   1.1  christos 	case "$ALPHA_CPU_TYPE" in
    277   1.1  christos 	    "EV4 (21064)")
    278   1.7     skrll 		UNAME_MACHINE=alpha ;;
    279   1.1  christos 	    "EV4.5 (21064)")
    280   1.7     skrll 		UNAME_MACHINE=alpha ;;
    281   1.1  christos 	    "LCA4 (21066/21068)")
    282   1.7     skrll 		UNAME_MACHINE=alpha ;;
    283   1.1  christos 	    "EV5 (21164)")
    284   1.7     skrll 		UNAME_MACHINE=alphaev5 ;;
    285   1.1  christos 	    "EV5.6 (21164A)")
    286   1.7     skrll 		UNAME_MACHINE=alphaev56 ;;
    287   1.1  christos 	    "EV5.6 (21164PC)")
    288   1.7     skrll 		UNAME_MACHINE=alphapca56 ;;
    289   1.1  christos 	    "EV5.7 (21164PC)")
    290   1.7     skrll 		UNAME_MACHINE=alphapca57 ;;
    291   1.1  christos 	    "EV6 (21264)")
    292   1.7     skrll 		UNAME_MACHINE=alphaev6 ;;
    293   1.1  christos 	    "EV6.7 (21264A)")
    294   1.7     skrll 		UNAME_MACHINE=alphaev67 ;;
    295   1.1  christos 	    "EV6.8CB (21264C)")
    296   1.7     skrll 		UNAME_MACHINE=alphaev68 ;;
    297   1.1  christos 	    "EV6.8AL (21264B)")
    298   1.7     skrll 		UNAME_MACHINE=alphaev68 ;;
    299   1.1  christos 	    "EV6.8CX (21264D)")
    300   1.7     skrll 		UNAME_MACHINE=alphaev68 ;;
    301   1.1  christos 	    "EV6.9A (21264/EV69A)")
    302   1.7     skrll 		UNAME_MACHINE=alphaev69 ;;
    303   1.1  christos 	    "EV7 (21364)")
    304   1.7     skrll 		UNAME_MACHINE=alphaev7 ;;
    305   1.1  christos 	    "EV7.9 (21364A)")
    306   1.7     skrll 		UNAME_MACHINE=alphaev79 ;;
    307   1.1  christos 	esac
    308   1.1  christos 	# A Pn.n version is a patched version.
    309   1.1  christos 	# A Vn.n version is a released version.
    310   1.1  christos 	# A Tn.n version is a released field test version.
    311   1.1  christos 	# A Xn.n version is an unreleased experimental baselevel.
    312   1.1  christos 	# 1.2 uses "1.2" for uname -r.
    313   1.7     skrll 	echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
    314   1.1  christos 	# Reset EXIT trap before exiting to avoid spurious non-zero exit code.
    315   1.1  christos 	exitcode=$?
    316   1.1  christos 	trap '' 0
    317   1.1  christos 	exit $exitcode ;;
    318   1.1  christos     Alpha\ *:Windows_NT*:*)
    319   1.1  christos 	# How do we know it's Interix rather than the generic POSIX subsystem?
    320   1.1  christos 	# Should we change UNAME_MACHINE based on the output of uname instead
    321   1.1  christos 	# of the specific Alpha model?
    322   1.1  christos 	echo alpha-pc-interix
    323   1.1  christos 	exit ;;
    324   1.1  christos     21064:Windows_NT:50:3)
    325   1.1  christos 	echo alpha-dec-winnt3.5
    326   1.1  christos 	exit ;;
    327   1.1  christos     Amiga*:UNIX_System_V:4.0:*)
    328   1.1  christos 	echo m68k-unknown-sysv4
    329   1.1  christos 	exit ;;
    330   1.1  christos     *:[Aa]miga[Oo][Ss]:*:*)
    331   1.1  christos 	echo ${UNAME_MACHINE}-unknown-amigaos
    332   1.1  christos 	exit ;;
    333   1.1  christos     *:[Mm]orph[Oo][Ss]:*:*)
    334   1.1  christos 	echo ${UNAME_MACHINE}-unknown-morphos
    335   1.1  christos 	exit ;;
    336   1.1  christos     *:OS/390:*:*)
    337   1.1  christos 	echo i370-ibm-openedition
    338   1.1  christos 	exit ;;
    339   1.1  christos     *:z/VM:*:*)
    340   1.1  christos 	echo s390-ibm-zvmoe
    341   1.1  christos 	exit ;;
    342   1.1  christos     *:OS400:*:*)
    343   1.1  christos 	echo powerpc-ibm-os400
    344   1.1  christos 	exit ;;
    345   1.1  christos     arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
    346   1.1  christos 	echo arm-acorn-riscix${UNAME_RELEASE}
    347   1.1  christos 	exit ;;
    348   1.3  christos     arm*:riscos:*:*|arm*:RISCOS:*:*)
    349   1.1  christos 	echo arm-unknown-riscos
    350   1.1  christos 	exit ;;
    351   1.1  christos     SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
    352   1.1  christos 	echo hppa1.1-hitachi-hiuxmpp
    353   1.1  christos 	exit ;;
    354   1.1  christos     Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
    355   1.1  christos 	# akee (at] wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
    356   1.1  christos 	if test "`(/bin/universe) 2>/dev/null`" = att ; then
    357   1.1  christos 		echo pyramid-pyramid-sysv3
    358   1.1  christos 	else
    359   1.1  christos 		echo pyramid-pyramid-bsd
    360   1.1  christos 	fi
    361   1.1  christos 	exit ;;
    362   1.1  christos     NILE*:*:*:dcosx)
    363   1.1  christos 	echo pyramid-pyramid-svr4
    364   1.1  christos 	exit ;;
    365   1.1  christos     DRS?6000:unix:4.0:6*)
    366   1.1  christos 	echo sparc-icl-nx6
    367   1.1  christos 	exit ;;
    368   1.1  christos     DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
    369   1.1  christos 	case `/usr/bin/uname -p` in
    370   1.1  christos 	    sparc) echo sparc-icl-nx7; exit ;;
    371   1.1  christos 	esac ;;
    372   1.1  christos     s390x:SunOS:*:*)
    373   1.1  christos 	echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
    374   1.1  christos 	exit ;;
    375   1.1  christos     sun4H:SunOS:5.*:*)
    376   1.1  christos 	echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
    377   1.1  christos 	exit ;;
    378   1.1  christos     sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
    379   1.1  christos 	echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
    380   1.1  christos 	exit ;;
    381   1.1  christos     i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
    382   1.1  christos 	echo i386-pc-auroraux${UNAME_RELEASE}
    383   1.1  christos 	exit ;;
    384   1.1  christos     i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
    385   1.1  christos 	eval $set_cc_for_build
    386   1.7     skrll 	SUN_ARCH=i386
    387   1.1  christos 	# If there is a compiler, see if it is configured for 64-bit objects.
    388   1.1  christos 	# Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
    389   1.1  christos 	# This test works for both compilers.
    390   1.7     skrll 	if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
    391   1.1  christos 	    if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
    392   1.7     skrll 		(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
    393   1.1  christos 		grep IS_64BIT_ARCH >/dev/null
    394   1.1  christos 	    then
    395   1.7     skrll 		SUN_ARCH=x86_64
    396   1.1  christos 	    fi
    397   1.1  christos 	fi
    398   1.1  christos 	echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
    399   1.1  christos 	exit ;;
    400   1.1  christos     sun4*:SunOS:6*:*)
    401   1.1  christos 	# According to config.sub, this is the proper way to canonicalize
    402   1.1  christos 	# SunOS6.  Hard to guess exactly what SunOS6 will be like, but
    403   1.1  christos 	# it's likely to be more like Solaris than SunOS4.
    404   1.1  christos 	echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
    405   1.1  christos 	exit ;;
    406   1.1  christos     sun4*:SunOS:*:*)
    407   1.1  christos 	case "`/usr/bin/arch -k`" in
    408   1.1  christos 	    Series*|S4*)
    409   1.1  christos 		UNAME_RELEASE=`uname -v`
    410   1.1  christos 		;;
    411   1.1  christos 	esac
    412   1.1  christos 	# Japanese Language versions have a version number like `4.1.3-JL'.
    413   1.1  christos 	echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
    414   1.1  christos 	exit ;;
    415   1.1  christos     sun3*:SunOS:*:*)
    416   1.1  christos 	echo m68k-sun-sunos${UNAME_RELEASE}
    417   1.1  christos 	exit ;;
    418   1.1  christos     sun*:*:4.2BSD:*)
    419   1.1  christos 	UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
    420   1.7     skrll 	test "x${UNAME_RELEASE}" = x && UNAME_RELEASE=3
    421   1.1  christos 	case "`/bin/arch`" in
    422   1.1  christos 	    sun3)
    423   1.1  christos 		echo m68k-sun-sunos${UNAME_RELEASE}
    424   1.1  christos 		;;
    425   1.1  christos 	    sun4)
    426   1.1  christos 		echo sparc-sun-sunos${UNAME_RELEASE}
    427   1.1  christos 		;;
    428   1.1  christos 	esac
    429   1.1  christos 	exit ;;
    430   1.1  christos     aushp:SunOS:*:*)
    431   1.1  christos 	echo sparc-auspex-sunos${UNAME_RELEASE}
    432   1.1  christos 	exit ;;
    433   1.1  christos     # The situation for MiNT is a little confusing.  The machine name
    434   1.1  christos     # can be virtually everything (everything which is not
    435   1.1  christos     # "atarist" or "atariste" at least should have a processor
    436   1.1  christos     # > m68000).  The system name ranges from "MiNT" over "FreeMiNT"
    437   1.1  christos     # to the lowercase version "mint" (or "freemint").  Finally
    438   1.1  christos     # the system name "TOS" denotes a system which is actually not
    439   1.1  christos     # MiNT.  But MiNT is downward compatible to TOS, so this should
    440   1.1  christos     # be no problem.
    441   1.1  christos     atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
    442   1.1  christos 	echo m68k-atari-mint${UNAME_RELEASE}
    443   1.1  christos 	exit ;;
    444   1.1  christos     atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
    445   1.1  christos 	echo m68k-atari-mint${UNAME_RELEASE}
    446   1.1  christos 	exit ;;
    447   1.1  christos     *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
    448   1.1  christos 	echo m68k-atari-mint${UNAME_RELEASE}
    449   1.1  christos 	exit ;;
    450   1.1  christos     milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
    451   1.1  christos 	echo m68k-milan-mint${UNAME_RELEASE}
    452   1.1  christos 	exit ;;
    453   1.1  christos     hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
    454   1.1  christos 	echo m68k-hades-mint${UNAME_RELEASE}
    455   1.1  christos 	exit ;;
    456   1.1  christos     *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
    457   1.1  christos 	echo m68k-unknown-mint${UNAME_RELEASE}
    458   1.1  christos 	exit ;;
    459   1.1  christos     m68k:machten:*:*)
    460   1.1  christos 	echo m68k-apple-machten${UNAME_RELEASE}
    461   1.1  christos 	exit ;;
    462   1.1  christos     powerpc:machten:*:*)
    463   1.1  christos 	echo powerpc-apple-machten${UNAME_RELEASE}
    464   1.1  christos 	exit ;;
    465   1.1  christos     RISC*:Mach:*:*)
    466   1.1  christos 	echo mips-dec-mach_bsd4.3
    467   1.1  christos 	exit ;;
    468   1.1  christos     RISC*:ULTRIX:*:*)
    469   1.1  christos 	echo mips-dec-ultrix${UNAME_RELEASE}
    470   1.1  christos 	exit ;;
    471   1.1  christos     VAX*:ULTRIX*:*:*)
    472   1.1  christos 	echo vax-dec-ultrix${UNAME_RELEASE}
    473   1.1  christos 	exit ;;
    474   1.1  christos     2020:CLIX:*:* | 2430:CLIX:*:*)
    475   1.1  christos 	echo clipper-intergraph-clix${UNAME_RELEASE}
    476   1.1  christos 	exit ;;
    477   1.1  christos     mips:*:*:UMIPS | mips:*:*:RISCos)
    478   1.1  christos 	eval $set_cc_for_build
    479   1.1  christos 	sed 's/^	//' << EOF >$dummy.c
    480   1.1  christos #ifdef __cplusplus
    481   1.1  christos #include <stdio.h>  /* for printf() prototype */
    482   1.1  christos 	int main (int argc, char *argv[]) {
    483   1.1  christos #else
    484   1.1  christos 	int main (argc, argv) int argc; char *argv[]; {
    485   1.1  christos #endif
    486   1.1  christos 	#if defined (host_mips) && defined (MIPSEB)
    487   1.1  christos 	#if defined (SYSTYPE_SYSV)
    488   1.1  christos 	  printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
    489   1.1  christos 	#endif
    490   1.1  christos 	#if defined (SYSTYPE_SVR4)
    491   1.1  christos 	  printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0);
    492   1.1  christos 	#endif
    493   1.1  christos 	#if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
    494   1.1  christos 	  printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0);
    495   1.1  christos 	#endif
    496   1.1  christos 	#endif
    497   1.1  christos 	  exit (-1);
    498   1.1  christos 	}
    499   1.1  christos EOF
    500   1.1  christos 	$CC_FOR_BUILD -o $dummy $dummy.c &&
    501   1.1  christos 	  dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
    502   1.1  christos 	  SYSTEM_NAME=`$dummy $dummyarg` &&
    503   1.1  christos 	    { echo "$SYSTEM_NAME"; exit; }
    504   1.1  christos 	echo mips-mips-riscos${UNAME_RELEASE}
    505   1.1  christos 	exit ;;
    506   1.1  christos     Motorola:PowerMAX_OS:*:*)
    507   1.1  christos 	echo powerpc-motorola-powermax
    508   1.1  christos 	exit ;;
    509   1.1  christos     Motorola:*:4.3:PL8-*)
    510   1.1  christos 	echo powerpc-harris-powermax
    511   1.1  christos 	exit ;;
    512   1.1  christos     Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
    513   1.1  christos 	echo powerpc-harris-powermax
    514   1.1  christos 	exit ;;
    515   1.1  christos     Night_Hawk:Power_UNIX:*:*)
    516   1.1  christos 	echo powerpc-harris-powerunix
    517   1.1  christos 	exit ;;
    518   1.1  christos     m88k:CX/UX:7*:*)
    519   1.1  christos 	echo m88k-harris-cxux7
    520   1.1  christos 	exit ;;
    521   1.1  christos     m88k:*:4*:R4*)
    522   1.1  christos 	echo m88k-motorola-sysv4
    523   1.1  christos 	exit ;;
    524   1.1  christos     m88k:*:3*:R3*)
    525   1.1  christos 	echo m88k-motorola-sysv3
    526   1.1  christos 	exit ;;
    527   1.1  christos     AViiON:dgux:*:*)
    528   1.1  christos 	# DG/UX returns AViiON for all architectures
    529   1.1  christos 	UNAME_PROCESSOR=`/usr/bin/uname -p`
    530   1.1  christos 	if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
    531   1.1  christos 	then
    532   1.1  christos 	    if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
    533   1.1  christos 	       [ ${TARGET_BINARY_INTERFACE}x = x ]
    534   1.1  christos 	    then
    535   1.1  christos 		echo m88k-dg-dgux${UNAME_RELEASE}
    536   1.1  christos 	    else
    537   1.1  christos 		echo m88k-dg-dguxbcs${UNAME_RELEASE}
    538   1.1  christos 	    fi
    539   1.1  christos 	else
    540   1.1  christos 	    echo i586-dg-dgux${UNAME_RELEASE}
    541   1.1  christos 	fi
    542   1.1  christos 	exit ;;
    543   1.1  christos     M88*:DolphinOS:*:*)	# DolphinOS (SVR3)
    544   1.1  christos 	echo m88k-dolphin-sysv3
    545   1.1  christos 	exit ;;
    546   1.1  christos     M88*:*:R3*:*)
    547   1.1  christos 	# Delta 88k system running SVR3
    548   1.1  christos 	echo m88k-motorola-sysv3
    549   1.1  christos 	exit ;;
    550   1.1  christos     XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
    551   1.1  christos 	echo m88k-tektronix-sysv3
    552   1.1  christos 	exit ;;
    553   1.1  christos     Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
    554   1.1  christos 	echo m68k-tektronix-bsd
    555   1.1  christos 	exit ;;
    556   1.1  christos     *:IRIX*:*:*)
    557   1.1  christos 	echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
    558   1.1  christos 	exit ;;
    559   1.1  christos     ????????:AIX?:[12].1:2)   # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
    560   1.1  christos 	echo romp-ibm-aix     # uname -m gives an 8 hex-code CPU id
    561   1.1  christos 	exit ;;               # Note that: echo "'`uname -s`'" gives 'AIX '
    562   1.1  christos     i*86:AIX:*:*)
    563   1.1  christos 	echo i386-ibm-aix
    564   1.1  christos 	exit ;;
    565   1.1  christos     ia64:AIX:*:*)
    566   1.1  christos 	if [ -x /usr/bin/oslevel ] ; then
    567   1.1  christos 		IBM_REV=`/usr/bin/oslevel`
    568   1.1  christos 	else
    569   1.1  christos 		IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
    570   1.1  christos 	fi
    571   1.1  christos 	echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
    572   1.1  christos 	exit ;;
    573   1.1  christos     *:AIX:2:3)
    574   1.1  christos 	if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
    575   1.1  christos 		eval $set_cc_for_build
    576   1.1  christos 		sed 's/^		//' << EOF >$dummy.c
    577   1.1  christos 		#include <sys/systemcfg.h>
    578   1.1  christos 
    579   1.1  christos 		main()
    580   1.1  christos 			{
    581   1.1  christos 			if (!__power_pc())
    582   1.1  christos 				exit(1);
    583   1.1  christos 			puts("powerpc-ibm-aix3.2.5");
    584   1.1  christos 			exit(0);
    585   1.1  christos 			}
    586   1.1  christos EOF
    587   1.1  christos 		if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
    588   1.1  christos 		then
    589   1.1  christos 			echo "$SYSTEM_NAME"
    590   1.1  christos 		else
    591   1.1  christos 			echo rs6000-ibm-aix3.2.5
    592   1.1  christos 		fi
    593   1.1  christos 	elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
    594   1.1  christos 		echo rs6000-ibm-aix3.2.4
    595   1.1  christos 	else
    596   1.1  christos 		echo rs6000-ibm-aix3.2
    597   1.1  christos 	fi
    598   1.1  christos 	exit ;;
    599   1.1  christos     *:AIX:*:[4567])
    600   1.1  christos 	IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
    601   1.1  christos 	if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
    602   1.1  christos 		IBM_ARCH=rs6000
    603   1.1  christos 	else
    604   1.1  christos 		IBM_ARCH=powerpc
    605   1.1  christos 	fi
    606   1.5  christos 	if [ -x /usr/bin/lslpp ] ; then
    607   1.5  christos 		IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
    608   1.5  christos 			   awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
    609   1.1  christos 	else
    610   1.1  christos 		IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
    611   1.1  christos 	fi
    612   1.1  christos 	echo ${IBM_ARCH}-ibm-aix${IBM_REV}
    613   1.1  christos 	exit ;;
    614   1.1  christos     *:AIX:*:*)
    615   1.1  christos 	echo rs6000-ibm-aix
    616   1.1  christos 	exit ;;
    617   1.1  christos     ibmrt:4.4BSD:*|romp-ibm:BSD:*)
    618   1.1  christos 	echo romp-ibm-bsd4.4
    619   1.1  christos 	exit ;;
    620   1.1  christos     ibmrt:*BSD:*|romp-ibm:BSD:*)            # covers RT/PC BSD and
    621   1.1  christos 	echo romp-ibm-bsd${UNAME_RELEASE}   # 4.3 with uname added to
    622   1.1  christos 	exit ;;                             # report: romp-ibm BSD 4.3
    623   1.1  christos     *:BOSX:*:*)
    624   1.1  christos 	echo rs6000-bull-bosx
    625   1.1  christos 	exit ;;
    626   1.1  christos     DPX/2?00:B.O.S.:*:*)
    627   1.1  christos 	echo m68k-bull-sysv3
    628   1.1  christos 	exit ;;
    629   1.1  christos     9000/[34]??:4.3bsd:1.*:*)
    630   1.1  christos 	echo m68k-hp-bsd
    631   1.1  christos 	exit ;;
    632   1.1  christos     hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
    633   1.1  christos 	echo m68k-hp-bsd4.4
    634   1.1  christos 	exit ;;
    635   1.1  christos     9000/[34678]??:HP-UX:*:*)
    636   1.1  christos 	HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
    637   1.1  christos 	case "${UNAME_MACHINE}" in
    638   1.1  christos 	    9000/31? )            HP_ARCH=m68000 ;;
    639   1.1  christos 	    9000/[34]?? )         HP_ARCH=m68k ;;
    640   1.1  christos 	    9000/[678][0-9][0-9])
    641   1.1  christos 		if [ -x /usr/bin/getconf ]; then
    642   1.1  christos 		    sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
    643   1.1  christos 		    sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
    644   1.1  christos 		    case "${sc_cpu_version}" in
    645   1.7     skrll 		      523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0
    646   1.7     skrll 		      528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1
    647   1.1  christos 		      532)                      # CPU_PA_RISC2_0
    648   1.1  christos 			case "${sc_kernel_bits}" in
    649   1.7     skrll 			  32) HP_ARCH=hppa2.0n ;;
    650   1.7     skrll 			  64) HP_ARCH=hppa2.0w ;;
    651   1.7     skrll 			  '') HP_ARCH=hppa2.0 ;;   # HP-UX 10.20
    652   1.1  christos 			esac ;;
    653   1.1  christos 		    esac
    654   1.1  christos 		fi
    655   1.1  christos 		if [ "${HP_ARCH}" = "" ]; then
    656   1.1  christos 		    eval $set_cc_for_build
    657   1.1  christos 		    sed 's/^		//' << EOF >$dummy.c
    658   1.1  christos 
    659   1.1  christos 		#define _HPUX_SOURCE
    660   1.1  christos 		#include <stdlib.h>
    661   1.1  christos 		#include <unistd.h>
    662   1.1  christos 
    663   1.1  christos 		int main ()
    664   1.1  christos 		{
    665   1.1  christos 		#if defined(_SC_KERNEL_BITS)
    666   1.1  christos 		    long bits = sysconf(_SC_KERNEL_BITS);
    667   1.1  christos 		#endif
    668   1.1  christos 		    long cpu  = sysconf (_SC_CPU_VERSION);
    669   1.1  christos 
    670   1.1  christos 		    switch (cpu)
    671   1.1  christos 			{
    672   1.1  christos 			case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
    673   1.1  christos 			case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
    674   1.1  christos 			case CPU_PA_RISC2_0:
    675   1.1  christos 		#if defined(_SC_KERNEL_BITS)
    676   1.1  christos 			    switch (bits)
    677   1.1  christos 				{
    678   1.1  christos 				case 64: puts ("hppa2.0w"); break;
    679   1.1  christos 				case 32: puts ("hppa2.0n"); break;
    680   1.1  christos 				default: puts ("hppa2.0"); break;
    681   1.1  christos 				} break;
    682   1.1  christos 		#else  /* !defined(_SC_KERNEL_BITS) */
    683   1.1  christos 			    puts ("hppa2.0"); break;
    684   1.1  christos 		#endif
    685   1.1  christos 			default: puts ("hppa1.0"); break;
    686   1.1  christos 			}
    687   1.1  christos 		    exit (0);
    688   1.1  christos 		}
    689   1.1  christos EOF
    690   1.7     skrll 		    (CCOPTS="" $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
    691   1.1  christos 		    test -z "$HP_ARCH" && HP_ARCH=hppa
    692   1.1  christos 		fi ;;
    693   1.1  christos 	esac
    694   1.7     skrll 	if [ ${HP_ARCH} = hppa2.0w ]
    695   1.1  christos 	then
    696   1.1  christos 	    eval $set_cc_for_build
    697   1.1  christos 
    698   1.1  christos 	    # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
    699   1.1  christos 	    # 32-bit code.  hppa64-hp-hpux* has the same kernel and a compiler
    700   1.1  christos 	    # generating 64-bit code.  GNU and HP use different nomenclature:
    701   1.1  christos 	    #
    702   1.1  christos 	    # $ CC_FOR_BUILD=cc ./config.guess
    703   1.1  christos 	    # => hppa2.0w-hp-hpux11.23
    704   1.1  christos 	    # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
    705   1.1  christos 	    # => hppa64-hp-hpux11.23
    706   1.1  christos 
    707   1.7     skrll 	    if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) |
    708   1.1  christos 		grep -q __LP64__
    709   1.1  christos 	    then
    710   1.7     skrll 		HP_ARCH=hppa2.0w
    711   1.1  christos 	    else
    712   1.7     skrll 		HP_ARCH=hppa64
    713   1.1  christos 	    fi
    714   1.1  christos 	fi
    715   1.1  christos 	echo ${HP_ARCH}-hp-hpux${HPUX_REV}
    716   1.1  christos 	exit ;;
    717   1.1  christos     ia64:HP-UX:*:*)
    718   1.1  christos 	HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
    719   1.1  christos 	echo ia64-hp-hpux${HPUX_REV}
    720   1.1  christos 	exit ;;
    721   1.1  christos     3050*:HI-UX:*:*)
    722   1.1  christos 	eval $set_cc_for_build
    723   1.1  christos 	sed 's/^	//' << EOF >$dummy.c
    724   1.1  christos 	#include <unistd.h>
    725   1.1  christos 	int
    726   1.1  christos 	main ()
    727   1.1  christos 	{
    728   1.1  christos 	  long cpu = sysconf (_SC_CPU_VERSION);
    729   1.1  christos 	  /* The order matters, because CPU_IS_HP_MC68K erroneously returns
    730   1.1  christos 	     true for CPU_PA_RISC1_0.  CPU_IS_PA_RISC returns correct
    731   1.1  christos 	     results, however.  */
    732   1.1  christos 	  if (CPU_IS_PA_RISC (cpu))
    733   1.1  christos 	    {
    734   1.1  christos 	      switch (cpu)
    735   1.1  christos 		{
    736   1.1  christos 		  case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
    737   1.1  christos 		  case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
    738   1.1  christos 		  case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
    739   1.1  christos 		  default: puts ("hppa-hitachi-hiuxwe2"); break;
    740   1.1  christos 		}
    741   1.1  christos 	    }
    742   1.1  christos 	  else if (CPU_IS_HP_MC68K (cpu))
    743   1.1  christos 	    puts ("m68k-hitachi-hiuxwe2");
    744   1.1  christos 	  else puts ("unknown-hitachi-hiuxwe2");
    745   1.1  christos 	  exit (0);
    746   1.1  christos 	}
    747   1.1  christos EOF
    748   1.1  christos 	$CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
    749   1.1  christos 		{ echo "$SYSTEM_NAME"; exit; }
    750   1.1  christos 	echo unknown-hitachi-hiuxwe2
    751   1.1  christos 	exit ;;
    752   1.1  christos     9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
    753   1.1  christos 	echo hppa1.1-hp-bsd
    754   1.1  christos 	exit ;;
    755   1.1  christos     9000/8??:4.3bsd:*:*)
    756   1.1  christos 	echo hppa1.0-hp-bsd
    757   1.1  christos 	exit ;;
    758   1.1  christos     *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
    759   1.1  christos 	echo hppa1.0-hp-mpeix
    760   1.1  christos 	exit ;;
    761   1.1  christos     hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
    762   1.1  christos 	echo hppa1.1-hp-osf
    763   1.1  christos 	exit ;;
    764   1.1  christos     hp8??:OSF1:*:*)
    765   1.1  christos 	echo hppa1.0-hp-osf
    766   1.1  christos 	exit ;;
    767   1.1  christos     i*86:OSF1:*:*)
    768   1.1  christos 	if [ -x /usr/sbin/sysversion ] ; then
    769   1.1  christos 	    echo ${UNAME_MACHINE}-unknown-osf1mk
    770   1.1  christos 	else
    771   1.1  christos 	    echo ${UNAME_MACHINE}-unknown-osf1
    772   1.1  christos 	fi
    773   1.1  christos 	exit ;;
    774   1.1  christos     parisc*:Lites*:*:*)
    775   1.1  christos 	echo hppa1.1-hp-lites
    776   1.1  christos 	exit ;;
    777   1.1  christos     C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
    778   1.1  christos 	echo c1-convex-bsd
    779   1.1  christos 	exit ;;
    780   1.1  christos     C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
    781   1.1  christos 	if getsysinfo -f scalar_acc
    782   1.1  christos 	then echo c32-convex-bsd
    783   1.1  christos 	else echo c2-convex-bsd
    784   1.1  christos 	fi
    785   1.1  christos 	exit ;;
    786   1.1  christos     C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
    787   1.1  christos 	echo c34-convex-bsd
    788   1.1  christos 	exit ;;
    789   1.1  christos     C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
    790   1.1  christos 	echo c38-convex-bsd
    791   1.1  christos 	exit ;;
    792   1.1  christos     C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
    793   1.1  christos 	echo c4-convex-bsd
    794   1.1  christos 	exit ;;
    795   1.1  christos     CRAY*Y-MP:*:*:*)
    796   1.1  christos 	echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
    797   1.1  christos 	exit ;;
    798   1.1  christos     CRAY*[A-Z]90:*:*:*)
    799   1.1  christos 	echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
    800   1.1  christos 	| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
    801   1.1  christos 	      -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
    802   1.1  christos 	      -e 's/\.[^.]*$/.X/'
    803   1.1  christos 	exit ;;
    804   1.1  christos     CRAY*TS:*:*:*)
    805   1.1  christos 	echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
    806   1.1  christos 	exit ;;
    807   1.1  christos     CRAY*T3E:*:*:*)
    808   1.1  christos 	echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
    809   1.1  christos 	exit ;;
    810   1.1  christos     CRAY*SV1:*:*:*)
    811   1.1  christos 	echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
    812   1.1  christos 	exit ;;
    813   1.1  christos     *:UNICOS/mp:*:*)
    814   1.1  christos 	echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
    815   1.1  christos 	exit ;;
    816   1.1  christos     F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
    817   1.7     skrll 	FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
    818   1.7     skrll 	FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
    819   1.1  christos 	FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
    820   1.1  christos 	echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
    821   1.1  christos 	exit ;;
    822   1.1  christos     5000:UNIX_System_V:4.*:*)
    823   1.7     skrll 	FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
    824   1.7     skrll 	FUJITSU_REL=`echo ${UNAME_RELEASE} | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'`
    825   1.1  christos 	echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
    826   1.1  christos 	exit ;;
    827   1.1  christos     i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
    828   1.1  christos 	echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
    829   1.1  christos 	exit ;;
    830   1.1  christos     sparc*:BSD/OS:*:*)
    831   1.1  christos 	echo sparc-unknown-bsdi${UNAME_RELEASE}
    832   1.1  christos 	exit ;;
    833   1.1  christos     *:BSD/OS:*:*)
    834   1.1  christos 	echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
    835   1.1  christos 	exit ;;
    836   1.1  christos     *:FreeBSD:*:*)
    837   1.3  christos 	UNAME_PROCESSOR=`/usr/bin/uname -p`
    838   1.3  christos 	case ${UNAME_PROCESSOR} in
    839   1.1  christos 	    amd64)
    840  1.10  christos 				UNAME_PROCESSOR=x86_64 ;;
    841  1.10  christos 	    i386)
    842  1.10  christos 		UNAME_PROCESSOR=i586 ;;
    843   1.1  christos 	esac
    844  1.10  christos 	echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
    845   1.1  christos 	exit ;;
    846   1.1  christos     i*:CYGWIN*:*)
    847   1.1  christos 	echo ${UNAME_MACHINE}-pc-cygwin
    848   1.1  christos 	exit ;;
    849   1.3  christos     *:MINGW64*:*)
    850   1.3  christos 	echo ${UNAME_MACHINE}-pc-mingw64
    851   1.3  christos 	exit ;;
    852   1.1  christos     *:MINGW*:*)
    853   1.1  christos 	echo ${UNAME_MACHINE}-pc-mingw32
    854   1.1  christos 	exit ;;
    855   1.5  christos     *:MSYS*:*)
    856   1.3  christos 	echo ${UNAME_MACHINE}-pc-msys
    857   1.3  christos 	exit ;;
    858   1.1  christos     i*:windows32*:*)
    859   1.1  christos 	# uname -m includes "-pc" on this system.
    860   1.1  christos 	echo ${UNAME_MACHINE}-mingw32
    861   1.1  christos 	exit ;;
    862   1.1  christos     i*:PW*:*)
    863   1.1  christos 	echo ${UNAME_MACHINE}-pc-pw32
    864   1.1  christos 	exit ;;
    865   1.1  christos     *:Interix*:*)
    866   1.1  christos 	case ${UNAME_MACHINE} in
    867   1.1  christos 	    x86)
    868   1.1  christos 		echo i586-pc-interix${UNAME_RELEASE}
    869   1.1  christos 		exit ;;
    870   1.1  christos 	    authenticamd | genuineintel | EM64T)
    871   1.1  christos 		echo x86_64-unknown-interix${UNAME_RELEASE}
    872   1.1  christos 		exit ;;
    873   1.1  christos 	    IA64)
    874   1.1  christos 		echo ia64-unknown-interix${UNAME_RELEASE}
    875   1.1  christos 		exit ;;
    876   1.1  christos 	esac ;;
    877   1.1  christos     [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
    878   1.1  christos 	echo i${UNAME_MACHINE}-pc-mks
    879   1.1  christos 	exit ;;
    880   1.1  christos     8664:Windows_NT:*)
    881   1.1  christos 	echo x86_64-pc-mks
    882   1.1  christos 	exit ;;
    883   1.1  christos     i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
    884   1.1  christos 	# How do we know it's Interix rather than the generic POSIX subsystem?
    885   1.1  christos 	# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
    886   1.1  christos 	# UNAME_MACHINE based on the output of uname instead of i386?
    887   1.1  christos 	echo i586-pc-interix
    888   1.1  christos 	exit ;;
    889   1.1  christos     i*:UWIN*:*)
    890   1.1  christos 	echo ${UNAME_MACHINE}-pc-uwin
    891   1.1  christos 	exit ;;
    892   1.1  christos     amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
    893   1.1  christos 	echo x86_64-unknown-cygwin
    894   1.1  christos 	exit ;;
    895   1.1  christos     p*:CYGWIN*:*)
    896   1.1  christos 	echo powerpcle-unknown-cygwin
    897   1.1  christos 	exit ;;
    898   1.1  christos     prep*:SunOS:5.*:*)
    899   1.1  christos 	echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
    900   1.1  christos 	exit ;;
    901   1.1  christos     *:GNU:*:*)
    902   1.1  christos 	# the GNU system
    903   1.4  christos 	echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
    904   1.1  christos 	exit ;;
    905   1.1  christos     *:GNU/*:*:*)
    906   1.1  christos 	# other systems with GNU libc and userland
    907   1.7     skrll 	echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC}
    908   1.1  christos 	exit ;;
    909   1.1  christos     i*86:Minix:*:*)
    910   1.1  christos 	echo ${UNAME_MACHINE}-pc-minix
    911   1.1  christos 	exit ;;
    912   1.3  christos     aarch64:Linux:*:*)
    913   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    914   1.3  christos 	exit ;;
    915   1.3  christos     aarch64_be:Linux:*:*)
    916   1.3  christos 	UNAME_MACHINE=aarch64_be
    917   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    918   1.3  christos 	exit ;;
    919   1.1  christos     alpha:Linux:*:*)
    920   1.1  christos 	case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
    921   1.1  christos 	  EV5)   UNAME_MACHINE=alphaev5 ;;
    922   1.1  christos 	  EV56)  UNAME_MACHINE=alphaev56 ;;
    923   1.1  christos 	  PCA56) UNAME_MACHINE=alphapca56 ;;
    924   1.1  christos 	  PCA57) UNAME_MACHINE=alphapca56 ;;
    925   1.1  christos 	  EV6)   UNAME_MACHINE=alphaev6 ;;
    926   1.1  christos 	  EV67)  UNAME_MACHINE=alphaev67 ;;
    927   1.1  christos 	  EV68*) UNAME_MACHINE=alphaev68 ;;
    928   1.1  christos 	esac
    929   1.1  christos 	objdump --private-headers /bin/sh | grep -q ld.so.1
    930   1.7     skrll 	if test "$?" = 0 ; then LIBC=gnulibc1 ; fi
    931   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    932   1.4  christos 	exit ;;
    933   1.4  christos     arc:Linux:*:* | arceb:Linux:*:*)
    934   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    935   1.1  christos 	exit ;;
    936   1.1  christos     arm*:Linux:*:*)
    937   1.1  christos 	eval $set_cc_for_build
    938   1.1  christos 	if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
    939   1.1  christos 	    | grep -q __ARM_EABI__
    940   1.1  christos 	then
    941   1.4  christos 	    echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    942   1.1  christos 	else
    943   1.3  christos 	    if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
    944   1.3  christos 		| grep -q __ARM_PCS_VFP
    945   1.3  christos 	    then
    946   1.4  christos 		echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi
    947   1.3  christos 	    else
    948   1.4  christos 		echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf
    949   1.3  christos 	    fi
    950   1.1  christos 	fi
    951   1.1  christos 	exit ;;
    952   1.1  christos     avr32*:Linux:*:*)
    953   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    954   1.1  christos 	exit ;;
    955   1.1  christos     cris:Linux:*:*)
    956   1.4  christos 	echo ${UNAME_MACHINE}-axis-linux-${LIBC}
    957   1.1  christos 	exit ;;
    958   1.1  christos     crisv32:Linux:*:*)
    959   1.4  christos 	echo ${UNAME_MACHINE}-axis-linux-${LIBC}
    960   1.1  christos 	exit ;;
    961   1.6  christos     e2k:Linux:*:*)
    962   1.6  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    963   1.6  christos 	exit ;;
    964   1.1  christos     frv:Linux:*:*)
    965   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    966   1.3  christos 	exit ;;
    967   1.3  christos     hexagon:Linux:*:*)
    968   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    969   1.1  christos 	exit ;;
    970   1.1  christos     i*86:Linux:*:*)
    971   1.4  christos 	echo ${UNAME_MACHINE}-pc-linux-${LIBC}
    972   1.1  christos 	exit ;;
    973   1.1  christos     ia64:Linux:*:*)
    974   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    975   1.1  christos 	exit ;;
    976   1.7     skrll     k1om:Linux:*:*)
    977   1.7     skrll 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    978   1.7     skrll 	exit ;;
    979   1.1  christos     m32r*:Linux:*:*)
    980   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    981   1.1  christos 	exit ;;
    982   1.1  christos     m68*:Linux:*:*)
    983   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
    984   1.1  christos 	exit ;;
    985   1.1  christos     mips:Linux:*:* | mips64:Linux:*:*)
    986   1.1  christos 	eval $set_cc_for_build
    987   1.1  christos 	sed 's/^	//' << EOF >$dummy.c
    988   1.1  christos 	#undef CPU
    989   1.1  christos 	#undef ${UNAME_MACHINE}
    990   1.1  christos 	#undef ${UNAME_MACHINE}el
    991   1.1  christos 	#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
    992   1.1  christos 	CPU=${UNAME_MACHINE}el
    993   1.1  christos 	#else
    994   1.1  christos 	#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
    995   1.1  christos 	CPU=${UNAME_MACHINE}
    996   1.1  christos 	#else
    997   1.1  christos 	CPU=
    998   1.1  christos 	#endif
    999   1.1  christos 	#endif
   1000   1.1  christos EOF
   1001   1.1  christos 	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
   1002   1.4  christos 	test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; }
   1003   1.1  christos 	;;
   1004   1.9     sevan     mips64el:Linux:*:*)
   1005   1.9     sevan 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1006   1.9     sevan 	exit ;;
   1007   1.5  christos     openrisc*:Linux:*:*)
   1008   1.5  christos 	echo or1k-unknown-linux-${LIBC}
   1009   1.4  christos 	exit ;;
   1010   1.5  christos     or32:Linux:*:* | or1k*:Linux:*:*)
   1011   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1012   1.1  christos 	exit ;;
   1013   1.1  christos     padre:Linux:*:*)
   1014   1.4  christos 	echo sparc-unknown-linux-${LIBC}
   1015   1.1  christos 	exit ;;
   1016   1.1  christos     parisc64:Linux:*:* | hppa64:Linux:*:*)
   1017   1.4  christos 	echo hppa64-unknown-linux-${LIBC}
   1018   1.1  christos 	exit ;;
   1019   1.1  christos     parisc:Linux:*:* | hppa:Linux:*:*)
   1020   1.1  christos 	# Look for CPU level
   1021   1.1  christos 	case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
   1022   1.4  christos 	  PA7*) echo hppa1.1-unknown-linux-${LIBC} ;;
   1023   1.4  christos 	  PA8*) echo hppa2.0-unknown-linux-${LIBC} ;;
   1024   1.4  christos 	  *)    echo hppa-unknown-linux-${LIBC} ;;
   1025   1.1  christos 	esac
   1026   1.1  christos 	exit ;;
   1027   1.1  christos     ppc64:Linux:*:*)
   1028   1.4  christos 	echo powerpc64-unknown-linux-${LIBC}
   1029   1.1  christos 	exit ;;
   1030   1.1  christos     ppc:Linux:*:*)
   1031   1.4  christos 	echo powerpc-unknown-linux-${LIBC}
   1032   1.4  christos 	exit ;;
   1033   1.4  christos     ppc64le:Linux:*:*)
   1034   1.4  christos 	echo powerpc64le-unknown-linux-${LIBC}
   1035   1.4  christos 	exit ;;
   1036   1.4  christos     ppcle:Linux:*:*)
   1037   1.4  christos 	echo powerpcle-unknown-linux-${LIBC}
   1038   1.1  christos 	exit ;;
   1039   1.9     sevan     riscv32:Linux:*:* | riscv64:Linux:*:*)
   1040   1.9     sevan 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1041   1.9     sevan 	exit ;;
   1042   1.1  christos     s390:Linux:*:* | s390x:Linux:*:*)
   1043   1.4  christos 	echo ${UNAME_MACHINE}-ibm-linux-${LIBC}
   1044   1.1  christos 	exit ;;
   1045   1.1  christos     sh64*:Linux:*:*)
   1046   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1047   1.1  christos 	exit ;;
   1048   1.1  christos     sh*:Linux:*:*)
   1049   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1050   1.1  christos 	exit ;;
   1051   1.1  christos     sparc:Linux:*:* | sparc64:Linux:*:*)
   1052   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1053   1.1  christos 	exit ;;
   1054   1.1  christos     tile*:Linux:*:*)
   1055   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1056   1.1  christos 	exit ;;
   1057   1.1  christos     vax:Linux:*:*)
   1058   1.4  christos 	echo ${UNAME_MACHINE}-dec-linux-${LIBC}
   1059   1.1  christos 	exit ;;
   1060   1.1  christos     x86_64:Linux:*:*)
   1061   1.7     skrll 	echo ${UNAME_MACHINE}-pc-linux-${LIBC}
   1062   1.1  christos 	exit ;;
   1063   1.1  christos     xtensa*:Linux:*:*)
   1064   1.4  christos 	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
   1065   1.1  christos 	exit ;;
   1066   1.1  christos     i*86:DYNIX/ptx:4*:*)
   1067   1.1  christos 	# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
   1068   1.1  christos 	# earlier versions are messed up and put the nodename in both
   1069   1.1  christos 	# sysname and nodename.
   1070   1.1  christos 	echo i386-sequent-sysv4
   1071   1.1  christos 	exit ;;
   1072   1.1  christos     i*86:UNIX_SV:4.2MP:2.*)
   1073   1.1  christos 	# Unixware is an offshoot of SVR4, but it has its own version
   1074   1.1  christos 	# number series starting with 2...
   1075   1.1  christos 	# I am not positive that other SVR4 systems won't match this,
   1076   1.1  christos 	# I just have to hope.  -- rms.
   1077   1.1  christos 	# Use sysv4.2uw... so that sysv4* matches it.
   1078   1.1  christos 	echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
   1079   1.1  christos 	exit ;;
   1080   1.1  christos     i*86:OS/2:*:*)
   1081   1.1  christos 	# If we were able to find `uname', then EMX Unix compatibility
   1082   1.1  christos 	# is probably installed.
   1083   1.1  christos 	echo ${UNAME_MACHINE}-pc-os2-emx
   1084   1.1  christos 	exit ;;
   1085   1.1  christos     i*86:XTS-300:*:STOP)
   1086   1.1  christos 	echo ${UNAME_MACHINE}-unknown-stop
   1087   1.1  christos 	exit ;;
   1088   1.1  christos     i*86:atheos:*:*)
   1089   1.1  christos 	echo ${UNAME_MACHINE}-unknown-atheos
   1090   1.1  christos 	exit ;;
   1091   1.1  christos     i*86:syllable:*:*)
   1092   1.1  christos 	echo ${UNAME_MACHINE}-pc-syllable
   1093   1.1  christos 	exit ;;
   1094   1.1  christos     i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
   1095   1.1  christos 	echo i386-unknown-lynxos${UNAME_RELEASE}
   1096   1.1  christos 	exit ;;
   1097   1.1  christos     i*86:*DOS:*:*)
   1098   1.1  christos 	echo ${UNAME_MACHINE}-pc-msdosdjgpp
   1099   1.1  christos 	exit ;;
   1100   1.1  christos     i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
   1101   1.1  christos 	UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
   1102   1.1  christos 	if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
   1103   1.1  christos 		echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
   1104   1.1  christos 	else
   1105   1.1  christos 		echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
   1106   1.1  christos 	fi
   1107   1.1  christos 	exit ;;
   1108   1.1  christos     i*86:*:5:[678]*)
   1109   1.1  christos 	# UnixWare 7.x, OpenUNIX and OpenServer 6.
   1110   1.1  christos 	case `/bin/uname -X | grep "^Machine"` in
   1111   1.1  christos 	    *486*)	     UNAME_MACHINE=i486 ;;
   1112   1.1  christos 	    *Pentium)	     UNAME_MACHINE=i586 ;;
   1113   1.1  christos 	    *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
   1114   1.1  christos 	esac
   1115   1.1  christos 	echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
   1116   1.1  christos 	exit ;;
   1117   1.1  christos     i*86:*:3.2:*)
   1118   1.1  christos 	if test -f /usr/options/cb.name; then
   1119   1.1  christos 		UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
   1120   1.1  christos 		echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
   1121   1.1  christos 	elif /bin/uname -X 2>/dev/null >/dev/null ; then
   1122   1.1  christos 		UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
   1123   1.1  christos 		(/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
   1124   1.1  christos 		(/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
   1125   1.1  christos 			&& UNAME_MACHINE=i586
   1126   1.1  christos 		(/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
   1127   1.1  christos 			&& UNAME_MACHINE=i686
   1128   1.1  christos 		(/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
   1129   1.1  christos 			&& UNAME_MACHINE=i686
   1130   1.1  christos 		echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
   1131   1.1  christos 	else
   1132   1.1  christos 		echo ${UNAME_MACHINE}-pc-sysv32
   1133   1.1  christos 	fi
   1134   1.1  christos 	exit ;;
   1135   1.1  christos     pc:*:*:*)
   1136   1.1  christos 	# Left here for compatibility:
   1137   1.1  christos 	# uname -m prints for DJGPP always 'pc', but it prints nothing about
   1138   1.1  christos 	# the processor, so we play safe by assuming i586.
   1139   1.1  christos 	# Note: whatever this is, it MUST be the same as what config.sub
   1140   1.7     skrll 	# prints for the "djgpp" host, or else GDB configure will decide that
   1141   1.1  christos 	# this is a cross-build.
   1142   1.1  christos 	echo i586-pc-msdosdjgpp
   1143   1.1  christos 	exit ;;
   1144   1.1  christos     Intel:Mach:3*:*)
   1145   1.1  christos 	echo i386-pc-mach3
   1146   1.1  christos 	exit ;;
   1147   1.1  christos     paragon:*:*:*)
   1148   1.1  christos 	echo i860-intel-osf1
   1149   1.1  christos 	exit ;;
   1150   1.1  christos     i860:*:4.*:*) # i860-SVR4
   1151   1.1  christos 	if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
   1152   1.1  christos 	  echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
   1153   1.1  christos 	else # Add other i860-SVR4 vendors below as they are discovered.
   1154   1.1  christos 	  echo i860-unknown-sysv${UNAME_RELEASE}  # Unknown i860-SVR4
   1155   1.1  christos 	fi
   1156   1.1  christos 	exit ;;
   1157   1.1  christos     mini*:CTIX:SYS*5:*)
   1158   1.1  christos 	# "miniframe"
   1159   1.1  christos 	echo m68010-convergent-sysv
   1160   1.1  christos 	exit ;;
   1161   1.1  christos     mc68k:UNIX:SYSTEM5:3.51m)
   1162   1.1  christos 	echo m68k-convergent-sysv
   1163   1.1  christos 	exit ;;
   1164   1.1  christos     M680?0:D-NIX:5.3:*)
   1165   1.1  christos 	echo m68k-diab-dnix
   1166   1.1  christos 	exit ;;
   1167   1.1  christos     M68*:*:R3V[5678]*:*)
   1168   1.1  christos 	test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
   1169   1.1  christos     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)
   1170   1.1  christos 	OS_REL=''
   1171   1.1  christos 	test -r /etc/.relid \
   1172   1.1  christos 	&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
   1173   1.1  christos 	/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
   1174   1.1  christos 	  && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
   1175   1.1  christos 	/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
   1176   1.1  christos 	  && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
   1177   1.1  christos     3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
   1178   1.1  christos 	/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
   1179   1.1  christos 	  && { echo i486-ncr-sysv4; exit; } ;;
   1180   1.1  christos     NCR*:*:4.2:* | MPRAS*:*:4.2:*)
   1181   1.1  christos 	OS_REL='.3'
   1182   1.1  christos 	test -r /etc/.relid \
   1183   1.1  christos 	    && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
   1184   1.1  christos 	/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
   1185   1.1  christos 	    && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
   1186   1.1  christos 	/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
   1187   1.1  christos 	    && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
   1188   1.1  christos 	/bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
   1189   1.1  christos 	    && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
   1190   1.1  christos     m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
   1191   1.1  christos 	echo m68k-unknown-lynxos${UNAME_RELEASE}
   1192   1.1  christos 	exit ;;
   1193   1.1  christos     mc68030:UNIX_System_V:4.*:*)
   1194   1.1  christos 	echo m68k-atari-sysv4
   1195   1.1  christos 	exit ;;
   1196   1.1  christos     TSUNAMI:LynxOS:2.*:*)
   1197   1.1  christos 	echo sparc-unknown-lynxos${UNAME_RELEASE}
   1198   1.1  christos 	exit ;;
   1199   1.1  christos     rs6000:LynxOS:2.*:*)
   1200   1.1  christos 	echo rs6000-unknown-lynxos${UNAME_RELEASE}
   1201   1.1  christos 	exit ;;
   1202   1.1  christos     PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
   1203   1.1  christos 	echo powerpc-unknown-lynxos${UNAME_RELEASE}
   1204   1.1  christos 	exit ;;
   1205   1.1  christos     SM[BE]S:UNIX_SV:*:*)
   1206   1.1  christos 	echo mips-dde-sysv${UNAME_RELEASE}
   1207   1.1  christos 	exit ;;
   1208   1.1  christos     RM*:ReliantUNIX-*:*:*)
   1209   1.1  christos 	echo mips-sni-sysv4
   1210   1.1  christos 	exit ;;
   1211   1.1  christos     RM*:SINIX-*:*:*)
   1212   1.1  christos 	echo mips-sni-sysv4
   1213   1.1  christos 	exit ;;
   1214   1.1  christos     *:SINIX-*:*:*)
   1215   1.1  christos 	if uname -p 2>/dev/null >/dev/null ; then
   1216   1.1  christos 		UNAME_MACHINE=`(uname -p) 2>/dev/null`
   1217   1.1  christos 		echo ${UNAME_MACHINE}-sni-sysv4
   1218   1.1  christos 	else
   1219   1.1  christos 		echo ns32k-sni-sysv
   1220   1.1  christos 	fi
   1221   1.1  christos 	exit ;;
   1222   1.1  christos     PENTIUM:*:4.0*:*)	# Unisys `ClearPath HMP IX 4000' SVR4/MP effort
   1223   1.1  christos 			# says <Richard.M.Bartel (at] ccMail.Census.GOV>
   1224   1.1  christos 	echo i586-unisys-sysv4
   1225   1.1  christos 	exit ;;
   1226   1.1  christos     *:UNIX_System_V:4*:FTX*)
   1227   1.1  christos 	# From Gerald Hewes <hewes (at] openmarket.com>.
   1228   1.1  christos 	# How about differentiating between stratus architectures? -djm
   1229   1.1  christos 	echo hppa1.1-stratus-sysv4
   1230   1.1  christos 	exit ;;
   1231   1.1  christos     *:*:*:FTX*)
   1232   1.1  christos 	# From seanf (at] swdc.stratus.com.
   1233   1.1  christos 	echo i860-stratus-sysv4
   1234   1.1  christos 	exit ;;
   1235   1.1  christos     i*86:VOS:*:*)
   1236   1.1  christos 	# From Paul.Green (at] stratus.com.
   1237   1.1  christos 	echo ${UNAME_MACHINE}-stratus-vos
   1238   1.1  christos 	exit ;;
   1239   1.1  christos     *:VOS:*:*)
   1240   1.1  christos 	# From Paul.Green (at] stratus.com.
   1241   1.1  christos 	echo hppa1.1-stratus-vos
   1242   1.1  christos 	exit ;;
   1243   1.1  christos     mc68*:A/UX:*:*)
   1244   1.1  christos 	echo m68k-apple-aux${UNAME_RELEASE}
   1245   1.1  christos 	exit ;;
   1246   1.1  christos     news*:NEWS-OS:6*:*)
   1247   1.1  christos 	echo mips-sony-newsos6
   1248   1.1  christos 	exit ;;
   1249   1.1  christos     R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
   1250   1.1  christos 	if [ -d /usr/nec ]; then
   1251   1.1  christos 		echo mips-nec-sysv${UNAME_RELEASE}
   1252   1.1  christos 	else
   1253   1.1  christos 		echo mips-unknown-sysv${UNAME_RELEASE}
   1254   1.1  christos 	fi
   1255   1.1  christos 	exit ;;
   1256   1.1  christos     BeBox:BeOS:*:*)	# BeOS running on hardware made by Be, PPC only.
   1257   1.1  christos 	echo powerpc-be-beos
   1258   1.1  christos 	exit ;;
   1259   1.1  christos     BeMac:BeOS:*:*)	# BeOS running on Mac or Mac clone, PPC only.
   1260   1.1  christos 	echo powerpc-apple-beos
   1261   1.1  christos 	exit ;;
   1262   1.1  christos     BePC:BeOS:*:*)	# BeOS running on Intel PC compatible.
   1263   1.1  christos 	echo i586-pc-beos
   1264   1.1  christos 	exit ;;
   1265   1.1  christos     BePC:Haiku:*:*)	# Haiku running on Intel PC compatible.
   1266   1.1  christos 	echo i586-pc-haiku
   1267   1.1  christos 	exit ;;
   1268   1.3  christos     x86_64:Haiku:*:*)
   1269   1.3  christos 	echo x86_64-unknown-haiku
   1270   1.3  christos 	exit ;;
   1271   1.1  christos     SX-4:SUPER-UX:*:*)
   1272   1.1  christos 	echo sx4-nec-superux${UNAME_RELEASE}
   1273   1.1  christos 	exit ;;
   1274   1.1  christos     SX-5:SUPER-UX:*:*)
   1275   1.1  christos 	echo sx5-nec-superux${UNAME_RELEASE}
   1276   1.1  christos 	exit ;;
   1277   1.1  christos     SX-6:SUPER-UX:*:*)
   1278   1.1  christos 	echo sx6-nec-superux${UNAME_RELEASE}
   1279   1.1  christos 	exit ;;
   1280   1.1  christos     SX-7:SUPER-UX:*:*)
   1281   1.1  christos 	echo sx7-nec-superux${UNAME_RELEASE}
   1282   1.1  christos 	exit ;;
   1283   1.1  christos     SX-8:SUPER-UX:*:*)
   1284   1.1  christos 	echo sx8-nec-superux${UNAME_RELEASE}
   1285   1.1  christos 	exit ;;
   1286   1.1  christos     SX-8R:SUPER-UX:*:*)
   1287   1.1  christos 	echo sx8r-nec-superux${UNAME_RELEASE}
   1288   1.1  christos 	exit ;;
   1289   1.7     skrll     SX-ACE:SUPER-UX:*:*)
   1290   1.7     skrll 	echo sxace-nec-superux${UNAME_RELEASE}
   1291   1.7     skrll 	exit ;;
   1292   1.1  christos     Power*:Rhapsody:*:*)
   1293   1.1  christos 	echo powerpc-apple-rhapsody${UNAME_RELEASE}
   1294   1.1  christos 	exit ;;
   1295   1.1  christos     *:Rhapsody:*:*)
   1296   1.1  christos 	echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
   1297   1.1  christos 	exit ;;
   1298   1.1  christos     *:Darwin:*:*)
   1299   1.1  christos 	UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
   1300   1.4  christos 	eval $set_cc_for_build
   1301   1.4  christos 	if test "$UNAME_PROCESSOR" = unknown ; then
   1302   1.4  christos 	    UNAME_PROCESSOR=powerpc
   1303   1.4  christos 	fi
   1304   1.5  christos 	if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then
   1305   1.7     skrll 	    if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
   1306   1.5  christos 		if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
   1307   1.7     skrll 		    (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
   1308   1.5  christos 		    grep IS_64BIT_ARCH >/dev/null
   1309   1.5  christos 		then
   1310   1.5  christos 		    case $UNAME_PROCESSOR in
   1311   1.5  christos 			i386) UNAME_PROCESSOR=x86_64 ;;
   1312   1.5  christos 			powerpc) UNAME_PROCESSOR=powerpc64 ;;
   1313   1.5  christos 		    esac
   1314   1.5  christos 		fi
   1315   1.4  christos 	    fi
   1316   1.5  christos 	elif test "$UNAME_PROCESSOR" = i386 ; then
   1317   1.5  christos 	    # Avoid executing cc on OS X 10.9, as it ships with a stub
   1318   1.5  christos 	    # that puts up a graphical alert prompting to install
   1319   1.5  christos 	    # developer tools.  Any system running Mac OS X 10.7 or
   1320   1.5  christos 	    # later (Darwin 11 and later) is required to have a 64-bit
   1321   1.5  christos 	    # processor. This is not true of the ARM version of Darwin
   1322   1.5  christos 	    # that Apple uses in portable devices.
   1323   1.5  christos 	    UNAME_PROCESSOR=x86_64
   1324   1.4  christos 	fi
   1325   1.1  christos 	echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
   1326   1.1  christos 	exit ;;
   1327   1.1  christos     *:procnto*:*:* | *:QNX:[0123456789]*:*)
   1328   1.1  christos 	UNAME_PROCESSOR=`uname -p`
   1329   1.7     skrll 	if test "$UNAME_PROCESSOR" = x86; then
   1330   1.1  christos 		UNAME_PROCESSOR=i386
   1331   1.1  christos 		UNAME_MACHINE=pc
   1332   1.1  christos 	fi
   1333   1.1  christos 	echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
   1334   1.1  christos 	exit ;;
   1335   1.1  christos     *:QNX:*:4*)
   1336   1.1  christos 	echo i386-pc-qnx
   1337   1.1  christos 	exit ;;
   1338   1.1  christos     NEO-?:NONSTOP_KERNEL:*:*)
   1339   1.1  christos 	echo neo-tandem-nsk${UNAME_RELEASE}
   1340   1.1  christos 	exit ;;
   1341   1.3  christos     NSE-*:NONSTOP_KERNEL:*:*)
   1342   1.1  christos 	echo nse-tandem-nsk${UNAME_RELEASE}
   1343   1.1  christos 	exit ;;
   1344   1.1  christos     NSR-?:NONSTOP_KERNEL:*:*)
   1345   1.1  christos 	echo nsr-tandem-nsk${UNAME_RELEASE}
   1346   1.1  christos 	exit ;;
   1347  1.10  christos     NSX-?:NONSTOP_KERNEL:*:*)
   1348  1.10  christos 	echo nsx-tandem-nsk${UNAME_RELEASE}
   1349  1.10  christos 	exit ;;
   1350   1.1  christos     *:NonStop-UX:*:*)
   1351   1.1  christos 	echo mips-compaq-nonstopux
   1352   1.1  christos 	exit ;;
   1353   1.1  christos     BS2000:POSIX*:*:*)
   1354   1.1  christos 	echo bs2000-siemens-sysv
   1355   1.1  christos 	exit ;;
   1356   1.1  christos     DS/*:UNIX_System_V:*:*)
   1357   1.1  christos 	echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
   1358   1.1  christos 	exit ;;
   1359   1.1  christos     *:Plan9:*:*)
   1360   1.1  christos 	# "uname -m" is not consistent, so use $cputype instead. 386
   1361   1.1  christos 	# is converted to i386 for consistency with other x86
   1362   1.1  christos 	# operating systems.
   1363   1.7     skrll 	if test "$cputype" = 386; then
   1364   1.1  christos 	    UNAME_MACHINE=i386
   1365   1.1  christos 	else
   1366   1.1  christos 	    UNAME_MACHINE="$cputype"
   1367   1.1  christos 	fi
   1368   1.1  christos 	echo ${UNAME_MACHINE}-unknown-plan9
   1369   1.1  christos 	exit ;;
   1370   1.1  christos     *:TOPS-10:*:*)
   1371   1.1  christos 	echo pdp10-unknown-tops10
   1372   1.1  christos 	exit ;;
   1373   1.1  christos     *:TENEX:*:*)
   1374   1.1  christos 	echo pdp10-unknown-tenex
   1375   1.1  christos 	exit ;;
   1376   1.1  christos     KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
   1377   1.1  christos 	echo pdp10-dec-tops20
   1378   1.1  christos 	exit ;;
   1379   1.1  christos     XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
   1380   1.1  christos 	echo pdp10-xkl-tops20
   1381   1.1  christos 	exit ;;
   1382   1.1  christos     *:TOPS-20:*:*)
   1383   1.1  christos 	echo pdp10-unknown-tops20
   1384   1.1  christos 	exit ;;
   1385   1.1  christos     *:ITS:*:*)
   1386   1.1  christos 	echo pdp10-unknown-its
   1387   1.1  christos 	exit ;;
   1388   1.1  christos     SEI:*:*:SEIUX)
   1389   1.1  christos 	echo mips-sei-seiux${UNAME_RELEASE}
   1390   1.1  christos 	exit ;;
   1391   1.1  christos     *:DragonFly:*:*)
   1392   1.1  christos 	echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
   1393   1.1  christos 	exit ;;
   1394   1.1  christos     *:*VMS:*:*)
   1395   1.1  christos 	UNAME_MACHINE=`(uname -p) 2>/dev/null`
   1396   1.1  christos 	case "${UNAME_MACHINE}" in
   1397   1.1  christos 	    A*) echo alpha-dec-vms ; exit ;;
   1398   1.1  christos 	    I*) echo ia64-dec-vms ; exit ;;
   1399   1.1  christos 	    V*) echo vax-dec-vms ; exit ;;
   1400   1.1  christos 	esac ;;
   1401   1.1  christos     *:XENIX:*:SysV)
   1402   1.1  christos 	echo i386-pc-xenix
   1403   1.1  christos 	exit ;;
   1404   1.1  christos     i*86:skyos:*:*)
   1405   1.7     skrll 	echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE} | sed -e 's/ .*$//'`
   1406   1.1  christos 	exit ;;
   1407   1.1  christos     i*86:rdos:*:*)
   1408   1.1  christos 	echo ${UNAME_MACHINE}-pc-rdos
   1409   1.1  christos 	exit ;;
   1410   1.1  christos     i*86:AROS:*:*)
   1411   1.1  christos 	echo ${UNAME_MACHINE}-pc-aros
   1412   1.1  christos 	exit ;;
   1413   1.3  christos     x86_64:VMkernel:*:*)
   1414   1.3  christos 	echo ${UNAME_MACHINE}-unknown-esx
   1415   1.3  christos 	exit ;;
   1416   1.7     skrll     amd64:Isilon\ OneFS:*:*)
   1417   1.7     skrll 	echo x86_64-unknown-onefs
   1418   1.7     skrll 	exit ;;
   1419   1.1  christos esac
   1420   1.1  christos 
   1421   1.1  christos cat >&2 <<EOF
   1422   1.1  christos $0: unable to guess system type
   1423   1.1  christos 
   1424   1.9     sevan This script (version $timestamp), has failed to recognize the
   1425   1.9     sevan operating system you are using. If your script is old, overwrite
   1426   1.9     sevan config.guess and config.sub with the latest versions from:
   1427   1.1  christos 
   1428   1.7     skrll   http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
   1429   1.1  christos and
   1430   1.7     skrll   http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
   1431   1.1  christos 
   1432   1.9     sevan If $0 has already been updated, send the following data and any
   1433   1.9     sevan information you think might be pertinent to config-patches@gnu.org to
   1434   1.9     sevan provide the necessary information to handle your system.
   1435   1.1  christos 
   1436   1.1  christos config.guess timestamp = $timestamp
   1437   1.1  christos 
   1438   1.1  christos uname -m = `(uname -m) 2>/dev/null || echo unknown`
   1439   1.1  christos uname -r = `(uname -r) 2>/dev/null || echo unknown`
   1440   1.1  christos uname -s = `(uname -s) 2>/dev/null || echo unknown`
   1441   1.1  christos uname -v = `(uname -v) 2>/dev/null || echo unknown`
   1442   1.1  christos 
   1443   1.1  christos /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
   1444   1.1  christos /bin/uname -X     = `(/bin/uname -X) 2>/dev/null`
   1445   1.1  christos 
   1446   1.1  christos hostinfo               = `(hostinfo) 2>/dev/null`
   1447   1.1  christos /bin/universe          = `(/bin/universe) 2>/dev/null`
   1448   1.1  christos /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null`
   1449   1.1  christos /bin/arch              = `(/bin/arch) 2>/dev/null`
   1450   1.1  christos /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null`
   1451   1.1  christos /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
   1452   1.1  christos 
   1453   1.1  christos UNAME_MACHINE = ${UNAME_MACHINE}
   1454   1.1  christos UNAME_RELEASE = ${UNAME_RELEASE}
   1455   1.1  christos UNAME_SYSTEM  = ${UNAME_SYSTEM}
   1456   1.1  christos UNAME_VERSION = ${UNAME_VERSION}
   1457   1.1  christos EOF
   1458   1.1  christos 
   1459   1.1  christos exit 1
   1460   1.1  christos 
   1461   1.1  christos # Local variables:
   1462   1.1  christos # eval: (add-hook 'write-file-hooks 'time-stamp)
   1463   1.1  christos # time-stamp-start: "timestamp='"
   1464   1.1  christos # time-stamp-format: "%:y-%02m-%02d"
   1465   1.1  christos # time-stamp-end: "'"
   1466   1.1  christos # End:
   1467