annotate src/libsndfile-1.0.27/Cfg/config.guess @ 84:08ae793730bd

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