]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
- Update generated configure, with autoconf.
authorW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Fri, 17 Apr 2026 15:00:09 +0000 (17:00 +0200)
committerW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Fri, 17 Apr 2026 15:00:09 +0000 (17:00 +0200)
config.h.in
configure
doc/Changelog

index d14257fda80e95221a5efe6454546dc5e59d1549..73548599103f2639cc3da14da020677c994b26d1 100644 (file)
 /* Define if you have POSIX threads libraries and header files. */
 #undef HAVE_PTHREAD
 
+/* Define to 1 if you have the <pthread_np.h> header file. */
+#undef HAVE_PTHREAD_NP_H
+
 /* Have PTHREAD_PRIO_INHERIT. */
 #undef HAVE_PTHREAD_PRIO_INHERIT
 
 /* Define to 1 if the system has the type `pthread_rwlock_t'. */
 #undef HAVE_PTHREAD_RWLOCK_T
 
+/* Define if pthread_setname_np has the common 2 arguments. */
+#undef HAVE_PTHREAD_SETNAME_NP
+
+/* Define if pthread_setname_np has only 1 argument. */
+#undef HAVE_PTHREAD_SETNAME_NP1
+
+/* Define if pthread_setname_np has 3 arguments. */
+#undef HAVE_PTHREAD_SETNAME_NP3
+
+/* Define if pthread_setname_np exists as pthread_set_name_np instead. */
+#undef HAVE_PTHREAD_SET_NAME_NP
+
 /* Define to 1 if the system has the type `pthread_spinlock_t'. */
 #undef HAVE_PTHREAD_SPINLOCK_T
 
index de41ecd1483d752586e13880a8894a81b5f7f614..c7fc98c4e6f61b35ac838fa208d21805a79d5852 100755 (executable)
--- a/configure
+++ b/configure
@@ -19080,6 +19080,168 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
 fi
 
+if test x_$ub_have_pthreads != x_no; then
+       # Long checks to support pthread_setname_np().
+       # Some OSes have the extra non-portable functions in a specific
+       # header file.
+       ac_fn_c_check_header_compile "$LINENO" "pthread_np.h" "ac_cv_header_pthread_np_h" "$ac_includes_default
+"
+if test "x$ac_cv_header_pthread_np_h" = xyes
+then :
+  printf "%s\n" "#define HAVE_PTHREAD_NP_H 1" >>confdefs.h
+
+fi
+
+       # MacOS only has 1 argument, the name.
+       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthread_setname_np has only 1 argument" >&5
+printf %s "checking whether pthread_setname_np has only 1 argument... " >&6; }
+       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+$ac_includes_default
+#include <pthread.h>
+#ifdef HAVE_PTHREAD_NP_H
+#include <pthread_np.h>
+#endif
+
+int
+main (void)
+{
+
+           (void)pthread_setname_np("");
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"
+then :
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_PTHREAD_SETNAME_NP1 1" >>confdefs.h
+
+
+else $as_nop
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+       # NetBSD has 3 arguments to allow for formatting of the name.
+       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthread_setname_np has 3 arguments" >&5
+printf %s "checking whether pthread_setname_np has 3 arguments... " >&6; }
+       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+$ac_includes_default
+#include <pthread.h>
+#ifdef HAVE_PTHREAD_NP_H
+#include <pthread_np.h>
+#endif
+
+int
+main (void)
+{
+
+           (void)pthread_setname_np(0, "", NULL);
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"
+then :
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_PTHREAD_SETNAME_NP3 1" >>confdefs.h
+
+
+else $as_nop
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+       # Most OSes have the common 2 arguments, thread and name.
+       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthread_setname_np has the common 2 arguments" >&5
+printf %s "checking whether pthread_setname_np has the common 2 arguments... " >&6; }
+       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+$ac_includes_default
+#include <pthread.h>
+#ifdef HAVE_PTHREAD_NP_H
+#include <pthread_np.h>
+#endif
+
+int
+main (void)
+{
+
+           (void)pthread_setname_np(0, "");
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"
+then :
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_PTHREAD_SETNAME_NP 1" >>confdefs.h
+
+
+else $as_nop
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+       # FreeBSD/OpenBSD use a slightly different function name.
+       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthread_setname_np exists as pthread_set_name_np instead" >&5
+printf %s "checking whether pthread_setname_np exists as pthread_set_name_np instead... " >&6; }
+       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+$ac_includes_default
+#include <pthread.h>
+#ifdef HAVE_PTHREAD_NP_H
+#include <pthread_np.h>
+#endif
+
+int
+main (void)
+{
+
+           (void)pthread_set_name_np(0, "");
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"
+then :
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_PTHREAD_SET_NAME_NP 1" >>confdefs.h
+
+
+else $as_nop
+
+           { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+fi
+
 # check solaris thread library
 
 # Check whether --with-solaris-threads was given.
index 53595e53c252038ad6e092c4f790acff2b830038..b1c4e4f54fcdaad7830aa5b956a04580770aa725 100644 (file)
@@ -16,6 +16,7 @@
        - Fix ttl comparisons in rdata_copy for 32bit signed or unsigned.
        - Fix subnet store of servfail to not leak memory.
        - Update generated man pages.
+       - Update generated configure, with autoconf.
 
 17 April 2026: Yorgos
        - Merge #1400: Support pthread_setname_np. Adds support for