Added delta88
[deliverable/binutils-gdb.git] / config.sub
1 #!/bin/sh
2
3 # Configuration subroutine to validate and canonicalize a configuration type.
4 # Supply the specified configuration type as an argument.
5 # If it is invalid, we print an error message on stderr and exit with code 1.
6 # Otherwise, we print the canonical config type on stdout and succeed.
7
8 # This file is supposed to be the same for all GNU packages
9 # and recognize all the CPU types, system types and aliases
10 # that are meaningful with *any* GNU software.
11 # Each package is responsible for reporting which valid configurations
12 # it does not support. The user should be able to distinguish
13 # a failure to support a valid configuration from a meaningless
14 # configuration.
15
16 # Please email any bugs, comments, and/or additions to this file to:
17 # configure@cygnus.com
18
19 # decode aliases into canonical names
20
21 case "$1" in
22 # cpu alone is a valid alias for cpu-none-none.
23 vax | tahoe | i386 | i860 | m68k | m68000 | m88k | sparc | ns32k \
24 | alliant | arm | c1 | c2 | mips | pyramid | tron | a29k \
25 | rtpc | rs6000 | i960)
26 cpu=$1
27 vendor=none
28 os=none
29 ;;
30 altos | altos3068)
31 cpu=m68k
32 vendor=altos
33 os=sysv # maybe?
34 ;;
35 altosgas)
36 cpu=m68k
37 vendor=altos
38 os=gas
39 ;;
40 am29k)
41 cpu=a29k
42 vendor=none
43 os=bsd
44 ;;
45 amdahl)
46 cpu=580
47 vendor=amdahl
48 os=uts
49 ;;
50 apollo68)
51 cpu=m68k
52 vendor=apollo
53 os=sysv # maybe?
54 ;;
55 balance)
56 cpu=ns32k
57 vendor=sequent
58 os=dynix
59 ;;
60 convex-c1)
61 cpu=c1
62 vendor=convex
63 os=sysv # maybe?
64 ;;
65 convex-c2)
66 cpu=c2
67 vendor=convex
68 os=sysv # maybe?
69 ;;
70 cray | ymp)
71 cpu=ymp
72 vendor=cray
73 os=unicos
74 ;;
75 cray2)
76 cpu=cray2
77 vendor=cray
78 os=unicos
79 ;;
80 dec3100 | decstatn | decstation | decstation-3100 | pmax | pmin)
81 cpu=mips
82 vendor=dec
83 os=ultrix
84 ;;
85 delta | 3300 | motorola-3300 | motorola-delta \
86 | 3300-motorola | delta-motorola)
87 cpu=m68k
88 vendor=motorola
89 os=sysv # maybe?
90 ;;
91
92 delta88)
93 cpu=m88k
94 vendor=motorola
95 os=m88kbcs
96 ;;
97
98 gmicro)
99 cpu=tron
100 vendor=gmicro
101 os=sysv # maybe?
102 ;;
103 # start-sanitize-v9
104 hal-32 | hal32)
105 cpu=sparc64
106 vendor=hal
107 os=hal32
108 ;;
109 hal-64 | hal64)
110 cpu=sparc64
111 vendor=hal
112 os=hal64
113 ;;
114 sparc64)
115 cpu=sparc64
116 vendor=sun
117 os=v9
118 ;;
119 sparc64-v7 | sparc64v7)
120 cpu=sparc64
121 vendor=sun
122 os=v7
123 ;;
124 # end-sanitize-v9
125 hp300bsd)
126 cpu=m68k
127 vendor=hp
128 os=bsd
129 ;;
130 hp300hpux | hpux | hp9k3[2-9][0-9])
131 cpu=m68k
132 vendor=hp
133 os=hpux
134 ;;
135 hp9k31[0-9] | hp9k2[0-9][0-9])
136 cpu=m68000
137 vendor=hp
138 os=hpux
139 ;;
140 i386sco)
141 cpu=i386
142 vendor=sco
143 os=sysv # maybe?
144 ;;
145 i386v)
146 cpu=i386
147 vendor=none
148 os=sysv
149 ;;
150 i386v32)
151 cpu=i386
152 vendor=none
153 os=sysv32
154 ;;
155 iris | iris4d)
156 cpu=mips
157 vendor=sgi
158 os=irix # maybe?
159 ;;
160 isi | isi68)
161 cpu=m68k
162 vendor=isi
163 os=sysv # maybe?
164 ;;
165 littlemips)
166 cpu=mips
167 vendor=little
168 os=bsd
169 ;;
170 magnum | m3230)
171 cpu=mips
172 vendor=mips
173 os=sysv # maybe?
174 ;;
175 merlin)
176 cpu=ns32k
177 vendor=utek
178 os=sysv # maybe?
179 ;;
180 miniframe)
181 cpu=m68000
182 vendor=convergent
183 os=sysv # maybe?
184 ;;
185 mmax)
186 cpu=ns32k
187 vendor=encore
188 os=sysv # maybe?
189 ;;
190 news | news700 | news800 | news900)
191 cpu=m68k
192 vendor=sony
193 os=sysv # maybe?
194 ;;
195 news1000)
196 cpu=m68030
197 vendor=sony
198 os=sysv # maybe?
199 ;;
200 news-3600 | bigmips | risc-news)
201 cpu=mips
202 vendor=sony
203 os=newsos # maybe?
204 ;;
205 next)
206 cpu=m68k
207 vendor=next
208 os=sysv # maybe?
209 ;;
210 nindy960)
211 cpu=i960
212 vendor=intel
213 os=nindy
214 ;;
215 none)
216 cpu=none
217 vendor=none
218 os=none
219 ;;
220 np1)
221 cpu=np1
222 vendor=gould
223 os=sysv # maybe?
224 ;;
225 pbd)
226 cpu=sparc
227 vendor=unicom
228 os=sysv
229 ;;
230 pn)
231 cpu=pn
232 vendor=gould
233 os=sysv # maybe?
234 ;;
235 ps2)
236 cpu=i386
237 vendor=ibm
238 os=sysv # maybe?
239 ;;
240 sun2)
241 cpu=m68000
242 vendor=sun
243 os=sunos4
244 ;;
245 sun2os3)
246 cpu=m68000
247 vendor=sun
248 os=sunos3
249 ;;
250 sun2os4)
251 cpu=m68000
252 vendor=sun
253 os=sunos4
254 ;;
255 sun3)
256 cpu=m68k
257 vendor=sun
258 os=sunos4
259 ;;
260 sun3os3)
261 cpu=m68k
262 vendor=sun
263 os=sunos3
264 ;;
265 sun3os4)
266 cpu=m68k
267 vendor=sun
268 os=sunos4
269 ;;
270 sun386 | roadrunner | sun386i)
271 cpu=i386
272 vendor=sun
273 os=sunos
274 ;;
275 sun4)
276 cpu=sparc
277 vendor=sun
278 os=sunos4
279 ;;
280 sun4os3)
281 cpu=sparc
282 vendor=sun
283 os=sunos3
284 ;;
285 sun4os4)
286 cpu=sparc
287 vendor=sun
288 os=sunos4
289 ;;
290 symmetry)
291 cpu=i386
292 vendor=sequent
293 os=dynix
294 ;;
295 tower | tower-32)
296 cpu=m68k
297 vendor=ncr
298 os=sysv # maybe?
299 ;;
300 umax)
301 cpu=ns32k
302 vendor=encore
303 os=sysv # maybe?
304 ;;
305 unixpc | safari | pc7300 | 3b1 | 7300 | 7300-att | att-7300)
306 cpu=m68k
307 vendor=att
308 os=sysv # maybe?
309 ;;
310 vax-dec)
311 cpu=vax
312 vendor=dec
313 os=ultrix # maybe?
314 ;;
315 vxworks68)
316 cpu=m68k
317 vendor=wrs
318 os=vxworks
319 ;;
320 vxworks960)
321 cpu=i960
322 vendor=wrs
323 os=vxworks
324 ;;
325 xmp)
326 cpu=xmp
327 vendor=cray
328 os=unicos
329 ;;
330 # not an alias. parse what we expect to be a canonical name.
331 *)
332 cpu=`echo $1 | sed 's/-.*$//'`
333
334 if [ "${cpu}" = "$1" ] ; then
335 # no vendor so this is an invalid name.
336 echo '***' No vendor: configuration \`$1\' not recognized 1>&2
337 exit 1
338 else
339 # parse out vendor
340 rest=`echo $1 | sed "s/${cpu}-//"`
341 vendor=`echo ${rest} | sed 's/-.*$//'`
342
343 if [ "${vendor}" = "${rest}" ] ; then
344 # a missing os is acceptable
345 os=none
346 else
347 os=`echo ${rest} | sed "s/${vendor}-//"`
348 fi
349 fi
350 ;;
351 esac
352
353 # At this point we should have three parts of a canonical name in cpu,
354 # vendor, and os.
355
356 # verify that the cpu is known.
357
358 case "${cpu}" in
359 none | vax | tahoe | i386 | i860 | m68k | m68000 | m88k | sparc \
360 | ns32k | alliant | arm | c1 | c2 | mips | pyramid | tron \
361 | a29k | rtpc | rs6000 | i960 | xmp | ymp | cray2 | 580)
362 ;;
363
364 # start-sanitize-v9
365 sparc64) ;;
366 # end-sanitize-v9
367
368 *)
369 echo '***' Invalid cpu \`${cpu}\': configuration \`$1\' not recognized 1>&2
370 exit 1
371 ;;
372 esac
373
374 # verify that the vendor is known.
375
376 case "${vendor}" in
377 none | convex | mips | dec | little | sony | ncr | convergent \
378 | altos | apollo | isi | hp | next | sco | ibm | sun \
379 | unicom | sequent | encore | motorola | att | sgi | utek \
380 | gould | wrs | intel | aout | bout | coff | bcs | amdahl \
381 | cray) ;;
382
383 # start-sanitize-v9
384 hal) ;;
385 # end-sanitize-v9
386
387 *)
388 echo '***' Invalid vendor \`${vendor}\': configuration \`$1\' not recognized 1>&2
389 exit 1
390 ;;
391 esac
392
393 # verify that the os is known, if it exists.
394
395 case "${os}" in
396 aix* | aout | bout | bsd* | coff | ctix* | dynix* | esix* | hpux* | irix* \
397 | isc* | mach* | newsos* | nindy* | none | osf* | osf* | sco* \
398 | sunos* | sysv* | ultrix* | unos* | v88r* | vms* | vxworks* \
399 | unicos* | uts)
400 ;;
401
402 # start-sanitize-v9
403 hal32 | hal64 | v7 | v9) ;;
404 # end-sanitize-v9
405
406 *)
407 echo '***' Invalid os \`${os}\': configuration \`$1\' not recognized 1>&2
408 exit 1
409 ;;
410 esac
411
412 echo ${cpu}-${vendor}-${os}
This page took 0.048253 seconds and 5 git commands to generate.