summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorRoland McGrath <roland@hack.frob.com>2011-06-27 20:39:05 -0700
committerRoland McGrath <roland@hack.frob.com>2011-06-27 20:39:05 -0700
commit62bede1313c3a1fa477a092006d64436de6821b1 (patch)
tree5ff88fe2b97e263a987a13190cfbce5aa48f11e9 /configure.in
parent78a7eee7fab0802addf500c481335ed6e9899bda (diff)
Distinguish configure check for .ctors/.dtors header/trailers.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in12
1 files changed, 11 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index d3f5210316..fc2a193321 100644
--- a/configure.in
+++ b/configure.in
@@ -1479,7 +1479,17 @@ EOF
rm -f conftest*])
if test $libc_cv_initfini_array != yes; then
AC_MSG_ERROR([Need linker with .init_array/.fini_array support.])
- elif AC_TRY_COMMAND([${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&AS_MESSAGE_LOG_FD]); then
+ fi
+
+ AC_CACHE_CHECK(whether to use .ctors/.dtors header and trailer,
+ libc_cv_ctors_header, [dnl
+ if AC_TRY_COMMAND([${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&AS_MESSAGE_LOG_FD]); then
+ libc_cv_ctors_header=no
+ else
+ libc_cv_ctors_header=yes
+ fi])
+
+ if test $libc_cv_ctors_header = no; then
AC_DEFINE(NO_CTORS_DTORS_SECTIONS)
fi