* MAINTAINERS: Very belatedly remove myself from from the list of people caught
[deliverable/binutils-gdb.git] / binutils / configure.in
index 767d237f9ba52f4fae604b6ed94fd865db4996c4..990b0605c9bade72c2cf288bed1efe3bf5b3368d 100644 (file)
@@ -1,6 +1,6 @@
 dnl Process this file with autoconf to produce a configure script.
 dnl
-AC_PREREQ(2.13)
+AC_PREREQ(2.57)
 AC_INIT(ar.c)
 
 AC_CANONICAL_SYSTEM
@@ -29,43 +29,8 @@ AC_ARG_ENABLE(commonbfdlib,
   *)   AC_MSG_ERROR([bad value ${enableval} for BFD commonbfdlib option]) ;;
 esac])dnl
 
-build_warnings="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-AC_ARG_ENABLE(werror,
-  [  --enable-werror    treat compile warnings as errors],
-  [case "${enableval}" in
-     yes | y) ERROR_ON_WARNING="yes" ;;
-     no | n)  ERROR_ON_WARNING="no" ;;
-     *) AC_MSG_ERROR(bad value ${enableval} for --enable-werror) ;;
-   esac])
-
-# Enable -Werror by default, suppressing it only for --disable-werror
-# or --disable-build-warnings.
-if test "${ERROR_ON_WARNING}" != no
-then
-  build_warnings="$build_warnings -Werror"
-fi
-
-AC_ARG_ENABLE(build-warnings,
-[  --enable-build-warnings Enable build-time compiler warnings if gcc is used],
-[case "${enableval}" in
-  yes) ;;
-  no)  build_warnings="-w";;
-  ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
-        build_warnings="${build_warnings} ${t}";;
-  *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
-        build_warnings="${t} ${build_warnings}";;
-  *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
-  echo "Setting warning flags = $build_warnings" 6>&1
-fi])dnl
-WARN_CFLAGS=""
-if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then
-    WARN_CFLAGS="${build_warnings}"
-fi
-AC_SUBST(WARN_CFLAGS)
-
+AM_BINUTILS_WARNINGS
+                  
 AM_CONFIG_HEADER(config.h:config.in)
 
 if test -z "$target" ; then
@@ -76,11 +41,12 @@ if test -z "$host" ; then
 fi
 
 AC_PROG_CC
+AC_GNU_SOURCE
 
 AC_PROG_YACC
 AM_PROG_LEX
 
-ALL_LINGUAS="fr tr ja es sv da zh_CN ru ro"
+ALL_LINGUAS="fr tr ja es sv da zh_CN ru ro rw zh_TW fi"
 CY_GNU_GETTEXT
 
 AM_MAINTAINER_MODE
@@ -180,6 +146,16 @@ if test $bu_cv_decl_time_t_types_h = yes; then
            [Is the type time_t defined in <sys/types.h>?])
 fi
 
+AC_MSG_CHECKING(for a known getopt prototype in unistd.h)
+AC_CACHE_VAL(bu_cv_decl_getopt_unistd_h,
+[AC_TRY_COMPILE([#include <unistd.h>], [extern int getopt (int, char *const*, const char *);],
+bu_cv_decl_getopt_unistd_h=yes, bu_cv_decl_getopt_unistd_h=no)])
+AC_MSG_RESULT($bu_cv_decl_getopt_unistd_h)
+if test $bu_cv_decl_getopt_unistd_h = yes; then
+  AC_DEFINE([HAVE_DECL_GETOPT], 1,
+           [Is the prototype for getopt in <unistd.h> in the expected format?])
+fi
+
 # Under Next 3.2 <utime.h> apparently does not define struct utimbuf
 # by default.
 AC_MSG_CHECKING([for utime.h])
@@ -196,11 +172,7 @@ if test $bu_cv_header_utime_h = yes; then
   AC_DEFINE(HAVE_GOOD_UTIME_H, 1, [Does <utime.h> define struct utimbuf?])
 fi
 
-BFD_NEED_DECLARATION(fprintf)
-BFD_NEED_DECLARATION(strstr)
-BFD_NEED_DECLARATION(sbrk)
-BFD_NEED_DECLARATION(getenv)
-BFD_NEED_DECLARATION(environ)
+AC_CHECK_DECLS([fprintf, stpcpy, strstr, sbrk, getenv, environ, getc_unlocked])
 
 BFD_BINARY_FOPEN
 
@@ -278,9 +250,6 @@ changequote([,])dnl
          DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
          BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
          ;;
-       arm*-* | xscale-* | strongarm-* | d10v-*)
-         OBJDUMP_DEFS="-DDISASSEMBLER_NEEDS_RELOCS"
-         ;;
 changequote(,)dnl
        i[3-7]86-*-pe* | i[3-7]86-*-cygwin* | i[3-7]86-*-mingw32** | i[3-7]86-*-netbsdpe*)
 changequote([,])dnl
This page took 0.043388 seconds and 4 git commands to generate.