Avoid assertion in processes with VM in bad shape
[platform/upstream/glibc.git] / configure
index 55a4b30..55cb008 100755 (executable)
--- a/configure
+++ b/configure
@@ -3,7 +3,7 @@
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.68 for GNU C Library (see version.h).
 #
-# Report bugs to <glibc>.
+# Report bugs to <http://sourceware.org/bugzilla/>.
 #
 #
 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -239,8 +239,9 @@ fi
     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
   else
-    $as_echo "$0: Please tell bug-autoconf@gnu.org and glibc about your
-$0: system, including any error possibly output before this
+    $as_echo "$0: Please tell bug-autoconf@gnu.org and
+$0: http://sourceware.org/bugzilla/ about your system,
+$0: including any error possibly output before this
 $0: message. Then install a modern shell, or manually run
 $0: the script under such a shell if you do have one."
   fi
@@ -559,11 +560,11 @@ MAKEFLAGS=
 
 # Identity of this package.
 PACKAGE_NAME='GNU C Library'
-PACKAGE_TARNAME='c-library'
+PACKAGE_TARNAME='glibc'
 PACKAGE_VERSION='(see version.h)'
 PACKAGE_STRING='GNU C Library (see version.h)'
-PACKAGE_BUGREPORT='glibc'
-PACKAGE_URL='http://www.gnu.org/software/c-library/'
+PACKAGE_BUGREPORT='http://sourceware.org/bugzilla/'
+PACKAGE_URL='http://www.gnu.org/software/glibc/'
 
 ac_unique_file="include/features.h"
 enable_option_checking=no
@@ -622,6 +623,7 @@ elf
 ldd_rewrite_script
 use_ldconfig
 libc_cv_as_i686
+libc_cv_cc_fma4
 libc_cv_cc_novzeroupper
 libc_cv_cc_avx
 libc_cv_cc_sse4
@@ -642,7 +644,6 @@ have_libaudit
 LIBGD
 libc_cv_cc_submachine
 exceptions
-no_whole_archive
 libc_cv_have_initfini
 gnu89_inline
 libc_cv_ssp
@@ -700,7 +701,6 @@ bindnow
 oldest_abi
 enable_check_abi
 use_default_link
-with_cvs
 with_fp
 ac_ct_CXX
 CXXFLAGS
@@ -772,7 +772,6 @@ with_binutils
 with_elf
 with_selinux
 with_xcoff
-with_cvs
 with_headers
 with_default_link
 enable_sanity_checks
@@ -785,8 +784,6 @@ enable_versioning
 enable_oldest_abi
 enable_stackguard_randomization
 enable_add_ons
-with_tls
-with___thread
 enable_hidden_plt
 enable_bind_now
 enable_static_nss
@@ -1400,7 +1397,7 @@ Fine tuning of the installation directories:
   --infodir=DIR           info documentation [DATAROOTDIR/info]
   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
   --mandir=DIR            man documentation [DATAROOTDIR/man]
-  --docdir=DIR            documentation root [DATAROOTDIR/doc/c-library]
+  --docdir=DIR            documentation root [DATAROOTDIR/doc/glibc]
   --htmldir=DIR           html documentation [DOCDIR]
   --dvidir=DIR            dvi documentation [DOCDIR]
   --pdfdir=DIR            pdf documentation [DOCDIR]
@@ -1466,12 +1463,9 @@ Optional Packages:
   --with-elf              if using the ELF object format
   --with-selinux          if building with SELinux support
   --with-xcoff            if using the XCOFF object format
-  --without-cvs           if CVS should not be used
   --with-headers=PATH     location of system headers to use (for example
                           /usr/src/linux/include) [default=compiler default]
-  --with-default-link     do not use explicit linker scripts [default=no]
-  --with-tls              enable support for TLS
-  --without-__thread      do not use TLS features even when supporting them
+  --with-default-link     do not use explicit linker scripts
   --with-cpu=CPU          select code for CPU variant
 
 Some influential environment variables:
