diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure index 138b99f42c4..13d52eb0c0e 100755 --- a/libstdc++-v3/configure +++ b/libstdc++-v3/configure @@ -76660,20 +76660,20 @@ fi done -ac_fn_c_check_decl "$LINENO" "F_GETFL" "ac_cv_have_decl_F_GETFL" "fcntl.h +ac_fn_c_check_decl "$LINENO" "F_GETFL" "ac_cv_have_decl_F_GETFL" "#include " if test "x$ac_cv_have_decl_F_GETFL" = xyes; then : fi -ac_fn_c_check_decl "$LINENO" "F_SETFL" "ac_cv_have_decl_F_SETFL" "fcntl.h +ac_fn_c_check_decl "$LINENO" "F_SETFL" "ac_cv_have_decl_F_SETFL" "#include " if test "x$ac_cv_have_decl_F_SETFL" = xyes; then : fi -if "$ac_cv_have_decl_F_GETFL$ac_cv_have_decl_F_SETFL" = 11 ; then - ac_fn_c_check_decl "$LINENO" "O_NONBLOCK" "ac_cv_have_decl_O_NONBLOCK" "fcntl.h +if test "$ac_cv_have_decl_F_GETFL$ac_cv_have_decl_F_SETFL" = yesyes ; then + ac_fn_c_check_decl "$LINENO" "O_NONBLOCK" "ac_cv_have_decl_O_NONBLOCK" "#include " if test "x$ac_cv_have_decl_O_NONBLOCK" = xyes; then : diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac index d29efa6cb5f..2d68b3672b9 100644 --- a/libstdc++-v3/configure.ac +++ b/libstdc++-v3/configure.ac @@ -481,10 +481,10 @@ GLIBCXX_CHECK_FILESYSTEM_DEPS # For Networking TS. AC_CHECK_HEADERS([fcntl.h sys/ioctl.h sys/socket.h sys/uio.h poll.h netdb.h arpa/inet.h netinet/in.h netinet/tcp.h]) -AC_CHECK_DECL(F_GETFL,[],[],[fcntl.h]) -AC_CHECK_DECL(F_SETFL,[],[],[fcntl.h]) -if [ "$ac_cv_have_decl_F_GETFL$ac_cv_have_decl_F_SETFL" = 11 ]; then - AC_CHECK_DECL(O_NONBLOCK,[],[],[fcntl.h]) +AC_CHECK_DECL(F_GETFL,,,[#include ]) +AC_CHECK_DECL(F_SETFL,,,[#include ]) +if test "$ac_cv_have_decl_F_GETFL$ac_cv_have_decl_F_SETFL" = yesyes ; then + AC_CHECK_DECL(O_NONBLOCK,,,[#include ]) fi # For Transactional Memory TS