libstdc++: Disabling AC_LIBTOOL_DLOPEN check if building with avr-libc
[gcc.git] / libstdc++-v3 / configure.ac
index 2e3a1a98f338361ed9a2934a5fe61e60d6852322..771814110a130941ad4b532670706a3ebf1799e8 100644 (file)
@@ -83,12 +83,14 @@ AC_PROG_CC
 AC_PROG_CXX
 CXXFLAGS="$save_CXXFLAGS"
 
+AC_SYS_LARGEFILE
+
 # Runs configure.host, and assorted other critical bits.  Sets
 # up critical shell variables.
 GLIBCXX_CONFIGURE
 
 # Libtool setup.
-if test "x${with_newlib}" != "xyes"; then
+if test "x${with_newlib}" != "xyes" && test "x${with_avrlibc}" != "xyes"; then
   AC_LIBTOOL_DLOPEN
 fi
 AM_PROG_LIBTOOL
@@ -220,6 +222,15 @@ GLIBCXX_ENABLE_LIBSTDCXX_TIME
 # Check for tmpnam which is obsolescent in POSIX.1-2008
 GLIBCXX_CHECK_TMPNAM
 
+# For pthread_cond_clockwait
+GLIBCXX_CHECK_PTHREAD_COND_CLOCKWAIT
+
+# For pthread_mutex_clocklock
+GLIBCXX_CHECK_PTHREAD_MUTEX_CLOCKLOCK
+
+# For pthread_rwlock_clockrdlock and pthread_rwlock_clockwrlock
+GLIBCXX_CHECK_PTHREAD_RWLOCK_CLOCKLOCK
+
 AC_LC_MESSAGES
 
 # For hardware_concurrency
@@ -245,6 +256,8 @@ AC_CHECK_HEADERS([linux/random.h], [], [],
 #endif
 ]])
 
+AC_CHECK_HEADERS([xlocale.h])
+
 # Only do link tests if native. Else, hardcode.
 if $GLIBCXX_IS_NATIVE; then
 
@@ -271,6 +284,9 @@ if $GLIBCXX_IS_NATIVE; then
   # For Networking TS.
   AC_CHECK_FUNCS(sockatmark)
 
+  # Non-standard functions used by C++17 std::from_chars
+  AC_CHECK_FUNCS(uselocale)
+
   # For iconv support.
   AM_ICONV
 
@@ -483,6 +499,10 @@ AM_CONDITIONAL(BUILD_MAN,
 AC_CHECK_PROG([DBLATEX], dblatex, yes, no)
 AC_CHECK_PROG([PDFLATEX], pdflatex, yes, no)
 AM_CONDITIONAL(BUILD_PDF,
+              test $ac_cv_prog_DOXYGEN = "yes" &&
+              test $ac_cv_prog_DOT = "yes" &&
+              test $ac_cv_prog_XSLTPROC = "yes" &&
+              test $ac_cv_prog_XMLLINT = "yes" &&
               test $ac_cv_prog_DBLATEX = "yes" &&
               test $ac_cv_prog_PDFLATEX = "yes")
 
@@ -513,6 +533,17 @@ AC_SUBST(ERROR_CONSTANTS_SRCDIR)
 AC_SUBST(CPU_OPT_EXT_RANDOM)
 AC_SUBST(CPU_OPT_BITS_RANDOM)
 
+# Conditionalize the makefile for this target machine.
+tmake_file_=
+for f in ${tmake_file}
+do
+       if test -f ${srcdir}/config/$f
+       then
+               tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
+       fi
+done
+tmake_file="${tmake_file_}"
+AC_SUBST(tmake_file)
 
 # Add CET specific flags if Intel CET is enabled.
 GCC_CET_FLAGS(CET_FLAGS)