configure.ac 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558
  1. dnl Process this file with autoconf to produce a configure script.
  2. dnl
  3. dnl Copyright (C) 2012-2022 Free Software Foundation, Inc.
  4. dnl
  5. dnl This file is free software; you can redistribute it and/or modify
  6. dnl it under the terms of the GNU General Public License as published by
  7. dnl the Free Software Foundation; either version 3 of the License, or
  8. dnl (at your option) any later version.
  9. dnl
  10. dnl This program is distributed in the hope that it will be useful,
  11. dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. dnl GNU General Public License for more details.
  14. dnl
  15. dnl You should have received a copy of the GNU General Public License
  16. dnl along with this program; see the file COPYING3. If not see
  17. dnl <http://www.gnu.org/licenses/>.
  18. dnl
  19. m4_include([../bfd/version.m4])
  20. m4_include([../config/debuginfod.m4])
  21. AC_INIT([binutils], BFD_VERSION)
  22. AC_CONFIG_SRCDIR(ar.c)
  23. AC_CANONICAL_TARGET
  24. AM_INIT_AUTOMAKE
  25. AM_SILENT_RULES([yes])
  26. AC_PROG_CC
  27. AC_GNU_SOURCE
  28. AC_USE_SYSTEM_EXTENSIONS
  29. LT_INIT
  30. ACX_LARGEFILE
  31. ac_checking=
  32. . ${srcdir}/../bfd/development.sh
  33. test "$development" = true && ac_checking=yes
  34. AC_ARG_ENABLE(checking,
  35. [ --enable-checking enable run-time checks],
  36. [case "${enableval}" in
  37. no|none) ac_checking= ;;
  38. *) ac_checking=yes ;;
  39. esac])dnl
  40. if test x$ac_checking != x ; then
  41. AC_DEFINE(ENABLE_CHECKING, 1, [Define if you want run-time sanity checks.])
  42. fi
  43. AC_ARG_ENABLE(targets,
  44. [ --enable-targets alternative target configurations],
  45. [case "${enableval}" in
  46. yes | "") AC_MSG_ERROR(enable-targets option must specify target names or 'all')
  47. ;;
  48. no) enable_targets= ;;
  49. *) enable_targets=$enableval ;;
  50. esac])dnl
  51. AC_ARG_ENABLE(deterministic-archives,
  52. [AS_HELP_STRING([--enable-deterministic-archives],
  53. [ar and ranlib default to -D behavior])], [
  54. if test "${enableval}" = no; then
  55. default_ar_deterministic=0
  56. else
  57. default_ar_deterministic=1
  58. fi], [default_ar_deterministic=0])
  59. AC_DEFINE_UNQUOTED(DEFAULT_AR_DETERMINISTIC, $default_ar_deterministic,
  60. [Should ar and ranlib use -D behavior by default?])
  61. AC_ARG_ENABLE(default-strings-all,
  62. [AS_HELP_STRING([--disable-default-strings-all],
  63. [strings defaults to --data behavior])], [
  64. if test "${enableval}" = no; then
  65. default_strings_all=0
  66. else
  67. default_strings_all=1
  68. fi], [default_strings_all=1])
  69. AC_DEFINE_UNQUOTED(DEFAULT_STRINGS_ALL, $default_strings_all,
  70. [Should strings use -a behavior by default?])
  71. AC_ARG_ENABLE(f-for-ifunc-symbols,
  72. [AS_HELP_STRING([--enable-f-for-ifunc-symbols],
  73. [Have nm use F and f for global and local ifunc symbols])], [
  74. if test "${enableval}" = no; then
  75. default_f_for_ifunc=0
  76. else
  77. default_f_for_ifunc=1
  78. fi], [default_f_for_ifunc=0])
  79. AC_DEFINE_UNQUOTED(DEFAULT_F_FOR_IFUNC_SYMBOLS, $default_f_for_ifunc,
  80. [Have nm use F and f for global and local ifunc symbols])
  81. AC_ARG_ENABLE(follow-debug-links,
  82. [AS_HELP_STRING([--enable-follow-debug-links],
  83. [Have readelf and objdump follow debug links by default])], [
  84. if test "${enableval}" = no; then
  85. default_for_follow_links=0
  86. else
  87. default_for_follow_links=1
  88. fi], [default_for_follow_links=1])
  89. AC_DEFINE_UNQUOTED(DEFAULT_FOR_FOLLOW_LINKS, $default_for_follow_links,
  90. [Have readelf and objdump follow debug links by default])
  91. AC_DEBUGINFOD
  92. GCC_ENABLE([libctf], [yes], [], [Handle .ctf type-info sections])
  93. if test "${enable_libctf}" = yes; then
  94. AC_DEFINE(ENABLE_LIBCTF, 1, [Handle .ctf type-info sections])
  95. fi
  96. AM_CONDITIONAL(ENABLE_LIBCTF, test "${enable_libctf}" = yes)
  97. AM_BINUTILS_WARNINGS
  98. AC_CONFIG_HEADERS(config.h:config.in)
  99. AH_VERBATIM([00_CONFIG_H_CHECK],
  100. [/* Check that config.h is #included before system headers
  101. (this works only for glibc, but that should be enough). */
  102. #if defined(__GLIBC__) && !defined(__FreeBSD_kernel__) && !defined(__CONFIG_H__)
  103. # error config.h must be #included before system headers
  104. #endif
  105. #define __CONFIG_H__ 1])
  106. if test -z "$target" ; then
  107. AC_MSG_ERROR(Unrecognized target system type; please check config.sub.)
  108. fi
  109. if test -z "$host" ; then
  110. AC_MSG_ERROR(Unrecognized host system type; please check config.sub.)
  111. fi
  112. AC_PROG_YACC
  113. AM_PROG_LEX
  114. ALL_LINGUAS="bg ca da es fi fr hr id it ja pt ro ru rw sk sr sv tr uk vi zh_CN zh_TW"
  115. ZW_GNU_GETTEXT_SISTER_DIR
  116. AM_PO_SUBDIRS
  117. AM_MAINTAINER_MODE
  118. AM_CONDITIONAL(GENINSRC_NEVER, false)
  119. AC_EXEEXT
  120. if test -n "$EXEEXT"; then
  121. AC_DEFINE(HAVE_EXECUTABLE_SUFFIX, 1,
  122. [Does the platform use an executable suffix?])
  123. fi
  124. AC_DEFINE_UNQUOTED(EXECUTABLE_SUFFIX, "${EXEEXT}",
  125. [Suffix used for executables, if any.])
  126. # host-specific stuff:
  127. HDEFINES=
  128. . ${srcdir}/../bfd/configure.host
  129. AC_SUBST(HDEFINES)
  130. AR=${AR-ar}
  131. AC_SUBST(AR)
  132. AC_PROG_RANLIB
  133. AC_PROG_INSTALL
  134. BFD_CC_FOR_BUILD
  135. DEMANGLER_NAME=c++filt
  136. case "${host}" in
  137. *-*-go32* | *-*-msdos*)
  138. DEMANGLER_NAME=cxxfilt
  139. esac
  140. AC_SUBST(DEMANGLER_NAME)
  141. AC_CHECK_SIZEOF([long])
  142. AC_CHECK_SIZEOF([long long])
  143. # We use headers from include/ that check various HAVE_*_H macros, thus
  144. # should ensure they are set by configure. This is true even when C99
  145. # guarantees they are available.
  146. # plugin-api.h tests HAVE_STDINT_H and HAVE_INTTYPES_H
  147. # Besides those, we need to check anything used in binutils/ not in C99.
  148. AC_CHECK_HEADERS(fcntl.h inttypes.h stdint.h sys/file.h \
  149. sys/stat.h sys/time.h sys/types.h unistd.h)
  150. AC_HEADER_SYS_WAIT
  151. AC_FUNC_MMAP
  152. AC_CHECK_FUNCS(getc_unlocked mkdtemp mkstemp sbrk utimensat utimes)
  153. AC_MSG_CHECKING([for mbstate_t])
  154. AC_TRY_COMPILE([#include <wchar.h>],
  155. [mbstate_t teststate;],
  156. have_mbstate_t=yes, have_mbstate_t=no)
  157. AC_MSG_RESULT($have_mbstate_t)
  158. if test x"$have_mbstate_t" = xyes; then
  159. AC_DEFINE(HAVE_MBSTATE_T,1,[Define if mbstate_t exists in wchar.h.])
  160. fi
  161. # Copied from gnulib stat-time.m4.
  162. # We should just switch over to using gnulib.
  163. AC_CHECK_MEMBERS([struct stat.st_atim.tv_nsec],
  164. [AC_CACHE_CHECK([whether struct stat.st_atim is of type struct timespec],
  165. [ac_cv_typeof_struct_stat_st_atim_is_struct_timespec],
  166. [AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
  167. [[
  168. #include <sys/types.h>
  169. #include <sys/stat.h>
  170. #if HAVE_SYS_TIME_H
  171. # include <sys/time.h>
  172. #endif
  173. #include <time.h>
  174. struct timespec ts;
  175. struct stat st;
  176. ]],
  177. [[
  178. st.st_atim = ts;
  179. ]])],
  180. [ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes],
  181. [ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no])])
  182. if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
  183. AC_DEFINE([TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC], [1],
  184. [Define to 1 if the type of the st_atim member of a struct stat is
  185. struct timespec.])
  186. fi],
  187. [AC_CHECK_MEMBERS([struct stat.st_atimespec.tv_nsec], [],
  188. [AC_CHECK_MEMBERS([struct stat.st_atimensec], [],
  189. [AC_CHECK_MEMBERS([struct stat.st_atim.st__tim.tv_nsec], [], [],
  190. [#include <sys/types.h>
  191. #include <sys/stat.h>])],
  192. [#include <sys/types.h>
  193. #include <sys/stat.h>])],
  194. [#include <sys/types.h>
  195. #include <sys/stat.h>])],
  196. [#include <sys/types.h>
  197. #include <sys/stat.h>])
  198. # Some systems have frexp only in -lm, not in -lc.
  199. AC_SEARCH_LIBS(frexp, m)
  200. AM_LC_MESSAGES
  201. AC_MSG_CHECKING(for a known getopt prototype in unistd.h)
  202. AC_CACHE_VAL(bu_cv_decl_getopt_unistd_h,
  203. [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <unistd.h>], [extern int getopt (int, char *const*, const char *);])],
  204. bu_cv_decl_getopt_unistd_h=yes, bu_cv_decl_getopt_unistd_h=no)])
  205. AC_MSG_RESULT($bu_cv_decl_getopt_unistd_h)
  206. if test $bu_cv_decl_getopt_unistd_h = yes; then
  207. AC_DEFINE([HAVE_DECL_GETOPT], 1,
  208. [Is the prototype for getopt in <unistd.h> in the expected format?])
  209. fi
  210. # Under Next 3.2 <utime.h> apparently does not define struct utimbuf
  211. # by default.
  212. AC_MSG_CHECKING([for utime.h])
  213. AC_CACHE_VAL(bu_cv_header_utime_h,
  214. [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <sys/types.h>
  215. #ifdef HAVE_TIME_H
  216. #include <time.h>
  217. #endif
  218. #include <utime.h>],
  219. [struct utimbuf s;])],
  220. bu_cv_header_utime_h=yes, bu_cv_header_utime_h=no)])
  221. AC_MSG_RESULT($bu_cv_header_utime_h)
  222. if test $bu_cv_header_utime_h = yes; then
  223. AC_DEFINE(HAVE_GOOD_UTIME_H, 1, [Does <utime.h> define struct utimbuf?])
  224. fi
  225. AC_CHECK_DECLS([asprintf, environ, getc_unlocked, sbrk, stpcpy, strnlen])
  226. # Link in zlib if we can. This allows us to read compressed debug
  227. # sections. This is used only by readelf.c (objdump uses bfd for
  228. # reading compressed sections).
  229. AM_ZLIB
  230. BFD_BINARY_FOPEN
  231. # Support for the msgpack C library.
  232. AC_ARG_WITH([msgpack],
  233. AC_HELP_STRING([--with-msgpack], [Enable msgpack support (auto/yes/no)]),
  234. [],
  235. [with_msgpack=auto])
  236. if test "$with_msgpack" != no; then
  237. PKG_CHECK_MODULES(MSGPACK, msgpack, [
  238. AC_DEFINE([HAVE_MSGPACK], [1], [Define to 1 if msgpack is available.])
  239. ], [
  240. if test "$with_msgpack" = yes; then
  241. AC_MSG_ERROR([--with-msgpack was given, but msgpack is missing or unusable.])
  242. fi
  243. ])
  244. fi
  245. # target-specific stuff:
  246. # Canonicalize the secondary target names.
  247. if test -n "$enable_targets"; then
  248. for targ in `echo $enable_targets | sed 's/,/ /g'`
  249. do
  250. result=`$ac_config_sub $targ 2>/dev/null`
  251. if test -n "$result"; then
  252. canon_targets="$canon_targets $result"
  253. else
  254. # Allow targets that config.sub doesn't recognize, like "all".
  255. canon_targets="$canon_targets $targ"
  256. fi
  257. done
  258. fi
  259. AC_CHECK_HEADER(iconv.h)
  260. AM_ICONV
  261. all_targets=false
  262. BUILD_SRCONV=
  263. BUILD_DLLTOOL=
  264. DLLTOOL_DEFS=
  265. DLLTOOL_DEFAULT=
  266. BUILD_WINDRES=
  267. BUILD_WINDMC=
  268. BUILD_DLLWRAP=
  269. BUILD_MISC=
  270. BUILD_INSTALL_MISC=
  271. OBJDUMP_DEFS=
  272. OBJDUMP_PRIVATE_VECTORS=
  273. OBJDUMP_PRIVATE_OFILES=
  274. od_vectors=
  275. for targ in $target $canon_targets
  276. do
  277. if test "x$targ" = "xall"; then
  278. all_targets=true
  279. BUILD_SRCONV='$(SRCONV_PROG)'
  280. BUILD_MISC="${BUILD_MISC} "'bin2c$(EXEEXT_FOR_BUILD)'
  281. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  282. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  283. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  284. if test -z "$DLLTOOL_DEFAULT"; then
  285. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386"
  286. fi
  287. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
  288. BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
  289. od_vectors="$od_vectors objdump_private_desc_xcoff"
  290. else
  291. case $targ in
  292. *-*-hms*) BUILD_SRCONV='$(SRCONV_PROG)' ;;
  293. esac
  294. case $targ in
  295. arm-wince-pe* | arm-*-wince | arm*-*-cegcc* | arm*-*-mingw32ce*)
  296. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  297. if test -z "$DLLTOOL_DEFAULT"; then
  298. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM_WINCE"
  299. fi
  300. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM_WINCE -DDLLTOOL_ARM"
  301. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  302. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  303. ;;
  304. arm-*-pe*)
  305. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  306. if test -z "$DLLTOOL_DEFAULT"; then
  307. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM"
  308. fi
  309. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
  310. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  311. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  312. ;;
  313. x86_64-*-mingw* | x86_64-*-cygwin*)
  314. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  315. if test -z "$DLLTOOL_DEFAULT"; then
  316. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MX86_64"
  317. fi
  318. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MX86_64"
  319. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  320. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  321. BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
  322. ;;
  323. changequote(,)dnl
  324. i[3-7]86-*-pe* | i[3-7]86-*-cygwin* | i[3-7]86-*-mingw32**)
  325. changequote([,])dnl
  326. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  327. if test -z "$DLLTOOL_DEFAULT"; then
  328. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386"
  329. fi
  330. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
  331. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  332. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  333. BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
  334. ;;
  335. changequote(,)dnl
  336. i[3-7]86-*-interix)
  337. changequote([,])dnl
  338. BUILD_DLLTOOL='$(DLLTOOL_PROG)'
  339. if test -z "$DLLTOOL_DEFAULT"; then
  340. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386"
  341. fi
  342. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
  343. ;;
  344. changequote(,)dnl
  345. powerpc*-aix5.[01])
  346. changequote([,])dnl
  347. ;;
  348. changequote(,)dnl
  349. powerpc*-aix[5-9].*)
  350. changequote([,])dnl
  351. OBJDUMP_DEFS="-DAIX_WEAK_SUPPORT"
  352. ;;
  353. powerpc*-*-linux* | powerpc*-*-elf* | powerpc*-*-eabi*)
  354. case "$BUILD_INSTALL_MISC" in
  355. *embedspu*) ;;
  356. *) BUILD_INSTALL_MISC="${BUILD_INSTALL_MISC} embedspu"
  357. esac
  358. ;;
  359. sh*-*-pe)
  360. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  361. if test -z "$DLLTOOL_DEFAULT"; then
  362. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_SH"
  363. fi
  364. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_SH"
  365. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  366. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  367. ;;
  368. spu-*-*)
  369. BUILD_MISC="${BUILD_MISC} "'bin2c$(EXEEXT_FOR_BUILD)'
  370. ;;
  371. mips*-*-pe)
  372. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  373. if test -z "$DLLTOOL_DEFAULT"; then
  374. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MIPS"
  375. fi
  376. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MIPS"
  377. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  378. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  379. ;;
  380. mcore-*-pe)
  381. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  382. if test -z "$DLLTOOL_DEFAULT"; then
  383. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MCORE"
  384. fi
  385. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE"
  386. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  387. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  388. ;;
  389. mcore-*-elf)
  390. BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
  391. if test -z "$DLLTOOL_DEFAULT"; then
  392. DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MCORE_ELF"
  393. fi
  394. DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF"
  395. ;;
  396. mep-*)
  397. OBJDUMP_DEFS="-DSKIP_ZEROES=256 -DSKIP_ZEROES_AT_END=0"
  398. ;;
  399. esac
  400. # Add objdump private vectors.
  401. case $targ in
  402. avr-*-*)
  403. od_vectors="$od_vectors objdump_private_desc_elf32_avr"
  404. ;;
  405. powerpc*-*-aix* | rs6000-*-aix*)
  406. od_vectors="$od_vectors objdump_private_desc_xcoff"
  407. ;;
  408. *-*-darwin*)
  409. od_vectors="$od_vectors objdump_private_desc_mach_o"
  410. ;;
  411. esac
  412. fi
  413. done
  414. # Uniq objdump private vector, build objdump target ofiles.
  415. od_files=
  416. f=""
  417. for i in $od_vectors ; do
  418. case " $f " in
  419. *" $i "*) ;;
  420. *)
  421. f="$f $i"
  422. OBJDUMP_PRIVATE_VECTORS="$OBJDUMP_PRIVATE_VECTORS &$i,"
  423. case $i in
  424. objdump_private_desc_elf32_avr)
  425. od_files="$od_files od-elf32_avr" ;;
  426. objdump_private_desc_xcoff)
  427. od_files="$od_files od-xcoff" ;;
  428. objdump_private_desc_mach_o)
  429. od_files="$od_files od-macho" ;;
  430. *) AC_MSG_ERROR(*** unknown private vector $i) ;;
  431. esac
  432. ;;
  433. esac
  434. done
  435. # Uniq objdump target ofiles
  436. f=""
  437. for i in $od_files ; do
  438. case " $f " in
  439. *" $i "*) ;;
  440. *)
  441. f="$f $i"
  442. OBJDUMP_PRIVATE_OFILES="$OBJDUMP_PRIVATE_OFILES $i.$objext"
  443. ;;
  444. esac
  445. done
  446. DLLTOOL_DEFS="$DLLTOOL_DEFS $DLLTOOL_DEFAULT"
  447. if test "${with_windres+set}" = set; then
  448. BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
  449. fi
  450. if test "${with_windmc+set}" = set; then
  451. BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
  452. fi
  453. OBJDUMP_DEFS="${OBJDUMP_DEFS} -DOBJDUMP_PRIVATE_VECTORS=\"${OBJDUMP_PRIVATE_VECTORS}\""
  454. AC_SUBST(BUILD_SRCONV)
  455. AC_SUBST(BUILD_DLLTOOL)
  456. AC_SUBST(DLLTOOL_DEFS)
  457. AC_SUBST(BUILD_WINDRES)
  458. AC_SUBST(BUILD_WINDMC)
  459. AC_SUBST(BUILD_DLLWRAP)
  460. AC_SUBST(BUILD_MISC)
  461. AC_SUBST(BUILD_INSTALL_MISC)
  462. AC_SUBST(OBJDUMP_DEFS)
  463. AC_SUBST(OBJDUMP_PRIVATE_OFILES)
  464. AC_DEFINE_UNQUOTED(TARGET, "${target}", [Configured target name.])
  465. targ=$target
  466. . $srcdir/../bfd/config.bfd
  467. if test "x$targ_underscore" = "xyes"; then
  468. UNDERSCORE=1
  469. else
  470. UNDERSCORE=0
  471. fi
  472. AC_DEFINE_UNQUOTED(TARGET_PREPENDS_UNDERSCORE, $UNDERSCORE,
  473. [Define to 1 if user symbol names have a leading underscore, 0 if not.])
  474. # Emulation
  475. targ=$target
  476. . ${srcdir}/configure.tgt
  477. EMULATION=$targ_emul
  478. EMULATION_VECTOR=$targ_emul_vector
  479. AC_SUBST(EMULATION)
  480. AC_SUBST(EMULATION_VECTOR)
  481. # Required for html and install-html
  482. AC_SUBST(datarootdir)
  483. AC_SUBST(docdir)
  484. AC_SUBST(htmldir)
  485. AC_SUBST(pdfdir)
  486. AC_CONFIG_FILES(Makefile po/Makefile.in:po/Make-in)
  487. AC_OUTPUT
  488. GNU_MAKE_JOBSERVER