de8141f1b00cd57105ba60d65531803afd74edea
[openwrt/svn-archive/archive.git] / libs / jpeg / patches / jpeg-6b-config_guess.patch
1 diff -urN jpeg.old/config.guess jpeg.dev/config.guess
2 --- jpeg.old/config.guess 1998-03-25 16:25:38.000000000 +0100
3 +++ jpeg.dev/config.guess 2006-04-21 16:22:05.000000000 +0200
4 @@ -1,7 +1,10 @@
5 #! /bin/sh
6 # Attempt to guess a canonical system name.
7 -# Copyright (C) 1992, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
8 -#
9 +# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
10 +# 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
11 +
12 +timestamp='2004-11-12'
13 +
14 # This file is free software; you can redistribute it and/or modify it
15 # under the terms of the GNU General Public License as published by
16 # the Free Software Foundation; either version 2 of the License, or
17 @@ -21,125 +24,314 @@
18 # configuration script generated by Autoconf, you may include it under
19 # the same distribution terms that you use for the rest of that program.
20
21 -# Written by Per Bothner <bothner@cygnus.com>.
22 -# The master version of this file is at the FSF in /home/gd/gnu/lib.
23 +# Originally written by Per Bothner <per@bothner.com>.
24 +# Please send patches to <config-patches@gnu.org>. Submit a context
25 +# diff and a properly formatted ChangeLog entry.
26 #
27 # This script attempts to guess a canonical system name similar to
28 # config.sub. If it succeeds, it prints the system name on stdout, and
29 # exits with 0. Otherwise, it exits with 1.
30 #
31 # The plan is that this can be called by configure scripts if you
32 -# don't specify an explicit system type (host/target name).
33 -#
34 -# Only a few systems have been added to this list; please add others
35 -# (but try to keep the structure clean).
36 -#
37 +# don't specify an explicit build system type.
38 +
39 +me=`echo "$0" | sed -e 's,.*/,,'`
40 +
41 +usage="\
42 +Usage: $0 [OPTION]
43 +
44 +Output the configuration name of the system \`$me' is run on.
45 +
46 +Operation modes:
47 + -h, --help print this help, then exit
48 + -t, --time-stamp print date of last modification, then exit
49 + -v, --version print version number, then exit
50 +
51 +Report bugs and patches to <config-patches@gnu.org>."
52 +
53 +version="\
54 +GNU config.guess ($timestamp)
55 +
56 +Originally written by Per Bothner.
57 +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
58 +Free Software Foundation, Inc.
59 +
60 +This is free software; see the source for copying conditions. There is NO
61 +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
62 +
63 +help="
64 +Try \`$me --help' for more information."
65 +
66 +# Parse command line
67 +while test $# -gt 0 ; do
68 + case $1 in
69 + --time-stamp | --time* | -t )
70 + echo "$timestamp" ; exit 0 ;;
71 + --version | -v )
72 + echo "$version" ; exit 0 ;;
73 + --help | --h* | -h )
74 + echo "$usage"; exit 0 ;;
75 + -- ) # Stop option processing
76 + shift; break ;;
77 + - ) # Use stdin as input.
78 + break ;;
79 + -* )
80 + echo "$me: invalid option $1$help" >&2
81 + exit 1 ;;
82 + * )
83 + break ;;
84 + esac
85 +done
86 +
87 +if test $# != 0; then
88 + echo "$me: too many arguments$help" >&2
89 + exit 1
90 +fi
91 +
92 +trap 'exit 1' 1 2 15
93 +
94 +# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
95 +# compiler to aid in system detection is discouraged as it requires
96 +# temporary files to be created and, as you can see below, it is a
97 +# headache to deal with in a portable fashion.
98 +
99 +# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
100 +# use `HOST_CC' if defined, but it is deprecated.
101 +
102 +# Portable tmp directory creation inspired by the Autoconf team.
103 +
104 +set_cc_for_build='
105 +trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
106 +trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
107 +: ${TMPDIR=/tmp} ;
108 + { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
109 + { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
110 + { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
111 + { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
112 +dummy=$tmp/dummy ;
113 +tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
114 +case $CC_FOR_BUILD,$HOST_CC,$CC in
115 + ,,) echo "int x;" > $dummy.c ;
116 + for c in cc gcc c89 c99 ; do
117 + if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
118 + CC_FOR_BUILD="$c"; break ;
119 + fi ;
120 + done ;
121 + if test x"$CC_FOR_BUILD" = x ; then
122 + CC_FOR_BUILD=no_compiler_found ;
123 + fi
124 + ;;
125 + ,,*) CC_FOR_BUILD=$CC ;;
126 + ,*,*) CC_FOR_BUILD=$HOST_CC ;;
127 +esac ;'
128
129 # This is needed to find uname on a Pyramid OSx when run in the BSD universe.
130 -# (ghazi@noc.rutgers.edu 8/24/94.)
131 +# (ghazi@noc.rutgers.edu 1994-08-24)
132 if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
133 PATH=$PATH:/.attbin ; export PATH
134 fi
135
136 UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
137 UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
138 -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
139 +UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
140 UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
141
142 -trap 'rm -f dummy.c dummy.o dummy; exit 1' 1 2 15
143 -
144 # Note: order is significant - the case branches are not exclusive.
145
146 case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
147 + *:NetBSD:*:*)
148 + # NetBSD (nbsd) targets should (where applicable) match one or
149 + # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
150 + # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
151 + # switched to ELF, *-*-netbsd* would select the old
152 + # object file format. This provides both forward
153 + # compatibility and a consistent mechanism for selecting the
154 + # object file format.
155 + #
156 + # Note: NetBSD doesn't particularly care about the vendor
157 + # portion of the name. We always set it to "unknown".
158 + sysctl="sysctl -n hw.machine_arch"
159 + UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
160 + /usr/sbin/$sysctl 2>/dev/null || echo unknown)`
161 + case "${UNAME_MACHINE_ARCH}" in
162 + armeb) machine=armeb-unknown ;;
163 + arm*) machine=arm-unknown ;;
164 + sh3el) machine=shl-unknown ;;
165 + sh3eb) machine=sh-unknown ;;
166 + *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
167 + esac
168 + # The Operating System including object format, if it has switched
169 + # to ELF recently, or will in the future.
170 + case "${UNAME_MACHINE_ARCH}" in
171 + arm*|i386|m68k|ns32k|sh3*|sparc|vax)
172 + eval $set_cc_for_build
173 + if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
174 + | grep __ELF__ >/dev/null
175 + then
176 + # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
177 + # Return netbsd for either. FIX?
178 + os=netbsd
179 + else
180 + os=netbsdelf
181 + fi
182 + ;;
183 + *)
184 + os=netbsd
185 + ;;
186 + esac
187 + # The OS release
188 + # Debian GNU/NetBSD machines have a different userland, and
189 + # thus, need a distinct triplet. However, they do not need
190 + # kernel version information, so it can be replaced with a
191 + # suitable tag, in the style of linux-gnu.
192 + case "${UNAME_VERSION}" in
193 + Debian*)
194 + release='-gnu'
195 + ;;
196 + *)
197 + release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
198 + ;;
199 + esac
200 + # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
201 + # contains redundant information, the shorter form:
202 + # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
203 + echo "${machine}-${os}${release}"
204 + exit 0 ;;
205 + amd64:OpenBSD:*:*)
206 + echo x86_64-unknown-openbsd${UNAME_RELEASE}
207 + exit 0 ;;
208 + amiga:OpenBSD:*:*)
209 + echo m68k-unknown-openbsd${UNAME_RELEASE}
210 + exit 0 ;;
211 + cats:OpenBSD:*:*)
212 + echo arm-unknown-openbsd${UNAME_RELEASE}
213 + exit 0 ;;
214 + hp300:OpenBSD:*:*)
215 + echo m68k-unknown-openbsd${UNAME_RELEASE}
216 + exit 0 ;;
217 + luna88k:OpenBSD:*:*)
218 + echo m88k-unknown-openbsd${UNAME_RELEASE}
219 + exit 0 ;;
220 + mac68k:OpenBSD:*:*)
221 + echo m68k-unknown-openbsd${UNAME_RELEASE}
222 + exit 0 ;;
223 + macppc:OpenBSD:*:*)
224 + echo powerpc-unknown-openbsd${UNAME_RELEASE}
225 + exit 0 ;;
226 + mvme68k:OpenBSD:*:*)
227 + echo m68k-unknown-openbsd${UNAME_RELEASE}
228 + exit 0 ;;
229 + mvme88k:OpenBSD:*:*)
230 + echo m88k-unknown-openbsd${UNAME_RELEASE}
231 + exit 0 ;;
232 + mvmeppc:OpenBSD:*:*)
233 + echo powerpc-unknown-openbsd${UNAME_RELEASE}
234 + exit 0 ;;
235 + sgi:OpenBSD:*:*)
236 + echo mips64-unknown-openbsd${UNAME_RELEASE}
237 + exit 0 ;;
238 + sun3:OpenBSD:*:*)
239 + echo m68k-unknown-openbsd${UNAME_RELEASE}
240 + exit 0 ;;
241 + *:OpenBSD:*:*)
242 + echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
243 + exit 0 ;;
244 + *:ekkoBSD:*:*)
245 + echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
246 + exit 0 ;;
247 + macppc:MirBSD:*:*)
248 + echo powerppc-unknown-mirbsd${UNAME_RELEASE}
249 + exit 0 ;;
250 + *:MirBSD:*:*)
251 + echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
252 + exit 0 ;;
253 alpha:OSF1:*:*)
254 - if test $UNAME_RELEASE = "V4.0"; then
255 + case $UNAME_RELEASE in
256 + *4.0)
257 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
258 - fi
259 + ;;
260 + *5.*)
261 + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
262 + ;;
263 + esac
264 + # According to Compaq, /usr/sbin/psrinfo has been available on
265 + # OSF/1 and Tru64 systems produced since 1995. I hope that
266 + # covers most systems running today. This code pipes the CPU
267 + # types through head -n 1, so we only detect the type of CPU 0.
268 + ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
269 + case "$ALPHA_CPU_TYPE" in
270 + "EV4 (21064)")
271 + UNAME_MACHINE="alpha" ;;
272 + "EV4.5 (21064)")
273 + UNAME_MACHINE="alpha" ;;
274 + "LCA4 (21066/21068)")
275 + UNAME_MACHINE="alpha" ;;
276 + "EV5 (21164)")
277 + UNAME_MACHINE="alphaev5" ;;
278 + "EV5.6 (21164A)")
279 + UNAME_MACHINE="alphaev56" ;;
280 + "EV5.6 (21164PC)")
281 + UNAME_MACHINE="alphapca56" ;;
282 + "EV5.7 (21164PC)")
283 + UNAME_MACHINE="alphapca57" ;;
284 + "EV6 (21264)")
285 + UNAME_MACHINE="alphaev6" ;;
286 + "EV6.7 (21264A)")
287 + UNAME_MACHINE="alphaev67" ;;
288 + "EV6.8CB (21264C)")
289 + UNAME_MACHINE="alphaev68" ;;
290 + "EV6.8AL (21264B)")
291 + UNAME_MACHINE="alphaev68" ;;
292 + "EV6.8CX (21264D)")
293 + UNAME_MACHINE="alphaev68" ;;
294 + "EV6.9A (21264/EV69A)")
295 + UNAME_MACHINE="alphaev69" ;;
296 + "EV7 (21364)")
297 + UNAME_MACHINE="alphaev7" ;;
298 + "EV7.9 (21364A)")
299 + UNAME_MACHINE="alphaev79" ;;
300 + esac
301 + # A Pn.n version is a patched version.
302 # A Vn.n version is a released version.
303 # A Tn.n version is a released field test version.
304 # A Xn.n version is an unreleased experimental baselevel.
305 # 1.2 uses "1.2" for uname -r.
306 - cat <<EOF >dummy.s
307 - .globl main
308 - .ent main
309 -main:
310 - .frame \$30,0,\$26,0
311 - .prologue 0
312 - .long 0x47e03d80 # implver $0
313 - lda \$2,259
314 - .long 0x47e20c21 # amask $2,$1
315 - srl \$1,8,\$2
316 - sll \$2,2,\$2
317 - sll \$0,3,\$0
318 - addl \$1,\$0,\$0
319 - addl \$2,\$0,\$0
320 - ret \$31,(\$26),1
321 - .end main
322 -EOF
323 - ${CC-cc} dummy.s -o dummy 2>/dev/null
324 - if test "$?" = 0 ; then
325 - ./dummy
326 - case "$?" in
327 - 7)
328 - UNAME_MACHINE="alpha"
329 - ;;
330 - 15)
331 - UNAME_MACHINE="alphaev5"
332 - ;;
333 - 14)
334 - UNAME_MACHINE="alphaev56"
335 - ;;
336 - 10)
337 - UNAME_MACHINE="alphapca56"
338 - ;;
339 - 16)
340 - UNAME_MACHINE="alphaev6"
341 - ;;
342 - esac
343 - fi
344 - rm -f dummy.s dummy
345 - echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr [[A-Z]] [[a-z]]`
346 + echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
347 + exit 0 ;;
348 + Alpha\ *:Windows_NT*:*)
349 + # How do we know it's Interix rather than the generic POSIX subsystem?
350 + # Should we change UNAME_MACHINE based on the output of uname instead
351 + # of the specific Alpha model?
352 + echo alpha-pc-interix
353 exit 0 ;;
354 21064:Windows_NT:50:3)
355 echo alpha-dec-winnt3.5
356 exit 0 ;;
357 Amiga*:UNIX_System_V:4.0:*)
358 - echo m68k-cbm-sysv4
359 + echo m68k-unknown-sysv4
360 exit 0;;
361 - amiga:NetBSD:*:*)
362 - echo m68k-cbm-netbsd${UNAME_RELEASE}
363 - exit 0 ;;
364 - amiga:OpenBSD:*:*)
365 - echo m68k-unknown-openbsd${UNAME_RELEASE}
366 - exit 0 ;;
367 - arc64:OpenBSD:*:*)
368 - echo mips64el-unknown-openbsd${UNAME_RELEASE}
369 + *:[Aa]miga[Oo][Ss]:*:*)
370 + echo ${UNAME_MACHINE}-unknown-amigaos
371 exit 0 ;;
372 - arc:OpenBSD:*:*)
373 - echo mipsel-unknown-openbsd${UNAME_RELEASE}
374 + *:[Mm]orph[Oo][Ss]:*:*)
375 + echo ${UNAME_MACHINE}-unknown-morphos
376 exit 0 ;;
377 - hkmips:OpenBSD:*:*)
378 - echo mips-unknown-openbsd${UNAME_RELEASE}
379 + *:OS/390:*:*)
380 + echo i370-ibm-openedition
381 exit 0 ;;
382 - pmax:OpenBSD:*:*)
383 - echo mipsel-unknown-openbsd${UNAME_RELEASE}
384 - exit 0 ;;
385 - sgi:OpenBSD:*:*)
386 - echo mips-unknown-openbsd${UNAME_RELEASE}
387 + *:z/VM:*:*)
388 + echo s390-ibm-zvmoe
389 exit 0 ;;
390 - wgrisc:OpenBSD:*:*)
391 - echo mipsel-unknown-openbsd${UNAME_RELEASE}
392 + *:OS400:*:*)
393 + echo powerpc-ibm-os400
394 exit 0 ;;
395 arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
396 echo arm-acorn-riscix${UNAME_RELEASE}
397 exit 0;;
398 - arm32:NetBSD:*:*)
399 - echo arm-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
400 - exit 0 ;;
401 - SR2?01:HI-UX/MPP:*:*)
402 + SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
403 echo hppa1.1-hitachi-hiuxmpp
404 exit 0;;
405 - Pyramid*:OSx*:*:*|MIS*:OSx*:*:*)
406 + Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
407 # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
408 if test "`(/bin/universe) 2>/dev/null`" = att ; then
409 echo pyramid-pyramid-sysv3
410 @@ -147,9 +339,19 @@
411 echo pyramid-pyramid-bsd
412 fi
413 exit 0 ;;
414 - NILE:*:*:dcosx)
415 + NILE*:*:*:dcosx)
416 echo pyramid-pyramid-svr4
417 exit 0 ;;
418 + DRS?6000:unix:4.0:6*)
419 + echo sparc-icl-nx6
420 + exit 0 ;;
421 + DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
422 + case `/usr/bin/uname -p` in
423 + sparc) echo sparc-icl-nx7 && exit 0 ;;
424 + esac ;;
425 + sun4H:SunOS:5.*:*)
426 + echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
427 + exit 0 ;;
428 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
429 echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
430 exit 0 ;;
431 @@ -175,7 +377,7 @@
432 echo m68k-sun-sunos${UNAME_RELEASE}
433 exit 0 ;;
434 sun*:*:4.2BSD:*)
435 - UNAME_RELEASE=`(head -1 /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
436 + UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
437 test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
438 case "`/bin/arch`" in
439 sun3)
440 @@ -189,29 +391,34 @@
441 aushp:SunOS:*:*)
442 echo sparc-auspex-sunos${UNAME_RELEASE}
443 exit 0 ;;
444 - atari*:NetBSD:*:*)
445 - echo m68k-atari-netbsd${UNAME_RELEASE}
446 + # The situation for MiNT is a little confusing. The machine name
447 + # can be virtually everything (everything which is not
448 + # "atarist" or "atariste" at least should have a processor
449 + # > m68000). The system name ranges from "MiNT" over "FreeMiNT"
450 + # to the lowercase version "mint" (or "freemint"). Finally
451 + # the system name "TOS" denotes a system which is actually not
452 + # MiNT. But MiNT is downward compatible to TOS, so this should
453 + # be no problem.
454 + atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
455 + echo m68k-atari-mint${UNAME_RELEASE}
456 exit 0 ;;
457 - atari*:OpenBSD:*:*)
458 - echo m68k-unknown-openbsd${UNAME_RELEASE}
459 - exit 0 ;;
460 - sun3*:NetBSD:*:*)
461 - echo m68k-sun-netbsd${UNAME_RELEASE}
462 - exit 0 ;;
463 - sun3*:OpenBSD:*:*)
464 - echo m68k-unknown-openbsd${UNAME_RELEASE}
465 - exit 0 ;;
466 - mac68k:NetBSD:*:*)
467 - echo m68k-apple-netbsd${UNAME_RELEASE}
468 - exit 0 ;;
469 - mac68k:OpenBSD:*:*)
470 - echo m68k-unknown-openbsd${UNAME_RELEASE}
471 - exit 0 ;;
472 - mvme68k:OpenBSD:*:*)
473 - echo m68k-unknown-openbsd${UNAME_RELEASE}
474 + atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
475 + echo m68k-atari-mint${UNAME_RELEASE}
476 + exit 0 ;;
477 + *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
478 + echo m68k-atari-mint${UNAME_RELEASE}
479 exit 0 ;;
480 - mvme88k:OpenBSD:*:*)
481 - echo m88k-unknown-openbsd${UNAME_RELEASE}
482 + milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
483 + echo m68k-milan-mint${UNAME_RELEASE}
484 + exit 0 ;;
485 + hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
486 + echo m68k-hades-mint${UNAME_RELEASE}
487 + exit 0 ;;
488 + *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
489 + echo m68k-unknown-mint${UNAME_RELEASE}
490 + exit 0 ;;
491 + m68k:machten:*:*)
492 + echo m68k-apple-machten${UNAME_RELEASE}
493 exit 0 ;;
494 powerpc:machten:*:*)
495 echo powerpc-apple-machten${UNAME_RELEASE}
496 @@ -225,12 +432,18 @@
497 VAX*:ULTRIX*:*:*)
498 echo vax-dec-ultrix${UNAME_RELEASE}
499 exit 0 ;;
500 - 2020:CLIX:*:*)
501 + 2020:CLIX:*:* | 2430:CLIX:*:*)
502 echo clipper-intergraph-clix${UNAME_RELEASE}
503 exit 0 ;;
504 mips:*:*:UMIPS | mips:*:*:RISCos)
505 - sed 's/^ //' << EOF >dummy.c
506 - int main (argc, argv) int argc; char **argv; {
507 + eval $set_cc_for_build
508 + sed 's/^ //' << EOF >$dummy.c
509 +#ifdef __cplusplus
510 +#include <stdio.h> /* for printf() prototype */
511 + int main (int argc, char *argv[]) {
512 +#else
513 + int main (argc, argv) int argc; char *argv[]; {
514 +#endif
515 #if defined (host_mips) && defined (MIPSEB)
516 #if defined (SYSTYPE_SYSV)
517 printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
518 @@ -245,12 +458,20 @@
519 exit (-1);
520 }
521 EOF
522 - ${CC-cc} dummy.c -o dummy \
523 - && ./dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
524 - && rm dummy.c dummy && exit 0
525 - rm -f dummy.c dummy
526 + $CC_FOR_BUILD -o $dummy $dummy.c \
527 + && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
528 + && exit 0
529 echo mips-mips-riscos${UNAME_RELEASE}
530 exit 0 ;;
531 + Motorola:PowerMAX_OS:*:*)
532 + echo powerpc-motorola-powermax
533 + exit 0 ;;
534 + Motorola:*:4.3:PL8-*)
535 + echo powerpc-harris-powermax
536 + exit 0 ;;
537 + Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
538 + echo powerpc-harris-powermax
539 + exit 0 ;;
540 Night_Hawk:Power_UNIX:*:*)
541 echo powerpc-harris-powerunix
542 exit 0 ;;
543 @@ -266,15 +487,18 @@
544 AViiON:dgux:*:*)
545 # DG/UX returns AViiON for all architectures
546 UNAME_PROCESSOR=`/usr/bin/uname -p`
547 - if [ $UNAME_PROCESSOR = mc88100 -o $UNAME_PROCESSOR = mc88110 ] ; then
548 - if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx \
549 - -o ${TARGET_BINARY_INTERFACE}x = x ] ; then
550 + if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
551 + then
552 + if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
553 + [ ${TARGET_BINARY_INTERFACE}x = x ]
554 + then
555 echo m88k-dg-dgux${UNAME_RELEASE}
556 - else
557 + else
558 echo m88k-dg-dguxbcs${UNAME_RELEASE}
559 + fi
560 + else
561 + echo i586-dg-dgux${UNAME_RELEASE}
562 fi
563 - else echo i586-dg-dgux${UNAME_RELEASE}
564 - fi
565 exit 0 ;;
566 M88*:DolphinOS:*:*) # DolphinOS (SVR3)
567 echo m88k-dolphin-sysv3
568 @@ -295,12 +519,21 @@
569 ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
570 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
571 exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX '
572 - i?86:AIX:*:*)
573 + i*86:AIX:*:*)
574 echo i386-ibm-aix
575 exit 0 ;;
576 + ia64:AIX:*:*)
577 + if [ -x /usr/bin/oslevel ] ; then
578 + IBM_REV=`/usr/bin/oslevel`
579 + else
580 + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
581 + fi
582 + echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
583 + exit 0 ;;
584 *:AIX:2:3)
585 if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
586 - sed 's/^ //' << EOF >dummy.c
587 + eval $set_cc_for_build
588 + sed 's/^ //' << EOF >$dummy.c
589 #include <sys/systemcfg.h>
590
591 main()
592 @@ -311,8 +544,7 @@
593 exit(0);
594 }
595 EOF
596 - ${CC-cc} dummy.c -o dummy && ./dummy && rm dummy.c dummy && exit 0
597 - rm -f dummy.c dummy
598 + $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
599 echo rs6000-ibm-aix3.2.5
600 elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
601 echo rs6000-ibm-aix3.2.4
602 @@ -320,8 +552,9 @@
603 echo rs6000-ibm-aix3.2
604 fi
605 exit 0 ;;
606 - *:AIX:*:4)
607 - if /usr/sbin/lsattr -EHl proc0 | grep POWER >/dev/null 2>&1; then
608 + *:AIX:*:[45])
609 + IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
610 + if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
611 IBM_ARCH=rs6000
612 else
613 IBM_ARCH=powerpc
614 @@ -329,7 +562,7 @@
615 if [ -x /usr/bin/oslevel ] ; then
616 IBM_REV=`/usr/bin/oslevel`
617 else
618 - IBM_REV=4.${UNAME_RELEASE}
619 + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
620 fi
621 echo ${IBM_ARCH}-ibm-aix${IBM_REV}
622 exit 0 ;;
623 @@ -339,7 +572,7 @@
624 ibmrt:4.4BSD:*|romp-ibm:BSD:*)
625 echo romp-ibm-bsd4.4
626 exit 0 ;;
627 - ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC NetBSD and
628 + ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
629 echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
630 exit 0 ;; # report: romp-ibm BSD 4.3
631 *:BOSX:*:*)
632 @@ -354,18 +587,85 @@
633 hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
634 echo m68k-hp-bsd4.4
635 exit 0 ;;
636 - 9000/[3478]??:HP-UX:*:*)
637 + 9000/[34678]??:HP-UX:*:*)
638 + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
639 case "${UNAME_MACHINE}" in
640 9000/31? ) HP_ARCH=m68000 ;;
641 9000/[34]?? ) HP_ARCH=m68k ;;
642 - 9000/7?? | 9000/8?[1679] ) HP_ARCH=hppa1.1 ;;
643 - 9000/8?? ) HP_ARCH=hppa1.0 ;;
644 + 9000/[678][0-9][0-9])
645 + if [ -x /usr/bin/getconf ]; then
646 + sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
647 + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
648 + case "${sc_cpu_version}" in
649 + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
650 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
651 + 532) # CPU_PA_RISC2_0
652 + case "${sc_kernel_bits}" in
653 + 32) HP_ARCH="hppa2.0n" ;;
654 + 64) HP_ARCH="hppa2.0w" ;;
655 + '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
656 + esac ;;
657 + esac
658 + fi
659 + if [ "${HP_ARCH}" = "" ]; then
660 + eval $set_cc_for_build
661 + sed 's/^ //' << EOF >$dummy.c
662 +
663 + #define _HPUX_SOURCE
664 + #include <stdlib.h>
665 + #include <unistd.h>
666 +
667 + int main ()
668 + {
669 + #if defined(_SC_KERNEL_BITS)
670 + long bits = sysconf(_SC_KERNEL_BITS);
671 + #endif
672 + long cpu = sysconf (_SC_CPU_VERSION);
673 +
674 + switch (cpu)
675 + {
676 + case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
677 + case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
678 + case CPU_PA_RISC2_0:
679 + #if defined(_SC_KERNEL_BITS)
680 + switch (bits)
681 + {
682 + case 64: puts ("hppa2.0w"); break;
683 + case 32: puts ("hppa2.0n"); break;
684 + default: puts ("hppa2.0"); break;
685 + } break;
686 + #else /* !defined(_SC_KERNEL_BITS) */
687 + puts ("hppa2.0"); break;
688 + #endif
689 + default: puts ("hppa1.0"); break;
690 + }
691 + exit (0);
692 + }
693 +EOF
694 + (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
695 + test -z "$HP_ARCH" && HP_ARCH=hppa
696 + fi ;;
697 esac
698 - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
699 + if [ ${HP_ARCH} = "hppa2.0w" ]
700 + then
701 + # avoid double evaluation of $set_cc_for_build
702 + test -n "$CC_FOR_BUILD" || eval $set_cc_for_build
703 + if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E -) | grep __LP64__ >/dev/null
704 + then
705 + HP_ARCH="hppa2.0w"
706 + else
707 + HP_ARCH="hppa64"
708 + fi
709 + fi
710 echo ${HP_ARCH}-hp-hpux${HPUX_REV}
711 exit 0 ;;
712 + ia64:HP-UX:*:*)
713 + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
714 + echo ia64-hp-hpux${HPUX_REV}
715 + exit 0 ;;
716 3050*:HI-UX:*:*)
717 - sed 's/^ //' << EOF >dummy.c
718 + eval $set_cc_for_build
719 + sed 's/^ //' << EOF >$dummy.c
720 #include <unistd.h>
721 int
722 main ()
723 @@ -390,8 +690,7 @@
724 exit (0);
725 }
726 EOF
727 - ${CC-cc} dummy.c -o dummy && ./dummy && rm dummy.c dummy && exit 0
728 - rm -f dummy.c dummy
729 + $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
730 echo unknown-hitachi-hiuxwe2
731 exit 0 ;;
732 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
733 @@ -400,13 +699,16 @@
734 9000/8??:4.3bsd:*:*)
735 echo hppa1.0-hp-bsd
736 exit 0 ;;
737 + *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
738 + echo hppa1.0-hp-mpeix
739 + exit 0 ;;
740 hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
741 echo hppa1.1-hp-osf
742 exit 0 ;;
743 hp8??:OSF1:*:*)
744 echo hppa1.0-hp-osf
745 exit 0 ;;
746 - i?86:OSF1:*:*)
747 + i*86:OSF1:*:*)
748 if [ -x /usr/sbin/sysversion ] ; then
749 echo ${UNAME_MACHINE}-unknown-osf1mk
750 else
751 @@ -434,196 +736,259 @@
752 C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
753 echo c4-convex-bsd
754 exit 0 ;;
755 - CRAY*X-MP:*:*:*)
756 - echo xmp-cray-unicos
757 - exit 0 ;;
758 CRAY*Y-MP:*:*:*)
759 - echo ymp-cray-unicos${UNAME_RELEASE}
760 + echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
761 exit 0 ;;
762 CRAY*[A-Z]90:*:*:*)
763 echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
764 | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
765 - -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/
766 + -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
767 + -e 's/\.[^.]*$/.X/'
768 exit 0 ;;
769 CRAY*TS:*:*:*)
770 - echo t90-cray-unicos${UNAME_RELEASE}
771 + echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
772 exit 0 ;;
773 - CRAY-2:*:*:*)
774 - echo cray2-cray-unicos
775 - exit 0 ;;
776 - F300:UNIX_System_V:*:*)
777 - FUJITSU_SYS=`uname -p | tr [A-Z] [a-z] | sed -e 's/\///'`
778 + CRAY*T3E:*:*:*)
779 + echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
780 + exit 0 ;;
781 + CRAY*SV1:*:*:*)
782 + echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
783 + exit 0 ;;
784 + *:UNICOS/mp:*:*)
785 + echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
786 + exit 0 ;;
787 + F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
788 + FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
789 + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
790 FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
791 - echo "f300-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
792 + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
793 exit 0 ;;
794 - F301:UNIX_System_V:*:*)
795 - echo f301-fujitsu-uxpv`echo $UNAME_RELEASE | sed 's/ .*//'`
796 - exit 0 ;;
797 - hp3[0-9][05]:NetBSD:*:*)
798 - echo m68k-hp-netbsd${UNAME_RELEASE}
799 + 5000:UNIX_System_V:4.*:*)
800 + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
801 + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
802 + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
803 exit 0 ;;
804 - hp300:OpenBSD:*:*)
805 - echo m68k-unknown-openbsd${UNAME_RELEASE}
806 - exit 0 ;;
807 - i?86:BSD/386:*:* | *:BSD/OS:*:*)
808 + i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
809 echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
810 exit 0 ;;
811 - *:FreeBSD:*:*)
812 - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
813 + sparc*:BSD/OS:*:*)
814 + echo sparc-unknown-bsdi${UNAME_RELEASE}
815 exit 0 ;;
816 - *:NetBSD:*:*)
817 - echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
818 + *:BSD/OS:*:*)
819 + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
820 exit 0 ;;
821 - *:OpenBSD:*:*)
822 - echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
823 + *:FreeBSD:*:*)
824 + echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
825 exit 0 ;;
826 i*:CYGWIN*:*)
827 - echo i386-pc-cygwin32
828 + echo ${UNAME_MACHINE}-pc-cygwin
829 exit 0 ;;
830 i*:MINGW*:*)
831 - echo i386-pc-mingw32
832 + echo ${UNAME_MACHINE}-pc-mingw32
833 + exit 0 ;;
834 + i*:PW*:*)
835 + echo ${UNAME_MACHINE}-pc-pw32
836 + exit 0 ;;
837 + x86:Interix*:[34]*)
838 + echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//'
839 + exit 0 ;;
840 + [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
841 + echo i${UNAME_MACHINE}-pc-mks
842 + exit 0 ;;
843 + i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
844 + # How do we know it's Interix rather than the generic POSIX subsystem?
845 + # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
846 + # UNAME_MACHINE based on the output of uname instead of i386?
847 + echo i586-pc-interix
848 + exit 0 ;;
849 + i*:UWIN*:*)
850 + echo ${UNAME_MACHINE}-pc-uwin
851 exit 0 ;;
852 p*:CYGWIN*:*)
853 - echo powerpcle-unknown-cygwin32
854 + echo powerpcle-unknown-cygwin
855 exit 0 ;;
856 prep*:SunOS:5.*:*)
857 echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
858 exit 0 ;;
859 *:GNU:*:*)
860 + # the GNU system
861 echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
862 exit 0 ;;
863 - *:Linux:*:*)
864 + *:GNU/*:*:*)
865 + # other systems with GNU libc and userland
866 + echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
867 + exit 0 ;;
868 + i*86:Minix:*:*)
869 + echo ${UNAME_MACHINE}-pc-minix
870 + exit 0 ;;
871 + arm*:Linux:*:*)
872 + echo ${UNAME_MACHINE}-unknown-linux-gnu
873 + exit 0 ;;
874 + cris:Linux:*:*)
875 + echo cris-axis-linux-gnu
876 + exit 0 ;;
877 + crisv32:Linux:*:*)
878 + echo crisv32-axis-linux-gnu
879 + exit 0 ;;
880 + frv:Linux:*:*)
881 + echo frv-unknown-linux-gnu
882 + exit 0 ;;
883 + ia64:Linux:*:*)
884 + echo ${UNAME_MACHINE}-unknown-linux-gnu
885 + exit 0 ;;
886 + m32r*:Linux:*:*)
887 + echo ${UNAME_MACHINE}-unknown-linux-gnu
888 + exit 0 ;;
889 + m68*:Linux:*:*)
890 + echo ${UNAME_MACHINE}-unknown-linux-gnu
891 + exit 0 ;;
892 + mips:Linux:*:*)
893 + eval $set_cc_for_build
894 + sed 's/^ //' << EOF >$dummy.c
895 + #undef CPU
896 + #undef mips
897 + #undef mipsel
898 + #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
899 + CPU=mipsel
900 + #else
901 + #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
902 + CPU=mips
903 + #else
904 + CPU=
905 + #endif
906 + #endif
907 +EOF
908 + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
909 + test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
910 + ;;
911 + mips64:Linux:*:*)
912 + eval $set_cc_for_build
913 + sed 's/^ //' << EOF >$dummy.c
914 + #undef CPU
915 + #undef mips64
916 + #undef mips64el
917 + #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
918 + CPU=mips64el
919 + #else
920 + #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
921 + CPU=mips64
922 + #else
923 + CPU=
924 + #endif
925 + #endif
926 +EOF
927 + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
928 + test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
929 + ;;
930 + ppc:Linux:*:*)
931 + echo powerpc-unknown-linux-gnu
932 + exit 0 ;;
933 + ppc64:Linux:*:*)
934 + echo powerpc64-unknown-linux-gnu
935 + exit 0 ;;
936 + alpha:Linux:*:*)
937 + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
938 + EV5) UNAME_MACHINE=alphaev5 ;;
939 + EV56) UNAME_MACHINE=alphaev56 ;;
940 + PCA56) UNAME_MACHINE=alphapca56 ;;
941 + PCA57) UNAME_MACHINE=alphapca56 ;;
942 + EV6) UNAME_MACHINE=alphaev6 ;;
943 + EV67) UNAME_MACHINE=alphaev67 ;;
944 + EV68*) UNAME_MACHINE=alphaev68 ;;
945 + esac
946 + objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
947 + if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
948 + echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
949 + exit 0 ;;
950 + parisc:Linux:*:* | hppa:Linux:*:*)
951 + # Look for CPU level
952 + case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
953 + PA7*) echo hppa1.1-unknown-linux-gnu ;;
954 + PA8*) echo hppa2.0-unknown-linux-gnu ;;
955 + *) echo hppa-unknown-linux-gnu ;;
956 + esac
957 + exit 0 ;;
958 + parisc64:Linux:*:* | hppa64:Linux:*:*)
959 + echo hppa64-unknown-linux-gnu
960 + exit 0 ;;
961 + s390:Linux:*:* | s390x:Linux:*:*)
962 + echo ${UNAME_MACHINE}-ibm-linux
963 + exit 0 ;;
964 + sh64*:Linux:*:*)
965 + echo ${UNAME_MACHINE}-unknown-linux-gnu
966 + exit 0 ;;
967 + sh*:Linux:*:*)
968 + echo ${UNAME_MACHINE}-unknown-linux-gnu
969 + exit 0 ;;
970 + sparc:Linux:*:* | sparc64:Linux:*:*)
971 + echo ${UNAME_MACHINE}-unknown-linux-gnu
972 + exit 0 ;;
973 + x86_64:Linux:*:*)
974 + echo x86_64-unknown-linux-gnu
975 + exit 0 ;;
976 + i*86:Linux:*:*)
977 # The BFD linker knows what the default object file format is, so
978 - # first see if it will tell us.
979 - ld_help_string=`ld --help 2>&1`
980 - ld_supported_emulations=`echo $ld_help_string \
981 - | sed -ne '/supported emulations:/!d
982 + # first see if it will tell us. cd to the root directory to prevent
983 + # problems with other programs or directories called `ld' in the path.
984 + # Set LC_ALL=C to ensure ld outputs messages in English.
985 + ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
986 + | sed -ne '/supported targets:/!d
987 s/[ ][ ]*/ /g
988 - s/.*supported emulations: *//
989 + s/.*supported targets: *//
990 s/ .*//
991 p'`
992 - case "$ld_supported_emulations" in
993 - i?86linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" ; exit 0 ;;
994 - i?86coff) echo "${UNAME_MACHINE}-pc-linux-gnucoff" ; exit 0 ;;
995 - sparclinux) echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0 ;;
996 - m68klinux) echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0 ;;
997 - elf32ppc) echo "powerpc-unknown-linux-gnu" ; exit 0 ;;
998 - esac
999 -
1000 - if test "${UNAME_MACHINE}" = "alpha" ; then
1001 - sed 's/^ //' <<EOF >dummy.s
1002 - .globl main
1003 - .ent main
1004 - main:
1005 - .frame \$30,0,\$26,0
1006 - .prologue 0
1007 - .long 0x47e03d80 # implver $0
1008 - lda \$2,259
1009 - .long 0x47e20c21 # amask $2,$1
1010 - srl \$1,8,\$2
1011 - sll \$2,2,\$2
1012 - sll \$0,3,\$0
1013 - addl \$1,\$0,\$0
1014 - addl \$2,\$0,\$0
1015 - ret \$31,(\$26),1
1016 - .end main
1017 -EOF
1018 - LIBC=""
1019 - ${CC-cc} dummy.s -o dummy 2>/dev/null
1020 - if test "$?" = 0 ; then
1021 - ./dummy
1022 - case "$?" in
1023 - 7)
1024 - UNAME_MACHINE="alpha"
1025 - ;;
1026 - 15)
1027 - UNAME_MACHINE="alphaev5"
1028 - ;;
1029 - 14)
1030 - UNAME_MACHINE="alphaev56"
1031 - ;;
1032 - 10)
1033 - UNAME_MACHINE="alphapca56"
1034 - ;;
1035 - 16)
1036 - UNAME_MACHINE="alphaev6"
1037 - ;;
1038 - esac
1039 -
1040 - objdump --private-headers dummy | \
1041 - grep ld.so.1 > /dev/null
1042 - if test "$?" = 0 ; then
1043 - LIBC="libc1"
1044 - fi
1045 - fi
1046 - rm -f dummy.s dummy
1047 - echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} ; exit 0
1048 - elif test "${UNAME_MACHINE}" = "mips" ; then
1049 - cat >dummy.c <<EOF
1050 -main(argc, argv)
1051 - int argc;
1052 - char *argv[];
1053 -{
1054 -#ifdef __MIPSEB__
1055 - printf ("%s-unknown-linux-gnu\n", argv[1]);
1056 -#endif
1057 -#ifdef __MIPSEL__
1058 - printf ("%sel-unknown-linux-gnu\n", argv[1]);
1059 -#endif
1060 - return 0;
1061 -}
1062 -EOF
1063 - ${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy "${UNAME_MACHINE}" && rm dummy.c dummy && exit 0
1064 - rm -f dummy.c dummy
1065 - else
1066 - # Either a pre-BFD a.out linker (linux-gnuoldld)
1067 - # or one that does not give us useful --help.
1068 - # GCC wants to distinguish between linux-gnuoldld and linux-gnuaout.
1069 - # If ld does not provide *any* "supported emulations:"
1070 - # that means it is gnuoldld.
1071 - echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations:"
1072 - test $? != 0 && echo "${UNAME_MACHINE}-pc-linux-gnuoldld" && exit 0
1073 -
1074 - case "${UNAME_MACHINE}" in
1075 - i?86)
1076 - VENDOR=pc;
1077 - ;;
1078 - *)
1079 - VENDOR=unknown;
1080 - ;;
1081 - esac
1082 - # Determine whether the default compiler is a.out or elf
1083 - cat >dummy.c <<EOF
1084 -#include <features.h>
1085 -main(argc, argv)
1086 - int argc;
1087 - char *argv[];
1088 -{
1089 -#ifdef __ELF__
1090 -# ifdef __GLIBC__
1091 -# if __GLIBC__ >= 2
1092 - printf ("%s-${VENDOR}-linux-gnu\n", argv[1]);
1093 -# else
1094 - printf ("%s-${VENDOR}-linux-gnulibc1\n", argv[1]);
1095 -# endif
1096 -# else
1097 - printf ("%s-${VENDOR}-linux-gnulibc1\n", argv[1]);
1098 -# endif
1099 -#else
1100 - printf ("%s-${VENDOR}-linux-gnuaout\n", argv[1]);
1101 -#endif
1102 - return 0;
1103 -}
1104 + case "$ld_supported_targets" in
1105 + elf32-i386)
1106 + TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
1107 + ;;
1108 + a.out-i386-linux)
1109 + echo "${UNAME_MACHINE}-pc-linux-gnuaout"
1110 + exit 0 ;;
1111 + coff-i386)
1112 + echo "${UNAME_MACHINE}-pc-linux-gnucoff"
1113 + exit 0 ;;
1114 + "")
1115 + # Either a pre-BFD a.out linker (linux-gnuoldld) or
1116 + # one that does not give us useful --help.
1117 + echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
1118 + exit 0 ;;
1119 + esac
1120 + # Determine whether the default compiler is a.out or elf
1121 + eval $set_cc_for_build
1122 + sed 's/^ //' << EOF >$dummy.c
1123 + #include <features.h>
1124 + #ifdef __ELF__
1125 + # ifdef __GLIBC__
1126 + # if __GLIBC__ >= 2
1127 + LIBC=gnu
1128 + # else
1129 + LIBC=gnulibc1
1130 + # endif
1131 + # else
1132 + LIBC=gnulibc1
1133 + # endif
1134 + #else
1135 + #ifdef __INTEL_COMPILER
1136 + LIBC=gnu
1137 + #else
1138 + LIBC=gnuaout
1139 + #endif
1140 + #endif
1141 + #ifdef __dietlibc__
1142 + LIBC=dietlibc
1143 + #endif
1144 EOF
1145 - ${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy "${UNAME_MACHINE}" && rm dummy.c dummy && exit 0
1146 - rm -f dummy.c dummy
1147 - fi ;;
1148 -# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. earlier versions
1149 -# are messed up and put the nodename in both sysname and nodename.
1150 - i?86:DYNIX/ptx:4*:*)
1151 + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
1152 + test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
1153 + test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
1154 + ;;
1155 + i*86:DYNIX/ptx:4*:*)
1156 + # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
1157 + # earlier versions are messed up and put the nodename in both
1158 + # sysname and nodename.
1159 echo i386-sequent-sysv4
1160 exit 0 ;;
1161 - i?86:UNIX_SV:4.2MP:2.*)
1162 + i*86:UNIX_SV:4.2MP:2.*)
1163 # Unixware is an offshoot of SVR4, but it has its own version
1164 # number series starting with 2...
1165 # I am not positive that other SVR4 systems won't match this,
1166 @@ -631,28 +996,62 @@
1167 # Use sysv4.2uw... so that sysv4* matches it.
1168 echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
1169 exit 0 ;;
1170 - i?86:*:4.*:* | i?86:SYSTEM_V:4.*:*)
1171 + i*86:OS/2:*:*)
1172 + # If we were able to find `uname', then EMX Unix compatibility
1173 + # is probably installed.
1174 + echo ${UNAME_MACHINE}-pc-os2-emx
1175 + exit 0 ;;
1176 + i*86:XTS-300:*:STOP)
1177 + echo ${UNAME_MACHINE}-unknown-stop
1178 + exit 0 ;;
1179 + i*86:atheos:*:*)
1180 + echo ${UNAME_MACHINE}-unknown-atheos
1181 + exit 0 ;;
1182 + i*86:syllable:*:*)
1183 + echo ${UNAME_MACHINE}-pc-syllable
1184 + exit 0 ;;
1185 + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
1186 + echo i386-unknown-lynxos${UNAME_RELEASE}
1187 + exit 0 ;;
1188 + i*86:*DOS:*:*)
1189 + echo ${UNAME_MACHINE}-pc-msdosdjgpp
1190 + exit 0 ;;
1191 + i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
1192 + UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
1193 if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
1194 - echo ${UNAME_MACHINE}-univel-sysv${UNAME_RELEASE}
1195 + echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
1196 else
1197 - echo ${UNAME_MACHINE}-pc-sysv${UNAME_RELEASE}
1198 + echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
1199 fi
1200 exit 0 ;;
1201 - i?86:*:3.2:*)
1202 + i*86:*:5:[78]*)
1203 + case `/bin/uname -X | grep "^Machine"` in
1204 + *486*) UNAME_MACHINE=i486 ;;
1205 + *Pentium) UNAME_MACHINE=i586 ;;
1206 + *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
1207 + esac
1208 + echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
1209 + exit 0 ;;
1210 + i*86:*:3.2:*)
1211 if test -f /usr/options/cb.name; then
1212 UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
1213 echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
1214 elif /bin/uname -X 2>/dev/null >/dev/null ; then
1215 - UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
1216 - (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
1217 - (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
1218 + UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
1219 + (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
1220 + (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
1221 && UNAME_MACHINE=i586
1222 + (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
1223 + && UNAME_MACHINE=i686
1224 + (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
1225 + && UNAME_MACHINE=i686
1226 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
1227 else
1228 echo ${UNAME_MACHINE}-pc-sysv32
1229 fi
1230 exit 0 ;;
1231 pc:*:*:*)
1232 + # Left here for compatibility:
1233 # uname -m prints for DJGPP always 'pc', but it prints nothing about
1234 # the processor, so we play safe by assuming i386.
1235 echo i386-pc-msdosdjgpp
1236 @@ -674,9 +1073,15 @@
1237 # "miniframe"
1238 echo m68010-convergent-sysv
1239 exit 0 ;;
1240 - M68*:*:R3V[567]*:*)
1241 + mc68k:UNIX:SYSTEM5:3.51m)
1242 + echo m68k-convergent-sysv
1243 + exit 0 ;;
1244 + M680?0:D-NIX:5.3:*)
1245 + echo m68k-diab-dnix
1246 + exit 0 ;;
1247 + M68*:*:R3V[5678]*:*)
1248 test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
1249 - 3[34]??:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*:4.0:3.0)
1250 + 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)
1251 OS_REL=''
1252 test -r /etc/.relid \
1253 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
1254 @@ -687,24 +1092,27 @@
1255 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
1256 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1257 && echo i486-ncr-sysv4 && exit 0 ;;
1258 - m68*:LynxOS:2.*:*)
1259 + m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
1260 echo m68k-unknown-lynxos${UNAME_RELEASE}
1261 exit 0 ;;
1262 mc68030:UNIX_System_V:4.*:*)
1263 echo m68k-atari-sysv4
1264 exit 0 ;;
1265 - i?86:LynxOS:2.*:*)
1266 - echo i386-unknown-lynxos${UNAME_RELEASE}
1267 - exit 0 ;;
1268 TSUNAMI:LynxOS:2.*:*)
1269 echo sparc-unknown-lynxos${UNAME_RELEASE}
1270 exit 0 ;;
1271 - rs6000:LynxOS:2.*:* | PowerPC:LynxOS:2.*:*)
1272 + rs6000:LynxOS:2.*:*)
1273 echo rs6000-unknown-lynxos${UNAME_RELEASE}
1274 exit 0 ;;
1275 + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
1276 + echo powerpc-unknown-lynxos${UNAME_RELEASE}
1277 + exit 0 ;;
1278 SM[BE]S:UNIX_SV:*:*)
1279 echo mips-dde-sysv${UNAME_RELEASE}
1280 exit 0 ;;
1281 + RM*:ReliantUNIX-*:*:*)
1282 + echo mips-sni-sysv4
1283 + exit 0 ;;
1284 RM*:SINIX-*:*:*)
1285 echo mips-sni-sysv4
1286 exit 0 ;;
1287 @@ -716,8 +1124,8 @@
1288 echo ns32k-sni-sysv
1289 fi
1290 exit 0 ;;
1291 - PENTIUM:CPunix:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
1292 - # says <Richard.M.Bartel@ccMail.Census.GOV>
1293 + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
1294 + # says <Richard.M.Bartel@ccMail.Census.GOV>
1295 echo i586-unisys-sysv4
1296 exit 0 ;;
1297 *:UNIX_System_V:4*:FTX*)
1298 @@ -729,25 +1137,130 @@
1299 # From seanf@swdc.stratus.com.
1300 echo i860-stratus-sysv4
1301 exit 0 ;;
1302 + *:VOS:*:*)
1303 + # From Paul.Green@stratus.com.
1304 + echo hppa1.1-stratus-vos
1305 + exit 0 ;;
1306 mc68*:A/UX:*:*)
1307 echo m68k-apple-aux${UNAME_RELEASE}
1308 exit 0 ;;
1309 - news*:NEWS-OS:*:6*)
1310 + news*:NEWS-OS:6*:*)
1311 echo mips-sony-newsos6
1312 exit 0 ;;
1313 - R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:*)
1314 + R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
1315 if [ -d /usr/nec ]; then
1316 echo mips-nec-sysv${UNAME_RELEASE}
1317 else
1318 echo mips-unknown-sysv${UNAME_RELEASE}
1319 fi
1320 exit 0 ;;
1321 + BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
1322 + echo powerpc-be-beos
1323 + exit 0 ;;
1324 + BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
1325 + echo powerpc-apple-beos
1326 + exit 0 ;;
1327 + BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
1328 + echo i586-pc-beos
1329 + exit 0 ;;
1330 + SX-4:SUPER-UX:*:*)
1331 + echo sx4-nec-superux${UNAME_RELEASE}
1332 + exit 0 ;;
1333 + SX-5:SUPER-UX:*:*)
1334 + echo sx5-nec-superux${UNAME_RELEASE}
1335 + exit 0 ;;
1336 + SX-6:SUPER-UX:*:*)
1337 + echo sx6-nec-superux${UNAME_RELEASE}
1338 + exit 0 ;;
1339 + Power*:Rhapsody:*:*)
1340 + echo powerpc-apple-rhapsody${UNAME_RELEASE}
1341 + exit 0 ;;
1342 + *:Rhapsody:*:*)
1343 + echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
1344 + exit 0 ;;
1345 + *:Darwin:*:*)
1346 + UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
1347 + case $UNAME_PROCESSOR in
1348 + *86) UNAME_PROCESSOR=i686 ;;
1349 + unknown) UNAME_PROCESSOR=powerpc ;;
1350 + esac
1351 + echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
1352 + exit 0 ;;
1353 + *:procnto*:*:* | *:QNX:[0123456789]*:*)
1354 + UNAME_PROCESSOR=`uname -p`
1355 + if test "$UNAME_PROCESSOR" = "x86"; then
1356 + UNAME_PROCESSOR=i386
1357 + UNAME_MACHINE=pc
1358 + fi
1359 + echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
1360 + exit 0 ;;
1361 + *:QNX:*:4*)
1362 + echo i386-pc-qnx
1363 + exit 0 ;;
1364 + NSR-?:NONSTOP_KERNEL:*:*)
1365 + echo nsr-tandem-nsk${UNAME_RELEASE}
1366 + exit 0 ;;
1367 + *:NonStop-UX:*:*)
1368 + echo mips-compaq-nonstopux
1369 + exit 0 ;;
1370 + BS2000:POSIX*:*:*)
1371 + echo bs2000-siemens-sysv
1372 + exit 0 ;;
1373 + DS/*:UNIX_System_V:*:*)
1374 + echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
1375 + exit 0 ;;
1376 + *:Plan9:*:*)
1377 + # "uname -m" is not consistent, so use $cputype instead. 386
1378 + # is converted to i386 for consistency with other x86
1379 + # operating systems.
1380 + if test "$cputype" = "386"; then
1381 + UNAME_MACHINE=i386
1382 + else
1383 + UNAME_MACHINE="$cputype"
1384 + fi
1385 + echo ${UNAME_MACHINE}-unknown-plan9
1386 + exit 0 ;;
1387 + *:TOPS-10:*:*)
1388 + echo pdp10-unknown-tops10
1389 + exit 0 ;;
1390 + *:TENEX:*:*)
1391 + echo pdp10-unknown-tenex
1392 + exit 0 ;;
1393 + KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
1394 + echo pdp10-dec-tops20
1395 + exit 0 ;;
1396 + XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
1397 + echo pdp10-xkl-tops20
1398 + exit 0 ;;
1399 + *:TOPS-20:*:*)
1400 + echo pdp10-unknown-tops20
1401 + exit 0 ;;
1402 + *:ITS:*:*)
1403 + echo pdp10-unknown-its
1404 + exit 0 ;;
1405 + SEI:*:*:SEIUX)
1406 + echo mips-sei-seiux${UNAME_RELEASE}
1407 + exit 0 ;;
1408 + *:DragonFly:*:*)
1409 + echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
1410 + exit 0 ;;
1411 + *:*VMS:*:*)
1412 + UNAME_MACHINE=`(uname -p) 2>/dev/null`
1413 + case "${UNAME_MACHINE}" in
1414 + A*) echo alpha-dec-vms && exit 0 ;;
1415 + I*) echo ia64-dec-vms && exit 0 ;;
1416 + V*) echo vax-dec-vms && exit 0 ;;
1417 + esac ;;
1418 + *:XENIX:*:SysV)
1419 + echo i386-pc-xenix
1420 + exit 0 ;;
1421 esac
1422
1423 #echo '(No uname command or uname output not recognized.)' 1>&2
1424 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
1425
1426 -cat >dummy.c <<EOF
1427 +eval $set_cc_for_build
1428 +cat >$dummy.c <<EOF
1429 #ifdef _SEQUENT_
1430 # include <sys/types.h>
1431 # include <sys/utsname.h>
1432 @@ -785,7 +1298,10 @@
1433 #endif
1434 int version;
1435 version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
1436 - printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
1437 + if (version < 4)
1438 + printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
1439 + else
1440 + printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
1441 exit (0);
1442 #endif
1443
1444 @@ -830,11 +1346,24 @@
1445 #endif
1446
1447 #if defined (vax)
1448 -#if !defined (ultrix)
1449 - printf ("vax-dec-bsd\n"); exit (0);
1450 -#else
1451 - printf ("vax-dec-ultrix\n"); exit (0);
1452 -#endif
1453 +# if !defined (ultrix)
1454 +# include <sys/param.h>
1455 +# if defined (BSD)
1456 +# if BSD == 43
1457 + printf ("vax-dec-bsd4.3\n"); exit (0);
1458 +# else
1459 +# if BSD == 199006
1460 + printf ("vax-dec-bsd4.3reno\n"); exit (0);
1461 +# else
1462 + printf ("vax-dec-bsd\n"); exit (0);
1463 +# endif
1464 +# endif
1465 +# else
1466 + printf ("vax-dec-bsd\n"); exit (0);
1467 +# endif
1468 +# else
1469 + printf ("vax-dec-ultrix\n"); exit (0);
1470 +# endif
1471 #endif
1472
1473 #if defined (alliant) && defined (i860)
1474 @@ -845,8 +1374,7 @@
1475 }
1476 EOF
1477
1478 -${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy && rm dummy.c dummy && exit 0
1479 -rm -f dummy.c dummy
1480 +$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && $dummy && exit 0
1481
1482 # Apollos put the system type in the environment.
1483
1484 @@ -878,6 +1406,48 @@
1485 esac
1486 fi
1487
1488 -#echo '(Unable to guess system type)' 1>&2
1489 +cat >&2 <<EOF
1490 +$0: unable to guess system type
1491 +
1492 +This script, last modified $timestamp, has failed to recognize
1493 +the operating system you are using. It is advised that you
1494 +download the most up to date version of the config scripts from
1495 +
1496 + ftp://ftp.gnu.org/pub/gnu/config/
1497 +
1498 +If the version you run ($0) is already up to date, please
1499 +send the following data and any information you think might be
1500 +pertinent to <config-patches@gnu.org> in order to provide the needed
1501 +information to handle your system.
1502 +
1503 +config.guess timestamp = $timestamp
1504 +
1505 +uname -m = `(uname -m) 2>/dev/null || echo unknown`
1506 +uname -r = `(uname -r) 2>/dev/null || echo unknown`
1507 +uname -s = `(uname -s) 2>/dev/null || echo unknown`
1508 +uname -v = `(uname -v) 2>/dev/null || echo unknown`
1509 +
1510 +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
1511 +/bin/uname -X = `(/bin/uname -X) 2>/dev/null`
1512 +
1513 +hostinfo = `(hostinfo) 2>/dev/null`
1514 +/bin/universe = `(/bin/universe) 2>/dev/null`
1515 +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null`
1516 +/bin/arch = `(/bin/arch) 2>/dev/null`
1517 +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
1518 +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
1519 +
1520 +UNAME_MACHINE = ${UNAME_MACHINE}
1521 +UNAME_RELEASE = ${UNAME_RELEASE}
1522 +UNAME_SYSTEM = ${UNAME_SYSTEM}
1523 +UNAME_VERSION = ${UNAME_VERSION}
1524 +EOF
1525
1526 exit 1
1527 +
1528 +# Local variables:
1529 +# eval: (add-hook 'write-file-hooks 'time-stamp)
1530 +# time-stamp-start: "timestamp='"
1531 +# time-stamp-format: "%:y-%02m-%02d"
1532 +# time-stamp-end: "'"
1533 +# End:
1534 diff -urN jpeg.old/config.sub jpeg.dev/config.sub
1535 --- jpeg.old/config.sub 1998-03-25 16:25:39.000000000 +0100
1536 +++ jpeg.dev/config.sub 2006-04-21 16:16:34.000000000 +0200
1537 @@ -1,6 +1,10 @@
1538 #! /bin/sh
1539 -# Configuration validation subroutine script, version 1.1.
1540 -# Copyright (C) 1991, 92, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
1541 +# Configuration validation subroutine script.
1542 +# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
1543 +# 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
1544 +
1545 +timestamp='2004-11-30'
1546 +
1547 # This file is (in principle) common to ALL GNU software.
1548 # The presence of a machine in this file suggests that SOME GNU software
1549 # can handle that machine. It does not imply ALL GNU software can.
1550 @@ -25,6 +29,9 @@
1551 # configuration script generated by Autoconf, you may include it under
1552 # the same distribution terms that you use for the rest of that program.
1553
1554 +# Please send patches to <config-patches@gnu.org>. Submit a context
1555 +# diff and a properly formatted ChangeLog entry.
1556 +#
1557 # Configuration subroutine to validate and canonicalize a configuration type.
1558 # Supply the specified configuration type as an argument.
1559 # If it is invalid, we print an error message on stderr and exit with code 1.
1560 @@ -45,30 +52,74 @@
1561 # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
1562 # It is wrong to echo any other type of specification.
1563
1564 -if [ x$1 = x ]
1565 -then
1566 - echo Configuration name missing. 1>&2
1567 - echo "Usage: $0 CPU-MFR-OPSYS" 1>&2
1568 - echo "or $0 ALIAS" 1>&2
1569 - echo where ALIAS is a recognized configuration type. 1>&2
1570 - exit 1
1571 -fi
1572 +me=`echo "$0" | sed -e 's,.*/,,'`
1573
1574 -# First pass through any local machine types.
1575 -case $1 in
1576 - *local*)
1577 - echo $1
1578 - exit 0
1579 - ;;
1580 - *)
1581 - ;;
1582 +usage="\
1583 +Usage: $0 [OPTION] CPU-MFR-OPSYS
1584 + $0 [OPTION] ALIAS
1585 +
1586 +Canonicalize a configuration name.
1587 +
1588 +Operation modes:
1589 + -h, --help print this help, then exit
1590 + -t, --time-stamp print date of last modification, then exit
1591 + -v, --version print version number, then exit
1592 +
1593 +Report bugs and patches to <config-patches@gnu.org>."
1594 +
1595 +version="\
1596 +GNU config.sub ($timestamp)
1597 +
1598 +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
1599 +Free Software Foundation, Inc.
1600 +
1601 +This is free software; see the source for copying conditions. There is NO
1602 +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
1603 +
1604 +help="
1605 +Try \`$me --help' for more information."
1606 +
1607 +# Parse command line
1608 +while test $# -gt 0 ; do
1609 + case $1 in
1610 + --time-stamp | --time* | -t )
1611 + echo "$timestamp" ; exit 0 ;;
1612 + --version | -v )
1613 + echo "$version" ; exit 0 ;;
1614 + --help | --h* | -h )
1615 + echo "$usage"; exit 0 ;;
1616 + -- ) # Stop option processing
1617 + shift; break ;;
1618 + - ) # Use stdin as input.
1619 + break ;;
1620 + -* )
1621 + echo "$me: invalid option $1$help"
1622 + exit 1 ;;
1623 +
1624 + *local*)
1625 + # First pass through any local machine types.
1626 + echo $1
1627 + exit 0;;
1628 +
1629 + * )
1630 + break ;;
1631 + esac
1632 +done
1633 +
1634 +case $# in
1635 + 0) echo "$me: missing argument$help" >&2
1636 + exit 1;;
1637 + 1) ;;
1638 + *) echo "$me: too many arguments$help" >&2
1639 + exit 1;;
1640 esac
1641
1642 # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
1643 # Here we must recognize all the valid KERNEL-OS combinations.
1644 maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
1645 case $maybe_os in
1646 - linux-gnu*)
1647 + nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \
1648 + kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
1649 os=-$maybe_os
1650 basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
1651 ;;
1652 @@ -94,15 +145,33 @@
1653 -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
1654 -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
1655 -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
1656 - -apple)
1657 + -apple | -axis | -knuth | -cray)
1658 os=
1659 basic_machine=$1
1660 ;;
1661 + -sim | -cisco | -oki | -wec | -winbond)
1662 + os=
1663 + basic_machine=$1
1664 + ;;
1665 + -scout)
1666 + ;;
1667 + -wrs)
1668 + os=-vxworks
1669 + basic_machine=$1
1670 + ;;
1671 + -chorusos*)
1672 + os=-chorusos
1673 + basic_machine=$1
1674 + ;;
1675 + -chorusrdb)
1676 + os=-chorusrdb
1677 + basic_machine=$1
1678 + ;;
1679 -hiux*)
1680 os=-hiuxwe2
1681 ;;
1682 -sco5)
1683 - os=sco3.2v5
1684 + os=-sco3.2v5
1685 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
1686 ;;
1687 -sco4)
1688 @@ -121,6 +190,9 @@
1689 os=-sco3.2v2
1690 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
1691 ;;
1692 + -udk*)
1693 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
1694 + ;;
1695 -isc)
1696 os=-isc2.2
1697 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
1698 @@ -143,26 +215,74 @@
1699 -psos*)
1700 os=-psos
1701 ;;
1702 + -mint | -mint[0-9]*)
1703 + basic_machine=m68k-atari
1704 + os=-mint
1705 + ;;
1706 esac
1707
1708 # Decode aliases for certain CPU-COMPANY combinations.
1709 case $basic_machine in
1710 # Recognize the basic CPU types without company name.
1711 # Some are omitted here because they have special meanings below.
1712 - tahoe | i860 | m32r | m68k | m68000 | m88k | ns32k | arc | arm \
1713 - | arme[lb] | pyramid | mn10200 | mn10300 \
1714 - | tron | a29k | 580 | i960 | h8300 | hppa | hppa1.0 | hppa1.1 \
1715 - | alpha | alphaev5 | alphaev56 | we32k | ns16k | clipper \
1716 - | i370 | sh | powerpc | powerpcle | 1750a | dsp16xx | pdp11 \
1717 - | mips64 | mipsel | mips64el | mips64orion | mips64orionel \
1718 - | mipstx39 | mipstx39el \
1719 - | sparc | sparclet | sparclite | sparc64 | v850)
1720 + 1750a | 580 \
1721 + | a29k \
1722 + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
1723 + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
1724 + | am33_2.0 \
1725 + | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
1726 + | c4x | clipper \
1727 + | d10v | d30v | dlx | dsp16xx \
1728 + | fr30 | frv \
1729 + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
1730 + | i370 | i860 | i960 | ia64 \
1731 + | ip2k | iq2000 \
1732 + | m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \
1733 + | mips | mipsbe | mipseb | mipsel | mipsle \
1734 + | mips16 \
1735 + | mips64 | mips64el \
1736 + | mips64vr | mips64vrel \
1737 + | mips64orion | mips64orionel \
1738 + | mips64vr4100 | mips64vr4100el \
1739 + | mips64vr4300 | mips64vr4300el \
1740 + | mips64vr5000 | mips64vr5000el \
1741 + | mipsisa32 | mipsisa32el \
1742 + | mipsisa32r2 | mipsisa32r2el \
1743 + | mipsisa64 | mipsisa64el \
1744 + | mipsisa64r2 | mipsisa64r2el \
1745 + | mipsisa64sb1 | mipsisa64sb1el \
1746 + | mipsisa64sr71k | mipsisa64sr71kel \
1747 + | mipstx39 | mipstx39el \
1748 + | mn10200 | mn10300 \
1749 + | msp430 \
1750 + | ns16k | ns32k \
1751 + | openrisc | or32 \
1752 + | pdp10 | pdp11 | pj | pjl \
1753 + | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
1754 + | pyramid \
1755 + | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
1756 + | sh64 | sh64le \
1757 + | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv8 | sparcv9 | sparcv9b \
1758 + | strongarm \
1759 + | tahoe | thumb | tic4x | tic80 | tron \
1760 + | v850 | v850e \
1761 + | we32k \
1762 + | x86 | xscale | xscalee[bl] | xstormy16 | xtensa \
1763 + | z8k)
1764 basic_machine=$basic_machine-unknown
1765 ;;
1766 + m6811 | m68hc11 | m6812 | m68hc12)
1767 + # Motorola 68HC11/12.
1768 + basic_machine=$basic_machine-unknown
1769 + os=-none
1770 + ;;
1771 + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
1772 + ;;
1773 +
1774 # We use `pc' rather than `unknown'
1775 # because (1) that's what they normally are, and
1776 # (2) the word "unknown" tends to confuse beginning users.
1777 - i[3456]86)
1778 + i*86 | x86_64)
1779 basic_machine=$basic_machine-pc
1780 ;;
1781 # Object if more than one company name word.
1782 @@ -171,27 +291,86 @@
1783 exit 1
1784 ;;
1785 # Recognize the basic CPU types with company name.
1786 - vax-* | tahoe-* | i[3456]86-* | i860-* | m32r-* | m68k-* | m68000-* \
1787 - | m88k-* | sparc-* | ns32k-* | fx80-* | arc-* | arm-* | c[123]* \
1788 - | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \
1789 - | power-* | none-* | 580-* | cray2-* | h8300-* | i960-* \
1790 - | xmp-* | ymp-* | hppa-* | hppa1.0-* | hppa1.1-* \
1791 - | alpha-* | alphaev5-* | alphaev56-* | we32k-* | cydra-* \
1792 - | ns16k-* | pn-* | np1-* | xps100-* | clipper-* | orion-* \
1793 - | sparclite-* | pdp11-* | sh-* | powerpc-* | powerpcle-* \
1794 - | sparc64-* | mips64-* | mipsel-* \
1795 - | mips64el-* | mips64orion-* | mips64orionel-* \
1796 - | mipstx39-* | mipstx39el-* \
1797 - | f301-*)
1798 + 580-* \
1799 + | a29k-* \
1800 + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
1801 + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
1802 + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
1803 + | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
1804 + | avr-* \
1805 + | bs2000-* \
1806 + | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
1807 + | clipper-* | craynv-* | cydra-* \
1808 + | d10v-* | d30v-* | dlx-* \
1809 + | elxsi-* \
1810 + | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
1811 + | h8300-* | h8500-* \
1812 + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
1813 + | i*86-* | i860-* | i960-* | ia64-* \
1814 + | ip2k-* | iq2000-* \
1815 + | m32r-* | m32rle-* \
1816 + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
1817 + | m88110-* | m88k-* | maxq-* | mcore-* \
1818 + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
1819 + | mips16-* \
1820 + | mips64-* | mips64el-* \
1821 + | mips64vr-* | mips64vrel-* \
1822 + | mips64orion-* | mips64orionel-* \
1823 + | mips64vr4100-* | mips64vr4100el-* \
1824 + | mips64vr4300-* | mips64vr4300el-* \
1825 + | mips64vr5000-* | mips64vr5000el-* \
1826 + | mipsisa32-* | mipsisa32el-* \
1827 + | mipsisa32r2-* | mipsisa32r2el-* \
1828 + | mipsisa64-* | mipsisa64el-* \
1829 + | mipsisa64r2-* | mipsisa64r2el-* \
1830 + | mipsisa64sb1-* | mipsisa64sb1el-* \
1831 + | mipsisa64sr71k-* | mipsisa64sr71kel-* \
1832 + | mipstx39-* | mipstx39el-* \
1833 + | mmix-* \
1834 + | msp430-* \
1835 + | none-* | np1-* | ns16k-* | ns32k-* \
1836 + | orion-* \
1837 + | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
1838 + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
1839 + | pyramid-* \
1840 + | romp-* | rs6000-* \
1841 + | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \
1842 + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
1843 + | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
1844 + | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
1845 + | tahoe-* | thumb-* \
1846 + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
1847 + | tron-* \
1848 + | v850-* | v850e-* | vax-* \
1849 + | we32k-* \
1850 + | x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \
1851 + | xstormy16-* | xtensa-* \
1852 + | ymp-* \
1853 + | z8k-*)
1854 ;;
1855 # Recognize the various machine names and aliases which stand
1856 # for a CPU type and a company and sometimes even an OS.
1857 + 386bsd)
1858 + basic_machine=i386-unknown
1859 + os=-bsd
1860 + ;;
1861 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
1862 basic_machine=m68000-att
1863 ;;
1864 3b*)
1865 basic_machine=we32k-att
1866 ;;
1867 + a29khif)
1868 + basic_machine=a29k-amd
1869 + os=-udi
1870 + ;;
1871 + abacus)
1872 + basic_machine=abacus-unknown
1873 + ;;
1874 + adobe68k)
1875 + basic_machine=m68010-adobe
1876 + os=-scout
1877 + ;;
1878 alliant | fx80)
1879 basic_machine=fx80-alliant
1880 ;;
1881 @@ -202,25 +381,35 @@
1882 basic_machine=a29k-none
1883 os=-bsd
1884 ;;
1885 + amd64)
1886 + basic_machine=x86_64-pc
1887 + ;;
1888 + amd64-*)
1889 + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
1890 + ;;
1891 amdahl)
1892 basic_machine=580-amdahl
1893 os=-sysv
1894 ;;
1895 amiga | amiga-*)
1896 - basic_machine=m68k-cbm
1897 + basic_machine=m68k-unknown
1898 ;;
1899 amigaos | amigados)
1900 - basic_machine=m68k-cbm
1901 + basic_machine=m68k-unknown
1902 os=-amigaos
1903 ;;
1904 amigaunix | amix)
1905 - basic_machine=m68k-cbm
1906 + basic_machine=m68k-unknown
1907 os=-sysv4
1908 ;;
1909 apollo68)
1910 basic_machine=m68k-apollo
1911 os=-sysv
1912 ;;
1913 + apollo68bsd)
1914 + basic_machine=m68k-apollo
1915 + os=-bsd
1916 + ;;
1917 aux)
1918 basic_machine=m68k-apple
1919 os=-aux
1920 @@ -229,6 +418,10 @@
1921 basic_machine=ns32k-sequent
1922 os=-dynix
1923 ;;
1924 + c90)
1925 + basic_machine=c90-cray
1926 + os=-unicos
1927 + ;;
1928 convex-c1)
1929 basic_machine=c1-convex
1930 os=-bsd
1931 @@ -249,27 +442,45 @@
1932 basic_machine=c38-convex
1933 os=-bsd
1934 ;;
1935 - cray | ymp)
1936 - basic_machine=ymp-cray
1937 - os=-unicos
1938 - ;;
1939 - cray2)
1940 - basic_machine=cray2-cray
1941 + cray | j90)
1942 + basic_machine=j90-cray
1943 os=-unicos
1944 ;;
1945 - [ctj]90-cray)
1946 - basic_machine=c90-cray
1947 - os=-unicos
1948 + craynv)
1949 + basic_machine=craynv-cray
1950 + os=-unicosmp
1951 + ;;
1952 + cr16c)
1953 + basic_machine=cr16c-unknown
1954 + os=-elf
1955 ;;
1956 crds | unos)
1957 basic_machine=m68k-crds
1958 ;;
1959 + crisv32 | crisv32-* | etraxfs*)
1960 + basic_machine=crisv32-axis
1961 + ;;
1962 + cris | cris-* | etrax*)
1963 + basic_machine=cris-axis
1964 + ;;
1965 + crx)
1966 + basic_machine=crx-unknown
1967 + os=-elf
1968 + ;;
1969 da30 | da30-*)
1970 basic_machine=m68k-da30
1971 ;;
1972 decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
1973 basic_machine=mips-dec
1974 ;;
1975 + decsystem10* | dec10*)
1976 + basic_machine=pdp10-dec
1977 + os=-tops10
1978 + ;;
1979 + decsystem20* | dec20*)
1980 + basic_machine=pdp10-dec
1981 + os=-tops20
1982 + ;;
1983 delta | 3300 | motorola-3300 | motorola-delta \
1984 | 3300-motorola | delta-motorola)
1985 basic_machine=m68k-motorola
1986 @@ -278,6 +489,10 @@
1987 basic_machine=m88k-motorola
1988 os=-sysv3
1989 ;;
1990 + djgpp)
1991 + basic_machine=i586-pc
1992 + os=-msdosdjgpp
1993 + ;;
1994 dpx20 | dpx20-*)
1995 basic_machine=rs6000-bull
1996 os=-bosx
1997 @@ -297,6 +512,10 @@
1998 encore | umax | mmax)
1999 basic_machine=ns32k-encore
2000 ;;
2001 + es1800 | OSE68k | ose68k | ose | OSE)
2002 + basic_machine=m68k-ericsson
2003 + os=-ose
2004 + ;;
2005 fx2800)
2006 basic_machine=i860-alliant
2007 ;;
2008 @@ -307,6 +526,10 @@
2009 basic_machine=tron-gmicro
2010 os=-sysv
2011 ;;
2012 + go32)
2013 + basic_machine=i386-pc
2014 + os=-go32
2015 + ;;
2016 h3050r* | hiux*)
2017 basic_machine=hppa1.1-hitachi
2018 os=-hiuxwe2
2019 @@ -315,6 +538,14 @@
2020 basic_machine=h8300-hitachi
2021 os=-hms
2022 ;;
2023 + h8300xray)
2024 + basic_machine=h8300-hitachi
2025 + os=-xray
2026 + ;;
2027 + h8500hms)
2028 + basic_machine=h8500-hitachi
2029 + os=-hms
2030 + ;;
2031 harris)
2032 basic_machine=m88k-harris
2033 os=-sysv3
2034 @@ -330,13 +561,30 @@
2035 basic_machine=m68k-hp
2036 os=-hpux
2037 ;;
2038 + hp3k9[0-9][0-9] | hp9[0-9][0-9])
2039 + basic_machine=hppa1.0-hp
2040 + ;;
2041 hp9k2[0-9][0-9] | hp9k31[0-9])
2042 basic_machine=m68000-hp
2043 ;;
2044 hp9k3[2-9][0-9])
2045 basic_machine=m68k-hp
2046 ;;
2047 - hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
2048 + hp9k6[0-9][0-9] | hp6[0-9][0-9])
2049 + basic_machine=hppa1.0-hp
2050 + ;;
2051 + hp9k7[0-79][0-9] | hp7[0-79][0-9])
2052 + basic_machine=hppa1.1-hp
2053 + ;;
2054 + hp9k78[0-9] | hp78[0-9])
2055 + # FIXME: really hppa2.0-hp
2056 + basic_machine=hppa1.1-hp
2057 + ;;
2058 + hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
2059 + # FIXME: really hppa2.0-hp
2060 + basic_machine=hppa1.1-hp
2061 + ;;
2062 + hp9k8[0-9][13679] | hp8[0-9][13679])
2063 basic_machine=hppa1.1-hp
2064 ;;
2065 hp9k8[0-9][0-9] | hp8[0-9][0-9])
2066 @@ -345,27 +593,42 @@
2067 hppa-next)
2068 os=-nextstep3
2069 ;;
2070 + hppaosf)
2071 + basic_machine=hppa1.1-hp
2072 + os=-osf
2073 + ;;
2074 + hppro)
2075 + basic_machine=hppa1.1-hp
2076 + os=-proelf
2077 + ;;
2078 i370-ibm* | ibm*)
2079 basic_machine=i370-ibm
2080 - os=-mvs
2081 ;;
2082 # I'm not sure what "Sysv32" means. Should this be sysv3.2?
2083 - i[3456]86v32)
2084 + i*86v32)
2085 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2086 os=-sysv32
2087 ;;
2088 - i[3456]86v4*)
2089 + i*86v4*)
2090 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2091 os=-sysv4
2092 ;;
2093 - i[3456]86v)
2094 + i*86v)
2095 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2096 os=-sysv
2097 ;;
2098 - i[3456]86sol2)
2099 + i*86sol2)
2100 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2101 os=-solaris2
2102 ;;
2103 + i386mach)
2104 + basic_machine=i386-mach
2105 + os=-mach
2106 + ;;
2107 + i386-vsta | vsta)
2108 + basic_machine=i386-unknown
2109 + os=-vsta
2110 + ;;
2111 iris | iris4d)
2112 basic_machine=mips-sgi
2113 case $os in
2114 @@ -391,16 +654,16 @@
2115 basic_machine=ns32k-utek
2116 os=-sysv
2117 ;;
2118 + mingw32)
2119 + basic_machine=i386-pc
2120 + os=-mingw32
2121 + ;;
2122 miniframe)
2123 basic_machine=m68000-convergent
2124 ;;
2125 - mipsel*-linux*)
2126 - basic_machine=mipsel-unknown
2127 - os=-linux-gnu
2128 - ;;
2129 - mips*-linux*)
2130 - basic_machine=mips-unknown
2131 - os=-linux-gnu
2132 + *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*)
2133 + basic_machine=m68k-atari
2134 + os=-mint
2135 ;;
2136 mips3*-*)
2137 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
2138 @@ -408,10 +671,34 @@
2139 mips3*)
2140 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
2141 ;;
2142 + monitor)
2143 + basic_machine=m68k-rom68k
2144 + os=-coff
2145 + ;;
2146 + morphos)
2147 + basic_machine=powerpc-unknown
2148 + os=-morphos
2149 + ;;
2150 + msdos)
2151 + basic_machine=i386-pc
2152 + os=-msdos
2153 + ;;
2154 + mvs)
2155 + basic_machine=i370-ibm
2156 + os=-mvs
2157 + ;;
2158 ncr3000)
2159 basic_machine=i486-ncr
2160 os=-sysv4
2161 ;;
2162 + netbsd386)
2163 + basic_machine=i386-unknown
2164 + os=-netbsd
2165 + ;;
2166 + netwinder)
2167 + basic_machine=armv4l-rebel
2168 + os=-linux
2169 + ;;
2170 news | news700 | news800 | news900)
2171 basic_machine=m68k-sony
2172 os=-newsos
2173 @@ -424,6 +711,10 @@
2174 basic_machine=mips-sony
2175 os=-newsos
2176 ;;
2177 + necv70)
2178 + basic_machine=v70-nec
2179 + os=-sysv
2180 + ;;
2181 next | m*-next )
2182 basic_machine=m68k-next
2183 case $os in
2184 @@ -449,9 +740,40 @@
2185 basic_machine=i960-intel
2186 os=-nindy
2187 ;;
2188 + mon960)
2189 + basic_machine=i960-intel
2190 + os=-mon960
2191 + ;;
2192 + nonstopux)
2193 + basic_machine=mips-compaq
2194 + os=-nonstopux
2195 + ;;
2196 np1)
2197 basic_machine=np1-gould
2198 ;;
2199 + nsr-tandem)
2200 + basic_machine=nsr-tandem
2201 + ;;
2202 + op50n-* | op60c-*)
2203 + basic_machine=hppa1.1-oki
2204 + os=-proelf
2205 + ;;
2206 + or32 | or32-*)
2207 + basic_machine=or32-unknown
2208 + os=-coff
2209 + ;;
2210 + os400)
2211 + basic_machine=powerpc-ibm
2212 + os=-os400
2213 + ;;
2214 + OSE68000 | ose68000)
2215 + basic_machine=m68000-ericsson
2216 + os=-ose
2217 + ;;
2218 + os68k)
2219 + basic_machine=m68k-none
2220 + os=-os68k
2221 + ;;
2222 pa-hitachi)
2223 basic_machine=hppa1.1-hitachi
2224 os=-hiuxwe2
2225 @@ -466,53 +788,95 @@
2226 pbb)
2227 basic_machine=m68k-tti
2228 ;;
2229 - pc532 | pc532-*)
2230 + pc532 | pc532-*)
2231 basic_machine=ns32k-pc532
2232 ;;
2233 - pentium | p5)
2234 - basic_machine=i586-intel
2235 + pentium | p5 | k5 | k6 | nexgen | viac3)
2236 + basic_machine=i586-pc
2237 + ;;
2238 + pentiumpro | p6 | 6x86 | athlon | athlon_*)
2239 + basic_machine=i686-pc
2240 ;;
2241 - pentiumpro | p6)
2242 - basic_machine=i686-intel
2243 + pentiumii | pentium2 | pentiumiii | pentium3)
2244 + basic_machine=i686-pc
2245 ;;
2246 - pentium-* | p5-*)
2247 + pentium4)
2248 + basic_machine=i786-pc
2249 + ;;
2250 + pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
2251 basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
2252 ;;
2253 - pentiumpro-* | p6-*)
2254 + pentiumpro-* | p6-* | 6x86-* | athlon-*)
2255 + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
2256 + ;;
2257 + pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
2258 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
2259 ;;
2260 - k5)
2261 - # We don't have specific support for AMD's K5 yet, so just call it a Pentium
2262 - basic_machine=i586-amd
2263 - ;;
2264 - nexen)
2265 - # We don't have specific support for Nexgen yet, so just call it a Pentium
2266 - basic_machine=i586-nexgen
2267 + pentium4-*)
2268 + basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
2269 ;;
2270 pn)
2271 basic_machine=pn-gould
2272 ;;
2273 - power) basic_machine=rs6000-ibm
2274 + power) basic_machine=power-ibm
2275 ;;
2276 ppc) basic_machine=powerpc-unknown
2277 - ;;
2278 + ;;
2279 ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
2280 ;;
2281 ppcle | powerpclittle | ppc-le | powerpc-little)
2282 basic_machine=powerpcle-unknown
2283 - ;;
2284 + ;;
2285 ppcle-* | powerpclittle-*)
2286 basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
2287 ;;
2288 + ppc64) basic_machine=powerpc64-unknown
2289 + ;;
2290 + ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
2291 + ;;
2292 + ppc64le | powerpc64little | ppc64-le | powerpc64-little)
2293 + basic_machine=powerpc64le-unknown
2294 + ;;
2295 + ppc64le-* | powerpc64little-*)
2296 + basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
2297 + ;;
2298 ps2)
2299 basic_machine=i386-ibm
2300 ;;
2301 + pw32)
2302 + basic_machine=i586-unknown
2303 + os=-pw32
2304 + ;;
2305 + rom68k)
2306 + basic_machine=m68k-rom68k
2307 + os=-coff
2308 + ;;
2309 rm[46]00)
2310 basic_machine=mips-siemens
2311 ;;
2312 rtpc | rtpc-*)
2313 basic_machine=romp-ibm
2314 ;;
2315 + s390 | s390-*)
2316 + basic_machine=s390-ibm
2317 + ;;
2318 + s390x | s390x-*)
2319 + basic_machine=s390x-ibm
2320 + ;;
2321 + sa29200)
2322 + basic_machine=a29k-amd
2323 + os=-udi
2324 + ;;
2325 + sb1)
2326 + basic_machine=mipsisa64sb1-unknown
2327 + ;;
2328 + sb1el)
2329 + basic_machine=mipsisa64sb1el-unknown
2330 + ;;
2331 + sei)
2332 + basic_machine=mips-sei
2333 + os=-seiux
2334 + ;;
2335 sequent)
2336 basic_machine=i386-sequent
2337 ;;
2338 @@ -520,6 +884,13 @@
2339 basic_machine=sh-hitachi
2340 os=-hms
2341 ;;
2342 + sh64)
2343 + basic_machine=sh64-unknown
2344 + ;;
2345 + sparclite-wrs | simso-wrs)
2346 + basic_machine=sparclite-wrs
2347 + os=-vxworks
2348 + ;;
2349 sps7)
2350 basic_machine=m68k-bull
2351 os=-sysv2
2352 @@ -527,6 +898,13 @@
2353 spur)
2354 basic_machine=spur-unknown
2355 ;;
2356 + st2000)
2357 + basic_machine=m68k-tandem
2358 + ;;
2359 + stratus)
2360 + basic_machine=i860-stratus
2361 + os=-sysv4
2362 + ;;
2363 sun2)
2364 basic_machine=m68000-sun
2365 ;;
2366 @@ -567,19 +945,51 @@
2367 sun386 | sun386i | roadrunner)
2368 basic_machine=i386-sun
2369 ;;
2370 + sv1)
2371 + basic_machine=sv1-cray
2372 + os=-unicos
2373 + ;;
2374 symmetry)
2375 basic_machine=i386-sequent
2376 os=-dynix
2377 ;;
2378 + t3e)
2379 + basic_machine=alphaev5-cray
2380 + os=-unicos
2381 + ;;
2382 + t90)
2383 + basic_machine=t90-cray
2384 + os=-unicos
2385 + ;;
2386 + tic54x | c54x*)
2387 + basic_machine=tic54x-unknown
2388 + os=-coff
2389 + ;;
2390 + tic55x | c55x*)
2391 + basic_machine=tic55x-unknown
2392 + os=-coff
2393 + ;;
2394 + tic6x | c6x*)
2395 + basic_machine=tic6x-unknown
2396 + os=-coff
2397 + ;;
2398 tx39)
2399 basic_machine=mipstx39-unknown
2400 ;;
2401 tx39el)
2402 basic_machine=mipstx39el-unknown
2403 ;;
2404 + toad1)
2405 + basic_machine=pdp10-xkl
2406 + os=-tops20
2407 + ;;
2408 tower | tower-32)
2409 basic_machine=m68k-ncr
2410 ;;
2411 + tpf)
2412 + basic_machine=s390x-ibm
2413 + os=-tpf
2414 + ;;
2415 udi29k)
2416 basic_machine=a29k-amd
2417 os=-udi
2418 @@ -588,6 +998,10 @@
2419 basic_machine=a29k-nyu
2420 os=-sym1
2421 ;;
2422 + v810 | necv810)
2423 + basic_machine=v810-nec
2424 + os=-none
2425 + ;;
2426 vaxv)
2427 basic_machine=vax-dec
2428 os=-sysv
2429 @@ -597,8 +1011,8 @@
2430 os=-vms
2431 ;;
2432 vpp*|vx|vx-*)
2433 - basic_machine=f301-fujitsu
2434 - ;;
2435 + basic_machine=f301-fujitsu
2436 + ;;
2437 vxworks960)
2438 basic_machine=i960-wrs
2439 os=-vxworks
2440 @@ -611,13 +1025,29 @@
2441 basic_machine=a29k-wrs
2442 os=-vxworks
2443 ;;
2444 - xmp)
2445 - basic_machine=xmp-cray
2446 - os=-unicos
2447 + w65*)
2448 + basic_machine=w65-wdc
2449 + os=-none
2450 + ;;
2451 + w89k-*)
2452 + basic_machine=hppa1.1-winbond
2453 + os=-proelf
2454 + ;;
2455 + xbox)
2456 + basic_machine=i686-pc
2457 + os=-mingw32
2458 ;;
2459 - xps | xps100)
2460 + xps | xps100)
2461 basic_machine=xps100-honeywell
2462 ;;
2463 + ymp)
2464 + basic_machine=ymp-cray
2465 + os=-unicos
2466 + ;;
2467 + z8k-*-coff)
2468 + basic_machine=z8k-unknown
2469 + os=-sim
2470 + ;;
2471 none)
2472 basic_machine=none-none
2473 os=-none
2474 @@ -625,32 +1055,47 @@
2475
2476 # Here we handle the default manufacturer of certain CPU types. It is in
2477 # some cases the only manufacturer, in others, it is the most popular.
2478 - mips)
2479 - if [ x$os = x-linux-gnu ]; then
2480 - basic_machine=mips-unknown
2481 - else
2482 - basic_machine=mips-mips
2483 - fi
2484 + w89k)
2485 + basic_machine=hppa1.1-winbond
2486 + ;;
2487 + op50n)
2488 + basic_machine=hppa1.1-oki
2489 + ;;
2490 + op60c)
2491 + basic_machine=hppa1.1-oki
2492 ;;
2493 romp)
2494 basic_machine=romp-ibm
2495 ;;
2496 + mmix)
2497 + basic_machine=mmix-knuth
2498 + ;;
2499 rs6000)
2500 basic_machine=rs6000-ibm
2501 ;;
2502 vax)
2503 basic_machine=vax-dec
2504 ;;
2505 + pdp10)
2506 + # there are many clones, so DEC is not a safe bet
2507 + basic_machine=pdp10-unknown
2508 + ;;
2509 pdp11)
2510 basic_machine=pdp11-dec
2511 ;;
2512 we32k)
2513 basic_machine=we32k-att
2514 ;;
2515 - sparc)
2516 + sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele)
2517 + basic_machine=sh-unknown
2518 + ;;
2519 + sh64)
2520 + basic_machine=sh64-unknown
2521 + ;;
2522 + sparc | sparcv8 | sparcv9 | sparcv9b)
2523 basic_machine=sparc-sun
2524 ;;
2525 - cydra)
2526 + cydra)
2527 basic_machine=cydra-cydrome
2528 ;;
2529 orion)
2530 @@ -659,6 +1104,15 @@
2531 orion105)
2532 basic_machine=clipper-highlevel
2533 ;;
2534 + mac | mpw | mac-mpw)
2535 + basic_machine=m68k-apple
2536 + ;;
2537 + pmac | pmac-mpw)
2538 + basic_machine=powerpc-apple
2539 + ;;
2540 + *-unknown)
2541 + # Make sure to match an already-canonicalized machine name.
2542 + ;;
2543 *)
2544 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
2545 exit 1
2546 @@ -711,14 +1165,46 @@
2547 | -aos* \
2548 | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
2549 | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
2550 - | -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \
2551 - | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
2552 + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \
2553 + | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
2554 + | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
2555 | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
2556 | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
2557 - | -cygwin32* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
2558 - | -mingw32* | -linux-gnu* | -uxpv*)
2559 + | -chorusos* | -chorusrdb* \
2560 + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
2561 + | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
2562 + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
2563 + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
2564 + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
2565 + | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
2566 + | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
2567 + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly*)
2568 # Remember, each alternative MUST END IN *, to match a version number.
2569 ;;
2570 + -qnx*)
2571 + case $basic_machine in
2572 + x86-* | i*86-*)
2573 + ;;
2574 + *)
2575 + os=-nto$os
2576 + ;;
2577 + esac
2578 + ;;
2579 + -nto-qnx*)
2580 + ;;
2581 + -nto*)
2582 + os=`echo $os | sed -e 's|nto|nto-qnx|'`
2583 + ;;
2584 + -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
2585 + | -windows* | -osx | -abug | -netware* | -os9* | -beos* \
2586 + | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
2587 + ;;
2588 + -mac*)
2589 + os=`echo $os | sed -e 's|mac|macos|'`
2590 + ;;
2591 + -linux-dietlibc)
2592 + os=-linux-dietlibc
2593 + ;;
2594 -linux*)
2595 os=`echo $os | sed -e 's|linux|linux-gnu|'`
2596 ;;
2597 @@ -728,6 +1214,15 @@
2598 -sunos6*)
2599 os=`echo $os | sed -e 's|sunos6|solaris3|'`
2600 ;;
2601 + -opened*)
2602 + os=-openedition
2603 + ;;
2604 + -os400*)
2605 + os=-os400
2606 + ;;
2607 + -wince*)
2608 + os=-wince
2609 + ;;
2610 -osfrose*)
2611 os=-osfrose
2612 ;;
2613 @@ -743,11 +1238,26 @@
2614 -acis*)
2615 os=-aos
2616 ;;
2617 + -atheos*)
2618 + os=-atheos
2619 + ;;
2620 + -syllable*)
2621 + os=-syllable
2622 + ;;
2623 + -386bsd)
2624 + os=-bsd
2625 + ;;
2626 -ctix* | -uts*)
2627 os=-sysv
2628 ;;
2629 + -nova*)
2630 + os=-rtmk-nova
2631 + ;;
2632 -ns2 )
2633 - os=-nextstep2
2634 + os=-nextstep2
2635 + ;;
2636 + -nsk*)
2637 + os=-nsk
2638 ;;
2639 # Preserve the version number of sinix5.
2640 -sinix5.*)
2641 @@ -756,6 +1266,9 @@
2642 -sinix*)
2643 os=-sysv4
2644 ;;
2645 + -tpf*)
2646 + os=-tpf
2647 + ;;
2648 -triton*)
2649 os=-sysv3
2650 ;;
2651 @@ -774,9 +1287,27 @@
2652 # This must come after -sysvr4.
2653 -sysv*)
2654 ;;
2655 + -ose*)
2656 + os=-ose
2657 + ;;
2658 + -es1800*)
2659 + os=-ose
2660 + ;;
2661 -xenix)
2662 os=-xenix
2663 ;;
2664 + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
2665 + os=-mint
2666 + ;;
2667 + -aros*)
2668 + os=-aros
2669 + ;;
2670 + -kaos*)
2671 + os=-kaos
2672 + ;;
2673 + -zvmoe)
2674 + os=-zvmoe
2675 + ;;
2676 -none)
2677 ;;
2678 *)
2679 @@ -802,10 +1333,20 @@
2680 *-acorn)
2681 os=-riscix1.2
2682 ;;
2683 + arm*-rebel)
2684 + os=-linux
2685 + ;;
2686 arm*-semi)
2687 os=-aout
2688 ;;
2689 - pdp11-*)
2690 + c4x-* | tic4x-*)
2691 + os=-coff
2692 + ;;
2693 + # This must come before the *-dec entry.
2694 + pdp10-*)
2695 + os=-tops20
2696 + ;;
2697 + pdp11-*)
2698 os=-none
2699 ;;
2700 *-dec | vax-*)
2701 @@ -823,15 +1364,42 @@
2702 # default.
2703 # os=-sunos4
2704 ;;
2705 + m68*-cisco)
2706 + os=-aout
2707 + ;;
2708 + mips*-cisco)
2709 + os=-elf
2710 + ;;
2711 + mips*-*)
2712 + os=-elf
2713 + ;;
2714 + or32-*)
2715 + os=-coff
2716 + ;;
2717 *-tti) # must be before sparc entry or we get the wrong os.
2718 os=-sysv3
2719 ;;
2720 sparc-* | *-sun)
2721 os=-sunos4.1.1
2722 ;;
2723 + *-be)
2724 + os=-beos
2725 + ;;
2726 *-ibm)
2727 os=-aix
2728 ;;
2729 + *-knuth)
2730 + os=-mmixware
2731 + ;;
2732 + *-wec)
2733 + os=-proelf
2734 + ;;
2735 + *-winbond)
2736 + os=-proelf
2737 + ;;
2738 + *-oki)
2739 + os=-proelf
2740 + ;;
2741 *-hp)
2742 os=-hpux
2743 ;;
2744 @@ -874,27 +1442,39 @@
2745 *-next)
2746 os=-nextstep3
2747 ;;
2748 - *-gould)
2749 + *-gould)
2750 os=-sysv
2751 ;;
2752 - *-highlevel)
2753 + *-highlevel)
2754 os=-bsd
2755 ;;
2756 *-encore)
2757 os=-bsd
2758 ;;
2759 - *-sgi)
2760 + *-sgi)
2761 os=-irix
2762 ;;
2763 - *-siemens)
2764 + *-siemens)
2765 os=-sysv4
2766 ;;
2767 *-masscomp)
2768 os=-rtu
2769 ;;
2770 - f301-fujitsu)
2771 + f30[01]-fujitsu | f700-fujitsu)
2772 os=-uxpv
2773 ;;
2774 + *-rom68k)
2775 + os=-coff
2776 + ;;
2777 + *-*bug)
2778 + os=-coff
2779 + ;;
2780 + *-apple)
2781 + os=-macos
2782 + ;;
2783 + *-atari*)
2784 + os=-mint
2785 + ;;
2786 *)
2787 os=-none
2788 ;;
2789 @@ -916,9 +1496,15 @@
2790 -aix*)
2791 vendor=ibm
2792 ;;
2793 + -beos*)
2794 + vendor=be
2795 + ;;
2796 -hpux*)
2797 vendor=hp
2798 ;;
2799 + -mpeix*)
2800 + vendor=hp
2801 + ;;
2802 -hiux*)
2803 vendor=hitachi
2804 ;;
2805 @@ -934,21 +1520,47 @@
2806 -genix*)
2807 vendor=ns
2808 ;;
2809 - -mvs*)
2810 + -mvs* | -opened*)
2811 + vendor=ibm
2812 + ;;
2813 + -os400*)
2814 vendor=ibm
2815 ;;
2816 -ptx*)
2817 vendor=sequent
2818 ;;
2819 - -vxsim* | -vxworks*)
2820 + -tpf*)
2821 + vendor=ibm
2822 + ;;
2823 + -vxsim* | -vxworks* | -windiss*)
2824 vendor=wrs
2825 ;;
2826 -aux*)
2827 vendor=apple
2828 ;;
2829 + -hms*)
2830 + vendor=hitachi
2831 + ;;
2832 + -mpw* | -macos*)
2833 + vendor=apple
2834 + ;;
2835 + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
2836 + vendor=atari
2837 + ;;
2838 + -vos*)
2839 + vendor=stratus
2840 + ;;
2841 esac
2842 basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
2843 ;;
2844 esac
2845
2846 echo $basic_machine$os
2847 +exit 0
2848 +
2849 +# Local variables:
2850 +# eval: (add-hook 'write-file-hooks 'time-stamp)
2851 +# time-stamp-start: "timestamp='"
2852 +# time-stamp-format: "%:y-%02m-%02d"
2853 +# time-stamp-end: "'"
2854 +# End: