[Bug fortran/124512] [16 Regression] libgfortran shmem caf: NetBSD has no pthread_condattr_setpshared
prlw1 at cam dot ac.uk
gcc-bugzilla@gcc.gnu.org
Sun Mar 22 12:02:18 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124512
--- Comment #22 from Patrick Welche <prlw1 at cam dot ac.uk> ---
Just compiled 569ace1fa50f759 successfully with the "proposed patch".
Slightly suprised at the complicated solution given that, as hinted
in the original bug report, AC_CHECK_FUNCS should do the trick:
$ cat configure.ac
AC_INIT
AC_LANG(C)
AC_CHECK_LIB(pthread, pthread_mutexattr_init)
AC_CHECK_FUNCS(pthread_mutexattr_setpshared pthread_condattr_setpshared)
$ ./configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether the compiler supports GNU C... yes
checking whether gcc accepts -g... yes
checking for gcc option to enable C11 features... none needed
checking for pthread_mutexattr_init in -lpthread... yes
checking for pthread_mutexattr_setpshared... no
checking for pthread_condattr_setpshared... no
Anyway, the build problem is solved. There still seems to be some
lingering doubt as to whether or not process-shared pthreads are
actually needed.
More information about the Gcc-bugs
mailing list