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