Commit | Line | Data |
---|---|---|
252b5132 RH |
1 | dnl Process this file with autoconf to produce a configure script. |
2 | dnl | |
da594c4a AM |
3 | AC_PREREQ(2.59) |
4 | AC_INIT | |
5 | AC_CONFIG_SRCDIR(ar.c) | |
252b5132 | 6 | |
da594c4a | 7 | AC_CANONICAL_TARGET |
5d64ca4e | 8 | AC_ISC_POSIX |
252b5132 | 9 | |
27b7e12d AM |
10 | changequote(,)dnl |
11 | BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${srcdir}/../bfd/configure.in` | |
12 | changequote([,])dnl | |
13 | AM_INIT_AUTOMAKE(binutils, ${BFD_VERSION}) | |
252b5132 | 14 | |
d45dc31f SE |
15 | AC_PROG_CC |
16 | AC_GNU_SOURCE | |
7357c5b6 | 17 | AC_USE_SYSTEM_EXTENSIONS |
d053aef8 | 18 | AC_SYS_LARGEFILE |
da594c4a | 19 | LT_INIT |
252b5132 RH |
20 | |
21 | AC_ARG_ENABLE(targets, | |
22 | [ --enable-targets alternative target configurations], | |
23 | [case "${enableval}" in | |
da594c4a | 24 | yes | "") AC_MSG_ERROR(enable-targets option must specify target names or 'all') |
252b5132 RH |
25 | ;; |
26 | no) enable_targets= ;; | |
27 | *) enable_targets=$enableval ;; | |
28 | esac])dnl | |
252b5132 | 29 | |
398ee8f1 | 30 | AM_BINUTILS_WARNINGS |
9e9b66a9 | 31 | |
da594c4a | 32 | AC_CONFIG_HEADERS(config.h:config.in) |
252b5132 RH |
33 | |
34 | if test -z "$target" ; then | |
35 | AC_MSG_ERROR(Unrecognized target system type; please check config.sub.) | |
36 | fi | |
37 | if test -z "$host" ; then | |
38 | AC_MSG_ERROR(Unrecognized host system type; please check config.sub.) | |
39 | fi | |
40 | ||
252b5132 RH |
41 | AC_PROG_YACC |
42 | AM_PROG_LEX | |
43 | ||
ac5d747e | 44 | ALL_LINGUAS="da es fi fr id ja ro ru rw sk sv tr uk vi zh_CN zh_TW" |
20e95c23 DJ |
45 | ZW_GNU_GETTEXT_SISTER_DIR |
46 | AM_PO_SUBDIRS | |
252b5132 RH |
47 | |
48 | AM_MAINTAINER_MODE | |
d5fbea21 | 49 | AM_CONDITIONAL(GENINSRC_NEVER, false) |
252b5132 | 50 | AC_EXEEXT |
2481e6a2 ILT |
51 | if test -n "$EXEEXT"; then |
52 | AC_DEFINE(HAVE_EXECUTABLE_SUFFIX, 1, | |
53 | [Does the platform use an executable suffix?]) | |
54 | fi | |
bb0cb4db ILT |
55 | AC_DEFINE_UNQUOTED(EXECUTABLE_SUFFIX, "${EXEEXT}", |
56 | [Suffix used for executables, if any.]) | |
252b5132 RH |
57 | |
58 | # host-specific stuff: | |
59 | ||
60 | HDEFINES= | |
61 | ||
62 | . ${srcdir}/../bfd/configure.host | |
63 | ||
64 | AC_SUBST(HDEFINES) | |
65 | AR=${AR-ar} | |
66 | AC_SUBST(AR) | |
67 | AC_PROG_RANLIB | |
68 | AC_PROG_INSTALL | |
69 | ||
70 | BFD_CC_FOR_BUILD | |
71 | ||
8a965946 ILT |
72 | DEMANGLER_NAME=c++filt |
73 | case "${host}" in | |
74 | *-*-go32* | *-*-msdos*) | |
75 | DEMANGLER_NAME=cxxfilt | |
76 | esac | |
77 | AC_SUBST(DEMANGLER_NAME) | |
78 | ||
f8eae8b2 | 79 | AC_CHECK_HEADERS(string.h strings.h stdlib.h unistd.h fcntl.h sys/file.h limits.h sys/param.h) |
252b5132 RH |
80 | AC_HEADER_SYS_WAIT |
81 | AC_FUNC_ALLOCA | |
9710509e | 82 | AC_CHECK_FUNCS(sbrk utimes setmode getc_unlocked strcoll) |
f9c026a8 NC |
83 | AC_CHECK_FUNC([mkstemp], |
84 | AC_DEFINE([HAVE_MKSTEMP], 1, | |
85 | [Define to 1 if you have the `mkstemp' function.])) | |
86 | AC_CHECK_FUNC([mkdtemp], | |
87 | AC_DEFINE([HAVE_MKDTEMP], 1, | |
88 | [Define to 1 if you have the `mkdtemp' function.])) | |
cedd9a58 JJ |
89 | |
90 | # Check whether fopen64 is available and whether _LARGEFILE64_SOURCE | |
91 | # needs to be defined for it | |
92 | AC_MSG_CHECKING([for fopen64]) | |
93 | AC_CACHE_VAL(bu_cv_have_fopen64, | |
da594c4a | 94 | [AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <stdio.h>], [FILE *f = fopen64 ("/tmp/foo","r");])], |
cedd9a58 JJ |
95 | bu_cv_have_fopen64=yes, |
96 | [saved_CPPFLAGS=$CPPFLAGS | |
97 | CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE" | |
da594c4a AM |
98 | AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <stdio.h>], [FILE *f = fopen64 ("/tmp/foo","r");])], |
99 | bu_cv_have_fopen64="need -D_LARGEFILE64_SOURCE", | |
100 | bu_cv_have_fopen64=no) | |
cedd9a58 JJ |
101 | CPPFLAGS=$saved_CPPFLAGS])]) |
102 | AC_MSG_RESULT($bu_cv_have_fopen64) | |
6db7a086 | 103 | if test "$bu_cv_have_fopen64" != no; then |
cedd9a58 JJ |
104 | AC_DEFINE([HAVE_FOPEN64], 1, |
105 | [Is fopen64 available?]) | |
fb5b5478 JJ |
106 | fi |
107 | AC_MSG_CHECKING([for stat64]) | |
108 | AC_CACHE_VAL(bu_cv_have_stat64, | |
da594c4a | 109 | [AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <sys/stat.h>], [struct stat64 st; stat64 ("/tmp/foo", &st);])], |
fb5b5478 JJ |
110 | bu_cv_have_stat64=yes, |
111 | [saved_CPPFLAGS=$CPPFLAGS | |
112 | CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE" | |
da594c4a AM |
113 | AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <sys/stat.h>], [struct stat64 st; stat64 ("/tmp/foo", &st);])], |
114 | bu_cv_have_stat64="need -D_LARGEFILE64_SOURCE", | |
115 | bu_cv_have_stat64=no) | |
fb5b5478 JJ |
116 | CPPFLAGS=$saved_CPPFLAGS])]) |
117 | AC_MSG_RESULT($bu_cv_have_stat64) | |
118 | if test "$bu_cv_have_stat64" != no; then | |
119 | AC_DEFINE([HAVE_STAT64], 1, | |
120 | [Is stat64 available?]) | |
121 | fi | |
122 | if test "$bu_cv_have_fopen64" = "need -D_LARGEFILE64_SOURCE" \ | |
123 | || test "$bu_cv_have_stat64" = "need -D_LARGEFILE64_SOURCE"; then | |
124 | AC_DEFINE([_LARGEFILE64_SOURCE], 1, | |
125 | [Enable LFS]) | |
126 | CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE" | |
cedd9a58 | 127 | fi |
252b5132 | 128 | |
f353eb8a | 129 | # Some systems have frexp only in -lm, not in -lc. |
07735828 | 130 | AC_SEARCH_LIBS(frexp, m) |
f353eb8a | 131 | |
252b5132 RH |
132 | AC_MSG_CHECKING(for time_t in time.h) |
133 | AC_CACHE_VAL(bu_cv_decl_time_t_time_h, | |
da594c4a | 134 | [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <time.h>], [time_t i;])], |
252b5132 RH |
135 | bu_cv_decl_time_t_time_h=yes, bu_cv_decl_time_t_time_h=no)]) |
136 | AC_MSG_RESULT($bu_cv_decl_time_t_time_h) | |
137 | if test $bu_cv_decl_time_t_time_h = yes; then | |
138 | AC_DEFINE([HAVE_TIME_T_IN_TIME_H], 1, | |
139 | [Is the type time_t defined in <time.h>?]) | |
140 | fi | |
141 | ||
142 | AC_MSG_CHECKING(for time_t in sys/types.h) | |
143 | AC_CACHE_VAL(bu_cv_decl_time_t_types_h, | |
da594c4a | 144 | [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <sys/types.h>], [time_t i;])], |
252b5132 RH |
145 | bu_cv_decl_time_t_types_h=yes, bu_cv_decl_time_t_types_h=no)]) |
146 | AC_MSG_RESULT($bu_cv_decl_time_t_types_h) | |
147 | if test $bu_cv_decl_time_t_types_h = yes; then | |
148 | AC_DEFINE([HAVE_TIME_T_IN_TYPES_H], 1, | |
149 | [Is the type time_t defined in <sys/types.h>?]) | |
150 | fi | |
151 | ||
e46eba98 NC |
152 | AC_MSG_CHECKING(for a known getopt prototype in unistd.h) |
153 | AC_CACHE_VAL(bu_cv_decl_getopt_unistd_h, | |
da594c4a | 154 | [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <unistd.h>], [extern int getopt (int, char *const*, const char *);])], |
e46eba98 NC |
155 | bu_cv_decl_getopt_unistd_h=yes, bu_cv_decl_getopt_unistd_h=no)]) |
156 | AC_MSG_RESULT($bu_cv_decl_getopt_unistd_h) | |
157 | if test $bu_cv_decl_getopt_unistd_h = yes; then | |
158 | AC_DEFINE([HAVE_DECL_GETOPT], 1, | |
159 | [Is the prototype for getopt in <unistd.h> in the expected format?]) | |
160 | fi | |
161 | ||
252b5132 RH |
162 | # Under Next 3.2 <utime.h> apparently does not define struct utimbuf |
163 | # by default. | |
164 | AC_MSG_CHECKING([for utime.h]) | |
165 | AC_CACHE_VAL(bu_cv_header_utime_h, | |
da594c4a | 166 | [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <sys/types.h> |
252b5132 RH |
167 | #ifdef HAVE_TIME_H |
168 | #include <time.h> | |
169 | #endif | |
170 | #include <utime.h>], | |
da594c4a | 171 | [struct utimbuf s;])], |
252b5132 RH |
172 | bu_cv_header_utime_h=yes, bu_cv_header_utime_h=no)]) |
173 | AC_MSG_RESULT($bu_cv_header_utime_h) | |
174 | if test $bu_cv_header_utime_h = yes; then | |
175 | AC_DEFINE(HAVE_GOOD_UTIME_H, 1, [Does <utime.h> define struct utimbuf?]) | |
176 | fi | |
177 | ||
db50c840 EB |
178 | AC_CHECK_DECLS([fprintf, stpcpy, strstr, sbrk, getenv, environ, getc_unlocked, |
179 | snprintf, vsnprintf]) | |
252b5132 | 180 | |
1b315056 CS |
181 | # Link in zlib if we can. This allows us to read compressed debug |
182 | # sections. This is used only by readelf.c (objdump uses bfd for | |
183 | # reading compressed sections). | |
184 | AC_SEARCH_LIBS(zlibVersion, z, [AC_CHECK_HEADERS(zlib.h)]) | |
185 | ||
252b5132 RH |
186 | BFD_BINARY_FOPEN |
187 | ||
188 | # target-specific stuff: | |
189 | ||
190 | # Canonicalize the secondary target names. | |
191 | if test -n "$enable_targets"; then | |
192 | for targ in `echo $enable_targets | sed 's/,/ /g'` | |
193 | do | |
6d83c84b | 194 | result=`$ac_config_sub $targ 2>/dev/null` |
252b5132 RH |
195 | if test -n "$result"; then |
196 | canon_targets="$canon_targets $result" | |
197 | else | |
198 | # Allow targets that config.sub doesn't recognize, like "all". | |
199 | canon_targets="$canon_targets $targ" | |
200 | fi | |
201 | done | |
202 | fi | |
203 | ||
5ba684e2 NC |
204 | AC_CHECK_HEADER(iconv.h) |
205 | AM_ICONV | |
206 | ||
252b5132 RH |
207 | all_targets=false |
208 | BUILD_NLMCONV= | |
209 | NLMCONV_DEFS= | |
210 | BUILD_SRCONV= | |
211 | BUILD_DLLTOOL= | |
212 | DLLTOOL_DEFS= | |
7aad4c3d | 213 | DLLTOOL_DEFAULT= |
252b5132 | 214 | BUILD_WINDRES= |
692ed3e7 | 215 | BUILD_WINDMC= |
252b5132 RH |
216 | BUILD_DLLWRAP= |
217 | BUILD_MISC= | |
1d97d67f | 218 | BUILD_INSTALL_MISC= |
8b1e6df3 | 219 | OBJDUMP_DEFS= |
252b5132 RH |
220 | |
221 | for targ in $target $canon_targets | |
222 | do | |
223 | if test "x$targ" = "xall"; then | |
224 | all_targets=true | |
225 | BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)' | |
226 | BUILD_SRCONV='$(SRCONV_PROG)' | |
227 | NLMCONV_DEFS="-DNLMCONV_I386 -DNLMCONV_ALPHA -DNLMCONV_POWERPC -DNLMCONV_SPARC" | |
1d97d67f | 228 | BUILD_MISC="${BUILD_MISC} "'bin2c$(EXEEXT_FOR_BUILD)' |
003bc0ba NC |
229 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' |
230 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' | |
231 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' | |
232 | if test -z "$DLLTOOL_DEFAULT"; then | |
233 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386" | |
234 | fi | |
235 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386" | |
236 | BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)' | |
252b5132 RH |
237 | else |
238 | case $targ in | |
239 | changequote(,)dnl | |
80c7c40a | 240 | i[3-7]86*-*-netware*) |
252b5132 RH |
241 | changequote([,])dnl |
242 | BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)' | |
243 | NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_I386" | |
244 | ;; | |
245 | alpha*-*-netware*) | |
246 | BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)' | |
247 | NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_ALPHA" | |
248 | ;; | |
249 | powerpc*-*-netware*) | |
250 | BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)' | |
251 | NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_POWERPC" | |
252 | ;; | |
253 | sparc*-*-netware*) | |
254 | BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)' | |
255 | NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_SPARC" | |
256 | ;; | |
257 | esac | |
258 | case $targ in | |
259 | *-*-hms*) BUILD_SRCONV='$(SRCONV_PROG)' ;; | |
260 | esac | |
261 | case $targ in | |
a8c548cb NC |
262 | arm-epoc-pe*) |
263 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' | |
7aad4c3d L |
264 | if test -z "$DLLTOOL_DEFAULT"; then |
265 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM_EPOC" | |
266 | fi | |
a8c548cb NC |
267 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM_EPOC -DDLLTOOL_ARM" |
268 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 269 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
a8c548cb | 270 | ;; |
7148cc28 NC |
271 | arm-wince-pe* | arm-*-wince) |
272 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' | |
7aad4c3d L |
273 | if test -z "$DLLTOOL_DEFAULT"; then |
274 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM_WINCE" | |
275 | fi | |
7148cc28 NC |
276 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM_WINCE -DDLLTOOL_ARM" |
277 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 278 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
7148cc28 NC |
279 | ;; |
280 | arm-*-pe*) | |
252b5132 | 281 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
282 | if test -z "$DLLTOOL_DEFAULT"; then |
283 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM" | |
284 | fi | |
252b5132 RH |
285 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM" |
286 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 287 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
7a7b06ef | 288 | ;; |
27a710e5 | 289 | thumb-*-pe*) |
252b5132 | 290 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
291 | if test -z "$DLLTOOL_DEFAULT"; then |
292 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM" | |
293 | fi | |
252b5132 RH |
294 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM" |
295 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 296 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
7a7b06ef | 297 | ;; |
42037fe5 | 298 | x86_64-*-mingw*) |
99ad8390 | 299 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
300 | if test -z "$DLLTOOL_DEFAULT"; then |
301 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MX86_64" | |
302 | fi | |
99ad8390 NC |
303 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MX86_64" |
304 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 305 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
99ad8390 NC |
306 | BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)' |
307 | ;; | |
252b5132 | 308 | changequote(,)dnl |
80c7c40a | 309 | i[3-7]86-*-pe* | i[3-7]86-*-cygwin* | i[3-7]86-*-mingw32** | i[3-7]86-*-netbsdpe*) |
252b5132 RH |
310 | changequote([,])dnl |
311 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' | |
7aad4c3d L |
312 | if test -z "$DLLTOOL_DEFAULT"; then |
313 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386" | |
314 | fi | |
252b5132 RH |
315 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386" |
316 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 317 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
252b5132 | 318 | BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)' |
7a7b06ef | 319 | ;; |
80c7c40a NC |
320 | changequote(,)dnl |
321 | i[3-7]86-*-interix) | |
322 | changequote([,])dnl | |
7a7b06ef | 323 | BUILD_DLLTOOL='$(DLLTOOL_PROG)' |
7aad4c3d L |
324 | if test -z "$DLLTOOL_DEFAULT"; then |
325 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386" | |
326 | fi | |
7a7b06ef ILT |
327 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386" |
328 | ;; | |
f0660b73 NC |
329 | changequote(,)dnl |
330 | powerpc*-aix5.[01]) | |
331 | changequote([,])dnl | |
332 | ;; | |
333 | powerpc*-aix5.*) | |
334 | OBJDUMP_DEFS="-DAIX_WEAK_SUPPORT" | |
335 | ;; | |
e1d5b1e7 | 336 | powerpc*-*-pe* | powerpc*-*-cygwin*) |
252b5132 | 337 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
338 | if test -z "$DLLTOOL_DEFAULT"; then |
339 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_PPC" | |
340 | fi | |
252b5132 RH |
341 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_PPC" |
342 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 343 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
7a7b06ef | 344 | ;; |
59678365 | 345 | powerpc*-*-linux* | powerpc*-*-elf* | powerpc*-*-eabi*) |
1d97d67f | 346 | BUILD_INSTALL_MISC="${BUILD_INSTALL_MISC} embedspu" |
669a9a2a | 347 | ;; |
e1d5b1e7 | 348 | sh*-*-pe) |
8a0e0f38 | 349 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
350 | if test -z "$DLLTOOL_DEFAULT"; then |
351 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_SH" | |
352 | fi | |
8a0e0f38 NC |
353 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_SH" |
354 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 355 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
8a0e0f38 | 356 | ;; |
cd14b966 | 357 | spu-*-*) |
1d97d67f | 358 | BUILD_MISC="${BUILD_MISC} "'bin2c$(EXEEXT_FOR_BUILD)' |
cd14b966 | 359 | ;; |
e1d5b1e7 | 360 | mips*-*-pe) |
8a0e0f38 | 361 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
362 | if test -z "$DLLTOOL_DEFAULT"; then |
363 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MIPS" | |
364 | fi | |
8a0e0f38 NC |
365 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MIPS" |
366 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 367 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
8a0e0f38 | 368 | ;; |
27a710e5 | 369 | mcore-*-pe) |
661016bb | 370 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
371 | if test -z "$DLLTOOL_DEFAULT"; then |
372 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MCORE" | |
373 | fi | |
661016bb NC |
374 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE" |
375 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
692ed3e7 | 376 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' |
7a7b06ef | 377 | ;; |
27a710e5 | 378 | mcore-*-elf) |
661016bb | 379 | BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)' |
7aad4c3d L |
380 | if test -z "$DLLTOOL_DEFAULT"; then |
381 | DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MCORE_ELF" | |
382 | fi | |
661016bb | 383 | DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF" |
7a7b06ef | 384 | ;; |
15ab5209 DB |
385 | mep-*) |
386 | OBJDUMP_DEFS="-DSKIP_ZEROES=256 -DSKIP_ZEROES_AT_END=0" | |
387 | ;; | |
252b5132 RH |
388 | esac |
389 | fi | |
390 | done | |
391 | ||
7aad4c3d L |
392 | DLLTOOL_DEFS="$DLLTOOL_DEFS $DLLTOOL_DEFAULT" |
393 | ||
c918cb96 DD |
394 | if test "${with_windres+set}" = set; then |
395 | BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)' | |
396 | fi | |
397 | ||
692ed3e7 NC |
398 | if test "${with_windmc+set}" = set; then |
399 | BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)' | |
400 | fi | |
401 | ||
252b5132 RH |
402 | AC_SUBST(NLMCONV_DEFS) |
403 | AC_SUBST(BUILD_NLMCONV) | |
404 | AC_SUBST(BUILD_SRCONV) | |
405 | AC_SUBST(BUILD_DLLTOOL) | |
406 | AC_SUBST(DLLTOOL_DEFS) | |
407 | AC_SUBST(BUILD_WINDRES) | |
692ed3e7 | 408 | AC_SUBST(BUILD_WINDMC) |
252b5132 RH |
409 | AC_SUBST(BUILD_DLLWRAP) |
410 | AC_SUBST(BUILD_MISC) | |
1d97d67f | 411 | AC_SUBST(BUILD_INSTALL_MISC) |
8b1e6df3 | 412 | AC_SUBST(OBJDUMP_DEFS) |
252b5132 RH |
413 | |
414 | AC_DEFINE_UNQUOTED(TARGET, "${target}", [Configured target name.]) | |
415 | ||
416 | targ=$target | |
417 | . $srcdir/../bfd/config.bfd | |
418 | if test "x$targ_underscore" = "xyes"; then | |
419 | UNDERSCORE=1 | |
420 | else | |
421 | UNDERSCORE=0 | |
422 | fi | |
bb279dc0 ZW |
423 | AC_DEFINE_UNQUOTED(TARGET_PREPENDS_UNDERSCORE, $UNDERSCORE, |
424 | [Define to 1 if user symbol names have a leading underscore, 0 if not.]) | |
252b5132 | 425 | |
eb1e0e80 NC |
426 | # Emulation |
427 | for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'` | |
428 | do | |
429 | # Canonicalize the secondary target names. | |
430 | result=`$ac_config_sub $targ_alias 2>/dev/null` | |
431 | if test -n "$result"; then | |
432 | targ=$result | |
433 | else | |
434 | targ=$targ_alias | |
435 | fi | |
436 | ||
437 | . ${srcdir}/configure.tgt | |
438 | ||
439 | EMULATION=$targ_emul | |
440 | EMULATION_VECTOR=$targ_emul_vector | |
441 | done | |
442 | ||
443 | AC_SUBST(EMULATION) | |
444 | AC_SUBST(EMULATION_VECTOR) | |
445 | ||
108a6f8e CD |
446 | # Required for html and install-html |
447 | AC_SUBST(datarootdir) | |
448 | AC_SUBST(docdir) | |
449 | AC_SUBST(htmldir) | |
450 | ||
da594c4a AM |
451 | AC_CONFIG_FILES(Makefile doc/Makefile po/Makefile.in:po/Make-in) |
452 | AC_OUTPUT |