]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Add detection of a handful of pthread _np functions 14458/head
authorOtto Moerbeek <otto.moerbeek@open-xchange.com>
Tue, 16 Jul 2024 09:26:34 +0000 (11:26 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Tue, 16 Jul 2024 09:27:09 +0000 (11:27 +0200)
meson/pthread-np/meson.build [new file with mode: 0644]
pdns/recursordist/meson.build

diff --git a/meson/pthread-np/meson.build b/meson/pthread-np/meson.build
new file mode 100644 (file)
index 0000000..7dc7892
--- /dev/null
@@ -0,0 +1,13 @@
+funcs = [
+  'pthread_setaffinity_np',
+  'pthread_getattr_np',
+  'pthread_get_stackaddr_np',
+  'pthread_get_stacksize_np',
+]
+
+foreach func: funcs
+  found = cxx.has_function(func, dependencies: dep_threads)
+  define = 'HAVE_' + func.to_upper()
+  conf.set(define, found, description: 'Have ' + func)
+  summary(func, found, bool_yn: true, section: 'POSIX Threads')
+endforeach
index 9c92a53b545a3eb7c777af2a9b533a527eb30029..08bcd6498c6ab7f52e861fed4ba64ab96bd5e31c 100644 (file)
@@ -37,6 +37,7 @@ subdir('meson' / 'timet-sign')              # Check the sign of time_t
 subdir('meson' / 'atomics')                 # Check atomics support
 subdir('meson' / 'pthread-headers')         # Check pthread headers
 subdir('meson' / 'pthread-setname')         # Pthread setname madness
+subdir('meson' / 'pthread-np')              # Pthread _np functions
 subdir('meson' / 'strerror')                # Strerror_r
 subdir('meson' / 'lua')                     # Lua
 subdir('meson' / 'hardening')               # Hardening