2000-08-10 Jason Eckhardt <jle@cygnus.com>
[platform/upstream/binutils.git] / ld / configure.tgt
1 # This is the linker target specific file.  This is invoked by the
2 # autoconf generated configure script.  Putting it in a separate shell
3 # file lets us skip running autoconf when modifying target specific
4 # information.
5
6 # This file switches on the shell variable ${targ}, and sets the
7 # following shell variables:
8 #  targ_emul            name of linker emulation to use
9 #  targ_extra_emuls     additional linker emulations to provide
10 #  targ_extra_libpath   additional linker emulations using LIB_PATH
11 #  targ_extra_ofiles    additional objects needed by the emulation
12
13 targ_extra_emuls=
14 targ_extra_ofiles=
15
16 case "${targ}" in
17 arm-epoc-pe)            targ_emul=arm_epoc_pe ;
18                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
19 arm-*-wince)            targ_emul=armpe ;
20                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
21 arm-*-pe)               targ_emul=armpe ;
22                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
23 arc-*-elf*)             targ_emul=arcelf ;;
24 avr-*-*)                targ_emul=avr85xx
25                         targ_extra_emuls="avr1200 avr23xx avr44x4 avr4433 avrmega603 avrmega103 avrmega161" ;;
26 cris-*-*)               targ_emul=crisaout
27                         targ_extra_emuls="criself crislinux"
28                         targ_extra_libpath=$targ_extra_emuls ;;
29 d10v-*-*)               targ_emul=d10velf ;;
30 d30v-*-*ext*)           targ_emul=d30v_e; targ_extra_emuls="d30velf d30v_o" ;;
31 d30v-*-*onchip*)        targ_emul=d30v_o; targ_extra_emuls="d30velf d30v_e" ;;
32 d30v-*-*)               targ_emul=d30velf; targ_extra_emuls="d30v_e d30v_o" ;;
33 sparc64-*-aout*)        targ_emul=sparcaout ;;
34 sparc64-*-elf*)         targ_emul=elf64_sparc ;;
35 sparc-sun-sunos4*)      targ_emul=sun4 ;;
36 sparclite*-*-elf)       targ_emul=elf32_sparc ;;
37 sparclite*-*-coff)      targ_emul=coff_sparc ;;
38 sparclite*-fujitsu-*)   targ_emul=sparcaout ;;
39 sparc*-*-aout)          targ_emul=sparcaout ;;
40 sparc*-*-coff)          targ_emul=coff_sparc ;;
41 sparc*-*-elf)           targ_emul=elf32_sparc ;;
42 sparc*-*-sysv4*)        targ_emul=elf32_sparc ;;
43 sparc*-*-linux*aout*)   targ_emul=sparclinux
44                         targ_extra_emuls="elf32_sparc sun4"
45                         tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/aout//'`
46                         tdir_sun4=sparc-sun-sunos4
47                         ;;
48 sparc64-*-linux-gnu*)   targ_emul=elf64_sparc
49                         targ_extra_emuls="elf32_sparc sparclinux sun4"
50                         tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'`
51                         tdir_sparclinux=${tdir_elf32_sparc}aout
52                         tdir_sun4=sparc-sun-sunos4
53                         ;;
54 sparc*-*-linux-gnu*)    targ_emul=elf32_sparc
55                         targ_extra_emuls="sparclinux elf64_sparc sun4"
56                         tdir_sparclinux=${targ_alias}aout
57                         tdir_elf64_sparc=`echo ${targ_alias} | sed -e 's/32//'`
58                         tdir_sun4=sparc-sun-sunos4
59                         ;;
60 sparc*-*-lynxos*)       targ_emul=sparclynx ;;
61 sparc64-*-netbsd*)      targ_emul=elf64_sparc ;;
62 sparc*-*-netbsd*elf*)   targ_emul=elf32_sparc ;;
63 sparc*-*-netbsd*)       targ_emul=sparcnbsd ;;
64 sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
65                         targ_emul=elf32_sparc ;;
66 sparc-*-solaris2*)      targ_emul=elf32_sparc
67                         targ_extra_emuls="elf64_sparc"
68                         targ_extra_libpath=$targ_extra_emuls
69                         tdir_elf64_sparc=`echo ${targ_alias} | sed -e 's/32//'`
70                         ;;
71 sparcv9-*-solaris2* | sparc64-*-solaris2*)
72                         targ_emul=elf64_sparc
73                         targ_extra_emuls="elf32_sparc"
74                         targ_extra_libpath=$targ_extra_emuls
75                         tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'`
76                         ;;
77 sparc*-*-solaris2*)     targ_emul=elf32_sparc ;;
78 sparc*-wrs-vxworks*)    targ_emul=sparcaout ;;
79 sparc*-*-rtems*)        targ_emul=sparcaout ;;
80 i860-stardent-sysv4* | i860-stardent-elf*)
81                         targ_emul=elf32_i860 ;;
82 i960-wrs-vxworks5.0*)   targ_emul=gld960 ;;
83 i960-wrs-vxworks5*)     targ_emul=gld960coff ;;
84 i960-wrs-vxworks*)      targ_emul=gld960 ;;
85 i960-*-coff)            targ_emul=gld960coff ;;
86 i960-intel-nindy)       targ_emul=gld960 ;;
87 i960-*-rtems*)          targ_emul=gld960coff ;;
88 i960-*-elf*)            targ_emul=elf32_i960 ;;
89 ia64-*-elf*)            targ_emul=elf64_ia64 ;;
90 ia64-*-linux*)          targ_emul=elf64_ia64 ;;
91 m32r-*-*)               targ_emul=m32relf ;;
92 m68hc11-*-*|m6811-*-*)  targ_emul=m68hc11elf 
93                         targ_extra_emuls="m68hc11elfb m68hc12elf m68hc12elfb" ;;
94 m68hc12-*-*|m6812-*-*)  targ_emul=m68hc12elf 
95                         targ_extra_emuls="m68hc12elfb m68hc11elf m68hc11elfb" ;;
96 m68*-sun-sunos[34]*)    targ_emul=sun3 ;;
97 m68*-wrs-vxworks*)      targ_emul=sun3 ;;
98 m68*-ericsson-ose)      targ_emul=sun3 ;;
99 m68*-apple-aux*)        targ_emul=m68kaux ;;
100 *-tandem-none)          targ_emul=st2000 ;;
101 i370-*-elf* | i370-*-linux-gnu*) targ_emul=elf32i370 ;;
102 i370-*-mvs*)            targ_emul=mvs ;;
103 i[3456]86-*-vsta)       targ_emul=vsta ;;
104 i[3456]86-go32-rtems*)  targ_emul=i386go32 ;;
105 i[3456]86-*-go32)       targ_emul=i386go32 ;;
106 i[3456]86-*-msdosdjgpp*) targ_emul=i386go32 ;;
107 i[3456]86-*-aix*)       targ_emul=i386coff ;;
108 i[3456]86-*-sco*)       targ_emul=i386coff ;;
109 i[3456]86-*-isc*)       targ_emul=i386coff ;;
110 i[3456]86-*-lynxos*)    targ_emul=i386lynx ;;
111 i[3456]86-*-coff)       targ_emul=i386coff ;;
112 i[3456]86-*-rtemself*)  targ_emul=elf_i386 ;;
113 i[3456]86-*-rtems*)     targ_emul=i386coff ;;
114 i[3456]86-*-bsd)        targ_emul=i386bsd ;;
115 i[3456]86-*-bsd386)     targ_emul=i386bsd ;;
116 i[3456]86-*-bsdi*)      targ_emul=i386bsd ;;
117 i[3456]86-*-aout)       targ_emul=i386aout ;;
118 i[3456]86-*-linux*aout*)        targ_emul=i386linux
119                         targ_extra_emuls=elf_i386
120                         tdir_elf_i386=`echo ${targ_alias} | sed -e 's/aout//'`
121                         ;;
122 i[3456]86-*-linuxoldld) targ_emul=i386linux; targ_extra_emuls=elf_i386 ;;
123 i[3456]86-*-linux-gnu*) targ_emul=elf_i386
124                         targ_extra_emuls=i386linux
125                         tdir_i386linux=${targ_alias}aout
126                         ;;
127 i[3456]86-*-sysv[45]*)  targ_emul=elf_i386 ;;
128 i[3456]86-*-solaris2*)  targ_emul=elf_i386 ;;
129 i[3456]86-*-unixware)   targ_emul=elf_i386 ;;
130 i[3456]86-*-solaris*)   targ_emul=elf_i386 ;;
131 i[3456]86-*-netbsd*)    targ_emul=i386nbsd ;;
132 i[3456]86-*-netware)    targ_emul=i386nw ;;
133 i[3456]86-*-elf*)       targ_emul=elf_i386 ;;
134 i[3456]86-*-freebsdaout* | i[3456]86-*-freebsd[12].* | i[3456]86-*-freebsd[12])
135                         targ_emul=i386bsd ;;
136 i[3456]86-*-freebsd*)   targ_emul=elf_i386 ;;
137 i[3456]86-*-sysv*)      targ_emul=i386coff ;;
138 i[3456]86-*-ptx*)       targ_emul=i386coff ;;
139 i[3456]86-*-mach*)      targ_emul=i386mach ;;
140 i[3456]86-*-gnu*)       targ_emul=elf_i386 ;;
141 i[3456]86-*-msdos*)     targ_emul=i386msdos; targ_extra_emuls=i386aout ;;
142 i[3456]86-*-moss*)      targ_emul=i386moss; targ_extra_emuls=i386msdos ;;
143 i[3456]86-*-winnt*)     targ_emul=i386pe ;
144                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
145 i[3456]86-*-pe)         targ_emul=i386pe ;
146                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
147 i[3456]86-*-cygwin*)    targ_emul=i386pe ;
148                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
149 i[3456]86-*-mingw32*)   targ_emul=i386pe ;
150                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
151 i[3456]86-*-interix*)   targ_emul=i386pe_posix;
152                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
153 i[3456]86-*-beospe*)    targ_emul=i386beos ;;
154 i[3456]86-*-beos*)      targ_emul=elf_i386_be ;;
155 i[3456]86-*-vxworks*)   targ_emul=i386aout ;;
156 m8*-*-*)                targ_emul=m88kbcs ;;
157 a29k-*-udi)             targ_emul=sa29200 ;;
158 a29k-*-ebmon)           targ_emul=ebmon29k ;;
159 a29k-*-*)               targ_emul=a29k ;;
160 #  arm-*-riscix*)               targ_emul=riscix ;;
161 arm-*-aout | armel-*-aout) targ_emul=armaoutl ;;
162 armeb-*-aout)           targ_emul=armaoutb ;;
163 arm-*-coff)             targ_emul=armcoff ;;
164 arm-*-netbsd*)          targ_emul=armnbsd ;;
165 arm-*-elf)              targ_emul=armelf ;;
166 arm-*-oabi)             targ_emul=armelf_oabi ;;
167 arm*-*-linux-gnu*)      targ_emul=armelf_linux; targ_extra_emuls="armelf_linux26 armelf" ;;
168 arm*-*-uclinux*)        targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
169 arm*-*-conix*)          targ_emul=armelf ;;
170 thumb-*-linux-gnu* | thumb-*-uclinux*)  targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
171 strongarm-*-coff)       targ_emul=armcoff ;;
172 strongarm-*-elf)        targ_emul=armelf ;;
173 thumb-*-coff)           targ_emul=armcoff ;;
174 thumb-*-elf)            targ_emul=armelf ;;
175 thumb-*-oabi)           targ_emul=armelf_oabi ;;
176 thumb-epoc-pe)          targ_emul=arm_epoc_pe ;
177                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
178 thumb-*-pe)             targ_emul=armpe ;
179                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
180 h8300-*-hms* | h8300-*-coff*)
181                         targ_emul=h8300; targ_extra_emuls="h8300h h8300s"
182                         ;;
183 h8500-*-hms* | h8500-*-coff*)
184                         targ_emul=h8500
185                         targ_extra_emuls="h8500s h8500b h8500m h8500c"
186                         ;;
187 sh-*-elf* | sh-*-rtemself*)
188                         targ_emul=shelf
189                         targ_extra_emuls="shlelf sh shl"
190                         ;;
191 sh-*-pe)                targ_emul=shpe ;
192                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
193 sh-*-*|sh-*-rtems*)     targ_emul=sh; targ_extra_emuls=shl ;;
194 m68k-sony-*)            targ_emul=news ;;
195 m68k-hp-bsd*)           targ_emul=hp300bsd ;;
196 m68*-motorola-sysv*)    targ_emul=delta68 ;;
197 m68*-*-aout)            targ_emul=m68kaout ;;
198 m68*-*-coff)            targ_emul=m68kcoff ;;
199 m68*-*-elf)             targ_emul=m68kelf ;;
200 m68*-*-hpux*)           targ_emul=hp3hpux ;;
201 m68k-*-linux*aout*)     targ_emul=m68klinux
202                         targ_extra_emuls=m68kelf
203                         tdir_m68kelf=`echo ${targ_alias} | sed -e 's/aout//'`
204                         ;;
205 m68k-*-linux-gnu*)      targ_emul=m68kelf
206                         targ_extra_emuls=m68klinux
207                         tdir_m68klinux=`echo ${targ_alias} | sed -e 's/linux/linuxaout/'`
208                         ;;
209 m68*-*-gnu*)            targ_emul=m68kelf ;;
210 m68*-*-lynxos*)         targ_emul=m68klynx ;;
211 m68*-hp*-netbsd*)       targ_emul=m68k4knbsd ;;
212 m68*-*-netbsd*)         targ_emul=m68knbsd ;;
213 m68*-*-psos*)           targ_emul=m68kpsos ;;
214 m68*-*-rtems*)          targ_emul=m68kcoff ;;
215 hppa*64*-*)             targ_emul=elf64hppa ;;
216 hppa*-*-linux-gnu*)     targ_emul=hppalinux ;;
217 hppa*-*-*elf*)          targ_emul=hppaelf ;;
218 hppa*-*-lites*)         targ_emul=hppaelf ;;
219 hppa*-*-rtems*)         targ_emul=hppaelf ;;
220 vax-dec-ultrix* | vax-dec-bsd*) targ_emul=vax ;;
221 mips*-*-pe)             targ_emul=mipspe ;
222                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
223 mips*-dec-ultrix*)      targ_emul=mipslit ;;
224 mips*-dec-osf*)         targ_emul=mipslit ;;
225 mips*-sgi-irix5*)       targ_emul=elf32bsmip ;;
226 mips*-sgi-irix6*)       targ_emul=elf32bmipn32
227                         targ_extra_emuls="elf32bsmip elf64bmip"
228                         ;;
229 mips*-sgi-irix*)        targ_emul=mipsbig ;;
230 mips*el-*-ecoff*)       targ_emul=mipsidtl ;;
231 mips*-*-ecoff*)         targ_emul=mipsidt ;;
232 mips*-dec-bsd*)         targ_emul=mipsbsd ;;
233 mips*-dec-netbsd*)      targ_emul=elf32lmip ;;
234 mips*-*-bsd*)           targ_emul=mipsbig ;;
235 mips*vr4300el-*-elf*)   targ_emul=elf32l4300 ;;
236 mips*vr4300-*-elf*)     targ_emul=elf32b4300 ;;
237 mips*vr4100el-*-elf*)   targ_emul=elf32l4300 ;;
238 mips*vr4100-*-elf*)     targ_emul=elf32b4300 ;;
239 mips*vr5000el-*-elf*)   targ_emul=elf32l4300 ;;
240 mips*vr5000-*-elf*)     targ_emul=elf32b4300 ;;
241 mips*el-*-elf*)         targ_emul=elf32elmip ;;
242 mips*-*-elf*)           targ_emul=elf32ebmip ;;
243 mips*el-*-rtems*)       targ_emul=elf32elmip ;;
244 mips*-*-rtems*)         targ_emul=elf32ebmip ;;
245 mips*el-*-vxworks*)     targ_emul=elf32elmip ;;
246 mips*-*-vxworks*)       targ_emul=elf32ebmip ;;
247 mips*el-*-linux-gnu*)   targ_emul=elf32lsmip
248                         targ_extra_emuls="elf32bsmip mipslit mipsbig"
249                         ;;
250 mips*-*-linux-gnu*)     targ_emul=elf32bsmip
251                         targ_extra_emuls="elf32lsmip mipsbig mipslit"
252                         ;;
253 mips*-*-lnews*)         targ_emul=mipslnews ;;
254 mips*-*-sysv4*)         targ_emul=elf32btsmip ;;
255 mn10200-*-*)            targ_emul=mn10200 ;;
256 mn10300-*-*)            targ_emul=mn10300 ;;
257 alpha*-*-linuxecoff*)   targ_emul=alpha targ_extra_emuls=elf64alpha
258                         tdir_elf64alpha=`echo ${targ_alias} | sed -e 's/ecoff//'`
259                         ;;
260 alpha*-*-linux-gnu*)    targ_emul=elf64alpha targ_extra_emuls=alpha
261                         tdir_alpha=`echo ${targ_alias} | sed -e 's/linux/linuxecoff/'`
262                         ;;
263 alpha*-*-osf*)          targ_emul=alpha ;;
264 alpha*-*-gnu*)          targ_emul=elf64alpha ;;
265 alpha*-*-netware*)      targ_emul=alpha ;;
266 alpha*-*-netbsd*)       targ_emul=elf64alpha ;;
267 z8k-*-coff)             targ_emul=z8002; targ_extra_emuls=z8001 ;;
268 ns32k-pc532-mach* | ns32k-pc532-ux*)    targ_emul=pc532macha ;;
269 ns32k-pc532-netbsd* | ns32k-pc532-lites*) targ_emul=ns32knbsd ;;
270 powerpc-*-linux-gnu*)   targ_emul=elf32ppclinux;
271                         targ_extra_emuls="elf32ppc elf32ppcsim";
272                         targ_extra_libpath=elf32ppc ;;
273 pjl*-*-*)               targ_emul=pjlelf ; targ_extra_emuls="elf_i386" ;;
274 pj*-*-*)                targ_emul=pjelf ;;
275 powerpc-*-elf* | powerpc-*-eabi* | powerpc-*-sysv* \
276   | powerpc-*-netbsd* | powerpc-*-vxworks*)
277         targ_emul=elf32ppc targ_extra_emuls="elf32ppclinux elf32ppcsim";;
278 powerpcle-*-elf* | powerpcle-*-eabi* | powerpcle-*-solaris* \
279   | powerpcle-*-sysv* | powerpcle-*-vxworks*)
280         targ_emul=elf32lppc targ_extra_emuls="elf32ppcsim";;
281 powerpcle-*-rtems*)     targ_emul=elf32leppc ;;
282 powerpc-*-rtems*)       targ_emul=elf32ppc ;;
283 powerpc-*-macos*)       targ_emul=ppcmacos ;;
284 powerpc-*-netware*)     targ_emul=ppcnw ;;
285 powerpcle-*-pe)         targ_emul=ppcpe ;;
286 powerpcle-*-winnt*)     targ_emul=ppcpe ;;
287 powerpcle-*-cygwin*)   targ_emul=ppcpe ;;
288 powerpc-*-aix*)         targ_emul=aixppc ;;
289 powerpc-*-beos*)        targ_emul=aixppc ;;
290 rs6000-*-aix*)          targ_emul=aixrs6 ;;
291 tic30-*-*aout*)         targ_emul=tic30aout ;;
292 tic30-*-*coff*)         targ_emul=tic30coff ;;
293 tic54x-*-* | c54x*-*-*) targ_emul=tic54xcoff ;;
294 tic80-*-*)              targ_emul=tic80coff ;;
295 v850-*-*)               targ_emul=v850 ;;
296 v850e-*-*)              targ_emul=v850 ;;
297 v850ea-*-*)             targ_emul=v850 ;;
298 w65-*-*)                targ_emul=w65 ;;
299 fr30-*-*)               targ_emul=elf32fr30 ;;
300 mcore-*-pe)             targ_emul=mcorepe ;
301                         targ_extra_ofiles="deffilep.o pe-dll.o" ;;
302 mcore-*-elf)            targ_emul=elf32mcore ;;
303 *-*-ieee*)              targ_emul=vanilla ;;
304
305 *)
306   echo 2>&1 "*** ld does not support target ${targ}"
307   echo 2>&1 "*** see ld/configure.tgt for supported targets"
308   exit 1
309
310 esac