From 242be5577142d181d2c90b727281a32d36f7b72b Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Wed, 24 Mar 2004 08:45:58 +0000 Subject: added check for strerror_r() --- acinclude.m4 | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) (limited to 'acinclude.m4') diff --git a/acinclude.m4 b/acinclude.m4 index 5acec28d2..b5865fc12 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -279,7 +279,7 @@ fi AC_DEFUN([CURL_CHECK_LOCALTIME_R], [ - dnl check for a few thread-safe functions + dnl check for localtime_r AC_CHECK_FUNCS(localtime_r,[ AC_MSG_CHECKING(whether localtime_r is declared) AC_EGREP_CPP(localtime_r,[ @@ -295,6 +295,24 @@ AC_DEFUN([CURL_CHECK_LOCALTIME_R], AC_MSG_RESULT(no))])]) ]) +AC_DEFUN([CURL_CHECK_STRERROR_R], +[ + dnl determine of strerror_r is present + AC_CHECK_FUNCS(strerror_r,[ + AC_MSG_CHECKING(whether strerror_r is declared) + AC_EGREP_CPP(strerror_r,[ +#include ],[ + AC_MSG_RESULT(yes)],[ + AC_MSG_RESULT(no) + AC_MSG_CHECKING(whether strerror_r with -D_REENTRANT is declared) + AC_EGREP_CPP(strerror_r,[ +#define _REENTRANT +#include ],[ + AC_DEFINE(NEED_REENTRANT) + AC_MSG_RESULT(yes)], + AC_MSG_RESULT(no))])]) +]) + AC_DEFUN([CURL_CHECK_INET_NTOA_R], [ dnl determine if function definition for inet_ntoa_r exists. -- cgit v1.2.3