@@ -1489,8 +1483,8 @@ Some influential environment variables:
 Use these variables to override the choices made by `configure' or to help
 it to find libraries and programs with nonstandard names/locations.
 
-Report bugs to <glibc>.
-GNU C Library home page: <http://www.gnu.org/software/c-library/>.
+Report bugs to <http://sourceware.org/bugzilla/>.
+GNU C Library home page: <http://www.gnu.org/software/glibc/>.
 General help using GNU software: <http://www.gnu.org/gethelp/>.
 _ACEOF
 ac_status=$?
@@ -3563,21 +3557,6 @@ else
 fi
 
 
-# Check whether --with-cvs was given.
-if test "${with_cvs+set}" = set; then :
-  withval=$with_cvs; with_cvs=$withval
-else
-  with_cvs=yes
-fi
-
-if test "$with_cvs" = yes; then
-  if test -d $srcdir/CVS && grep :pserver: $srcdir/CVS/Root > /dev/null
-  then
-    with_cvs=no
-  fi
-fi
-
-
 
 # Check whether --with-headers was given.
 if test "${with_headers+set}" = set; then :
@@ -3593,7 +3572,7 @@ fi
 if test "${with_default_link+set}" = set; then :
   withval=$with_default_link; use_default_link=$withval
 else
-  use_default_link=no
+  use_default_link=default
 fi
 
 
@@ -3688,24 +3667,6 @@ else
 fi
 
 
-
-# Check whether --with-tls was given.
-if test "${with_tls+set}" = set; then :
-  withval=$with_tls; usetls=$withval
-else
-  usetls=yes
-fi
-
-
-
-# Check whether --with-__thread was given.
-if test "${with___thread+set}" = set; then :
-  withval=$with___thread; use__thread=$withval
-else
-  use__thread=yes
-fi
-
-
 # Check whether --enable-hidden-plt was given.
 if test "${enable_hidden_plt+set}" = set; then :
   enableval=$enable_hidden_plt; hidden=$enableval
@@ -5383,8 +5344,7 @@ $as_echo "$libc_cv_autoconf_works" >&6; }
   test $libc_cv_autoconf_works = yes || AUTOCONF=no
   ;;
 esac
-if test "x$with_cvs" = xyes && test "x$AUTOCONF" = xno; then
-  # If --without-cvs they probably won't change configure.in, so no complaints.
+if test "x$AUTOCONF" = xno; then
   aux_missing="$aux_missing autoconf"
 fi
 
@@ -5413,11 +5373,16 @@ if test -n "$sysheaders"; then
   SYSINCLUDES="$SYSINCLUDES \
 -isystem `echo $sysheaders | sed 's/:/ -isystem /g'`"
   if test -n "$CXX"; then
+    CXX_SYSINCLUDES=
     cxxversion=`$CXX -dumpversion 2>&5` &&
     cxxmachine=`$CXX -dumpmachine 2>&5` &&
-    cxxheaders=`$CXX -print-file-name=../../../../include/c++/`"$cxxversion" &&
-    CXX_SYSINCLUDES="-isystem $cxxheaders \
+    for d in include "$cxxmachine/include"; do
+      i=../../../../$d/c++/$cxxversion
+      cxxheaders=`$CXX -print-file-name="$i"` &&
+      test "x$cxxheaders" != x && test "x$i" != "x$cxxheaders" &&
+      CXX_SYSINCLUDES="$CXX_SYSINCLUDES -isystem $cxxheaders \
 -isystem $cxxheaders/$cxxmachine -isystem $cxxheaders/backward"
+    done
   fi
 fi
 
@@ -6235,13 +6200,13 @@ __attribute__ ((destructor))  void dtor (void) { puts("dtor"); }
 _ACEOF
 if ac_fn_c_try_link "$LINENO"; then :
         if $READELF -WS conftest$ac_exeext | $AWK '
-        { gsub(/\[ */, "[") }
+       { gsub(/\[ */, "[") }
        $2 == ".ctors" || $2 == ".dtors" {
          size = strtonum("0x" $6)
          align = strtonum("0x" $NF)
          seen[$2] = 1
          stub[$2] = size == align * 2
-        }
+       }
        END {
          ctors_ok = !seen[".ctors"] || stub[".ctors"]
          dtors_ok = !seen[".dtors"] || stub[".dtors"]
@@ -6702,6 +6667,69 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_hashstyle" >&5
 $as_echo "$libc_cv_hashstyle" >&6; }
 
+
+  # The linker's default -shared behavior is good enough if it
+  # does these things that our custom linker scripts ensure that
+  # all allocated NOTE sections come first.
+  if test "$use_default_link" = default; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sufficient default -shared layout" >&5
+$as_echo_n "checking for sufficient default -shared layout... " >&6; }
+if ${libc_cv_use_default_link+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+      libc_cv_use_default_link=no
+    cat > conftest.s <<\EOF
+         .section .note.a,"a",%note
+         .balign 4
+         .long 4,4,9
+         .string "GNU"
+         .string "foo"
+         .section .note.b,"a",%note
+         .balign 4
+         .long 4,4,9
+         .string "GNU"
+         .string "bar"
+EOF
+    if { ac_try='  ${CC-cc} $ASFLAGS -shared -o conftest.so conftest.s 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; }; } &&
+       ac_try=`$READELF -S conftest.so | sed -n \
+        '${x;p;}
+         s/^ *\[ *[1-9][0-9]*\]  *\([^ ][^ ]*\)  *\([^ ][^ ]*\) .*$/\2 \1/
+         t a
+         b
+         : a
+         H'`
+    then
+      libc_seen_a=no libc_seen_b=no
+      set -- $ac_try
+      while test $# -ge 2 -a "$1" = NOTE; do
+       case "$2" in
+       .note.a) libc_seen_a=yes ;;
+       .note.b) libc_seen_b=yes ;;
+       esac
+       shift 2
+      done
+      case "$libc_seen_a$libc_seen_b" in
+      yesyes)
+       libc_cv_use_default_link=yes
+       ;;
+      *)
+       echo >&5 "\
+$libc_seen_a$libc_seen_b from:
+$ac_try"
+       ;;
+      esac
+    fi
+    rm -f conftest*
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_use_default_link" >&5
+$as_echo "$libc_cv_use_default_link" >&6; }
+    use_default_link=$libc_cv_use_default_link
+  fi
 fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker output format" >&5
