* configure.in (mips*-sgi-irix5*): New target. Use mipsb-elf32.
[deliverable/binutils-gdb.git] / ld / configure.in
CommitLineData
02757e59
SC
1# This file is a shell script fragment that supplies the information
2# necessary to tailor a template configure script into the configure
3# script appropriate for this directory. For more information, check
4# any existing configure script.
5
6srctrigger=ldmain.c
7srcname="linker"
818a192a 8target_dependent=true
02757e59
SC
9
10# per-host:
11
8ddef552
DM
12. ${srcdir}/../bfd/configure.host
13
8a60817c 14host_makefile_frag=
ab57b174 15
9d1fe8a4
SC
16if [ -f ${srcdir}/config/${my_host}.mh ] ; then
17 host_makefile_frag=config/${my_host}.mh
8a60817c 18fi
02757e59
SC
19
20# per-target:
21
1c4b3cda
ILT
22# Canonicalize the secondary target names.
23if [ -n "$with_targets" ]; then
24 for targ in `echo $with_targets | sed 's/,/ /g'`
25 do
26 result=`$configsub $targ 2>/dev/null`
27 if [ -n "$result" ]; then
28 canon_targets="$canon_targets $result"
29 else
30 # Allow targets that config.sub doesn't recognize, like "all".
31 canon_targets="$canon_targets $targ"
32 fi
33 done
34fi
35
36all_targets=false
37
38for targ in $target $canon_targets
39do
40
41case "${targ}" in
42
43 sparc-sun-sunos4*) ld_target=sun4 ;;
44 m68k-sun-sunos[34]*) ld_target=sun3 ;;
45 sparclite*-fujitsu-*) ld_target=sun4 ;;
e637dcf0 46# start-sanitize-v9
1c4b3cda
ILT
47 sparc64-*-elf*) ld_target=sparc64-elf ;;
48 sparc64*) ld_target=sun4 ;;
e637dcf0 49# end-sanitize-v9
1c4b3cda
ILT
50 sparc*-*-aout) ld_target=sun4 ;;
51 sparc*-*-elf) ld_target=sun4sol2 ;;
7b95fe96 52 sparc*-*-lynxos*) ld_target=sparc-lynx ;;
1c4b3cda 53 sparc*-*-solaris2*) ld_target=sun4sol2 ;;
b4a79a16 54 sparc*-*-netware) ld_target=sun4sol2 ;;
1c4b3cda
ILT
55 i960-wrs-vxworks*) ld_target=i960 ;;
56 i960-intel-nindy) ld_target=i960 ;;
57 m68k-wrs-vxworks*) ld_target=vxworks68 ;;
58 m680[01234]0-wrs-vxworks*) ld_target=vxworks68 ;;
59 m683?2-wrs-vxworks*) ld_target=vxworks68 ;;
60 sparc*-wrs-vxworks*) ld_target=sun4 ;;
61 m68k-ericsson-ose) ld_target=ose68 ;;
62 m680[01234]0-ericsson-ose) ld_target=ose68 ;;
63 m683?2-ericsson-ose) ld_target=ose68 ;;
64 *-tandem-none) ld_target=st2000 ;; # FIXME needs better name
65 i[34]86-*-go32) ld_target=go32 ;;
66 i[34]86-*-aix*) ld_target=i386-coff ;;
67 i[34]86-*-sco*) ld_target=i386-coff ;;
68 i[34]86-*-lynxos*) ld_target=i386-lynx ;;
69 i[34]86-*-coff) ld_target=i386-coff ;;
70 i[34]86-*-bsd) ld_target=i386-bsd ;;
71 i[34]86-*-aout) ld_target=i386-aout ;;
72 i[34]86-*-linux) ld_target=i386-linux ;;
73 i[34]86-*-sysv4*) ld_target=i386-elf ;;
b4a79a16
SEF
74 i[34]86-*-unixware) ld_target=i386-elf ;;
75 i[34]86-*-netware) ld_target=i386-elf ;;
1c4b3cda
ILT
76 i[34]86-*-elf*) ld_target=i386-elf ;;
77 i[34]86-*-sysv*) ld_target=i386-coff ;;
b4a79a16 78 i[34]86-*-mach*) ld_target=i386-mach ;;
1c4b3cda
ILT
79 m8*-*-*) ld_target=m88k-bcs ;;
80 a29k-*-udi) ld_target=sa29200 ;;
81 a29k-*-ebmon) ld_target=ebmon29k ;;
82 a29k-*-*) ld_target=coff-a29k ;;
83 h8300-*-hms) ld_target=coff-h8300 ;;
84 h8300h-*-hms) ld_target=coff-h8300h ;;
85 h8500-*-hms) ld_target=coff-h8500 ;;
86 sh-*-*) ld_target=coff-sh ;;
87 m68k-sony-*) ld_target=news ;;
88 m68k-hp-bsd*) ld_target=hp300bsd ;;
89 m68*-*-aout) ld_target=m68k ;;
90 m68*-*-coff) ld_target=m68k-coff ;;
91 m68*-*-hpux) ld_target=hp300hpux ;;
92 m68*-*-lynxos*) ld_target=m68k-lynx ;;
93 m68*-*-*)
94 echo '***' "Unknown m68k target vendor for ld:" ${target_vendor} 1>&2
95 exit 1 ;;
96 hppa*-hp-osf) ld_target=hppaosf ;;
97 vax-dec-ultrix* | vax-dec-bsd*) ld_target=vax ;;
7b95fe96
SS
98 mips*-dec-ultrix*) ld_target=mips-lit ;;
99 mips*-sgi-irix*) ld_target=mips-big ;;
100 mips*el-idt-ecoff*) ld_target=mips-idtl ;;
101 mips*-idt-ecoff*) ld_target=mips-idt ;;
102 mips*-dec-bsd*) ld_target=mipsbsd ;;
103 mips*-*-elf*) ld_target=mipsb-elf32 ;;
1c4b3cda
ILT
104 alpha-*-osf*) ld_target=alpha ;;
105 z8k-*-sim | z8k-*-coff) ld_target=z8ksim ;;
106 *-*-aout) ld_target=${target_cpu}-${target_vendor} ;;
107 *-*-coff) ld_target=${target_cpu}-${target_vendor} ;;
b4a79a16 108 *-*-netware) ld_target=${target_cpu}-elf ;;
1c4b3cda
ILT
109
110 all) ld_target=all ;;
02757e59
SC
111esac
112
1c4b3cda
ILT
113 if [ "x$ld_target" = "xall" ]; then
114 all_targets=true
115 else
116 if [ ! -f ${srcdir}/config/${ld_target}.mt ] ; then
117 echo '***' No file ${srcdir}/config/${ld_target}.mt 1>&2
118 echo '***' GNU LD does not support target ${ld_target} 1>&2
119 echo '***' Look in ld/configure.in for supported targets 1>&2
120 exit 1
121 fi
7f2649bb 122
1c4b3cda
ILT
123 if [ "x$targ" = "x$target" ]; then
124 target_makefile_frag=${srcdir}/config/${ld_target}.mt
125 else
126 target_extra_frags="$target_extra_frags ${srcdir}/config/${ld_target}.mt"
127 fi
128 fi
129done
130
131# We don't do any links based on the target system, just makefile config.
132
133# post-target:
134
135rm -f Makefile.tmp Makefile.2
136mv Makefile Makefile.tmp
137
138if [ x${all_targets} = xfalse ]; then
139
140 allfrags="$target_makefile_frag $target_extra_frags"
141
142 # The emulations in all the configured targets.
143 tb=`sed -n '
144 s/EMUL[ ]*=[ ]*\([^ ]*\)/em_\1.o/p
145 ' $allfrags`
146 # uniq the list.
147 f=""
148 for i in $tb ; do
149 case " $f " in
150 *" $i "*) ;;
151 *) f="$f $i" ;;
152 esac
153 done
154 tb="$f"
155
156 echo "EMULATION_OFILES = $tb" >> Makefile.2
157
158else # all_targets is true
159 echo 'EMULATION_OFILES = $(ALL_EMULATIONS)' >> Makefile.2
160fi # all_targets is true
161
162cat Makefile.tmp >> Makefile.2
163rm -f Makefile.tmp
164mv Makefile.2 Makefile
8ddef552 165
173a0c3d 166mkdir ldscripts 2>/dev/null
This page took 0.098152 seconds and 4 git commands to generate.