***/
@TOP@
-/** define if your system needs pthread_init() before using pthreads */
-#undef NEED_PTHREAD_INIT
-
/** define if your system has sigwait() */
#undef HAVE_SIGWAIT
*** it does not get installed.
***/
-/** define if your system needs pthread_init() before using pthreads */
-#undef NEED_PTHREAD_INIT
-
/** define if your system has sigwait() */
#undef HAVE_SIGWAIT
/* Define if Thread-Local Storage is available */
#undef HAVE_TLS
+/* Define to 1 if you have the `tzset' function. */
+#undef HAVE_TZSET
+
/* Define to 1 if you have the <uchar.h> header file. */
#undef HAVE_UCHAR_H
/* Define to 1 if the system has the type `uintptr_t'. */
#undef HAVE_UINTPTR_T
+/* define if uname is available */
+#undef HAVE_UNAME
+
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* define on DEC OSF to enable 4.4BSD style sa_len support */
/* #undef _SOCKADDR_LEN */
-/* define if your system needs pthread_init() before using pthreads */
-/* #undef NEED_PTHREAD_INIT */
-
/* define if your system has sigwait() */
/* #undef HAVE_SIGWAIT */
$as_echo_n "checking for uname... " >&6; }
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-
#include <sys/utsname.h>
-#include <stdio.h>
+ #include <stdio.h>
int
main ()
{
-struct utsname uts;
-uname(&uts);
-printf("running on %s %s %s for %s\n",
- uts.sysname, uts.release, uts.version, uts.machine);
+ struct utsname uts;
+ uname(&uts);
+ printf("running on %s %s %s for %s\n",
+ uts.sysname, uts.release, uts.version, uts.machine);
;
return 0;
if ac_fn_c_try_compile "$LINENO"; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
- $as_echo "#define HAVE_UNAME 1" >>confdefs.h
+
+$as_echo "#define HAVE_UNAME 1" >>confdefs.h
+
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: uname is not correctly supported" >&5
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: uname is not correctly supported" >&5
$as_echo "$as_me: WARNING: uname is not correctly supported" >&2;}
+
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
#
# Time Zone Stuff
#
-ac_fn_c_check_func "$LINENO" "tzset" "ac_cv_func_tzset"
+for ac_func in tzset
+do :
+ ac_fn_c_check_func "$LINENO" "tzset" "ac_cv_func_tzset"
if test "x$ac_cv_func_tzset" = xyes; then :
- $as_echo "#define HAVE_TZSET 1" >>confdefs.h
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_TZSET 1
+_ACEOF
fi
+done
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for optarg declaration" >&5
#
# check for uname library routine
#
-AC_MSG_CHECKING(for uname)
-AC_TRY_COMPILE([
-#include <sys/utsname.h>
-#include <stdio.h>
-],
-[
-struct utsname uts;
-uname(&uts);
-printf("running on %s %s %s for %s\n",
- uts.sysname, uts.release, uts.version, uts.machine);
-],
- [AC_MSG_RESULT(yes)
- AC_DEFINE(HAVE_UNAME)],
- [AC_MSG_RESULT(no)
- AC_MSG_WARN([uname is not correctly supported])])
+AC_MSG_CHECKING([for uname])
+AC_COMPILE_IFELSE(
+ [AC_LANG_PROGRAM(
+ [[#include <sys/utsname.h>
+ #include <stdio.h>
+ ]],
+ [[
+ struct utsname uts;
+ uname(&uts);
+ printf("running on %s %s %s for %s\n",
+ uts.sysname, uts.release, uts.version, uts.machine);
+ ]])],
+ [AC_MSG_RESULT(yes)
+ AC_DEFINE([HAVE_UNAME], [1], [define if uname is available])
+ ],
+ [AC_MSG_RESULT(no)
+ AC_MSG_WARN([uname is not correctly supported])
+ ])
#
# check for GCC noreturn attribute
#
# Time Zone Stuff
#
-AC_CHECK_FUNC(tzset, AC_DEFINE(HAVE_TZSET))
+AC_CHECK_FUNCS([tzset])
AC_MSG_CHECKING(for optarg declaration)
AC_TRY_COMPILE([
* Start an ISC library application.
*/
-#ifdef NEED_PTHREAD_INIT
- /*
- * BSDI 3.1 seg faults in pthread_sigmask() if we don't do this.
- */
- presult = pthread_init();
- if (presult != 0) {
- strerror_r(presult, strbuf, sizeof(strbuf));
- UNEXPECTED_ERROR(__FILE__, __LINE__,
- "isc_app_start() pthread_init: %s", strbuf);
- return (ISC_R_UNEXPECTED);
- }
-#endif
-
#ifdef HAVE_LINUXTHREADS
main_thread = pthread_self();
#endif /* HAVE_LINUXTHREADS */