@@ -7087,8 +7115,8 @@ rm -f conftest*
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_ld_no_whole_archive" >&5
 $as_echo "$libc_cv_ld_no_whole_archive" >&6; }
-if test $libc_cv_ld_no_whole_archive = yes; then
-  no_whole_archive=-Wl,--no-whole-archive
+if test $libc_cv_ld_no_whole_archive = no; then
+  as_fn_error $? "support for --no-whole-archive is needed" "$LINENO" 5
 fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc -fexceptions" >&5
@@ -7183,9 +7211,8 @@ rm -f conftest*
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_gcc_builtin_expect" >&5
 $as_echo "$libc_cv_gcc_builtin_expect" >&6; }
-if test "$libc_cv_gcc_builtin_expect" = yes; then
-  $as_echo "#define HAVE_BUILTIN_EXPECT 1" >>confdefs.h
-
+if test "$libc_cv_gcc_builtin_expect" = no; then
+  as_fn_error $? "support for __builtin_expect needed" "$LINENO" 5
 fi
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_memset" >&5
@@ -7246,13 +7273,11 @@ rm -f conftest*
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_gcc_builtin_redirection" >&5
 $as_echo "$libc_cv_gcc_builtin_redirection" >&6; }
-if test "$libc_cv_gcc_builtin_redirection" = yes ; then
-  $as_echo "#define HAVE_BUILTIN_REDIRECTION 1" >>confdefs.h
-
+if test "$libc_cv_gcc_builtin_redirection" = no; then
+  as_fn_error $? "support for the symbol redirection needed" "$LINENO" 5
 fi
 
