Remove building with NOCRYPTO option
[minix.git] / external / bsd / bind / dist / unit / atf-src / admin / config.sub
blob85186096a9e1c6953474b9294f9d5c6041d648cf
1 #! /bin/sh
2 # Configuration validation subroutine script.
3 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4 # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
5 # Free Software Foundation, Inc.
7 timestamp='2009-12-31'
9 # This file is (in principle) common to ALL GNU software.
10 # The presence of a machine in this file suggests that SOME GNU software
11 # can handle that machine. It does not imply ALL GNU software can.
13 # This file is free software; you can redistribute it and/or modify
14 # it under the terms of the GNU General Public License as published by
15 # the Free Software Foundation; either version 2 of the License, or
16 # (at your option) any later version.
18 # This program is distributed in the hope that it will be useful,
19 # but WITHOUT ANY WARRANTY; without even the implied warranty of
20 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 # GNU General Public License for more details.
23 # You should have received a copy of the GNU General Public License
24 # along with this program; if not, write to the Free Software
25 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
26 # 02110-1301, USA.
28 # As a special exception to the GNU General Public License, if you
29 # distribute this file as part of a program that contains a
30 # configuration script generated by Autoconf, you may include it under
31 # the same distribution terms that you use for the rest of that program.
34 # Please send patches to <config-patches@gnu.org>. Submit a context
35 # diff and a properly formatted GNU ChangeLog entry.
37 # Configuration subroutine to validate and canonicalize a configuration type.
38 # Supply the specified configuration type as an argument.
39 # If it is invalid, we print an error message on stderr and exit with code 1.
40 # Otherwise, we print the canonical config type on stdout and succeed.
42 # You can get the latest version of this script from:
43 # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
45 # This file is supposed to be the same for all GNU packages
46 # and recognize all the CPU types, system types and aliases
47 # that are meaningful with *any* GNU software.
48 # Each package is responsible for reporting which valid configurations
49 # it does not support. The user should be able to distinguish
50 # a failure to support a valid configuration from a meaningless
51 # configuration.
53 # The goal of this file is to map all the various variations of a given
54 # machine specification into a single specification in the form:
55 # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
56 # or in some cases, the newer four-part form:
57 # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
58 # It is wrong to echo any other type of specification.
60 me=`echo "$0" | sed -e 's,.*/,,'`
62 usage="\
63 Usage: $0 [OPTION] CPU-MFR-OPSYS
64 $0 [OPTION] ALIAS
66 Canonicalize a configuration name.
68 Operation modes:
69 -h, --help print this help, then exit
70 -t, --time-stamp print date of last modification, then exit
71 -v, --version print version number, then exit
73 Report bugs and patches to <config-patches@gnu.org>."
75 version="\
76 GNU config.sub ($timestamp)
78 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
79 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
80 Software Foundation, Inc.
82 This is free software; see the source for copying conditions. There is NO
83 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
85 help="
86 Try \`$me --help' for more information."
88 # Parse command line
89 while test $# -gt 0 ; do
90 case $1 in
91 --time-stamp | --time* | -t )
92 echo "$timestamp" ; exit ;;
93 --version | -v )
94 echo "$version" ; exit ;;
95 --help | --h* | -h )
96 echo "$usage"; exit ;;
97 -- ) # Stop option processing
98 shift; break ;;
99 - ) # Use stdin as input.
100 break ;;
101 -* )
102 echo "$me: invalid option $1$help"
103 exit 1 ;;
105 *local*)
106 # First pass through any local machine types.
107 echo $1
108 exit ;;
111 break ;;
112 esac
113 done
115 case $# in
116 0) echo "$me: missing argument$help" >&2
117 exit 1;;
118 1) ;;
119 *) echo "$me: too many arguments$help" >&2
120 exit 1;;
121 esac
123 # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
124 # Here we must recognize all the valid KERNEL-OS combinations.
125 maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
126 case $maybe_os in
127 nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \
128 uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \
129 kopensolaris*-gnu* | \
130 storm-chaos* | os2-emx* | rtmk-nova*)
131 os=-$maybe_os
132 basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
135 basic_machine=`echo $1 | sed 's/-[^-]*$//'`
136 if [ $basic_machine != $1 ]
137 then os=`echo $1 | sed 's/.*-/-/'`
138 else os=; fi
140 esac
142 ### Let's recognize common machines as not being operating systems so
143 ### that things like config.sub decstation-3100 work. We also
144 ### recognize some manufacturers as not being operating systems, so we
145 ### can provide default operating systems below.
146 case $os in
147 -sun*os*)
148 # Prevent following clause from handling this invalid input.
150 -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
151 -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
152 -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
153 -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
154 -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
155 -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
156 -apple | -axis | -knuth | -cray | -microblaze)
158 basic_machine=$1
160 -bluegene*)
161 os=-cnk
163 -sim | -cisco | -oki | -wec | -winbond)
165 basic_machine=$1
167 -scout)
169 -wrs)
170 os=-vxworks
171 basic_machine=$1
173 -chorusos*)
174 os=-chorusos
175 basic_machine=$1
177 -chorusrdb)
178 os=-chorusrdb
179 basic_machine=$1
181 -hiux*)
182 os=-hiuxwe2
184 -sco6)
185 os=-sco5v6
186 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
188 -sco5)
189 os=-sco3.2v5
190 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
192 -sco4)
193 os=-sco3.2v4
194 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
196 -sco3.2.[4-9]*)
197 os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
198 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
200 -sco3.2v[4-9]*)
201 # Don't forget version if it is 3.2v4 or newer.
202 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
204 -sco5v6*)
205 # Don't forget version if it is 3.2v4 or newer.
206 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
208 -sco*)
209 os=-sco3.2v2
210 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
212 -udk*)
213 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
215 -isc)
216 os=-isc2.2
217 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
219 -clix*)
220 basic_machine=clipper-intergraph
222 -isc*)
223 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
225 -lynx*)
226 os=-lynxos
228 -ptx*)
229 basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
231 -windowsnt*)
232 os=`echo $os | sed -e 's/windowsnt/winnt/'`
234 -psos*)
235 os=-psos
237 -mint | -mint[0-9]*)
238 basic_machine=m68k-atari
239 os=-mint
241 esac
243 # Decode aliases for certain CPU-COMPANY combinations.
244 case $basic_machine in
245 # Recognize the basic CPU types without company name.
246 # Some are omitted here because they have special meanings below.
247 1750a | 580 \
248 | a29k \
249 | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
250 | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
251 | am33_2.0 \
252 | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \
253 | bfin \
254 | c4x | clipper \
255 | d10v | d30v | dlx | dsp16xx \
256 | fido | fr30 | frv \
257 | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
258 | i370 | i860 | i960 | ia64 \
259 | ip2k | iq2000 \
260 | lm32 \
261 | m32c | m32r | m32rle | m68000 | m68k | m88k \
262 | maxq | mb | microblaze | mcore | mep | metag \
263 | mips | mipsbe | mipseb | mipsel | mipsle \
264 | mips16 \
265 | mips64 | mips64el \
266 | mips64octeon | mips64octeonel \
267 | mips64orion | mips64orionel \
268 | mips64r5900 | mips64r5900el \
269 | mips64vr | mips64vrel \
270 | mips64vr4100 | mips64vr4100el \
271 | mips64vr4300 | mips64vr4300el \
272 | mips64vr5000 | mips64vr5000el \
273 | mips64vr5900 | mips64vr5900el \
274 | mipsisa32 | mipsisa32el \
275 | mipsisa32r2 | mipsisa32r2el \
276 | mipsisa64 | mipsisa64el \
277 | mipsisa64r2 | mipsisa64r2el \
278 | mipsisa64sb1 | mipsisa64sb1el \
279 | mipsisa64sr71k | mipsisa64sr71kel \
280 | mipstx39 | mipstx39el \
281 | mn10200 | mn10300 \
282 | moxie \
283 | mt \
284 | msp430 \
285 | nios | nios2 \
286 | ns16k | ns32k \
287 | or32 \
288 | pdp10 | pdp11 | pj | pjl \
289 | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
290 | pyramid \
291 | rx \
292 | score \
293 | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
294 | sh64 | sh64le \
295 | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
296 | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
297 | spu | strongarm \
298 | tahoe | thumb | tic4x | tic80 | tron \
299 | ubicom32 \
300 | v850 | v850e \
301 | we32k \
302 | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
303 | z8k | z80)
304 basic_machine=$basic_machine-unknown
306 m6811 | m68hc11 | m6812 | m68hc12 | picochip)
307 # Motorola 68HC11/12.
308 basic_machine=$basic_machine-unknown
309 os=-none
311 m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
313 ms1)
314 basic_machine=mt-unknown
317 # We use `pc' rather than `unknown'
318 # because (1) that's what they normally are, and
319 # (2) the word "unknown" tends to confuse beginning users.
320 i*86 | x86_64)
321 basic_machine=$basic_machine-pc
323 # Object if more than one company name word.
324 *-*-*)
325 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
326 exit 1
328 # Recognize the basic CPU types with company name.
329 580-* \
330 | a29k-* \
331 | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
332 | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
333 | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
334 | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
335 | avr-* | avr32-* \
336 | bfin-* | bs2000-* \
337 | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
338 | clipper-* | craynv-* | cydra-* \
339 | d10v-* | d30v-* | dlx-* \
340 | elxsi-* \
341 | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
342 | h8300-* | h8500-* \
343 | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
344 | i*86-* | i860-* | i960-* | ia64-* \
345 | ip2k-* | iq2000-* \
346 | lm32-* \
347 | m32c-* | m32r-* | m32rle-* \
348 | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
349 | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \
350 | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
351 | mips16-* \
352 | mips64-* | mips64el-* \
353 | mips64octeon-* | mips64octeonel-* \
354 | mips64orion-* | mips64orionel-* \
355 | mips64r5900-* | mips64r5900el-* \
356 | mips64vr-* | mips64vrel-* \
357 | mips64vr4100-* | mips64vr4100el-* \
358 | mips64vr4300-* | mips64vr4300el-* \
359 | mips64vr5000-* | mips64vr5000el-* \
360 | mips64vr5900-* | mips64vr5900el-* \
361 | mipsisa32-* | mipsisa32el-* \
362 | mipsisa32r2-* | mipsisa32r2el-* \
363 | mipsisa64-* | mipsisa64el-* \
364 | mipsisa64r2-* | mipsisa64r2el-* \
365 | mipsisa64sb1-* | mipsisa64sb1el-* \
366 | mipsisa64sr71k-* | mipsisa64sr71kel-* \
367 | mipstx39-* | mipstx39el-* \
368 | mmix-* \
369 | mt-* \
370 | msp430-* \
371 | nios-* | nios2-* \
372 | none-* | np1-* | ns16k-* | ns32k-* \
373 | orion-* \
374 | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
375 | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
376 | pyramid-* \
377 | romp-* | rs6000-* | rx-* \
378 | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
379 | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
380 | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
381 | sparclite-* \
382 | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
383 | tahoe-* | thumb-* \
384 | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* | tile-* \
385 | tron-* \
386 | ubicom32-* \
387 | v850-* | v850e-* | vax-* \
388 | we32k-* \
389 | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
390 | xstormy16-* | xtensa*-* \
391 | ymp-* \
392 | z8k-* | z80-*)
394 # Recognize the basic CPU types without company name, with glob match.
395 xtensa*)
396 basic_machine=$basic_machine-unknown
398 # Recognize the various machine names and aliases which stand
399 # for a CPU type and a company and sometimes even an OS.
400 386bsd)
401 basic_machine=i386-unknown
402 os=-bsd
404 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
405 basic_machine=m68000-att
407 3b*)
408 basic_machine=we32k-att
410 a29khif)
411 basic_machine=a29k-amd
412 os=-udi
414 abacus)
415 basic_machine=abacus-unknown
417 adobe68k)
418 basic_machine=m68010-adobe
419 os=-scout
421 alliant | fx80)
422 basic_machine=fx80-alliant
424 altos | altos3068)
425 basic_machine=m68k-altos
427 am29k)
428 basic_machine=a29k-none
429 os=-bsd
431 amd64)
432 basic_machine=x86_64-pc
434 amd64-*)
435 basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
437 amdahl)
438 basic_machine=580-amdahl
439 os=-sysv
441 amiga | amiga-*)
442 basic_machine=m68k-unknown
444 amigaos | amigados)
445 basic_machine=m68k-unknown
446 os=-amigaos
448 amigaunix | amix)
449 basic_machine=m68k-unknown
450 os=-sysv4
452 apollo68)
453 basic_machine=m68k-apollo
454 os=-sysv
456 apollo68bsd)
457 basic_machine=m68k-apollo
458 os=-bsd
460 aros)
461 basic_machine=i386-pc
462 os=-aros
464 aux)
465 basic_machine=m68k-apple
466 os=-aux
468 balance)
469 basic_machine=ns32k-sequent
470 os=-dynix
472 blackfin)
473 basic_machine=bfin-unknown
474 os=-linux
476 blackfin-*)
477 basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
478 os=-linux
480 bluegene*)
481 basic_machine=powerpc-ibm
482 os=-cnk
484 c90)
485 basic_machine=c90-cray
486 os=-unicos
488 cegcc)
489 basic_machine=arm-unknown
490 os=-cegcc
492 convex-c1)
493 basic_machine=c1-convex
494 os=-bsd
496 convex-c2)
497 basic_machine=c2-convex
498 os=-bsd
500 convex-c32)
501 basic_machine=c32-convex
502 os=-bsd
504 convex-c34)
505 basic_machine=c34-convex
506 os=-bsd
508 convex-c38)
509 basic_machine=c38-convex
510 os=-bsd
512 cray | j90)
513 basic_machine=j90-cray
514 os=-unicos
516 craynv)
517 basic_machine=craynv-cray
518 os=-unicosmp
520 cr16)
521 basic_machine=cr16-unknown
522 os=-elf
524 crds | unos)
525 basic_machine=m68k-crds
527 crisv32 | crisv32-* | etraxfs*)
528 basic_machine=crisv32-axis
530 cris | cris-* | etrax*)
531 basic_machine=cris-axis
533 crx)
534 basic_machine=crx-unknown
535 os=-elf
537 da30 | da30-*)
538 basic_machine=m68k-da30
540 decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
541 basic_machine=mips-dec
543 decsystem10* | dec10*)
544 basic_machine=pdp10-dec
545 os=-tops10
547 decsystem20* | dec20*)
548 basic_machine=pdp10-dec
549 os=-tops20
551 delta | 3300 | motorola-3300 | motorola-delta \
552 | 3300-motorola | delta-motorola)
553 basic_machine=m68k-motorola
555 delta88)
556 basic_machine=m88k-motorola
557 os=-sysv3
559 dicos)
560 basic_machine=i686-pc
561 os=-dicos
563 djgpp)
564 basic_machine=i586-pc
565 os=-msdosdjgpp
567 dpx20 | dpx20-*)
568 basic_machine=rs6000-bull
569 os=-bosx
571 dpx2* | dpx2*-bull)
572 basic_machine=m68k-bull
573 os=-sysv3
575 ebmon29k)
576 basic_machine=a29k-amd
577 os=-ebmon
579 elxsi)
580 basic_machine=elxsi-elxsi
581 os=-bsd
583 encore | umax | mmax)
584 basic_machine=ns32k-encore
586 es1800 | OSE68k | ose68k | ose | OSE)
587 basic_machine=m68k-ericsson
588 os=-ose
590 fx2800)
591 basic_machine=i860-alliant
593 genix)
594 basic_machine=ns32k-ns
596 gmicro)
597 basic_machine=tron-gmicro
598 os=-sysv
600 go32)
601 basic_machine=i386-pc
602 os=-go32
604 h3050r* | hiux*)
605 basic_machine=hppa1.1-hitachi
606 os=-hiuxwe2
608 h8300hms)
609 basic_machine=h8300-hitachi
610 os=-hms
612 h8300xray)
613 basic_machine=h8300-hitachi
614 os=-xray
616 h8500hms)
617 basic_machine=h8500-hitachi
618 os=-hms
620 harris)
621 basic_machine=m88k-harris
622 os=-sysv3
624 hp300-*)
625 basic_machine=m68k-hp
627 hp300bsd)
628 basic_machine=m68k-hp
629 os=-bsd
631 hp300hpux)
632 basic_machine=m68k-hp
633 os=-hpux
635 hp3k9[0-9][0-9] | hp9[0-9][0-9])
636 basic_machine=hppa1.0-hp
638 hp9k2[0-9][0-9] | hp9k31[0-9])
639 basic_machine=m68000-hp
641 hp9k3[2-9][0-9])
642 basic_machine=m68k-hp
644 hp9k6[0-9][0-9] | hp6[0-9][0-9])
645 basic_machine=hppa1.0-hp
647 hp9k7[0-79][0-9] | hp7[0-79][0-9])
648 basic_machine=hppa1.1-hp
650 hp9k78[0-9] | hp78[0-9])
651 # FIXME: really hppa2.0-hp
652 basic_machine=hppa1.1-hp
654 hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
655 # FIXME: really hppa2.0-hp
656 basic_machine=hppa1.1-hp
658 hp9k8[0-9][13679] | hp8[0-9][13679])
659 basic_machine=hppa1.1-hp
661 hp9k8[0-9][0-9] | hp8[0-9][0-9])
662 basic_machine=hppa1.0-hp
664 hppa-next)
665 os=-nextstep3
667 hppaosf)
668 basic_machine=hppa1.1-hp
669 os=-osf
671 hppro)
672 basic_machine=hppa1.1-hp
673 os=-proelf
675 i370-ibm* | ibm*)
676 basic_machine=i370-ibm
678 # I'm not sure what "Sysv32" means. Should this be sysv3.2?
679 i*86v32)
680 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
681 os=-sysv32
683 i*86v4*)
684 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
685 os=-sysv4
687 i*86v)
688 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
689 os=-sysv
691 i*86sol2)
692 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
693 os=-solaris2
695 i386mach)
696 basic_machine=i386-mach
697 os=-mach
699 i386-vsta | vsta)
700 basic_machine=i386-unknown
701 os=-vsta
703 iris | iris4d)
704 basic_machine=mips-sgi
705 case $os in
706 -irix*)
709 os=-irix4
711 esac
713 isi68 | isi)
714 basic_machine=m68k-isi
715 os=-sysv
717 m68knommu)
718 basic_machine=m68k-unknown
719 os=-linux
721 m68knommu-*)
722 basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
723 os=-linux
725 m88k-omron*)
726 basic_machine=m88k-omron
728 magnum | m3230)
729 basic_machine=mips-mips
730 os=-sysv
732 merlin)
733 basic_machine=ns32k-utek
734 os=-sysv
736 microblaze)
737 basic_machine=microblaze-xilinx
739 mingw32)
740 basic_machine=i386-pc
741 os=-mingw32
743 mingw32ce)
744 basic_machine=arm-unknown
745 os=-mingw32ce
747 miniframe)
748 basic_machine=m68000-convergent
750 *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*)
751 basic_machine=m68k-atari
752 os=-mint
754 mips3*-*)
755 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
757 mips3*)
758 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
760 monitor)
761 basic_machine=m68k-rom68k
762 os=-coff
764 morphos)
765 basic_machine=powerpc-unknown
766 os=-morphos
768 msdos)
769 basic_machine=i386-pc
770 os=-msdos
772 ms1-*)
773 basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
775 mvs)
776 basic_machine=i370-ibm
777 os=-mvs
779 ncr3000)
780 basic_machine=i486-ncr
781 os=-sysv4
783 netbsd386)
784 basic_machine=i386-unknown
785 os=-netbsd
787 netwinder)
788 basic_machine=armv4l-rebel
789 os=-linux
791 news | news700 | news800 | news900)
792 basic_machine=m68k-sony
793 os=-newsos
795 news1000)
796 basic_machine=m68030-sony
797 os=-newsos
799 news-3600 | risc-news)
800 basic_machine=mips-sony
801 os=-newsos
803 necv70)
804 basic_machine=v70-nec
805 os=-sysv
807 next | m*-next )
808 basic_machine=m68k-next
809 case $os in
810 -nextstep* )
812 -ns2*)
813 os=-nextstep2
816 os=-nextstep3
818 esac
820 nh3000)
821 basic_machine=m68k-harris
822 os=-cxux
824 nh[45]000)
825 basic_machine=m88k-harris
826 os=-cxux
828 nindy960)
829 basic_machine=i960-intel
830 os=-nindy
832 mon960)
833 basic_machine=i960-intel
834 os=-mon960
836 nonstopux)
837 basic_machine=mips-compaq
838 os=-nonstopux
840 np1)
841 basic_machine=np1-gould
843 nsr-tandem)
844 basic_machine=nsr-tandem
846 op50n-* | op60c-*)
847 basic_machine=hppa1.1-oki
848 os=-proelf
850 openrisc | openrisc-*)
851 basic_machine=or32-unknown
853 os400)
854 basic_machine=powerpc-ibm
855 os=-os400
857 OSE68000 | ose68000)
858 basic_machine=m68000-ericsson
859 os=-ose
861 os68k)
862 basic_machine=m68k-none
863 os=-os68k
865 pa-hitachi)
866 basic_machine=hppa1.1-hitachi
867 os=-hiuxwe2
869 paragon)
870 basic_machine=i860-intel
871 os=-osf
873 parisc)
874 basic_machine=hppa-unknown
875 os=-linux
877 parisc-*)
878 basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
879 os=-linux
881 pbd)
882 basic_machine=sparc-tti
884 pbb)
885 basic_machine=m68k-tti
887 pc532 | pc532-*)
888 basic_machine=ns32k-pc532
890 pc98)
891 basic_machine=i386-pc
893 pc98-*)
894 basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`
896 pentium | p5 | k5 | k6 | nexgen | viac3)
897 basic_machine=i586-pc
899 pentiumpro | p6 | 6x86 | athlon | athlon_*)
900 basic_machine=i686-pc
902 pentiumii | pentium2 | pentiumiii | pentium3)
903 basic_machine=i686-pc
905 pentium4)
906 basic_machine=i786-pc
908 pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
909 basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
911 pentiumpro-* | p6-* | 6x86-* | athlon-*)
912 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
914 pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
915 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
917 pentium4-*)
918 basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
921 basic_machine=pn-gould
923 power) basic_machine=power-ibm
925 ppc) basic_machine=powerpc-unknown
927 ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
929 ppcle | powerpclittle | ppc-le | powerpc-little)
930 basic_machine=powerpcle-unknown
932 ppcle-* | powerpclittle-*)
933 basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
935 ppc64) basic_machine=powerpc64-unknown
937 ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
939 ppc64le | powerpc64little | ppc64-le | powerpc64-little)
940 basic_machine=powerpc64le-unknown
942 ppc64le-* | powerpc64little-*)
943 basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
945 ps2)
946 basic_machine=i386-ibm
948 pw32)
949 basic_machine=i586-unknown
950 os=-pw32
952 rdos)
953 basic_machine=i386-pc
954 os=-rdos
956 rom68k)
957 basic_machine=m68k-rom68k
958 os=-coff
960 rm[46]00)
961 basic_machine=mips-siemens
963 rtpc | rtpc-*)
964 basic_machine=romp-ibm
966 s390 | s390-*)
967 basic_machine=s390-ibm
969 s390x | s390x-*)
970 basic_machine=s390x-ibm
972 sa29200)
973 basic_machine=a29k-amd
974 os=-udi
976 sb1)
977 basic_machine=mipsisa64sb1-unknown
979 sb1el)
980 basic_machine=mipsisa64sb1el-unknown
982 sde)
983 basic_machine=mipsisa32-sde
984 os=-elf
986 sei)
987 basic_machine=mips-sei
988 os=-seiux
990 sequent)
991 basic_machine=i386-sequent
994 basic_machine=sh-hitachi
995 os=-hms
997 sh5el)
998 basic_machine=sh5le-unknown
1000 sh64)
1001 basic_machine=sh64-unknown
1003 sparclite-wrs | simso-wrs)
1004 basic_machine=sparclite-wrs
1005 os=-vxworks
1007 sps7)
1008 basic_machine=m68k-bull
1009 os=-sysv2
1011 spur)
1012 basic_machine=spur-unknown
1014 st2000)
1015 basic_machine=m68k-tandem
1017 stratus)
1018 basic_machine=i860-stratus
1019 os=-sysv4
1021 sun2)
1022 basic_machine=m68000-sun
1024 sun2os3)
1025 basic_machine=m68000-sun
1026 os=-sunos3
1028 sun2os4)
1029 basic_machine=m68000-sun
1030 os=-sunos4
1032 sun3os3)
1033 basic_machine=m68k-sun
1034 os=-sunos3
1036 sun3os4)
1037 basic_machine=m68k-sun
1038 os=-sunos4
1040 sun4os3)
1041 basic_machine=sparc-sun
1042 os=-sunos3
1044 sun4os4)
1045 basic_machine=sparc-sun
1046 os=-sunos4
1048 sun4sol2)
1049 basic_machine=sparc-sun
1050 os=-solaris2
1052 sun3 | sun3-*)
1053 basic_machine=m68k-sun
1055 sun4)
1056 basic_machine=sparc-sun
1058 sun386 | sun386i | roadrunner)
1059 basic_machine=i386-sun
1061 sv1)
1062 basic_machine=sv1-cray
1063 os=-unicos
1065 symmetry)
1066 basic_machine=i386-sequent
1067 os=-dynix
1069 t3e)
1070 basic_machine=alphaev5-cray
1071 os=-unicos
1073 t90)
1074 basic_machine=t90-cray
1075 os=-unicos
1077 tic54x | c54x*)
1078 basic_machine=tic54x-unknown
1079 os=-coff
1081 tic55x | c55x*)
1082 basic_machine=tic55x-unknown
1083 os=-coff
1085 tic6x | c6x*)
1086 basic_machine=tic6x-unknown
1087 os=-coff
1089 tile*)
1090 basic_machine=tile-unknown
1091 os=-linux-gnu
1093 tx39)
1094 basic_machine=mipstx39-unknown
1096 tx39el)
1097 basic_machine=mipstx39el-unknown
1099 toad1)
1100 basic_machine=pdp10-xkl
1101 os=-tops20
1103 tower | tower-32)
1104 basic_machine=m68k-ncr
1106 tpf)
1107 basic_machine=s390x-ibm
1108 os=-tpf
1110 udi29k)
1111 basic_machine=a29k-amd
1112 os=-udi
1114 ultra3)
1115 basic_machine=a29k-nyu
1116 os=-sym1
1118 v810 | necv810)
1119 basic_machine=v810-nec
1120 os=-none
1122 vaxv)
1123 basic_machine=vax-dec
1124 os=-sysv
1126 vms)
1127 basic_machine=vax-dec
1128 os=-vms
1130 vpp*|vx|vx-*)
1131 basic_machine=f301-fujitsu
1133 vxworks960)
1134 basic_machine=i960-wrs
1135 os=-vxworks
1137 vxworks68)
1138 basic_machine=m68k-wrs
1139 os=-vxworks
1141 vxworks29k)
1142 basic_machine=a29k-wrs
1143 os=-vxworks
1145 w65*)
1146 basic_machine=w65-wdc
1147 os=-none
1149 w89k-*)
1150 basic_machine=hppa1.1-winbond
1151 os=-proelf
1153 xbox)
1154 basic_machine=i686-pc
1155 os=-mingw32
1157 xps | xps100)
1158 basic_machine=xps100-honeywell
1160 ymp)
1161 basic_machine=ymp-cray
1162 os=-unicos
1164 z8k-*-coff)
1165 basic_machine=z8k-unknown
1166 os=-sim
1168 z80-*-coff)
1169 basic_machine=z80-unknown
1170 os=-sim
1172 none)
1173 basic_machine=none-none
1174 os=-none
1177 # Here we handle the default manufacturer of certain CPU types. It is in
1178 # some cases the only manufacturer, in others, it is the most popular.
1179 w89k)
1180 basic_machine=hppa1.1-winbond
1182 op50n)
1183 basic_machine=hppa1.1-oki
1185 op60c)
1186 basic_machine=hppa1.1-oki
1188 romp)
1189 basic_machine=romp-ibm
1191 mmix)
1192 basic_machine=mmix-knuth
1194 rs6000)
1195 basic_machine=rs6000-ibm
1197 vax)
1198 basic_machine=vax-dec
1200 pdp10)
1201 # there are many clones, so DEC is not a safe bet
1202 basic_machine=pdp10-unknown
1204 pdp11)
1205 basic_machine=pdp11-dec
1207 we32k)
1208 basic_machine=we32k-att
1210 sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
1211 basic_machine=sh-unknown
1213 sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
1214 basic_machine=sparc-sun
1216 cydra)
1217 basic_machine=cydra-cydrome
1219 orion)
1220 basic_machine=orion-highlevel
1222 orion105)
1223 basic_machine=clipper-highlevel
1225 mac | mpw | mac-mpw)
1226 basic_machine=m68k-apple
1228 pmac | pmac-mpw)
1229 basic_machine=powerpc-apple
1231 *-unknown)
1232 # Make sure to match an already-canonicalized machine name.
1235 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
1236 exit 1
1238 esac
1240 # Here we canonicalize certain aliases for manufacturers.
1241 case $basic_machine in
1242 *-digital*)
1243 basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
1245 *-commodore*)
1246 basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
1250 esac
1252 # Decode manufacturer-specific aliases for certain operating systems.
1254 if [ x"$os" != x"" ]
1255 then
1256 case $os in
1257 # First match some system type aliases
1258 # that might get confused with valid system types.
1259 # -solaris* is a basic system type, with this one exception.
1260 -auroraux)
1261 os=-auroraux
1263 -solaris1 | -solaris1.*)
1264 os=`echo $os | sed -e 's|solaris1|sunos4|'`
1266 -solaris)
1267 os=-solaris2
1269 -svr4*)
1270 os=-sysv4
1272 -unixware*)
1273 os=-sysv4.2uw
1275 -gnu/linux*)
1276 os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
1278 # First accept the basic system types.
1279 # The portable systems comes first.
1280 # Each alternative MUST END IN A *, to match a version number.
1281 # -sysv* is not here because it comes later, after sysvr4.
1282 -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
1283 | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
1284 | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
1285 | -sym* | -kopensolaris* \
1286 | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
1287 | -aos* | -aros* \
1288 | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
1289 | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
1290 | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
1291 | -openbsd* | -solidbsd* \
1292 | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
1293 | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
1294 | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
1295 | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
1296 | -chorusos* | -chorusrdb* | -cegcc* \
1297 | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
1298 | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \
1299 | -uxpv* | -beos* | -mpeix* | -udk* \
1300 | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
1301 | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
1302 | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
1303 | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
1304 | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
1305 | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
1306 | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
1307 # Remember, each alternative MUST END IN *, to match a version number.
1309 -qnx*)
1310 case $basic_machine in
1311 x86-* | i*86-*)
1314 os=-nto$os
1316 esac
1318 -nto-qnx*)
1320 -nto*)
1321 os=`echo $os | sed -e 's|nto|nto-qnx|'`
1323 -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
1324 | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
1325 | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
1327 -mac*)
1328 os=`echo $os | sed -e 's|mac|macos|'`
1330 -linux-dietlibc)
1331 os=-linux-dietlibc
1333 -linux*)
1334 os=`echo $os | sed -e 's|linux|linux-gnu|'`
1336 -sunos5*)
1337 os=`echo $os | sed -e 's|sunos5|solaris2|'`
1339 -sunos6*)
1340 os=`echo $os | sed -e 's|sunos6|solaris3|'`
1342 -opened*)
1343 os=-openedition
1345 -os400*)
1346 os=-os400
1348 -wince*)
1349 os=-wince
1351 -osfrose*)
1352 os=-osfrose
1354 -osf*)
1355 os=-osf
1357 -utek*)
1358 os=-bsd
1360 -dynix*)
1361 os=-bsd
1363 -acis*)
1364 os=-aos
1366 -atheos*)
1367 os=-atheos
1369 -syllable*)
1370 os=-syllable
1372 -386bsd)
1373 os=-bsd
1375 -ctix* | -uts*)
1376 os=-sysv
1378 -nova*)
1379 os=-rtmk-nova
1381 -ns2 )
1382 os=-nextstep2
1384 -nsk*)
1385 os=-nsk
1387 # Preserve the version number of sinix5.
1388 -sinix5.*)
1389 os=`echo $os | sed -e 's|sinix|sysv|'`
1391 -sinix*)
1392 os=-sysv4
1394 -tpf*)
1395 os=-tpf
1397 -triton*)
1398 os=-sysv3
1400 -oss*)
1401 os=-sysv3
1403 -svr4)
1404 os=-sysv4
1406 -svr3)
1407 os=-sysv3
1409 -sysvr4)
1410 os=-sysv4
1412 # This must come after -sysvr4.
1413 -sysv*)
1415 -ose*)
1416 os=-ose
1418 -es1800*)
1419 os=-ose
1421 -xenix)
1422 os=-xenix
1424 -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
1425 os=-mint
1427 -aros*)
1428 os=-aros
1430 -kaos*)
1431 os=-kaos
1433 -zvmoe)
1434 os=-zvmoe
1436 -dicos*)
1437 os=-dicos
1439 -nacl*)
1441 -none)
1444 # Get rid of the `-' at the beginning of $os.
1445 os=`echo $os | sed 's/[^-]*-//'`
1446 echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
1447 exit 1
1449 esac
1450 else
1452 # Here we handle the default operating systems that come with various machines.
1453 # The value should be what the vendor currently ships out the door with their
1454 # machine or put another way, the most popular os provided with the machine.
1456 # Note that if you're going to try to match "-MANUFACTURER" here (say,
1457 # "-sun"), then you have to tell the case statement up towards the top
1458 # that MANUFACTURER isn't an operating system. Otherwise, code above
1459 # will signal an error saying that MANUFACTURER isn't an operating
1460 # system, and we'll never get to this point.
1462 case $basic_machine in
1463 score-*)
1464 os=-elf
1466 spu-*)
1467 os=-elf
1469 *-acorn)
1470 os=-riscix1.2
1472 arm*-rebel)
1473 os=-linux
1475 arm*-semi)
1476 os=-aout
1478 c4x-* | tic4x-*)
1479 os=-coff
1481 # This must come before the *-dec entry.
1482 pdp10-*)
1483 os=-tops20
1485 pdp11-*)
1486 os=-none
1488 *-dec | vax-*)
1489 os=-ultrix4.2
1491 m68*-apollo)
1492 os=-domain
1494 i386-sun)
1495 os=-sunos4.0.2
1497 m68000-sun)
1498 os=-sunos3
1499 # This also exists in the configure program, but was not the
1500 # default.
1501 # os=-sunos4
1503 m68*-cisco)
1504 os=-aout
1506 mep-*)
1507 os=-elf
1509 mips*-cisco)
1510 os=-elf
1512 mips*-*)
1513 os=-elf
1515 or32-*)
1516 os=-coff
1518 *-tti) # must be before sparc entry or we get the wrong os.
1519 os=-sysv3
1521 sparc-* | *-sun)
1522 os=-sunos4.1.1
1524 *-be)
1525 os=-beos
1527 *-haiku)
1528 os=-haiku
1530 *-ibm)
1531 os=-aix
1533 *-knuth)
1534 os=-mmixware
1536 *-wec)
1537 os=-proelf
1539 *-winbond)
1540 os=-proelf
1542 *-oki)
1543 os=-proelf
1545 *-hp)
1546 os=-hpux
1548 *-hitachi)
1549 os=-hiux
1551 i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
1552 os=-sysv
1554 *-cbm)
1555 os=-amigaos
1557 *-dg)
1558 os=-dgux
1560 *-dolphin)
1561 os=-sysv3
1563 m68k-ccur)
1564 os=-rtu
1566 m88k-omron*)
1567 os=-luna
1569 *-next )
1570 os=-nextstep
1572 *-sequent)
1573 os=-ptx
1575 *-crds)
1576 os=-unos
1578 *-ns)
1579 os=-genix
1581 i370-*)
1582 os=-mvs
1584 *-next)
1585 os=-nextstep3
1587 *-gould)
1588 os=-sysv
1590 *-highlevel)
1591 os=-bsd
1593 *-encore)
1594 os=-bsd
1596 *-sgi)
1597 os=-irix
1599 *-siemens)
1600 os=-sysv4
1602 *-masscomp)
1603 os=-rtu
1605 f30[01]-fujitsu | f700-fujitsu)
1606 os=-uxpv
1608 *-rom68k)
1609 os=-coff
1611 *-*bug)
1612 os=-coff
1614 *-apple)
1615 os=-macos
1617 *-atari*)
1618 os=-mint
1621 os=-none
1623 esac
1626 # Here we handle the case where we know the os, and the CPU type, but not the
1627 # manufacturer. We pick the logical manufacturer.
1628 vendor=unknown
1629 case $basic_machine in
1630 *-unknown)
1631 case $os in
1632 -riscix*)
1633 vendor=acorn
1635 -sunos*)
1636 vendor=sun
1638 -cnk*|-aix*)
1639 vendor=ibm
1641 -beos*)
1642 vendor=be
1644 -hpux*)
1645 vendor=hp
1647 -mpeix*)
1648 vendor=hp
1650 -hiux*)
1651 vendor=hitachi
1653 -unos*)
1654 vendor=crds
1656 -dgux*)
1657 vendor=dg
1659 -luna*)
1660 vendor=omron
1662 -genix*)
1663 vendor=ns
1665 -mvs* | -opened*)
1666 vendor=ibm
1668 -os400*)
1669 vendor=ibm
1671 -ptx*)
1672 vendor=sequent
1674 -tpf*)
1675 vendor=ibm
1677 -vxsim* | -vxworks* | -windiss*)
1678 vendor=wrs
1680 -aux*)
1681 vendor=apple
1683 -hms*)
1684 vendor=hitachi
1686 -mpw* | -macos*)
1687 vendor=apple
1689 -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
1690 vendor=atari
1692 -vos*)
1693 vendor=stratus
1695 esac
1696 basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
1698 esac
1700 echo $basic_machine$os
1701 exit
1703 # Local variables:
1704 # eval: (add-hook 'write-file-hooks 'time-stamp)
1705 # time-stamp-start: "timestamp='"
1706 # time-stamp-format: "%:y-%02m-%02d"
1707 # time-stamp-end: "'"
1708 # End: