diff --git a/libstdc++-v3/config.h.in b/libstdc++-v3/config.h.in index 486ba450749..91e920044ee 100644 --- a/libstdc++-v3/config.h.in +++ b/libstdc++-v3/config.h.in @@ -302,6 +302,9 @@ /* Define if openat is available in . */ #undef HAVE_OPENAT +/* Define if O_NONBLOCK is defined in */ +#undef HAVE_O_NONBLOCK + /* Define if poll is available in . */ #undef HAVE_POLL diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure index 305675eaa1e..005c4a29fd0 100755 --- a/libstdc++-v3/configure +++ b/libstdc++-v3/configure @@ -54132,6 +54132,8 @@ if test "$ac_cv_have_decl_F_GETFL$ac_cv_have_decl_F_SETFL" = yesyes ; then " if test "x$ac_cv_have_decl_O_NONBLOCK" = xyes; then : +$as_echo "#define HAVE_O_NONBLOCK 1" >>confdefs.h + fi fi diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac index 4049f54bd5a..a3b257fe652 100644 --- a/libstdc++-v3/configure.ac +++ b/libstdc++-v3/configure.ac @@ -554,7 +554,10 @@ AC_CHECK_HEADERS([fcntl.h sys/ioctl.h sys/socket.h sys/uio.h poll.h netdb.h arpa 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 ]) + AC_CHECK_DECL(O_NONBLOCK, + AC_DEFINE(HAVE_O_NONBLOCK,1,[Define if O_NONBLOCK is defined in ]), + [], + [#include ]) fi # For Transactional Memory TS