+2023-10-15 Bruno Haible <bruno@clisp.org>
+
+ threadlib: Fix link errors on FreeBSD 5.2.1/i386.
+ * m4/threadlib.m4 (gl_PTHREADLIB_BODY): When pthread_kill could not be
+ found in -lpthread, try -lthr.
+
2023-10-15 Bruno Haible <bruno@clisp.org>
lock: Make Autoconf macro more robust.
-# threadlib.m4 serial 32b
+# threadlib.m4 serial 32c
dnl Copyright (C) 2005-2023 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
[Define if the pthread_in_use() detection is hard.])
esac
fi
+ ],
+ [dnl This is needed on FreeBSD 5.2.1.
+ AC_CHECK_LIB([thr], [pthread_kill],
+ [if test $gl_pthread_in_glibc = yes; then
+ LIBPMULTITHREAD=
+ else
+ LIBPMULTITHREAD=-lthr
+ fi
+ ])
])
elif test $gl_pthread_api != yes; then
# Some library is needed. Try libpthread and libc_r.