2
2
# Configuration validation subroutine script.
3
3
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4
# 2000, 2001, 2002 Free Software Foundation, Inc.
4
# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
8
8
# This file is (in principle) common to ALL GNU software.
9
9
# The presence of a machine in this file suggests that SOME GNU software
22
22
# You should have received a copy of the GNU General Public License
23
23
# along with this program; if not, write to the Free Software
24
# Foundation, Inc., 59 Temple Place - Suite 330,
25
# Boston, MA 02111-1307, USA.
24
# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
27
27
# As a special exception to the GNU General Public License, if you
28
28
# distribute this file as part of a program that contains a
29
29
# configuration script generated by Autoconf, you may include it under
30
30
# the same distribution terms that you use for the rest of that program.
32
33
# Please send patches to <config-patches@gnu.org>. Submit a context
33
34
# diff and a properly formatted ChangeLog entry.
71
72
GNU config.sub ($timestamp)
73
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
74
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
74
75
Free Software Foundation, Inc.
76
77
This is free software; see the source for copying conditions. There is NO
83
84
while test $# -gt 0 ; do
85
86
--time-stamp | --time* | -t )
86
echo "$timestamp" ; exit 0 ;;
87
echo "$timestamp" ; exit ;;
88
echo "$version" ; exit 0 ;;
89
echo "$version" ; exit ;;
89
90
--help | --h* | -h )
90
echo "$usage"; exit 0 ;;
91
echo "$usage"; exit ;;
91
92
-- ) # Stop option processing
93
94
- ) # Use stdin as input.
118
119
# Here we must recognize all the valid KERNEL-OS combinations.
119
120
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
120
121
case $maybe_os in
121
nto-qnx* | linux-gnu* | freebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
122
nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \
123
kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
123
125
basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
144
146
-convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
145
147
-c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
146
148
-harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
149
-apple | -axis | -knuth | -cray)
229
231
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
230
232
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
231
234
| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
233
237
| d10v | d30v | dlx | dsp16xx \
235
239
| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
236
240
| i370 | i860 | i960 | ia64 \
238
| m32r | m68000 | m68k | m88k | mcore \
242
| m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \
239
243
| mips | mipsbe | mipseb | mipsel | mipsle \
241
245
| mips64 | mips64el \
244
248
| mips64vr4100 | mips64vr4100el \
245
249
| mips64vr4300 | mips64vr4300el \
246
250
| mips64vr5000 | mips64vr5000el \
251
| mips64vr5900 | mips64vr5900el \
247
252
| mipsisa32 | mipsisa32el \
253
| mipsisa32r2 | mipsisa32r2el \
248
254
| mipsisa64 | mipsisa64el \
255
| mipsisa64r2 | mipsisa64r2el \
249
256
| mipsisa64sb1 | mipsisa64sb1el \
250
257
| mipsisa64sr71k | mipsisa64sr71kel \
251
258
| mipstx39 | mipstx39el \
252
259
| mn10200 | mn10300 \
253
262
| ns16k | ns32k \
255
264
| pdp10 | pdp11 | pj | pjl \
256
265
| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
258
| sh | sh[1234] | sh3e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
267
| sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
259
268
| sh64 | sh64le \
260
| sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
269
| sparc | sparc64 | sparc64b | sparc86x | sparclet | sparclite \
270
| sparcv8 | sparcv9 | sparcv9b \
262
| tahoe | thumb | tic80 | tron \
272
| tahoe | thumb | tic4x | tic80 | tron \
265
| x86 | xscale | xstormy16 | xtensa \
275
| x86 | xscale | xscalee[bl] | xstormy16 | xtensa \
267
277
basic_machine=$basic_machine-unknown
280
basic_machine=$basic_machine-unknown
269
282
m6811 | m68hc11 | m6812 | m68hc12)
270
283
# Motorola 68HC11/12.
271
284
basic_machine=$basic_machine-unknown
293
306
| alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
294
307
| arm-* | armbe-* | armle-* | armeb-* | armv*-* \
297
| c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* \
298
| clipper-* | cydra-* \
309
| bfin-* | bs2000-* \
310
| c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
311
| clipper-* | craynv-* | cydra-* \
299
312
| d10v-* | d30v-* | dlx-* \
301
314
| f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
302
315
| h8300-* | h8500-* \
303
316
| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
304
317
| i*86-* | i860-* | i960-* | ia64-* \
318
| ip2k-* | iq2000-* \
319
| m32r-* | m32rle-* \
307
320
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
308
| m88110-* | m88k-* | mcore-* \
321
| m88110-* | m88k-* | maxq-* | mcore-* \
309
322
| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
311
324
| mips64-* | mips64el-* \
314
327
| mips64vr4100-* | mips64vr4100el-* \
315
328
| mips64vr4300-* | mips64vr4300el-* \
316
329
| mips64vr5000-* | mips64vr5000el-* \
330
| mips64vr5900-* | mips64vr5900el-* \
317
331
| mipsisa32-* | mipsisa32el-* \
332
| mipsisa32r2-* | mipsisa32r2el-* \
318
333
| mipsisa64-* | mipsisa64el-* \
334
| mipsisa64r2-* | mipsisa64r2el-* \
319
335
| mipsisa64sb1-* | mipsisa64sb1el-* \
320
336
| mipsisa64sr71k-* | mipsisa64sr71kel-* \
321
| mipstx39 | mipstx39el \
337
| mipstx39-* | mipstx39el-* \
322
341
| none-* | np1-* | ns16k-* | ns32k-* \
324
343
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
325
344
| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
327
346
| romp-* | rs6000-* \
328
| sh-* | sh[1234]-* | sh3e-* | sh[34]eb-* | shbe-* \
347
| sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | shbe-* \
329
348
| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
330
| sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
331
| sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
332
| tahoe-* | thumb-* | tic30-* | tic4x-* | tic54x-* | tic80-* | tron-* \
349
| sparc-* | sparc64-* | sparc64b-* | sparc86x-* | sparclet-* \
351
| sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
352
| tahoe-* | thumb-* \
353
| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
333
355
| v850-* | v850e-* | vax-* \
335
| x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
357
| x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \
358
| xstormy16-* | xtensa-* \
340
364
# Recognize the various machine names and aliases which stand
341
365
# for a CPU type and a company and sometimes even an OS.
426
459
basic_machine=j90-cray
463
basic_machine=craynv-cray
467
basic_machine=cr16c-unknown
430
471
basic_machine=m68k-crds
473
crisv32 | crisv32-* | etraxfs*)
474
basic_machine=crisv32-axis
432
476
cris | cris-* | etrax*)
433
477
basic_machine=cris-axis
480
basic_machine=crx-unknown
436
484
basic_machine=m68k-da30
758
809
pentiumpro | p6 | 6x86 | athlon | athlon_*)
759
810
basic_machine=i686-pc
761
pentiumii | pentium2)
812
pentiumii | pentium2 | pentiumiii | pentium3)
762
813
basic_machine=i686-pc
816
basic_machine=i786-pc
764
818
pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
765
819
basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
767
821
pentiumpro-* | p6-* | 6x86-* | athlon-*)
768
822
basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
770
pentiumii-* | pentium2-*)
824
pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
771
825
basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
828
basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
774
831
basic_machine=pn-gould
776
833
power) basic_machine=power-ibm
836
basic_machine=powerpc-unknown
778
839
ppc) basic_machine=powerpc-unknown
780
841
ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
913
977
basic_machine=t90-cray
917
basic_machine=tic4x-unknown
921
981
basic_machine=tic54x-unknown
985
basic_machine=tic55x-unknown
989
basic_machine=tic6x-unknown
925
993
basic_machine=mipstx39-unknown
1024
1107
basic_machine=we32k-att
1026
sh3 | sh4 | sh3eb | sh4eb | sh[1234]le | sh3ele)
1109
sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele)
1027
1110
basic_machine=sh-unknown
1030
basic_machine=sh64-unknown
1032
sparc | sparcv9 | sparcv9b)
1112
sparc | sparcv8 | sparcv9 | sparcv9b)
1033
1113
basic_machine=sparc-sun
1099
1179
| -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
1100
1180
| -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
1101
1181
| -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
1182
| -aos* | -warpos* | -powerup* \
1103
1183
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
1104
1184
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
1105
| -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \
1106
| -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
1185
| -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \
1186
| -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
1187
| -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
1107
1188
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
1108
1189
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
1109
1190
| -chorusos* | -chorusrdb* \
1110
1191
| -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
1111
| -mingw32* | -linux* | -uxpv* | -beos* | -mpeix* | -udk* \
1192
| -mingw32* | -linux* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
1112
1193
| -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
1113
1194
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
1114
1195
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
1115
1196
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
1116
1197
| -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
1117
| -powermax* | -dnix*)
1198
| -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
1199
| -skyos* | -haiku*)
1118
1200
# Remember, each alternative MUST END IN *, to match a version number.
1132
1214
os=`echo $os | sed -e 's|nto|nto-qnx|'`
1134
1216
-sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
1135
| -windows* | -osx | -abug | -netware* | -os9* | -beos* \
1217
| -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
1136
1218
| -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
1139
1221
os=`echo $os | sed -e 's|mac|macos|'`
1142
1227
os=`echo $os | sed -e 's|sunos5|solaris2|'`