Changeset 4435 for pjproject/trunk/config.guess
- Timestamp:
- Mar 11, 2013 6:32:58 AM (12 years ago)
- Location:
- pjproject/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk
- Property svn:mergeinfo changed
/pjproject/branches/projects/android (added) merged: 4153,4192-4195,4202,4211,4215,4221-4222,4226,4231,4237,4250,4284,4286-4287,4289,4292
- Property svn:mergeinfo changed
-
pjproject/trunk/config.guess
r795 r4435 1 1 #! /bin/sh 2 2 # Attempt to guess a canonical system name. 3 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 4 # Free Software Foundation, Inc. 5 6 timestamp='2001-09-04' 3 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 4 # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 5 # 2011, 2012 Free Software Foundation, Inc. 6 7 timestamp='2012-06-17' 7 8 8 9 # This file is free software; you can redistribute it and/or modify it … … 17 18 # 18 19 # You should have received a copy of the GNU General Public License 19 # along with this program; if not, write to the Free Software 20 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 20 # along with this program; if not, see <http://www.gnu.org/licenses/>. 21 21 # 22 22 # As a special exception to the GNU General Public License, if you … … 25 25 # the same distribution terms that you use for the rest of that program. 26 26 27 # Written by Per Bothner <bothner@cygnus.com>. 28 # Please send patches to <config-patches@gnu.org>. 27 28 # Originally written by Per Bothner. Please send patches (context 29 # diff format) to <config-patches@gnu.org> and include a ChangeLog 30 # entry. 29 31 # 30 32 # This script attempts to guess a canonical system name similar to … … 32 34 # exits with 0. Otherwise, it exits with 1. 33 35 # 34 # The plan is that this can be called by configure scripts if you35 # don't specify an explicit build system type.36 # You can get the latest version of this script from: 37 # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD 36 38 37 39 me=`echo "$0" | sed -e 's,.*/,,'` … … 53 55 54 56 Originally written by Per Bothner. 55 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 57 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 58 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 56 59 Free Software Foundation, Inc. 57 60 … … 66 69 case $1 in 67 70 --time-stamp | --time* | -t ) 68 echo "$timestamp" ; exit 0;;71 echo "$timestamp" ; exit ;; 69 72 --version | -v ) 70 echo "$version" ; exit 0;;73 echo "$version" ; exit ;; 71 74 --help | --h* | -h ) 72 echo "$usage"; exit 0;;75 echo "$usage"; exit ;; 73 76 -- ) # Stop option processing 74 77 shift; break ;; … … 88 91 fi 89 92 90 91 dummy=dummy-$$ 92 trap 'rm -f $dummy.c $dummy.o $dummy.rel $dummy; exit 1' 1 2 15 93 94 # CC_FOR_BUILD -- compiler used by this script. 93 trap 'exit 1' 1 2 15 94 95 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a 96 # compiler to aid in system detection is discouraged as it requires 97 # temporary files to be created and, as you can see below, it is a 98 # headache to deal with in a portable fashion. 99 95 100 # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still 96 101 # use `HOST_CC' if defined, but it is deprecated. 97 102 98 set_cc_for_build='case $CC_FOR_BUILD,$HOST_CC,$CC in 99 ,,) echo "int dummy(){}" > $dummy.c ; 100 for c in cc gcc c89 ; do 101 ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ; 102 if test $? = 0 ; then 103 # Portable tmp directory creation inspired by the Autoconf team. 104 105 set_cc_for_build=' 106 trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; 107 trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; 108 : ${TMPDIR=/tmp} ; 109 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || 110 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || 111 { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || 112 { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; 113 dummy=$tmp/dummy ; 114 tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; 115 case $CC_FOR_BUILD,$HOST_CC,$CC in 116 ,,) echo "int x;" > $dummy.c ; 117 for c in cc gcc c89 c99 ; do 118 if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then 103 119 CC_FOR_BUILD="$c"; break ; 104 120 fi ; 105 121 done ; 106 rm -f $dummy.c $dummy.o $dummy.rel ;107 122 if test x"$CC_FOR_BUILD" = x ; then 108 123 CC_FOR_BUILD=no_compiler_found ; … … 111 126 ,,*) CC_FOR_BUILD=$CC ;; 112 127 ,*,*) CC_FOR_BUILD=$HOST_CC ;; 113 esac '128 esac ; set_cc_for_build= ;' 114 129 115 130 # This is needed to find uname on a Pyramid OSx when run in the BSD universe. … … 128 143 case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in 129 144 *:NetBSD:*:*) 130 # Net bsd(nbsd) targets should (where applicable) match one or131 # more of the tup ples: *-*-netbsdelf*, *-*-netbsdaout*,145 # NetBSD (nbsd) targets should (where applicable) match one or 146 # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, 132 147 # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently 133 148 # switched to ELF, *-*-netbsd* would select the old … … 135 150 # compatibility and a consistent mechanism for selecting the 136 151 # object file format. 137 # Determine the machine/vendor (is the vendor relevant). 138 case "${UNAME_MACHINE}" in 139 amiga) machine=m68k-unknown ;; 140 arm32) machine=arm-unknown ;; 141 atari*) machine=m68k-atari ;; 142 sun3*) machine=m68k-sun ;; 143 mac68k) machine=m68k-apple ;; 144 macppc) machine=powerpc-apple ;; 145 hp3[0-9][05]) machine=m68k-hp ;; 146 ibmrt|romp-ibm) machine=romp-ibm ;; 147 *) machine=${UNAME_MACHINE}-unknown ;; 152 # 153 # Note: NetBSD doesn't particularly care about the vendor 154 # portion of the name. We always set it to "unknown". 155 sysctl="sysctl -n hw.machine_arch" 156 UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ 157 /usr/sbin/$sysctl 2>/dev/null || echo unknown)` 158 case "${UNAME_MACHINE_ARCH}" in 159 armeb) machine=armeb-unknown ;; 160 arm*) machine=arm-unknown ;; 161 sh3el) machine=shl-unknown ;; 162 sh3eb) machine=sh-unknown ;; 163 sh5el) machine=sh5le-unknown ;; 164 *) machine=${UNAME_MACHINE_ARCH}-unknown ;; 148 165 esac 149 166 # The Operating System including object format, if it has switched 150 167 # to ELF recently, or will in the future. 151 case "${UNAME_MACHINE }" in152 i386|sparc|amiga|arm*|hp300|mvme68k|vax|atari|luna68k|mac68k|news68k|next68k|pc532|sun3*|x68k)168 case "${UNAME_MACHINE_ARCH}" in 169 arm*|i386|m68k|ns32k|sh3*|sparc|vax) 153 170 eval $set_cc_for_build 154 171 if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ 155 | grep __ELF__ >/dev/null172 | grep -q __ELF__ 156 173 then 157 174 # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). … … 163 180 ;; 164 181 *) 165 182 os=netbsd 166 183 ;; 167 184 esac 168 185 # The OS release 169 release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` 186 # Debian GNU/NetBSD machines have a different userland, and 187 # thus, need a distinct triplet. However, they do not need 188 # kernel version information, so it can be replaced with a 189 # suitable tag, in the style of linux-gnu. 190 case "${UNAME_VERSION}" in 191 Debian*) 192 release='-gnu' 193 ;; 194 *) 195 release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` 196 ;; 197 esac 170 198 # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: 171 199 # contains redundant information, the shorter form: 172 200 # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. 173 201 echo "${machine}-${os}${release}" 174 exit 0 ;; 202 exit ;; 203 *:Bitrig:*:*) 204 UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` 205 echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} 206 exit ;; 207 *:OpenBSD:*:*) 208 UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` 209 echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} 210 exit ;; 211 *:ekkoBSD:*:*) 212 echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} 213 exit ;; 214 *:SolidBSD:*:*) 215 echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} 216 exit ;; 217 macppc:MirBSD:*:*) 218 echo powerpc-unknown-mirbsd${UNAME_RELEASE} 219 exit ;; 220 *:MirBSD:*:*) 221 echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} 222 exit ;; 175 223 alpha:OSF1:*:*) 176 if test $UNAME_RELEASE = "V4.0"; then 224 case $UNAME_RELEASE in 225 *4.0) 177 226 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` 178 fi 227 ;; 228 *5.*) 229 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` 230 ;; 231 esac 232 # According to Compaq, /usr/sbin/psrinfo has been available on 233 # OSF/1 and Tru64 systems produced since 1995. I hope that 234 # covers most systems running today. This code pipes the CPU 235 # types through head -n 1, so we only detect the type of CPU 0. 236 ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` 237 case "$ALPHA_CPU_TYPE" in 238 "EV4 (21064)") 239 UNAME_MACHINE="alpha" ;; 240 "EV4.5 (21064)") 241 UNAME_MACHINE="alpha" ;; 242 "LCA4 (21066/21068)") 243 UNAME_MACHINE="alpha" ;; 244 "EV5 (21164)") 245 UNAME_MACHINE="alphaev5" ;; 246 "EV5.6 (21164A)") 247 UNAME_MACHINE="alphaev56" ;; 248 "EV5.6 (21164PC)") 249 UNAME_MACHINE="alphapca56" ;; 250 "EV5.7 (21164PC)") 251 UNAME_MACHINE="alphapca57" ;; 252 "EV6 (21264)") 253 UNAME_MACHINE="alphaev6" ;; 254 "EV6.7 (21264A)") 255 UNAME_MACHINE="alphaev67" ;; 256 "EV6.8CB (21264C)") 257 UNAME_MACHINE="alphaev68" ;; 258 "EV6.8AL (21264B)") 259 UNAME_MACHINE="alphaev68" ;; 260 "EV6.8CX (21264D)") 261 UNAME_MACHINE="alphaev68" ;; 262 "EV6.9A (21264/EV69A)") 263 UNAME_MACHINE="alphaev69" ;; 264 "EV7 (21364)") 265 UNAME_MACHINE="alphaev7" ;; 266 "EV7.9 (21364A)") 267 UNAME_MACHINE="alphaev79" ;; 268 esac 269 # A Pn.n version is a patched version. 179 270 # A Vn.n version is a released version. 180 271 # A Tn.n version is a released field test version. 181 272 # A Xn.n version is an unreleased experimental baselevel. 182 273 # 1.2 uses "1.2" for uname -r. 183 cat <<EOF >$dummy.s 184 .data 185 \$Lformat: 186 .byte 37,100,45,37,120,10,0 # "%d-%x\n" 187 188 .text 189 .globl main 190 .align 4 191 .ent main 192 main: 193 .frame \$30,16,\$26,0 194 ldgp \$29,0(\$27) 195 .prologue 1 196 .long 0x47e03d80 # implver \$0 197 lda \$2,-1 198 .long 0x47e20c21 # amask \$2,\$1 199 lda \$16,\$Lformat 200 mov \$0,\$17 201 not \$1,\$18 202 jsr \$26,printf 203 ldgp \$29,0(\$26) 204 mov 0,\$16 205 jsr \$26,exit 206 .end main 207 EOF 208 eval $set_cc_for_build 209 $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null 210 if test "$?" = 0 ; then 211 case `./$dummy` in 212 0-0) 213 UNAME_MACHINE="alpha" 214 ;; 215 1-0) 216 UNAME_MACHINE="alphaev5" 217 ;; 218 1-1) 219 UNAME_MACHINE="alphaev56" 220 ;; 221 1-101) 222 UNAME_MACHINE="alphapca56" 223 ;; 224 2-303) 225 UNAME_MACHINE="alphaev6" 226 ;; 227 2-307) 228 UNAME_MACHINE="alphaev67" 229 ;; 230 2-1307) 231 UNAME_MACHINE="alphaev68" 232 ;; 233 esac 234 fi 235 rm -f $dummy.s $dummy 236 echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 237 exit 0 ;; 274 echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 275 # Reset EXIT trap before exiting to avoid spurious non-zero exit code. 276 exitcode=$? 277 trap '' 0 278 exit $exitcode ;; 238 279 Alpha\ *:Windows_NT*:*) 239 280 # How do we know it's Interix rather than the generic POSIX subsystem? … … 241 282 # of the specific Alpha model? 242 283 echo alpha-pc-interix 243 exit 0;;284 exit ;; 244 285 21064:Windows_NT:50:3) 245 286 echo alpha-dec-winnt3.5 246 exit 0;;287 exit ;; 247 288 Amiga*:UNIX_System_V:4.0:*) 248 289 echo m68k-unknown-sysv4 249 exit 0;; 250 amiga:OpenBSD:*:*) 251 echo m68k-unknown-openbsd${UNAME_RELEASE} 252 exit 0 ;; 290 exit ;; 253 291 *:[Aa]miga[Oo][Ss]:*:*) 254 292 echo ${UNAME_MACHINE}-unknown-amigaos 255 exit 0 ;; 256 arc64:OpenBSD:*:*) 257 echo mips64el-unknown-openbsd${UNAME_RELEASE} 258 exit 0 ;; 259 arc:OpenBSD:*:*) 260 echo mipsel-unknown-openbsd${UNAME_RELEASE} 261 exit 0 ;; 262 hkmips:OpenBSD:*:*) 263 echo mips-unknown-openbsd${UNAME_RELEASE} 264 exit 0 ;; 265 pmax:OpenBSD:*:*) 266 echo mipsel-unknown-openbsd${UNAME_RELEASE} 267 exit 0 ;; 268 sgi:OpenBSD:*:*) 269 echo mips-unknown-openbsd${UNAME_RELEASE} 270 exit 0 ;; 271 wgrisc:OpenBSD:*:*) 272 echo mipsel-unknown-openbsd${UNAME_RELEASE} 273 exit 0 ;; 293 exit ;; 294 *:[Mm]orph[Oo][Ss]:*:*) 295 echo ${UNAME_MACHINE}-unknown-morphos 296 exit ;; 274 297 *:OS/390:*:*) 275 298 echo i370-ibm-openedition 276 exit 0 ;; 299 exit ;; 300 *:z/VM:*:*) 301 echo s390-ibm-zvmoe 302 exit ;; 303 *:OS400:*:*) 304 echo powerpc-ibm-os400 305 exit ;; 277 306 arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) 278 307 echo arm-acorn-riscix${UNAME_RELEASE} 279 exit 0;; 308 exit ;; 309 arm:riscos:*:*|arm:RISCOS:*:*) 310 echo arm-unknown-riscos 311 exit ;; 280 312 SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) 281 313 echo hppa1.1-hitachi-hiuxmpp 282 exit 0;;314 exit ;; 283 315 Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) 284 316 # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. … … 288 320 echo pyramid-pyramid-bsd 289 321 fi 290 exit 0;;322 exit ;; 291 323 NILE*:*:*:dcosx) 292 324 echo pyramid-pyramid-svr4 293 exit 0 ;; 325 exit ;; 326 DRS?6000:unix:4.0:6*) 327 echo sparc-icl-nx6 328 exit ;; 329 DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) 330 case `/usr/bin/uname -p` in 331 sparc) echo sparc-icl-nx7; exit ;; 332 esac ;; 333 s390x:SunOS:*:*) 334 echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 335 exit ;; 294 336 sun4H:SunOS:5.*:*) 295 337 echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 296 exit 0;;338 exit ;; 297 339 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) 298 340 echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 299 exit 0 ;; 300 i86pc:SunOS:5.*:*) 301 echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 302 exit 0 ;; 341 exit ;; 342 i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) 343 echo i386-pc-auroraux${UNAME_RELEASE} 344 exit ;; 345 i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) 346 eval $set_cc_for_build 347 SUN_ARCH="i386" 348 # If there is a compiler, see if it is configured for 64-bit objects. 349 # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. 350 # This test works for both compilers. 351 if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then 352 if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ 353 (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ 354 grep IS_64BIT_ARCH >/dev/null 355 then 356 SUN_ARCH="x86_64" 357 fi 358 fi 359 echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 360 exit ;; 303 361 sun4*:SunOS:6*:*) 304 362 # According to config.sub, this is the proper way to canonicalize … … 306 364 # it's likely to be more like Solaris than SunOS4. 307 365 echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 308 exit 0;;366 exit ;; 309 367 sun4*:SunOS:*:*) 310 368 case "`/usr/bin/arch -k`" in … … 315 373 # Japanese Language versions have a version number like `4.1.3-JL'. 316 374 echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` 317 exit 0;;375 exit ;; 318 376 sun3*:SunOS:*:*) 319 377 echo m68k-sun-sunos${UNAME_RELEASE} 320 exit 0;;378 exit ;; 321 379 sun*:*:4.2BSD:*) 322 UNAME_RELEASE=`( head -1/etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`380 UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` 323 381 test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 324 382 case "`/bin/arch`" in … … 330 388 ;; 331 389 esac 332 exit 0;;390 exit ;; 333 391 aushp:SunOS:*:*) 334 392 echo sparc-auspex-sunos${UNAME_RELEASE} 335 exit 0 ;; 336 sparc*:NetBSD:*) 337 echo `uname -p`-unknown-netbsd${UNAME_RELEASE} 338 exit 0 ;; 339 atari*:OpenBSD:*:*) 340 echo m68k-unknown-openbsd${UNAME_RELEASE} 341 exit 0 ;; 393 exit ;; 342 394 # The situation for MiNT is a little confusing. The machine name 343 395 # can be virtually everything (everything which is not … … 349 401 # be no problem. 350 402 atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) 351 352 exit 0;;403 echo m68k-atari-mint${UNAME_RELEASE} 404 exit ;; 353 405 atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) 354 406 echo m68k-atari-mint${UNAME_RELEASE} 355 exit 0;;407 exit ;; 356 408 *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) 357 358 exit 0;;409 echo m68k-atari-mint${UNAME_RELEASE} 410 exit ;; 359 411 milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) 360 361 exit 0;;412 echo m68k-milan-mint${UNAME_RELEASE} 413 exit ;; 362 414 hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) 363 364 exit 0;;415 echo m68k-hades-mint${UNAME_RELEASE} 416 exit ;; 365 417 *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) 366 echo m68k-unknown-mint${UNAME_RELEASE} 367 exit 0 ;; 368 sun3*:OpenBSD:*:*) 369 echo m68k-unknown-openbsd${UNAME_RELEASE} 370 exit 0 ;; 371 mac68k:OpenBSD:*:*) 372 echo m68k-unknown-openbsd${UNAME_RELEASE} 373 exit 0 ;; 374 mvme68k:OpenBSD:*:*) 375 echo m68k-unknown-openbsd${UNAME_RELEASE} 376 exit 0 ;; 377 mvme88k:OpenBSD:*:*) 378 echo m88k-unknown-openbsd${UNAME_RELEASE} 379 exit 0 ;; 418 echo m68k-unknown-mint${UNAME_RELEASE} 419 exit ;; 420 m68k:machten:*:*) 421 echo m68k-apple-machten${UNAME_RELEASE} 422 exit ;; 380 423 powerpc:machten:*:*) 381 424 echo powerpc-apple-machten${UNAME_RELEASE} 382 exit 0;;425 exit ;; 383 426 RISC*:Mach:*:*) 384 427 echo mips-dec-mach_bsd4.3 385 exit 0;;428 exit ;; 386 429 RISC*:ULTRIX:*:*) 387 430 echo mips-dec-ultrix${UNAME_RELEASE} 388 exit 0;;431 exit ;; 389 432 VAX*:ULTRIX*:*:*) 390 433 echo vax-dec-ultrix${UNAME_RELEASE} 391 exit 0;;434 exit ;; 392 435 2020:CLIX:*:* | 2430:CLIX:*:*) 393 436 echo clipper-intergraph-clix${UNAME_RELEASE} 394 exit 0;;437 exit ;; 395 438 mips:*:*:UMIPS | mips:*:*:RISCos) 396 439 eval $set_cc_for_build … … 416 459 } 417 460 EOF 418 $CC_FOR_BUILD $dummy.c -o $dummy \419 && ./$dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \420 && rm -f $dummy.c $dummy && exit 0421 rm -f $dummy.c $dummy461 $CC_FOR_BUILD -o $dummy $dummy.c && 462 dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && 463 SYSTEM_NAME=`$dummy $dummyarg` && 464 { echo "$SYSTEM_NAME"; exit; } 422 465 echo mips-mips-riscos${UNAME_RELEASE} 423 exit 0;;466 exit ;; 424 467 Motorola:PowerMAX_OS:*:*) 425 468 echo powerpc-motorola-powermax 426 exit 0 ;; 469 exit ;; 470 Motorola:*:4.3:PL8-*) 471 echo powerpc-harris-powermax 472 exit ;; 473 Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) 474 echo powerpc-harris-powermax 475 exit ;; 427 476 Night_Hawk:Power_UNIX:*:*) 428 477 echo powerpc-harris-powerunix 429 exit 0;;478 exit ;; 430 479 m88k:CX/UX:7*:*) 431 480 echo m88k-harris-cxux7 432 exit 0;;481 exit ;; 433 482 m88k:*:4*:R4*) 434 483 echo m88k-motorola-sysv4 435 exit 0;;484 exit ;; 436 485 m88k:*:3*:R3*) 437 486 echo m88k-motorola-sysv3 438 exit 0;;487 exit ;; 439 488 AViiON:dgux:*:*) 440 441 489 # DG/UX returns AViiON for all architectures 490 UNAME_PROCESSOR=`/usr/bin/uname -p` 442 491 if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] 443 492 then … … 452 501 echo i586-dg-dgux${UNAME_RELEASE} 453 502 fi 454 exit 0;;503 exit ;; 455 504 M88*:DolphinOS:*:*) # DolphinOS (SVR3) 456 505 echo m88k-dolphin-sysv3 457 exit 0;;506 exit ;; 458 507 M88*:*:R3*:*) 459 508 # Delta 88k system running SVR3 460 509 echo m88k-motorola-sysv3 461 exit 0;;510 exit ;; 462 511 XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) 463 512 echo m88k-tektronix-sysv3 464 exit 0;;513 exit ;; 465 514 Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) 466 515 echo m68k-tektronix-bsd 467 exit 0;;516 exit ;; 468 517 *:IRIX*:*:*) 469 518 echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` 470 exit 0;;519 exit ;; 471 520 ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. 472 echo romp-ibm-aix 473 exit 0 ;;# Note that: echo "'`uname -s`'" gives 'AIX '521 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id 522 exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' 474 523 i*86:AIX:*:*) 475 524 echo i386-ibm-aix 476 exit 0;;525 exit ;; 477 526 ia64:AIX:*:*) 478 527 if [ -x /usr/bin/oslevel ] ; then … … 482 531 fi 483 532 echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} 484 exit 0;;533 exit ;; 485 534 *:AIX:2:3) 486 535 if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then … … 497 546 } 498 547 EOF 499 $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0 500 rm -f $dummy.c $dummy 501 echo rs6000-ibm-aix3.2.5 548 if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` 549 then 550 echo "$SYSTEM_NAME" 551 else 552 echo rs6000-ibm-aix3.2.5 553 fi 502 554 elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then 503 555 echo rs6000-ibm-aix3.2.4 … … 505 557 echo rs6000-ibm-aix3.2 506 558 fi 507 exit 0;;508 *:AIX:*:[45 ])509 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | head -1| awk '{ print $1 }'`559 exit ;; 560 *:AIX:*:[4567]) 561 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` 510 562 if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then 511 563 IBM_ARCH=rs6000 … … 519 571 fi 520 572 echo ${IBM_ARCH}-ibm-aix${IBM_REV} 521 exit 0;;573 exit ;; 522 574 *:AIX:*:*) 523 575 echo rs6000-ibm-aix 524 exit 0;;576 exit ;; 525 577 ibmrt:4.4BSD:*|romp-ibm:BSD:*) 526 578 echo romp-ibm-bsd4.4 527 exit 0;;579 exit ;; 528 580 ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and 529 581 echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to 530 exit 0 ;;# report: romp-ibm BSD 4.3582 exit ;; # report: romp-ibm BSD 4.3 531 583 *:BOSX:*:*) 532 584 echo rs6000-bull-bosx 533 exit 0;;585 exit ;; 534 586 DPX/2?00:B.O.S.:*:*) 535 587 echo m68k-bull-sysv3 536 exit 0;;588 exit ;; 537 589 9000/[34]??:4.3bsd:1.*:*) 538 590 echo m68k-hp-bsd 539 exit 0;;591 exit ;; 540 592 hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) 541 593 echo m68k-hp-bsd4.4 542 exit 0;;594 exit ;; 543 595 9000/[34678]??:HP-UX:*:*) 544 596 HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` … … 547 599 9000/[34]?? ) HP_ARCH=m68k ;; 548 600 9000/[678][0-9][0-9]) 549 case "${HPUX_REV}" in 550 11.[0-9][0-9]) 551 if [ -x /usr/bin/getconf ]; then 552 sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` 553 sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` 554 case "${sc_cpu_version}" in 555 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 556 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 557 532) # CPU_PA_RISC2_0 558 case "${sc_kernel_bits}" in 559 32) HP_ARCH="hppa2.0n" ;; 560 64) HP_ARCH="hppa2.0w" ;; 561 esac ;; 562 esac 563 fi ;; 564 esac 565 if [ "${HP_ARCH}" = "" ]; then 566 eval $set_cc_for_build 567 sed 's/^ //' << EOF >$dummy.c 568 569 #define _HPUX_SOURCE 570 #include <stdlib.h> 571 #include <unistd.h> 572 573 int main () 574 { 575 #if defined(_SC_KERNEL_BITS) 576 long bits = sysconf(_SC_KERNEL_BITS); 577 #endif 578 long cpu = sysconf (_SC_CPU_VERSION); 579 580 switch (cpu) 581 { 582 case CPU_PA_RISC1_0: puts ("hppa1.0"); break; 583 case CPU_PA_RISC1_1: puts ("hppa1.1"); break; 584 case CPU_PA_RISC2_0: 585 #if defined(_SC_KERNEL_BITS) 586 switch (bits) 587 { 588 case 64: puts ("hppa2.0w"); break; 589 case 32: puts ("hppa2.0n"); break; 590 default: puts ("hppa2.0"); break; 591 } break; 592 #else /* !defined(_SC_KERNEL_BITS) */ 593 puts ("hppa2.0"); break; 594 #endif 595 default: puts ("hppa1.0"); break; 596 } 597 exit (0); 598 } 601 if [ -x /usr/bin/getconf ]; then 602 sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` 603 sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` 604 case "${sc_cpu_version}" in 605 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 606 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 607 532) # CPU_PA_RISC2_0 608 case "${sc_kernel_bits}" in 609 32) HP_ARCH="hppa2.0n" ;; 610 64) HP_ARCH="hppa2.0w" ;; 611 '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 612 esac ;; 613 esac 614 fi 615 if [ "${HP_ARCH}" = "" ]; then 616 eval $set_cc_for_build 617 sed 's/^ //' << EOF >$dummy.c 618 619 #define _HPUX_SOURCE 620 #include <stdlib.h> 621 #include <unistd.h> 622 623 int main () 624 { 625 #if defined(_SC_KERNEL_BITS) 626 long bits = sysconf(_SC_KERNEL_BITS); 627 #endif 628 long cpu = sysconf (_SC_CPU_VERSION); 629 630 switch (cpu) 631 { 632 case CPU_PA_RISC1_0: puts ("hppa1.0"); break; 633 case CPU_PA_RISC1_1: puts ("hppa1.1"); break; 634 case CPU_PA_RISC2_0: 635 #if defined(_SC_KERNEL_BITS) 636 switch (bits) 637 { 638 case 64: puts ("hppa2.0w"); break; 639 case 32: puts ("hppa2.0n"); break; 640 default: puts ("hppa2.0"); break; 641 } break; 642 #else /* !defined(_SC_KERNEL_BITS) */ 643 puts ("hppa2.0"); break; 644 #endif 645 default: puts ("hppa1.0"); break; 646 } 647 exit (0); 648 } 599 649 EOF 600 (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null ) && HP_ARCH=`./$dummy` 601 if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi 602 rm -f $dummy.c $dummy 603 fi ;; 650 (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` 651 test -z "$HP_ARCH" && HP_ARCH=hppa 652 fi ;; 604 653 esac 654 if [ ${HP_ARCH} = "hppa2.0w" ] 655 then 656 eval $set_cc_for_build 657 658 # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating 659 # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler 660 # generating 64-bit code. GNU and HP use different nomenclature: 661 # 662 # $ CC_FOR_BUILD=cc ./config.guess 663 # => hppa2.0w-hp-hpux11.23 664 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess 665 # => hppa64-hp-hpux11.23 666 667 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | 668 grep -q __LP64__ 669 then 670 HP_ARCH="hppa2.0w" 671 else 672 HP_ARCH="hppa64" 673 fi 674 fi 605 675 echo ${HP_ARCH}-hp-hpux${HPUX_REV} 606 exit 0;;676 exit ;; 607 677 ia64:HP-UX:*:*) 608 678 HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` 609 679 echo ia64-hp-hpux${HPUX_REV} 610 exit 0;;680 exit ;; 611 681 3050*:HI-UX:*:*) 612 682 eval $set_cc_for_build … … 636 706 } 637 707 EOF 638 $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0639 rm -f $dummy.c $dummy708 $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && 709 { echo "$SYSTEM_NAME"; exit; } 640 710 echo unknown-hitachi-hiuxwe2 641 exit 0;;711 exit ;; 642 712 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) 643 713 echo hppa1.1-hp-bsd 644 exit 0;;714 exit ;; 645 715 9000/8??:4.3bsd:*:*) 646 716 echo hppa1.0-hp-bsd 647 exit 0;;717 exit ;; 648 718 *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) 649 719 echo hppa1.0-hp-mpeix 650 exit 0;;720 exit ;; 651 721 hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) 652 722 echo hppa1.1-hp-osf 653 exit 0;;723 exit ;; 654 724 hp8??:OSF1:*:*) 655 725 echo hppa1.0-hp-osf 656 exit 0;;726 exit ;; 657 727 i*86:OSF1:*:*) 658 728 if [ -x /usr/sbin/sysversion ] ; then … … 661 731 echo ${UNAME_MACHINE}-unknown-osf1 662 732 fi 663 exit 0;;733 exit ;; 664 734 parisc*:Lites*:*:*) 665 735 echo hppa1.1-hp-lites 666 exit 0 ;; 667 hppa*:OpenBSD:*:*) 668 echo hppa-unknown-openbsd 669 exit 0 ;; 736 exit ;; 670 737 C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) 671 738 echo c1-convex-bsd 672 exit 0;;739 exit ;; 673 740 C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) 674 741 if getsysinfo -f scalar_acc … … 676 743 else echo c2-convex-bsd 677 744 fi 678 exit 0;;745 exit ;; 679 746 C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) 680 747 echo c34-convex-bsd 681 exit 0;;748 exit ;; 682 749 C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) 683 750 echo c38-convex-bsd 684 exit 0;;751 exit ;; 685 752 C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) 686 753 echo c4-convex-bsd 687 exit 0 ;; 688 CRAY*X-MP:*:*:*) 689 echo xmp-cray-unicos 690 exit 0 ;; 754 exit ;; 691 755 CRAY*Y-MP:*:*:*) 692 756 echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 693 exit 0;;757 exit ;; 694 758 CRAY*[A-Z]90:*:*:*) 695 759 echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ … … 697 761 -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ 698 762 -e 's/\.[^.]*$/.X/' 699 exit 0;;763 exit ;; 700 764 CRAY*TS:*:*:*) 701 765 echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 702 exit 0 ;; 703 CRAY*T3D:*:*:*) 704 echo alpha-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 705 exit 0 ;; 766 exit ;; 706 767 CRAY*T3E:*:*:*) 707 768 echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 708 exit 0;;769 exit ;; 709 770 CRAY*SV1:*:*:*) 710 771 echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 711 exit 0;;712 CRAY-2:*:*:*)713 echo cray 2-cray-unicos714 exit 0;;772 exit ;; 773 *:UNICOS/mp:*:*) 774 echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 775 exit ;; 715 776 F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) 716 777 FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 717 FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` 718 FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` 719 echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" 720 exit 0 ;; 721 hp300:OpenBSD:*:*) 722 echo m68k-unknown-openbsd${UNAME_RELEASE} 723 exit 0 ;; 778 FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` 779 FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` 780 echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" 781 exit ;; 782 5000:UNIX_System_V:4.*:*) 783 FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` 784 FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` 785 echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" 786 exit ;; 724 787 i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) 725 788 echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} 726 exit 0;;789 exit ;; 727 790 sparc*:BSD/OS:*:*) 728 791 echo sparc-unknown-bsdi${UNAME_RELEASE} 729 exit 0;;792 exit ;; 730 793 *:BSD/OS:*:*) 731 794 echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} 732 exit 0;;795 exit ;; 733 796 *:FreeBSD:*:*) 734 echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` 735 exit 0 ;; 736 *:OpenBSD:*:*) 737 echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` 738 exit 0 ;; 797 UNAME_PROCESSOR=`/usr/bin/uname -p` 798 case ${UNAME_PROCESSOR} in 799 amd64) 800 echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; 801 *) 802 echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; 803 esac 804 exit ;; 739 805 i*:CYGWIN*:*) 740 806 echo ${UNAME_MACHINE}-pc-cygwin 741 exit 0;;742 i*:MINGW*:*)807 exit ;; 808 *:MINGW*:*) 743 809 echo ${UNAME_MACHINE}-pc-mingw32 744 exit 0 ;; 810 exit ;; 811 i*:MSYS*:*) 812 echo ${UNAME_MACHINE}-pc-msys 813 exit ;; 814 i*:windows32*:*) 815 # uname -m includes "-pc" on this system. 816 echo ${UNAME_MACHINE}-mingw32 817 exit ;; 745 818 i*:PW*:*) 746 819 echo ${UNAME_MACHINE}-pc-pw32 747 exit 0 ;; 820 exit ;; 821 *:Interix*:*) 822 case ${UNAME_MACHINE} in 823 x86) 824 echo i586-pc-interix${UNAME_RELEASE} 825 exit ;; 826 authenticamd | genuineintel | EM64T) 827 echo x86_64-unknown-interix${UNAME_RELEASE} 828 exit ;; 829 IA64) 830 echo ia64-unknown-interix${UNAME_RELEASE} 831 exit ;; 832 esac ;; 833 [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) 834 echo i${UNAME_MACHINE}-pc-mks 835 exit ;; 836 8664:Windows_NT:*) 837 echo x86_64-pc-mks 838 exit ;; 748 839 i*:Windows_NT*:* | Pentium*:Windows_NT*:*) 749 840 # How do we know it's Interix rather than the generic POSIX subsystem? 750 841 # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we 751 842 # UNAME_MACHINE based on the output of uname instead of i386? 752 echo i 386-pc-interix753 exit 0;;843 echo i586-pc-interix 844 exit ;; 754 845 i*:UWIN*:*) 755 846 echo ${UNAME_MACHINE}-pc-uwin 756 exit 0 ;; 847 exit ;; 848 amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) 849 echo x86_64-unknown-cygwin 850 exit ;; 757 851 p*:CYGWIN*:*) 758 852 echo powerpcle-unknown-cygwin 759 exit 0;;853 exit ;; 760 854 prep*:SunOS:5.*:*) 761 855 echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 762 exit 0;;856 exit ;; 763 857 *:GNU:*:*) 858 # the GNU system 764 859 echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` 765 exit 0 ;; 860 exit ;; 861 *:GNU/*:*:*) 862 # other systems with GNU libc and userland 863 echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu 864 exit ;; 766 865 i*86:Minix:*:*) 767 866 echo ${UNAME_MACHINE}-pc-minix 768 exit 0;;769 a rm*:Linux:*:*)867 exit ;; 868 aarch64:Linux:*:*) 770 869 echo ${UNAME_MACHINE}-unknown-linux-gnu 771 exit 0 ;; 772 ia64:Linux:*:*) 773 echo ${UNAME_MACHINE}-unknown-linux 774 exit 0 ;; 775 m68*:Linux:*:*) 870 exit ;; 871 aarch64_be:Linux:*:*) 872 UNAME_MACHINE=aarch64_be 776 873 echo ${UNAME_MACHINE}-unknown-linux-gnu 777 exit 0 ;; 778 mips:Linux:*:*) 779 case `sed -n '/^byte/s/^.*: \(.*\) endian/\1/p' < /proc/cpuinfo` in 780 big) echo mips-unknown-linux-gnu && exit 0 ;; 781 little) echo mipsel-unknown-linux-gnu && exit 0 ;; 782 esac 783 ;; 784 ppc:Linux:*:*) 785 echo powerpc-unknown-linux-gnu 786 exit 0 ;; 787 ppc64:Linux:*:*) 788 echo powerpc64-unknown-linux-gnu 789 exit 0 ;; 874 exit ;; 790 875 alpha:Linux:*:*) 791 876 case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in … … 797 882 EV67) UNAME_MACHINE=alphaev67 ;; 798 883 EV68*) UNAME_MACHINE=alphaev68 ;; 799 800 objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null884 esac 885 objdump --private-headers /bin/sh | grep -q ld.so.1 801 886 if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi 802 887 echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} 803 exit 0 ;; 888 exit ;; 889 arm*:Linux:*:*) 890 eval $set_cc_for_build 891 if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ 892 | grep -q __ARM_EABI__ 893 then 894 echo ${UNAME_MACHINE}-unknown-linux-gnu 895 else 896 if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ 897 | grep -q __ARM_PCS_VFP 898 then 899 echo ${UNAME_MACHINE}-unknown-linux-gnueabi 900 else 901 echo ${UNAME_MACHINE}-unknown-linux-gnueabihf 902 fi 903 fi 904 exit ;; 905 avr32*:Linux:*:*) 906 echo ${UNAME_MACHINE}-unknown-linux-gnu 907 exit ;; 908 cris:Linux:*:*) 909 echo ${UNAME_MACHINE}-axis-linux-gnu 910 exit ;; 911 crisv32:Linux:*:*) 912 echo ${UNAME_MACHINE}-axis-linux-gnu 913 exit ;; 914 frv:Linux:*:*) 915 echo ${UNAME_MACHINE}-unknown-linux-gnu 916 exit ;; 917 hexagon:Linux:*:*) 918 echo ${UNAME_MACHINE}-unknown-linux-gnu 919 exit ;; 920 i*86:Linux:*:*) 921 LIBC=gnu 922 eval $set_cc_for_build 923 sed 's/^ //' << EOF >$dummy.c 924 #ifdef __dietlibc__ 925 LIBC=dietlibc 926 #endif 927 EOF 928 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` 929 echo "${UNAME_MACHINE}-pc-linux-${LIBC}" 930 exit ;; 931 ia64:Linux:*:*) 932 echo ${UNAME_MACHINE}-unknown-linux-gnu 933 exit ;; 934 m32r*:Linux:*:*) 935 echo ${UNAME_MACHINE}-unknown-linux-gnu 936 exit ;; 937 m68*:Linux:*:*) 938 echo ${UNAME_MACHINE}-unknown-linux-gnu 939 exit ;; 940 mips:Linux:*:* | mips64:Linux:*:*) 941 eval $set_cc_for_build 942 sed 's/^ //' << EOF >$dummy.c 943 #undef CPU 944 #undef ${UNAME_MACHINE} 945 #undef ${UNAME_MACHINE}el 946 #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) 947 CPU=${UNAME_MACHINE}el 948 #else 949 #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) 950 CPU=${UNAME_MACHINE} 951 #else 952 CPU= 953 #endif 954 #endif 955 EOF 956 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` 957 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } 958 ;; 959 or32:Linux:*:*) 960 echo ${UNAME_MACHINE}-unknown-linux-gnu 961 exit ;; 962 padre:Linux:*:*) 963 echo sparc-unknown-linux-gnu 964 exit ;; 965 parisc64:Linux:*:* | hppa64:Linux:*:*) 966 echo hppa64-unknown-linux-gnu 967 exit ;; 804 968 parisc:Linux:*:* | hppa:Linux:*:*) 805 969 # Look for CPU level … … 809 973 *) echo hppa-unknown-linux-gnu ;; 810 974 esac 811 exit 0 ;; 812 parisc64:Linux:*:* | hppa64:Linux:*:*) 813 echo hppa64-unknown-linux-gnu 814 exit 0 ;; 975 exit ;; 976 ppc64:Linux:*:*) 977 echo powerpc64-unknown-linux-gnu 978 exit ;; 979 ppc:Linux:*:*) 980 echo powerpc-unknown-linux-gnu 981 exit ;; 815 982 s390:Linux:*:* | s390x:Linux:*:*) 816 983 echo ${UNAME_MACHINE}-ibm-linux 817 exit 0 ;; 984 exit ;; 985 sh64*:Linux:*:*) 986 echo ${UNAME_MACHINE}-unknown-linux-gnu 987 exit ;; 818 988 sh*:Linux:*:*) 819 989 echo ${UNAME_MACHINE}-unknown-linux-gnu 820 exit 0;;990 exit ;; 821 991 sparc:Linux:*:* | sparc64:Linux:*:*) 822 992 echo ${UNAME_MACHINE}-unknown-linux-gnu 823 exit 0 ;; 993 exit ;; 994 tile*:Linux:*:*) 995 echo ${UNAME_MACHINE}-unknown-linux-gnu 996 exit ;; 997 vax:Linux:*:*) 998 echo ${UNAME_MACHINE}-dec-linux-gnu 999 exit ;; 824 1000 x86_64:Linux:*:*) 825 echo x86_64-unknown-linux-gnu 826 exit 0 ;; 827 i*86:Linux:*:*) 828 # The BFD linker knows what the default object file format is, so 829 # first see if it will tell us. cd to the root directory to prevent 830 # problems with other programs or directories called `ld' in the path. 831 ld_supported_targets=`cd /; ld --help 2>&1 \ 832 | sed -ne '/supported targets:/!d 833 s/[ ][ ]*/ /g 834 s/.*supported targets: *// 835 s/ .*// 836 p'` 837 case "$ld_supported_targets" in 838 elf32-i386) 839 TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" 840 ;; 841 a.out-i386-linux) 842 echo "${UNAME_MACHINE}-pc-linux-gnuaout" 843 exit 0 ;; 844 coff-i386) 845 echo "${UNAME_MACHINE}-pc-linux-gnucoff" 846 exit 0 ;; 847 "") 848 # Either a pre-BFD a.out linker (linux-gnuoldld) or 849 # one that does not give us useful --help. 850 echo "${UNAME_MACHINE}-pc-linux-gnuoldld" 851 exit 0 ;; 852 esac 853 # Determine whether the default compiler is a.out or elf 854 eval $set_cc_for_build 855 cat >$dummy.c <<EOF 856 #include <features.h> 857 #ifdef __cplusplus 858 #include <stdio.h> /* for printf() prototype */ 859 int main (int argc, char *argv[]) { 860 #else 861 int main (argc, argv) int argc; char *argv[]; { 862 #endif 863 #ifdef __ELF__ 864 # ifdef __GLIBC__ 865 # if __GLIBC__ >= 2 866 printf ("%s-pc-linux-gnu\n", argv[1]); 867 # else 868 printf ("%s-pc-linux-gnulibc1\n", argv[1]); 869 # endif 870 # else 871 printf ("%s-pc-linux-gnulibc1\n", argv[1]); 872 # endif 873 #else 874 printf ("%s-pc-linux-gnuaout\n", argv[1]); 875 #endif 876 return 0; 877 } 878 EOF 879 $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy "${UNAME_MACHINE}" && rm -f $dummy.c $dummy && exit 0 880 rm -f $dummy.c $dummy 881 test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0 882 ;; 1001 echo ${UNAME_MACHINE}-unknown-linux-gnu 1002 exit ;; 1003 xtensa*:Linux:*:*) 1004 echo ${UNAME_MACHINE}-unknown-linux-gnu 1005 exit ;; 883 1006 i*86:DYNIX/ptx:4*:*) 884 1007 # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. … … 886 1009 # sysname and nodename. 887 1010 echo i386-sequent-sysv4 888 exit 0;;1011 exit ;; 889 1012 i*86:UNIX_SV:4.2MP:2.*) 890 891 892 1013 # Unixware is an offshoot of SVR4, but it has its own version 1014 # number series starting with 2... 1015 # I am not positive that other SVR4 systems won't match this, 893 1016 # I just have to hope. -- rms. 894 1017 # Use sysv4.2uw... so that sysv4* matches it. 895 1018 echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} 896 exit 0 ;; 1019 exit ;; 1020 i*86:OS/2:*:*) 1021 # If we were able to find `uname', then EMX Unix compatibility 1022 # is probably installed. 1023 echo ${UNAME_MACHINE}-pc-os2-emx 1024 exit ;; 1025 i*86:XTS-300:*:STOP) 1026 echo ${UNAME_MACHINE}-unknown-stop 1027 exit ;; 1028 i*86:atheos:*:*) 1029 echo ${UNAME_MACHINE}-unknown-atheos 1030 exit ;; 1031 i*86:syllable:*:*) 1032 echo ${UNAME_MACHINE}-pc-syllable 1033 exit ;; 1034 i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) 1035 echo i386-unknown-lynxos${UNAME_RELEASE} 1036 exit ;; 1037 i*86:*DOS:*:*) 1038 echo ${UNAME_MACHINE}-pc-msdosdjgpp 1039 exit ;; 897 1040 i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) 898 1041 UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` … … 902 1045 echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} 903 1046 fi 904 exit 0 ;; 905 i*86:*:5:[78]*) 1047 exit ;; 1048 i*86:*:5:[678]*) 1049 # UnixWare 7.x, OpenUNIX and OpenServer 6. 906 1050 case `/bin/uname -X | grep "^Machine"` in 907 1051 *486*) UNAME_MACHINE=i486 ;; … … 910 1054 esac 911 1055 echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} 912 exit 0;;1056 exit ;; 913 1057 i*86:*:3.2:*) 914 1058 if test -f /usr/options/cb.name; then … … 916 1060 echo ${UNAME_MACHINE}-pc-isc$UNAME_REL 917 1061 elif /bin/uname -X 2>/dev/null >/dev/null ; then 918 UNAME_REL=`(/bin/uname -X| egrep Release|sed -e 's/.*= //')`919 (/bin/uname -X| egrep i80486 >/dev/null) && UNAME_MACHINE=i486920 (/bin/uname -X| egrep '^Machine.*Pentium' >/dev/null) \1062 UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` 1063 (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 1064 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ 921 1065 && UNAME_MACHINE=i586 922 (/bin/uname -X| egrep '^Machine.*Pent ?II' >/dev/null) \1066 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ 923 1067 && UNAME_MACHINE=i686 924 (/bin/uname -X| egrep '^Machine.*Pentium Pro' >/dev/null) \1068 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ 925 1069 && UNAME_MACHINE=i686 926 1070 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL … … 928 1072 echo ${UNAME_MACHINE}-pc-sysv32 929 1073 fi 930 exit 0 ;; 931 i*86:*DOS:*:*) 932 echo ${UNAME_MACHINE}-pc-msdosdjgpp 933 exit 0 ;; 1074 exit ;; 934 1075 pc:*:*:*) 935 1076 # Left here for compatibility: 936 # uname -m prints for DJGPP always 'pc', but it prints nothing about 937 # the processor, so we play safe by assuming i386. 938 echo i386-pc-msdosdjgpp 939 exit 0 ;; 1077 # uname -m prints for DJGPP always 'pc', but it prints nothing about 1078 # the processor, so we play safe by assuming i586. 1079 # Note: whatever this is, it MUST be the same as what config.sub 1080 # prints for the "djgpp" host, or else GDB configury will decide that 1081 # this is a cross-build. 1082 echo i586-pc-msdosdjgpp 1083 exit ;; 940 1084 Intel:Mach:3*:*) 941 1085 echo i386-pc-mach3 942 exit 0;;1086 exit ;; 943 1087 paragon:*:*:*) 944 1088 echo i860-intel-osf1 945 exit 0;;1089 exit ;; 946 1090 i860:*:4.*:*) # i860-SVR4 947 1091 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then … … 950 1094 echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 951 1095 fi 952 exit 0;;1096 exit ;; 953 1097 mini*:CTIX:SYS*5:*) 954 1098 # "miniframe" 955 1099 echo m68010-convergent-sysv 956 exit 0 ;; 957 M68*:*:R3V[567]*:*) 958 test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; 959 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*:4.0:3.0) 1100 exit ;; 1101 mc68k:UNIX:SYSTEM5:3.51m) 1102 echo m68k-convergent-sysv 1103 exit ;; 1104 M680?0:D-NIX:5.3:*) 1105 echo m68k-diab-dnix 1106 exit ;; 1107 M68*:*:R3V[5678]*:*) 1108 test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 1109 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) 960 1110 OS_REL='' 961 1111 test -r /etc/.relid \ 962 1112 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` 963 1113 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 964 && echo i486-ncr-sysv4.3${OS_REL} && exit 01114 && { echo i486-ncr-sysv4.3${OS_REL}; exit; } 965 1115 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ 966 && echo i586-ncr-sysv4.3${OS_REL} && exit 0;;1116 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 967 1117 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) 968 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 969 && echo i486-ncr-sysv4 && exit 0 ;; 1118 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 1119 && { echo i486-ncr-sysv4; exit; } ;; 1120 NCR*:*:4.2:* | MPRAS*:*:4.2:*) 1121 OS_REL='.3' 1122 test -r /etc/.relid \ 1123 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` 1124 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 1125 && { echo i486-ncr-sysv4.3${OS_REL}; exit; } 1126 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ 1127 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } 1128 /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ 1129 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 970 1130 m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) 971 1131 echo m68k-unknown-lynxos${UNAME_RELEASE} 972 exit 0;;1132 exit ;; 973 1133 mc68030:UNIX_System_V:4.*:*) 974 1134 echo m68k-atari-sysv4 975 exit 0 ;; 976 i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) 977 echo i386-unknown-lynxos${UNAME_RELEASE} 978 exit 0 ;; 1135 exit ;; 979 1136 TSUNAMI:LynxOS:2.*:*) 980 1137 echo sparc-unknown-lynxos${UNAME_RELEASE} 981 exit 0;;1138 exit ;; 982 1139 rs6000:LynxOS:2.*:*) 983 1140 echo rs6000-unknown-lynxos${UNAME_RELEASE} 984 exit 0;;985 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4. 0*:*)1141 exit ;; 1142 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) 986 1143 echo powerpc-unknown-lynxos${UNAME_RELEASE} 987 exit 0;;1144 exit ;; 988 1145 SM[BE]S:UNIX_SV:*:*) 989 1146 echo mips-dde-sysv${UNAME_RELEASE} 990 exit 0;;1147 exit ;; 991 1148 RM*:ReliantUNIX-*:*:*) 992 1149 echo mips-sni-sysv4 993 exit 0;;1150 exit ;; 994 1151 RM*:SINIX-*:*:*) 995 1152 echo mips-sni-sysv4 996 exit 0;;1153 exit ;; 997 1154 *:SINIX-*:*:*) 998 1155 if uname -p 2>/dev/null >/dev/null ; then … … 1002 1159 echo ns32k-sni-sysv 1003 1160 fi 1004 exit 0;;1005 PENTIUM:*:4.0*:*) 1006 1007 1008 exit 0;;1161 exit ;; 1162 PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort 1163 # says <Richard.M.Bartel@ccMail.Census.GOV> 1164 echo i586-unisys-sysv4 1165 exit ;; 1009 1166 *:UNIX_System_V:4*:FTX*) 1010 1167 # From Gerald Hewes <hewes@openmarket.com>. 1011 1168 # How about differentiating between stratus architectures? -djm 1012 1169 echo hppa1.1-stratus-sysv4 1013 exit 0;;1170 exit ;; 1014 1171 *:*:*:FTX*) 1015 1172 # From seanf@swdc.stratus.com. 1016 1173 echo i860-stratus-sysv4 1017 exit 0 ;; 1174 exit ;; 1175 i*86:VOS:*:*) 1176 # From Paul.Green@stratus.com. 1177 echo ${UNAME_MACHINE}-stratus-vos 1178 exit ;; 1018 1179 *:VOS:*:*) 1019 1180 # From Paul.Green@stratus.com. 1020 1181 echo hppa1.1-stratus-vos 1021 exit 0;;1182 exit ;; 1022 1183 mc68*:A/UX:*:*) 1023 1184 echo m68k-apple-aux${UNAME_RELEASE} 1024 exit 0;;1185 exit ;; 1025 1186 news*:NEWS-OS:6*:*) 1026 1187 echo mips-sony-newsos6 1027 exit 0;;1188 exit ;; 1028 1189 R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) 1029 1190 if [ -d /usr/nec ]; then 1030 1191 echo mips-nec-sysv${UNAME_RELEASE} 1031 1192 else 1032 1033 fi 1034 exit 0;;1193 echo mips-unknown-sysv${UNAME_RELEASE} 1194 fi 1195 exit ;; 1035 1196 BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. 1036 1197 echo powerpc-be-beos 1037 exit 0;;1198 exit ;; 1038 1199 BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. 1039 1200 echo powerpc-apple-beos 1040 exit 0;;1201 exit ;; 1041 1202 BePC:BeOS:*:*) # BeOS running on Intel PC compatible. 1042 1203 echo i586-pc-beos 1043 exit 0 ;; 1204 exit ;; 1205 BePC:Haiku:*:*) # Haiku running on Intel PC compatible. 1206 echo i586-pc-haiku 1207 exit ;; 1044 1208 SX-4:SUPER-UX:*:*) 1045 1209 echo sx4-nec-superux${UNAME_RELEASE} 1046 exit 0;;1210 exit ;; 1047 1211 SX-5:SUPER-UX:*:*) 1048 1212 echo sx5-nec-superux${UNAME_RELEASE} 1049 exit 0 ;; 1213 exit ;; 1214 SX-6:SUPER-UX:*:*) 1215 echo sx6-nec-superux${UNAME_RELEASE} 1216 exit ;; 1217 SX-7:SUPER-UX:*:*) 1218 echo sx7-nec-superux${UNAME_RELEASE} 1219 exit ;; 1220 SX-8:SUPER-UX:*:*) 1221 echo sx8-nec-superux${UNAME_RELEASE} 1222 exit ;; 1223 SX-8R:SUPER-UX:*:*) 1224 echo sx8r-nec-superux${UNAME_RELEASE} 1225 exit ;; 1050 1226 Power*:Rhapsody:*:*) 1051 1227 echo powerpc-apple-rhapsody${UNAME_RELEASE} 1052 exit 0;;1228 exit ;; 1053 1229 *:Rhapsody:*:*) 1054 1230 echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} 1055 exit 0;;1231 exit ;; 1056 1232 *:Darwin:*:*) 1057 echo `uname -p`-apple-darwin${UNAME_RELEASE} 1058 exit 0 ;; 1233 UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown 1234 case $UNAME_PROCESSOR in 1235 i386) 1236 eval $set_cc_for_build 1237 if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then 1238 if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ 1239 (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ 1240 grep IS_64BIT_ARCH >/dev/null 1241 then 1242 UNAME_PROCESSOR="x86_64" 1243 fi 1244 fi ;; 1245 unknown) UNAME_PROCESSOR=powerpc ;; 1246 esac 1247 echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} 1248 exit ;; 1059 1249 *:procnto*:*:* | *:QNX:[0123456789]*:*) 1060 if test "${UNAME_MACHINE}" = "x86pc"; then 1250 UNAME_PROCESSOR=`uname -p` 1251 if test "$UNAME_PROCESSOR" = "x86"; then 1252 UNAME_PROCESSOR=i386 1061 1253 UNAME_MACHINE=pc 1062 1254 fi 1063 echo `uname -p`-${UNAME_MACHINE}-nto-qnx1064 exit 0;;1255 echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} 1256 exit ;; 1065 1257 *:QNX:*:4*) 1066 1258 echo i386-pc-qnx 1067 exit 0 ;; 1068 NSR-[KW]:NONSTOP_KERNEL:*:*) 1259 exit ;; 1260 NEO-?:NONSTOP_KERNEL:*:*) 1261 echo neo-tandem-nsk${UNAME_RELEASE} 1262 exit ;; 1263 NSE-*:NONSTOP_KERNEL:*:*) 1264 echo nse-tandem-nsk${UNAME_RELEASE} 1265 exit ;; 1266 NSR-?:NONSTOP_KERNEL:*:*) 1069 1267 echo nsr-tandem-nsk${UNAME_RELEASE} 1070 exit 0;;1268 exit ;; 1071 1269 *:NonStop-UX:*:*) 1072 1270 echo mips-compaq-nonstopux 1073 exit 0;;1271 exit ;; 1074 1272 BS2000:POSIX*:*:*) 1075 1273 echo bs2000-siemens-sysv 1076 exit 0;;1274 exit ;; 1077 1275 DS/*:UNIX_System_V:*:*) 1078 1276 echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} 1079 exit 0;;1277 exit ;; 1080 1278 *:Plan9:*:*) 1081 1279 # "uname -m" is not consistent, so use $cputype instead. 386 … … 1088 1286 fi 1089 1287 echo ${UNAME_MACHINE}-unknown-plan9 1090 exit 0 ;; 1091 i*86:OS/2:*:*) 1092 # If we were able to find `uname', then EMX Unix compatibility 1093 # is probably installed. 1094 echo ${UNAME_MACHINE}-pc-os2-emx 1095 exit 0 ;; 1288 exit ;; 1096 1289 *:TOPS-10:*:*) 1097 1290 echo pdp10-unknown-tops10 1098 exit 0;;1291 exit ;; 1099 1292 *:TENEX:*:*) 1100 1293 echo pdp10-unknown-tenex 1101 exit 0;;1294 exit ;; 1102 1295 KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) 1103 1296 echo pdp10-dec-tops20 1104 exit 0;;1297 exit ;; 1105 1298 XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) 1106 1299 echo pdp10-xkl-tops20 1107 exit 0;;1300 exit ;; 1108 1301 *:TOPS-20:*:*) 1109 1302 echo pdp10-unknown-tops20 1110 exit 0;;1303 exit ;; 1111 1304 *:ITS:*:*) 1112 1305 echo pdp10-unknown-its 1113 exit 0 ;; 1114 i*86:XTS-300:*:STOP) 1115 echo ${UNAME_MACHINE}-unknown-stop 1116 exit 0 ;; 1117 i*86:atheos:*:*) 1118 echo ${UNAME_MACHINE}-unknown-atheos 1119 exit 0 ;; 1306 exit ;; 1307 SEI:*:*:SEIUX) 1308 echo mips-sei-seiux${UNAME_RELEASE} 1309 exit ;; 1310 *:DragonFly:*:*) 1311 echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` 1312 exit ;; 1313 *:*VMS:*:*) 1314 UNAME_MACHINE=`(uname -p) 2>/dev/null` 1315 case "${UNAME_MACHINE}" in 1316 A*) echo alpha-dec-vms ; exit ;; 1317 I*) echo ia64-dec-vms ; exit ;; 1318 V*) echo vax-dec-vms ; exit ;; 1319 esac ;; 1320 *:XENIX:*:SysV) 1321 echo i386-pc-xenix 1322 exit ;; 1323 i*86:skyos:*:*) 1324 echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' 1325 exit ;; 1326 i*86:rdos:*:*) 1327 echo ${UNAME_MACHINE}-pc-rdos 1328 exit ;; 1329 i*86:AROS:*:*) 1330 echo ${UNAME_MACHINE}-pc-aros 1331 exit ;; 1332 x86_64:VMkernel:*:*) 1333 echo ${UNAME_MACHINE}-unknown-esx 1334 exit ;; 1120 1335 esac 1121 1336 … … 1140 1355 printf ("m68k-sony-newsos%s\n", 1141 1356 #ifdef NEWSOS4 1142 1357 "4" 1143 1358 #else 1144 1145 #endif 1146 1359 "" 1360 #endif 1361 ); exit (0); 1147 1362 #endif 1148 1363 #endif 1149 1364 1150 1365 #if defined (__arm) && defined (__acorn) && defined (__unix) 1151 printf ("arm-acorn-riscix "); exit (0);1366 printf ("arm-acorn-riscix\n"); exit (0); 1152 1367 #endif 1153 1368 … … 1238 1453 EOF 1239 1454 1240 $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy && rm -f $dummy.c $dummy && exit 01241 rm -f $dummy.c $dummy 1455 $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && 1456 { echo "$SYSTEM_NAME"; exit; } 1242 1457 1243 1458 # Apollos put the system type in the environment. 1244 1459 1245 test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; }1460 test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } 1246 1461 1247 1462 # Convex versions that predate uname can use getsysinfo(1) … … 1252 1467 c1*) 1253 1468 echo c1-convex-bsd 1254 exit 0;;1469 exit ;; 1255 1470 c2*) 1256 1471 if getsysinfo -f scalar_acc … … 1258 1473 else echo c2-convex-bsd 1259 1474 fi 1260 exit 0;;1475 exit ;; 1261 1476 c34*) 1262 1477 echo c34-convex-bsd 1263 exit 0;;1478 exit ;; 1264 1479 c38*) 1265 1480 echo c38-convex-bsd 1266 exit 0;;1481 exit ;; 1267 1482 c4*) 1268 1483 echo c4-convex-bsd 1269 exit 0;;1484 exit ;; 1270 1485 esac 1271 1486 fi … … 1278 1493 download the most up to date version of the config scripts from 1279 1494 1280 ftp://ftp.gnu.org/pub/gnu/config/ 1495 http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD 1496 and 1497 http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD 1281 1498 1282 1499 If the version you run ($0) is already up to date, please
Note: See TracChangeset
for help on using the changeset viewer.