]> git.saurik.com Git - wxWidgets.git/blobdiff - build/aclocal/ac_raf_func_which_getservbyname_r.m4
fixed wxXmlResource::Load's detection of filenames to be done as early as possible
[wxWidgets.git] / build / aclocal / ac_raf_func_which_getservbyname_r.m4
index 7ba304ae38b0f169057f0cc58d78709007e5968e..d14fb20d30b94b772518c84c4a601d920a9f7156 100644 (file)
@@ -23,6 +23,9 @@ AC_DEFUN([AC_raf_FUNC_WHICH_GETSERVBYNAME_R],
 AC_CACHE_CHECK(how many arguments getservbyname_r() takes,
     ac_cv_func_which_getservbyname_r,
     [
 AC_CACHE_CHECK(how many arguments getservbyname_r() takes,
     ac_cv_func_which_getservbyname_r,
     [
+        dnl we need to use C++ to detect missing prototypes
+        AC_LANG_PUSH(C++)
+
         AC_TRY_COMPILE([#include <netdb.h>],
             [
                 char *name;
         AC_TRY_COMPILE([#include <netdb.h>],
             [
                 char *name;
@@ -60,6 +63,7 @@ AC_CACHE_CHECK(how many arguments getservbyname_r() takes,
                 )
             ]
         )
                 )
             ]
         )
+        AC_LANG_POP()
     ]
 )
 
     ]
 )