-if test "x$use__thread" != xno; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __thread" >&5
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __thread" >&5
 $as_echo_n "checking for __thread... " >&6; }
 if ${libc_cv_gcc___thread+:} false; then :
   $as_echo_n "(cached) " >&6
@@ -7260,55 +7285,48 @@ else
   cat > conftest.c <<\EOF
 __thread int a = 42;
 EOF
-  if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -c conftest.c >&5'
+if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -c conftest.c >&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_gcc___thread=yes
-  else
-    libc_cv_gcc___thread=no
-  fi
-  rm -f conftest*
+  libc_cv_gcc___thread=yes
+else
+  libc_cv_gcc___thread=no
+fi
+rm -f conftest*
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_gcc___thread" >&5
 $as_echo "$libc_cv_gcc___thread" >&6; }
-  if test "$libc_cv_gcc___thread" = yes; then
-    $as_echo "#define HAVE___THREAD 1" >>confdefs.h
-
-  fi
-else
-  libc_cv_gcc___thread=no
+if test "$libc_cv_gcc___thread" = no; then
+  as_fn_error $? "support for the __thread keyword is required" "$LINENO" 5
 fi
 
-if test "$libc_cv_gcc___thread" = yes; then
-    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tls_model attribute" >&5
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tls_model attribute" >&5
 $as_echo_n "checking for tls_model attribute... " >&6; }
 if ${libc_cv_gcc_tls_model_attr+:} false; then :
   $as_echo_n "(cached) " >&6
 else
-    cat > conftest.c <<\EOF
+  cat > conftest.c <<\EOF
 extern __thread int a __attribute__((tls_model ("initial-exec")));
 EOF
-  if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -S -Werror conftest.c >&5'
+if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -S -Werror conftest.c >&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_gcc_tls_model_attr=yes
-  else
-    libc_cv_gcc_tls_model_attr=no
-  fi
-  rm -f conftest*
+  libc_cv_gcc_tls_model_attr=yes
+else
+  libc_cv_gcc_tls_model_attr=no
+fi
+rm -f conftest*
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_gcc_tls_model_attr" >&5
 $as_echo "$libc_cv_gcc_tls_model_attr" >&6; }
-  if test "$libc_cv_gcc_tls_model_attr" = yes; then
-    $as_echo "#define HAVE_TLS_MODEL_ATTRIBUTE 1" >>confdefs.h
-
-  fi
+if test "$libc_cv_gcc_tls_model_attr" = no; then
+  as_fn_error $? "support for the tls_model attribute is required" "$LINENO" 5
 fi
 
 if test -n "$submachine"; then
@@ -7891,9 +7909,6 @@ if test x$libc_cv_gcc_unwind_find_fde = xyes; then
 fi
 
 
-$as_echo "#define USE_IN_LIBIO 1" >>confdefs.h
-
-
 # Test for old glibc 2.0.x headers so that they can be removed properly
 # Search only in includedir.
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for old glibc 2.0.x headers" >&5
@@ -7930,6 +7945,7 @@ fi
 
 
 
+
 if test $elf = yes; then
   $as_echo "#define HAVE_ELF 1" >>confdefs.h
 
@@ -8568,8 +8584,8 @@ $config_headers
 Configuration commands:
 $config_commands
 
-Report bugs to <glibc>.
-GNU C Library home page: <http://www.gnu.org/software/c-library/>.
+Report bugs to <http://sourceware.org/bugzilla/>.
+GNU C Library home page: <http://www.gnu.org/software/glibc/>.
 General help using GNU software: <http://www.gnu.org/gethelp/>."
 
 _ACEOF