]>
Commit | Line | Data |
---|---|---|
4f183929 | 1 | #!/bin/sh |
378fd382 | 2 | # Configuration validation subroutine script, version 1.1. |
6559fbdb | 3 | # Copyright (C) 1991-1993 Free Software Foundation, Inc. |
378fd382 DZ |
4 | # This file is (in principle) common to ALL GNU software. |
5 | # The presence of a machine in this file suggests that SOME GNU software | |
6 | # can handle that machine. It does not imply ALL GNU software can. | |
a2ee3e6d JW |
7 | |
8 | #This file is free software; you can redistribute it and/or modify | |
9 | #it under the terms of the GNU General Public License as published by | |
10 | #the Free Software Foundation; either version 2 of the License, or | |
11 | #(at your option) any later version. | |
12 | ||
13 | #This program is distributed in the hope that it will be useful, | |
14 | #but WITHOUT ANY WARRANTY; without even the implied warranty of | |
15 | #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
16 | #GNU General Public License for more details. | |
17 | ||
18 | #You should have received a copy of the GNU General Public License | |
19 | #along with this program; if not, write to the Free Software | |
20 | #Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | |
21 | ||
4f183929 RP |
22 | |
23 | # Configuration subroutine to validate and canonicalize a configuration type. | |
24 | # Supply the specified configuration type as an argument. | |
25 | # If it is invalid, we print an error message on stderr and exit with code 1. | |
26 | # Otherwise, we print the canonical config type on stdout and succeed. | |
27 | ||
28 | # This file is supposed to be the same for all GNU packages | |
29 | # and recognize all the CPU types, system types and aliases | |
30 | # that are meaningful with *any* GNU software. | |
31 | # Each package is responsible for reporting which valid configurations | |
32 | # it does not support. The user should be able to distinguish | |
33 | # a failure to support a valid configuration from a meaningless | |
a2ee3e6d | 34 | # configuration. |
4f183929 | 35 | |
a2ee3e6d JW |
36 | # The goal of this file is to map all the various variations of a given |
37 | # machine specification into a single specification in the form: | |
38 | # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM | |
27a2a371 | 39 | # It is wrong to echo any other type of specification. |
8b204e6e | 40 | |
23ab00aa KR |
41 | if [ x$1 = x ] |
42 | then | |
43 | echo Configuration name missing. 1>&2 | |
44 | echo "Usage: $0 CPU-MFR-OPSYS" 1>&2 | |
45 | echo "or $0 ALIAS" 1>&2 | |
46 | echo where ALIAS is a recognized configuration type. 1>&2 | |
47 | exit 1 | |
48 | fi | |
49 | ||
a2ee3e6d JW |
50 | # First pass through any local machine types. |
51 | case $1 in | |
52 | *local*) | |
53 | echo $1 | |
54 | exit 0 | |
55 | ;; | |
56 | *) | |
69e87de2 | 57 | ;; |
a2ee3e6d | 58 | esac |
b9fe720d | 59 | |
a2ee3e6d | 60 | # Separate what the user gave into CPU-COMPANY and OS (if any). |
378fd382 | 61 | basic_machine=`echo $1 | sed 's/-[^-]*$//'` |
a2ee3e6d JW |
62 | if [ $basic_machine != $1 ] |
63 | then os=`echo $1 | sed 's/.*-/-/'` | |
64 | else os=; fi | |
caebaa16 | 65 | |
27a2a371 JW |
66 | ### Let's recognize common machines as not being operating systems so |
67 | ### that things like config.sub decstation-3100 work. We also | |
6559fbdb | 68 | ### recognize some manufacturers as not being operating systems, so we |
27a2a371 | 69 | ### can provide default operating systems below. |
a2ee3e6d JW |
70 | case $os in |
71 | -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ | |
72 | -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ | |
73 | -unicom* | -ibm* | -next* | -hp | -isi* | -apollo | -altos* | \ | |
378fd382 | 74 | -convergent* | -ncr* | -news | -32* | -3600* | -3100* | \ |
a2ee3e6d | 75 | -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ |
984b27cb | 76 | -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp) |
a2ee3e6d JW |
77 | os= |
78 | basic_machine=$1 | |
79 | ;; | |
378fd382 | 80 | -scout) # CYGNUS LOCAL |
f68be6f0 | 81 | ;; |
6559fbdb | 82 | -wrs) # CYGNUS LOCAL |
300f6a4f RS |
83 | os=vxworks |
84 | basic_machine=$1 | |
85 | ;; | |
27a2a371 JW |
86 | -sco3.2v[4-9]*) |
87 | # Don't forget version if it is 3.2v4 or newer. | |
6559fbdb | 88 | basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'` |
27a2a371 | 89 | ;; |
a2ee3e6d | 90 | -sco*) |
378fd382 | 91 | os=-sco3.2v2 |
6559fbdb | 92 | basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'` |
a2ee3e6d | 93 | ;; |
27a2a371 JW |
94 | -isc) |
95 | os=-isc2.2 | |
6559fbdb | 96 | basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'` |
27a2a371 | 97 | ;; |
378fd382 | 98 | -isc*) |
6559fbdb | 99 | basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'` |
a2ee3e6d | 100 | ;; |
a2ee3e6d | 101 | esac |
b9fe720d | 102 | |
a2ee3e6d JW |
103 | # Decode aliases for certain CPU-COMPANY combinations. |
104 | case $basic_machine in | |
105 | # Recognize the basic CPU types with without company name. | |
378fd382 DZ |
106 | # Some are omitted here because they have special meanings below. |
107 | tahoe | i[34]86 | i860 | m68k | m68000 | m88k | ns32k | arm | pyramid \ | |
108 | | tron | a29k | 580 | i960 | h8300 | hppa1.0 | hppa1.1 \ | |
6559fbdb | 109 | | alpha | we32k | ns16k | clipper | sparclite \ |
ba7f177a | 110 | | sparc | m680[01234]0 | m683?2 | z8k | v70 | h8500)# CYGNUS LOCAL |
a2ee3e6d JW |
111 | basic_machine=$basic_machine-unknown |
112 | ;; | |
113 | # Recognize the basic CPU types with with company name. | |
378fd382 DZ |
114 | vax-* | tahoe-* | i[34]86-* | i860-* | m68k-* | m68000-* | m88k-* \ |
115 | | sparc-* | ns32k-* | fx80-* | arm-* | c[123]* \ | |
a2ee3e6d JW |
116 | | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \ |
117 | | none-* | 580-* | cray2-* | h8300-* | i960-* | xmp-* | ymp-* \ | |
27a2a371 | 118 | | hppa1.0-* | hppa1.1-* | alpha-* | we32k-* | cydra-* | ns16k-* \ |
6559fbdb | 119 | | pn-* | np1-* | xps100-* | clipper-* | orion-* | sparclite-* \ |
984b27cb | 120 | | m680[01234]0-* | m683?2-* | z8k-* | h8500-* | sh-*) # CYGNUS LOCAL |
a2ee3e6d JW |
121 | ;; |
122 | # Recognize the various machine names and aliases which stand | |
123 | # for a CPU type and a company and sometimes even an OS. | |
25fa8f53 | 124 | # start-sanitize-v9 |
378fd382 | 125 | sparc64) # CYGNUS LOCAL |
a2ee3e6d | 126 | basic_machine=sparc64-sun |
6559fbdb | 127 | os=-elf64i64p |
a2ee3e6d | 128 | ;; |
6559fbdb | 129 | sparc64-*) # CYGNUS LOCAL |
a2ee3e6d | 130 | ;; |
25fa8f53 | 131 | # end-sanitize-v9 |
7054ee6d | 132 | |
984b27cb | 133 | |
ba7f177a PB |
134 | dpx20 | dpx20-*) # CYGNUS LOCAL |
135 | basic_machine=rs6000-bull | |
136 | os=-bosx | |
137 | ;; | |
a2ee3e6d JW |
138 | vaxv) |
139 | basic_machine=vax-dec | |
140 | os=-sysv | |
141 | ;; | |
142 | vms) | |
143 | basic_machine=vax-dec | |
144 | os=-vms | |
145 | ;; | |
378fd382 | 146 | i386mach) # CYGNUS LOCAL |
68cd7865 SEF |
147 | basic_machine=i386-mach |
148 | os=-mach | |
149 | ;; | |
6559fbdb RP |
150 | i[34]86v32) |
151 | basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'` | |
99aea58e | 152 | os=-sysv3.2 |
a2ee3e6d | 153 | ;; |
6559fbdb RP |
154 | i[34]86v4*) |
155 | basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'` | |
156 | os=-sysv4 | |
157 | ;; | |
158 | i[34]86v) | |
159 | basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'` | |
160 | os=-sysv | |
161 | ;; | |
162 | i[34]86sol2) | |
163 | basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'` | |
164 | os=-solaris2 | |
a2ee3e6d | 165 | ;; |
378fd382 | 166 | go32 | i386-go32) # CYGNUS LOCAL |
2501643a PB |
167 | basic_machine=i386-unknown |
168 | os=-go32 | |
169 | ;; | |
378fd382 | 170 | i386-linux* | linux) # CYGNUS LOCAL |
8bcd7db2 JW |
171 | basic_machine=i386-unknown |
172 | os=-linux | |
173 | ;; | |
378fd382 | 174 | 386bsd) # CYGNUS LOCAL |
23ab00aa KR |
175 | basic_machine=i386-unknown |
176 | os=-bsd | |
177 | ;; | |
a2ee3e6d JW |
178 | spur) |
179 | basic_machine=spur-unknown | |
180 | ;; | |
378fd382 DZ |
181 | alliant | fx80) |
182 | basic_machine=fx80-alliant | |
a2ee3e6d JW |
183 | ;; |
184 | convex-c1) | |
185 | basic_machine=c1-convex | |
378fd382 | 186 | os=-bsd |
a2ee3e6d JW |
187 | ;; |
188 | convex-c2) | |
189 | basic_machine=c2-convex | |
378fd382 | 190 | os=-bsd |
a2ee3e6d JW |
191 | ;; |
192 | convex-c32) | |
193 | basic_machine=c32-convex | |
378fd382 | 194 | os=-bsd |
a2ee3e6d JW |
195 | ;; |
196 | convex-c34) | |
197 | basic_machine=c34-convex | |
378fd382 | 198 | os=-bsd |
a2ee3e6d JW |
199 | ;; |
200 | convex-c38) | |
201 | basic_machine=c38-convex | |
378fd382 | 202 | os=-bsd |
a2ee3e6d JW |
203 | ;; |
204 | m88k-omron*) | |
205 | basic_machine=m88k-omron | |
206 | ;; | |
207 | merlin) | |
208 | basic_machine=ns32k-utek | |
209 | os=-sysv | |
210 | ;; | |
211 | crds | unos) | |
212 | basic_machine=m68k-crds | |
213 | ;; | |
378fd382 DZ |
214 | elxsi) |
215 | basic_machine=elxsi-elxsi | |
216 | os=-bsd | |
217 | ;; | |
a2ee3e6d JW |
218 | encore | umax | mmax) |
219 | basic_machine=ns32k-encore | |
a2ee3e6d JW |
220 | ;; |
221 | genix) | |
222 | basic_machine=ns32k-ns | |
223 | ;; | |
378fd382 DZ |
224 | iris | iris4d | \ |
225 | iris3 | iris4) # CYGNUS LOCAL | |
68cd7865 | 226 | basic_machine=mips-sgi |
378fd382 DZ |
227 | case $os in |
228 | -irix*) | |
229 | ;; | |
230 | *) | |
231 | os=-irix4 | |
232 | ;; | |
233 | esac | |
a2ee3e6d JW |
234 | ;; |
235 | news | news700 | news800 | news900) | |
236 | basic_machine=m68k-sony | |
237 | os=-newsos | |
238 | ;; | |
239 | 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) | |
378fd382 | 240 | basic_machine=m68000-att |
a2ee3e6d | 241 | ;; |
378fd382 | 242 | 3b*) |
de0f17d8 | 243 | basic_machine=we32k-att |
de0f17d8 | 244 | ;; |
a2ee3e6d JW |
245 | delta | 3300 | motorola-3300 | motorola-delta \ |
246 | | 3300-motorola | delta-motorola) | |
247 | basic_machine=m68k-motorola | |
248 | ;; | |
249 | balance) | |
250 | basic_machine=ns32k-sequent | |
251 | os=-dynix | |
252 | ;; | |
253 | pc532) | |
254 | basic_machine=ns32k-pc532 | |
255 | ;; | |
256 | symmetry) | |
257 | basic_machine=i386-sequent | |
258 | os=-dynix | |
259 | ;; | |
260 | sun2) | |
261 | basic_machine=m68000-sun | |
262 | ;; | |
263 | sun2os3) | |
264 | basic_machine=m68000-sun | |
265 | os=-sunos3 | |
266 | ;; | |
267 | sun2os4) | |
268 | basic_machine=m68000-sun | |
269 | os=-sunos4 | |
270 | ;; | |
271 | sun3os3) | |
272 | basic_machine=m68k-sun | |
273 | os=-sunos3 | |
274 | ;; | |
275 | sun3os4) | |
276 | basic_machine=m68k-sun | |
277 | os=-sunos4 | |
278 | ;; | |
279 | sun4os3) | |
280 | basic_machine=sparc-sun | |
281 | os=-sunos3 | |
282 | ;; | |
283 | sun4os4) | |
284 | basic_machine=sparc-sun | |
285 | os=-sunos4 | |
286 | ;; | |
378fd382 | 287 | sun4sol2) # CYGNUS LOCAL |
8bcd7db2 JW |
288 | basic_machine=sparc-sun |
289 | os=-solaris2 | |
290 | ;; | |
378fd382 | 291 | z8ksim) # CYGNUS LOCAL |
984b27cb | 292 | basic_machine=z8k-zilog |
de0f17d8 BK |
293 | os=-sim |
294 | ;; | |
984b27cb SC |
295 | z8k) # CYGNUS LOCAL |
296 | basic_machine=z8k-zilog | |
297 | ;; | |
a2ee3e6d JW |
298 | sun3) |
299 | basic_machine=m68k-sun | |
300 | ;; | |
301 | sun4) | |
302 | basic_machine=sparc-sun | |
303 | ;; | |
378fd382 | 304 | msdos) # CYGNUS LOCAL |
afba2b22 ILT |
305 | basic_machine=i386-unknown |
306 | os=-msdos | |
307 | ;; | |
a2ee3e6d | 308 | pbd) |
378fd382 DZ |
309 | basic_machine=sparc-tti |
310 | ;; | |
311 | pbb) | |
312 | basic_machine=m68k-tti | |
a2ee3e6d JW |
313 | ;; |
314 | sun386 | sun386i | roadrunner) | |
315 | basic_machine=i386-sun | |
316 | ;; | |
317 | ps2) | |
318 | basic_machine=i386-ibm | |
319 | ;; | |
378fd382 DZ |
320 | fx2800) |
321 | basic_machine=i860-alliant | |
322 | ;; | |
a2ee3e6d JW |
323 | next) |
324 | basic_machine=m68k-next | |
ad1f7512 | 325 | os=-bsd |
a2ee3e6d | 326 | ;; |
378fd382 DZ |
327 | amiga) |
328 | basic_machine=m68k-cbm | |
329 | ;; | |
27a2a371 JW |
330 | amigados) |
331 | basic_machine=m68k-cbm | |
332 | os=-amigados | |
333 | ;; | |
334 | amigaunix | amix) | |
335 | basic_machine=m68k-cbm | |
336 | os=-sysv4 | |
337 | ;; | |
a2ee3e6d JW |
338 | hp9k3[2-9][0-9]) |
339 | basic_machine=m68k-hp | |
340 | ;; | |
341 | hp9k31[0-9] | hp9k2[0-9][0-9]) | |
342 | basic_machine=m68000-hp | |
343 | ;; | |
8bcd7db2 JW |
344 | hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7) |
345 | basic_machine=hppa1.1-hp | |
346 | ;; | |
347 | hp9k8[0-9][0-9] | hp8[0-9][0-9]) | |
348 | basic_machine=hppa1.0-hp | |
a2ee3e6d JW |
349 | ;; |
350 | isi68 | isi) | |
351 | basic_machine=m68k-isi | |
352 | os=-sysv | |
353 | ;; | |
354 | apollo68) | |
355 | basic_machine=m68k-apollo | |
356 | os=-sysv | |
357 | ;; | |
378fd382 | 358 | apollo68bsd) # CYGNUS LOCAL |
68cd7865 SEF |
359 | basic_machine=m68k-apollo |
360 | os=-bsd | |
361 | ;; | |
a2ee3e6d JW |
362 | altos | altos3068) |
363 | basic_machine=m68k-altos | |
364 | ;; | |
365 | miniframe) | |
366 | basic_machine=m68000-convergent | |
367 | ;; | |
368 | tower | tower-32) | |
369 | basic_machine=m68k-ncr | |
370 | ;; | |
371 | news-3600 | risc-news) | |
372 | basic_machine=mips-sony | |
373 | os=-newsos | |
374 | ;; | |
378fd382 | 375 | st2000) # CYGNUS LOCAL |
012be2b1 | 376 | basic_machine=m68k-tandem |
68cd7865 | 377 | ;; |
378fd382 | 378 | decstation | decstation-3100 | pmax | pmin | dec3100 | decstatn) |
a2ee3e6d JW |
379 | basic_machine=mips-dec |
380 | ;; | |
381 | magnum | m3230) | |
382 | basic_machine=mips-mips | |
383 | os=-sysv | |
384 | ;; | |
385 | gmicro) | |
386 | basic_machine=tron-gmicro | |
387 | os=-sysv | |
388 | ;; | |
389 | rtpc | rtpc-*) | |
390 | basic_machine=romp-ibm | |
391 | ;; | |
392 | am29k) | |
393 | basic_machine=a29k-none | |
394 | os=-bsd | |
395 | ;; | |
396 | amdahl) | |
397 | basic_machine=580-amdahl | |
398 | os=-sysv | |
399 | ;; | |
378fd382 | 400 | stratus) # CYGNUS LOCAL |
dd16baba SEF |
401 | basic_machine=i860-stratus |
402 | os=-sysv4 | |
403 | ;; | |
a2ee3e6d JW |
404 | cray | ymp) |
405 | basic_machine=ymp-cray | |
406 | os=-unicos | |
407 | ;; | |
408 | cray2) | |
409 | basic_machine=cray2-cray | |
410 | os=-unicos | |
411 | ;; | |
412 | xmp) | |
413 | basic_machine=xmp-cray | |
414 | os=-unicos | |
415 | ;; | |
416 | delta88) | |
417 | basic_machine=m88k-motorola | |
6559fbdb | 418 | os=-sysv3 |
a2ee3e6d JW |
419 | ;; |
420 | dpx2) | |
421 | basic_machine=m68k-bull | |
422 | os=-sysv | |
423 | ;; | |
424 | ebmon29k) | |
425 | basic_machine=a29k-amd | |
426 | os=-ebmon | |
427 | ;; | |
378fd382 | 428 | h8300hms) # CYGNUS LOCAL |
a2ee3e6d | 429 | basic_machine=h8300-hitachi |
2501643a PB |
430 | os=-hms |
431 | ;; | |
984b27cb SC |
432 | |
433 | sh) # CYGNUS LOCAL | |
434 | basic_machine=sh-hitachi | |
435 | os=-hms | |
436 | ;; | |
437 | ||
438 | h8500hms) # CYGNUS LOCAL | |
439 | basic_machine=h8500-hitachi | |
440 | os=-hms | |
441 | ;; | |
378fd382 DZ |
442 | h8300xray) # CYGNUS LOCAL |
443 | basic_machine=h8300-hitachi | |
444 | os=-xray | |
445 | ;; | |
446 | h8300hds) | |
447 | basic_machine=h8300-hitachi | |
448 | os=-hds | |
449 | ;; | |
450 | udi29k) # CYGNUS LOCAL | |
2501643a PB |
451 | basic_machine=a29k-amd |
452 | os=-udi | |
453 | ;; | |
378fd382 | 454 | a29khif) # CYGNUS LOCAL |
2501643a PB |
455 | basic_machine=a29k-amd |
456 | os=-udi | |
457 | ;; | |
378fd382 | 458 | sa29200) # CYGNUS LOCAL |
2501643a PB |
459 | basic_machine=a29k-amd |
460 | os=-udi | |
461 | ;; | |
a2ee3e6d JW |
462 | harris) |
463 | basic_machine=m88k-harris | |
6559fbdb | 464 | os=-sysv3 |
a2ee3e6d JW |
465 | ;; |
466 | hp300bsd) | |
467 | basic_machine=m68k-hp | |
468 | os=-bsd | |
469 | ;; | |
470 | hp300hpux) | |
471 | basic_machine=m68k-hp | |
472 | os=-hpux | |
473 | ;; | |
474 | hp9k2[0-9][0-9] | hp9k31[0-9]) | |
475 | basic_machine=m68000-hp | |
476 | os=-hpux | |
477 | ;; | |
478 | hp9k3[2-9][0-9]) | |
479 | basic_machine=m68k-hp | |
480 | os=-hpux | |
481 | ;; | |
99a5da15 KR |
482 | hppaosf) |
483 | basic_machine=hppa1.1-hp | |
484 | os=-osf | |
485 | ;; | |
a2ee3e6d | 486 | ncr3000) |
afba2b22 | 487 | basic_machine=i486-ncr |
a2ee3e6d JW |
488 | os=-sysv4 |
489 | ;; | |
378fd382 | 490 | necv70) # CYGNUS LOCAL |
68cd7865 SEF |
491 | basic_machine=v70-nec |
492 | os=-sysv | |
493 | ;; | |
a2ee3e6d JW |
494 | news1000) |
495 | basic_machine=m68030-sony | |
496 | os=-newsos | |
497 | ;; | |
498 | nindy960) | |
499 | basic_machine=i960-intel | |
500 | os=-nindy | |
501 | ;; | |
502 | pn) | |
503 | basic_machine=pn-gould | |
a2ee3e6d JW |
504 | ;; |
505 | np1) | |
506 | basic_machine=np1-gould | |
a2ee3e6d JW |
507 | ;; |
508 | ultra3) | |
509 | basic_machine=a29k-nyu | |
c1e296fc | 510 | os=-sym1 |
a2ee3e6d JW |
511 | ;; |
512 | vxworks960) | |
513 | basic_machine=i960-wrs | |
514 | os=-vxworks | |
515 | ;; | |
516 | vxworks68) | |
517 | basic_machine=m68k-wrs | |
518 | os=-vxworks | |
519 | ;; | |
300f6a4f | 520 | es1800 | OSE68k | ose68k | ose | OSE) # CYGNUS LOCAL |
afba2b22 ILT |
521 | basic_machine=m68k-ericsson |
522 | os=-ose | |
523 | ;; | |
378fd382 | 524 | OSE68000 | ose68000) # CYGNUS LOCAL |
afba2b22 ILT |
525 | basic_machine=m68000-ericsson |
526 | os=-ose | |
527 | ;; | |
378fd382 | 528 | os68k) # CYGNUS LOCAL |
dd16baba SEF |
529 | basic_machine=m68k-none |
530 | os=-os68k | |
531 | ;; | |
378fd382 | 532 | sparclite-wrs) # CYGNUS LOCAL |
fb90daeb ME |
533 | basic_machine=sparclite-wrs |
534 | os=-vxworks | |
535 | ;; | |
378fd382 | 536 | sparcfrw) # CYGNUS LOCAL |
c73e3fe4 JW |
537 | basic_machine=sparcfrw-sun |
538 | os=-sunos4 | |
539 | ;; | |
378fd382 | 540 | sparcfrwcompat) # CYGNUS LOCAL |
c73e3fe4 JW |
541 | basic_machine=sparcfrwcompat-sun |
542 | os=-sunos4 | |
543 | ;; | |
378fd382 | 544 | sparclitefrw) # CYGNUS LOCAL |
c73e3fe4 JW |
545 | basic_machine=sparclitefrw-fujitsu |
546 | os=-none | |
547 | ;; | |
378fd382 | 548 | sparclitefrwcompat) # CYGNUS LOCAL |
c73e3fe4 JW |
549 | basic_machine=sparclitefrwcompat-fujitsu |
550 | os=-none | |
551 | ;; | |
378fd382 | 552 | adobe68k) # CYGNUS LOCAL |
f68be6f0 ILT |
553 | basic_machine=m68010-adobe |
554 | os=-scout | |
555 | ;; | |
ad1f7512 | 556 | |
27a2a371 JW |
557 | xps | xps100) |
558 | basic_machine=xps100-honeywell | |
559 | ;; | |
a2ee3e6d JW |
560 | none) |
561 | basic_machine=none-none | |
562 | os=-none | |
563 | ;; | |
69e87de2 | 564 | |
a2ee3e6d JW |
565 | # Here we handle the default manufacturer of certain CPU types. It is in |
566 | # some cases the only manufacturer, in others, it is the most popular. | |
567 | mips) | |
568 | basic_machine=mips-mips | |
569 | ;; | |
570 | romp) | |
571 | basic_machine=romp-ibm | |
572 | ;; | |
573 | rs6000) | |
574 | basic_machine=rs6000-ibm | |
575 | ;; | |
576 | vax) | |
577 | basic_machine=vax-dec | |
578 | ;; | |
378fd382 DZ |
579 | we32k) |
580 | basic_machine=we32k-att | |
581 | ;; | |
6559fbdb RP |
582 | sparc) |
583 | basic_machine=sparc-sun | |
584 | ;; | |
27a2a371 JW |
585 | cydra) |
586 | basic_machine=cydra-cydrome | |
587 | ;; | |
588 | orion) | |
589 | basic_machine=orion-highlevel | |
590 | ;; | |
591 | orion105) | |
592 | basic_machine=clipper-highlevel | |
593 | ;; | |
a2ee3e6d JW |
594 | *) |
595 | echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 | |
4f183929 | 596 | exit 1 |
a2ee3e6d | 597 | ;; |
4f183929 RP |
598 | esac |
599 | ||
378fd382 DZ |
600 | # Here we canonicalize certain aliases for manufacturers. |
601 | case $basic_machine in | |
602 | *-digital*) | |
603 | basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` | |
604 | ;; | |
605 | *-commodore*) | |
606 | basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` | |
607 | ;; | |
608 | *) | |
609 | ;; | |
610 | esac | |
611 | ||
a2ee3e6d | 612 | # Decode manufacturer-specific aliases for certain operating systems. |
e6602723 | 613 | |
a2ee3e6d JW |
614 | if [ "$os" ] |
615 | then | |
616 | case $os in | |
6559fbdb RP |
617 | # -solaris* is a basic system type, with this one exception. |
618 | -solaris1 | -solaris1.*) | |
619 | os=`echo $os | sed -e 's|solaris1|sunos4|'` | |
620 | ;; | |
a2ee3e6d JW |
621 | # First accept the basic system types. |
622 | # The portable systems comes first. | |
623 | # Each alternative must end in a *, to match a version number. | |
378fd382 | 624 | -bsd* | -sysv* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ |
6559fbdb | 625 | | -vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]* | -hpux* \ |
378fd382 DZ |
626 | | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ |
627 | | -amigados* | -msdos* | -newsos* | -unicos* | -aos* \ | |
6559fbdb | 628 | | -nindy* | -vxworks* | -ebmon* | -hds* \ |
27a2a371 JW |
629 | | -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \ |
630 | | -go32 | -sim | -es1800* | -udi | -hms* | -xray \ | |
ba7f177a PB |
631 | | -os68k* | -none* | -v88r* | -aout | -coff | -elf | -bosx* \ |
632 | | -abug | -ecoff) | |
633 | # The last three lines above are CYGNUS LOCAL | |
2501643a | 634 | ;; |
25fa8f53 | 635 | # start-sanitize-v9 |
6559fbdb | 636 | -v7 | -old* | -aout* | -elf*) ;; # CYGNUS LOCAL |
25fa8f53 | 637 | # end-sanitize-v9 |
6559fbdb RP |
638 | -sunos5*) |
639 | os=`echo $os | sed -e 's|sunos5|solaris2|'` | |
640 | ;; | |
641 | -sunos6*) | |
642 | os=`echo $os | sed -e 's|sunos6|solaris3|'` | |
643 | ;; | |
a2ee3e6d | 644 | -osfrose*) |
378fd382 | 645 | os=-osfrose |
a2ee3e6d JW |
646 | ;; |
647 | -osf*) | |
378fd382 DZ |
648 | os=-osf |
649 | ;; | |
650 | -utek*) | |
a2ee3e6d JW |
651 | os=-bsd |
652 | ;; | |
653 | -dynix*) | |
654 | os=-bsd | |
655 | ;; | |
378fd382 DZ |
656 | -acis*) |
657 | os=-aos | |
a2ee3e6d | 658 | ;; |
378fd382 | 659 | -386bsd) # CYGNUS LOCAL |
23ab00aa KR |
660 | os=-bsd |
661 | ;; | |
68cd7865 | 662 | -ctix* | -uts*) |
a2ee3e6d JW |
663 | os=-sysv |
664 | ;; | |
378fd382 DZ |
665 | -triton*) |
666 | os=-sysv3 | |
667 | ;; | |
668 | -oss*) | |
669 | os=-sysv3 | |
670 | ;; | |
c1e296fc SG |
671 | -svr4) |
672 | os=-sysv4 | |
673 | ;; | |
674 | -svr3) | |
675 | os=-sysv3 | |
676 | ;; | |
378fd382 | 677 | -ose*) # CYGNUS LOCAL |
afba2b22 ILT |
678 | os=-ose |
679 | ;; | |
378fd382 | 680 | -es1800*) # CYGNUS LOCAL |
afba2b22 ILT |
681 | os=-ose |
682 | ;; | |
27a2a371 JW |
683 | -xenix) |
684 | os=-xenix | |
685 | ;; | |
378fd382 DZ |
686 | -none) |
687 | ;; | |
a2ee3e6d JW |
688 | *) |
689 | # Get rid of the `-' at the beginning of $os. | |
690 | os=`echo $1 | sed 's/[^-]*-//'` | |
691 | echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 | |
692 | exit 1 | |
693 | ;; | |
69e87de2 | 694 | esac |
a2ee3e6d | 695 | else |
69e87de2 | 696 | |
a2ee3e6d JW |
697 | # Here we handle the default operating systems that come with various machines. |
698 | # The value should be what the vendor currently ships out the door with their | |
699 | # machine or put another way, the most popular os provided with the machine. | |
27a2a371 JW |
700 | |
701 | # Note that if you're going to try to match "-MANUFACTURER" here (say, | |
702 | # "-sun"), then you have to tell the case statement up towards the top | |
703 | # that MANUFACTURER isn't an operating system. Otherwise, code above | |
704 | # will signal an error saying that MANUFACTURER isn't an operating | |
705 | # system, and we'll never get to this point. | |
706 | ||
a2ee3e6d JW |
707 | case $basic_machine in |
708 | *-dec | vax-*) | |
378fd382 | 709 | os=-ultrix4.2 |
a2ee3e6d JW |
710 | ;; |
711 | i386-sun) | |
378fd382 | 712 | os=-sunos4.0.2 |
a2ee3e6d JW |
713 | ;; |
714 | m68000-sun) | |
715 | os=-sunos3 | |
716 | # This also exists in the configure program, but was not the | |
717 | # default. | |
718 | # os=-sunos4 | |
719 | ;; | |
378fd382 DZ |
720 | *-tti) # must be before sparc entry or we get the wrong os. |
721 | os=-sysv3 | |
a2ee3e6d | 722 | ;; |
378fd382 DZ |
723 | sparc-* | *-sun) |
724 | os=-sunos4.1.1 | |
a2ee3e6d JW |
725 | ;; |
726 | *-ibm) | |
727 | os=-aix | |
728 | ;; | |
729 | *-hp) | |
730 | os=-hpux | |
731 | ;; | |
27a2a371 | 732 | i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) |
a2ee3e6d JW |
733 | os=-sysv |
734 | ;; | |
378fd382 DZ |
735 | *-cbm) |
736 | os=-amigados | |
737 | ;; | |
a2ee3e6d JW |
738 | *-dg) |
739 | os=-dgux | |
740 | ;; | |
378fd382 DZ |
741 | *-dolphin) |
742 | os=-sysv3 | |
743 | ;; | |
a2ee3e6d JW |
744 | m88k-omron*) |
745 | os=-luna | |
746 | ;; | |
a70c9959 KR |
747 | *-sequent) |
748 | os=-bsd | |
749 | ;; | |
a2ee3e6d JW |
750 | *-crds) |
751 | os=-unos | |
752 | ;; | |
753 | *-ns) | |
754 | os=-genix | |
755 | ;; | |
378fd382 DZ |
756 | i[34]86-*) |
757 | os=-sco3.2v2 | |
a2ee3e6d | 758 | ;; |
27a2a371 JW |
759 | *-gould) |
760 | os=-sysv | |
761 | ;; | |
762 | *-highlevel) | |
763 | os=-bsd | |
764 | ;; | |
765 | *-encore) | |
766 | os=-bsd | |
767 | ;; | |
768 | *-sgi) | |
769 | os=-irix | |
770 | ;; | |
771 | *-masscomp) | |
772 | os=-rtu | |
773 | ;; | |
a2ee3e6d JW |
774 | *) |
775 | os=-none | |
776 | ;; | |
69e87de2 | 777 | esac |
a2ee3e6d | 778 | fi |
69e87de2 | 779 | |
a2ee3e6d JW |
780 | # Here we handle the case where we know the os, and the CPU type, but not the |
781 | # manufacturer. We pick the logical manufacturer. | |
782 | vendor=unknown | |
783 | case $basic_machine in | |
784 | *-unknown) | |
785 | case $os in | |
786 | -sunos*) | |
787 | vendor=sun | |
788 | ;; | |
6559fbdb | 789 | -bosx*) # CYGNUS LOCAL |
ba7f177a PB |
790 | vendor=bull |
791 | ;; | |
a2ee3e6d JW |
792 | -aix*) |
793 | vendor=ibm | |
794 | ;; | |
795 | -hpux*) | |
796 | vendor=hp | |
797 | ;; | |
798 | -unos*) | |
799 | vendor=crds | |
800 | ;; | |
801 | -dgux*) | |
802 | vendor=dg | |
803 | ;; | |
804 | -luna*) | |
805 | vendor=omron | |
806 | ;; | |
807 | -genix*) | |
808 | vendor=ns | |
809 | ;; | |
378fd382 | 810 | -vxworks*) # CYGNUS LOCAL |
afba2b22 ILT |
811 | vendor=wrs |
812 | ;; | |
984b27cb SC |
813 | -hms*) # CYGNUS LOCAL |
814 | vendor=hitachi | |
815 | ;; | |
a2ee3e6d JW |
816 | esac |
817 | basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` | |
818 | ;; | |
4f183929 RP |
819 | esac |
820 | ||
a2ee3e6d | 821 | echo $basic_machine$os |