aboutsummaryrefslogtreecommitdiff
path: root/gold/configure.ac
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>2009-06-23 14:37:24 +0000
committerIan Lance Taylor <ian@airs.com>2009-06-23 14:37:24 +0000
commit0639a6f66272d7fdc956bd64e2cbf6acfd10a03d (patch)
tree4d0e7af53fb11ad1c9c42ae364640ac0ecd21908 /gold/configure.ac
parent999fa59e92178fb78942db555a1c46047738c94b (diff)
downloadfsf-binutils-gdb-0639a6f66272d7fdc956bd64e2cbf6acfd10a03d.zip
fsf-binutils-gdb-0639a6f66272d7fdc956bd64e2cbf6acfd10a03d.tar.gz
fsf-binutils-gdb-0639a6f66272d7fdc956bd64e2cbf6acfd10a03d.tar.bz2
* configure.ac: Call AC_CHECK_DECLS using C, not C++.
* configure: Rebuild.
Diffstat (limited to 'gold/configure.ac')
-rw-r--r--gold/configure.ac7
1 files changed, 6 insertions, 1 deletions
diff --git a/gold/configure.ac b/gold/configure.ac
index c249ae4..6415271 100644
--- a/gold/configure.ac
+++ b/gold/configure.ac
@@ -321,13 +321,18 @@ AC_REPLACE_FUNCS(pread ftruncate mremap ffsll)
AC_SEARCH_LIBS(zlibVersion, z, [AC_CHECK_HEADERS(zlib.h)])
AM_CONDITIONAL(HAVE_ZLIB, test "$ac_cv_search_zlibVersion" != "no")
+dnl We have to check these in C, not C++, because autoconf generates
+dnl tests which have no type information, and current glibc provides
+dnl multiple declarations of functions like basename when compiling
+dnl with C++.
+AC_CHECK_DECLS([basename, ffs, asprintf, vasprintf, snprintf, vsnprintf, strverscmp])
+
AC_LANG_PUSH(C++)
AC_CHECK_HEADERS(tr1/unordered_set tr1/unordered_map)
AC_CHECK_HEADERS(ext/hash_map ext/hash_set)
AC_CHECK_HEADERS(byteswap.h)
AC_CHECK_FUNCS(mallinfo posix_fallocate)
-AC_CHECK_DECLS([basename, ffs, asprintf, vasprintf, snprintf, vsnprintf, strverscmp])
# Use of ::std::tr1::unordered_map::rehash causes undefined symbols
# at link time with some versions of GCC.