about summary refs log tree commit diff
path: root/configure
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
parent78a7eee7fab0802addf500c481335ed6e9899bda (diff)
downloadglibc-62bede1313c3a1fa477a092006d64436de6821b1.tar.gz
glibc-62bede1313c3a1fa477a092006d64436de6821b1.tar.xz
glibc-62bede1313c3a1fa477a092006d64436de6821b1.zip
Distinguish configure check for .ctors/.dtors header/trailers.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure18
1 files changed, 17 insertions, 1 deletions
diff --git a/configure b/configure
index 1db57ae38c..7814072a81 100755
--- a/configure
+++ b/configure
@@ -6111,12 +6111,28 @@ fi
 $as_echo "$libc_cv_initfini_array" >&6; }
   if test $libc_cv_initfini_array != yes; then
     as_fn_error $? "Need linker with .init_array/.fini_array support." "$LINENO" 5
-  elif { ac_try='${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&5'
+  fi
+
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use .ctors/.dtors header and trailer" >&5
+$as_echo_n "checking whether to use .ctors/.dtors header and trailer... " >&6; }
+if ${libc_cv_ctors_header+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+    if { ac_try='${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&5'
   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
   (eval $ac_try) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; }; }; then
+    libc_cv_ctors_header=no
+  else
+    libc_cv_ctors_header=yes
+  fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_ctors_header" >&5
+$as_echo "$libc_cv_ctors_header" >&6; }
+
+  if test $libc_cv_ctors_header = no; then
     $as_echo "#define NO_CTORS_DTORS_SECTIONS 1" >>confdefs.h
 
   fi