* config/ho-irix.h: New file; if not gcc, define BROKEN_ASSERT.
[deliverable/binutils-gdb.git] / gas / configure.in
1 # This file is configure.in
2 #
3 # Copyright (C) 1987-1992 Free Software Foundation, Inc.
4 #
5 # This file is part of GAS, the GNU Assembler.
6 #
7 # GAS is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2, or (at your option)
10 # any later version.
11 #
12 # GAS is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with GAS; see the file COPYING. If not, write to
19 # the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
20 #
21
22 # This file was written, and is maintained by K. Richard Pixley
23 # <rich@cygnus.com>.
24
25 # This file is a shell script that supplies the information necessary
26 # to tailor a template configure script into the configure script
27 # appropriate for this directory. For more information, check any
28 # existing configure script.
29
30 srctrigger=as.c
31 srcname="gas"
32 need_bfd=no
33 configdirs="doc testsuite"
34
35 # per-host:
36
37 gas_host=generic
38
39 case "${host}" in
40 a29k-*-* | rs6000-*-* | vax-*-*)
41 case "${host_os}" in
42 vms*) gas_host=vms ;;
43 bsd*) gas_host=bsd ;;
44 *) gas_host=${host_cpu} ;;
45 esac
46 ;;
47 mips-dec-ultrix)
48 gas_host=decstatn
49 ;;
50 mips-*-bsd*)
51 gas_host=mipsbsd
52 ;;
53 mips-sgi-irix*)
54 gas_host=irix
55 ;;
56 i[34]86-ibm-aix*)
57 gas_host=i386aix
58 ;;
59 i[34]86-*-isc*)
60 gas_host=sysv
61 ;;
62 m68k-sun-sunos*)
63 gas_host=sun3
64 ;;
65 i386-sun-sunos*)
66 gas_host=sun386
67 ;;
68 sparc-sun-sunos*)
69 gas_host=sun4
70 ;;
71 sparc-sun-solaris2*)
72 gas_host=sysv
73 ;;
74 *-*-ansi | *-*-ultrix | *-*-hpux | *-*-sysv*)
75 gas_host=${host_os}
76 ;;
77 esac
78
79 # per-target:
80
81 # not yet...
82 case ${with_bfd_assembler} in
83 yes)
84 echo "*** Warning: GAS BFD configuration option not yet supported" 1>&2
85 need_bfd=yes
86 bfd_gas=yes
87 ;;
88 no | "")
89 ;;
90 *)
91 echo "*** Bad value \"${with_bfd_assembler}\" for --with_bfd_assembler option" 1>&2
92 exit 1
93 ;;
94 esac
95
96 # assign cpu type
97 emulation=generic
98
99 cpu_type=${target_cpu}
100
101 # check for architecture variants
102 case ${target_cpu} in
103 sparclite*) cpu_type=sparc ;;
104 sparc64) cpu_type=sparc obj_format=aout ;;
105 m680[01234]0) cpu_type=m68k ;;
106 m683??) cpu_type=m68k ;;
107 i486) cpu_type=i386 ;;
108 esac
109
110 gas_target=${cpu_type}
111
112 generic_target=${cpu_type}-${target_vendor}-${target_os}
113
114 # assign object format
115 case ${generic_target} in
116 a29k-amd-udi)
117 obj_format=coffbfd
118 need_bfd=yes
119 gas_target=ebmon29k
120 ;;
121 a29k-amd-ebmon)
122 obj_format=coffbfd
123 need_bfd=yes
124 gas_target=ebmon29k
125 ;;
126 a29k-amd-ebmonold)
127 obj_format=coff
128 need_bfd=yes
129 gas_target=ebmon29k
130 ;;
131 i386-ibm-aix*)
132 obj_format=coffbfd
133 need_bfd=yes
134 gas_target=i386coff
135 emulation=i386aix
136 ;;
137 i386-*-bsd*)
138 obj_format=aout
139 ;;
140 i386-*-coff | i386-*-sysv* | i386-*-sco* | i386-*-isc*)
141 obj_format=coffbfd
142 need_bfd=yes
143 gas_target=i386coff
144 ;;
145 i386-*-go32)
146 obj_format=aout
147 ;;
148 i960-wrs-vxworks)
149 obj_format=bout
150 ;;
151 i960-*-coff)
152 obj_format=coff
153 emulation=ic960
154 ;;
155 m68k-wrs-vxworks)
156 obj_format=aout
157 emulation=sun3
158 ;;
159 m68k-ericsson-[Oo][Ss][Ee])
160 obj_format=aout
161 emulation=sun3
162 ;;
163 m68k-*-coff)
164 obj_format=coffbfd
165 need_bfd=yes
166 gas_target=m68kcoff
167 ;;
168 mips-*-bsd*)
169 # don't change emulation like *-*-bsd does
170 bfd_gas=yes
171 obj_format=aout
172 gas_target=mips-lit
173 ;;
174 mips-*-ultrix*)
175 bfd_gas=yes
176 obj_format=ecoff
177 gas_target=mips-lit
178 ;;
179 mips-*-irix* | mips-*-ecoff)
180 bfd_gas=yes
181 obj_format=ecoff
182 gas_target=mips-big
183 ;;
184 sparclite*-fujitsu-none)
185 obj_format=aout
186 ;;
187 *-*-aout | *-*-scout | *-*-linux)
188 obj_format=aout
189 ;;
190 *-*-bout* | *-*-nindy*)
191 obj_format=bout
192 ;;
193 *-*-bsd* | *-*-sunos*)
194 obj_format=aout
195 emulation=sun3
196 ;;
197 *-*-generic)
198 obj_format=generic
199 ;;
200 *-*-xray | *-*-hms)
201 obj_format=coffbfd
202 need_bfd=yes
203 ;;
204 *-*-sysv32)
205 obj_format=coff
206 emulation=sysv32
207 ;;
208 *-*-sim)
209 obj_format=coffbfd
210 need_bfd=yes
211 ;;
212 *-*-coff* | *-sysv* | *-*-sco*)
213 obj_format=coff
214 case ${target_vendor} in
215 bull) emulation=dpx2 ;;
216 sun) emulation=sun3 ;;
217 esac
218 ;;
219 *-*-vxworks)
220 obj_format=aout
221 ;;
222 *-*-coff)
223 obj_format=coff
224 ;;
225 *-*-elf | *-*-solaris*)
226 case ${bfd_gas} in
227 yes) ;;
228 *)
229 echo "*** warning: gas ${target_os} configuration implies" 1>&2
230 echo " (unsupported) --with-bfd-assembler option" 1>&2
231 bfd_gas=yes
232 ;;
233 esac
234 obj_format=elf
235 ;;
236 *-*-vms)
237 obj_format=vms
238 ;;
239 esac
240
241 # assign floating point type
242 case ${target_cpu} in
243 ns32k) atof=ns32k ;;
244 vax) atof=vax ;;
245 tahoe) atof=tahoe ;;
246 *) atof=ieee ;;
247 esac
248
249 # and target makefile frag
250
251 target_makefile_frag=config/${gas_target}.mt
252
253 files="config/ho-${gas_host}.h config/tc-${cpu_type}.c \
254 config/tc-${cpu_type}.h config/te-${emulation}.h \
255 config/obj-${obj_format}.h config/obj-${obj_format}.c \
256 config/atof-${atof}.c"
257
258 links="host.h targ-cpu.c targ-cpu.h targ-env.h obj-format.h obj-format.c atof-targ.c"
259
260 # post-target:
261
262 case ${bfd_gas} in
263 yes)
264 rm -f Makefile.tem
265 mv Makefile Makefile.tem
266 echo BFDDEF=-DBFD_ASSEMBLER > Makefile
267 cat Makefile.tem >> Makefile
268 rm -f Makefile.tem
269 need_bfd=yes
270 ;;
271 *)
272 ;;
273 esac
274
275 case ${need_bfd} in
276 yes)
277 rm -f Makefile.tem
278 mv Makefile Makefile.tem
279 echo BFDLIB=../bfd/libbfd.a > Makefile
280 cat Makefile.tem >> Makefile
281 rm -f Makefile.tem
282 ;;
283 *)
284 ;;
285 esac
286
287 # end of gas/configure.in
This page took 0.035389 seconds and 4 git commands to generate.