--- configure.orig 2019-10-02 07:02:19.000000000 +0200 +++ configure 2021-11-22 23:55:41.696433000 +0100 @@ -9041,6 +9041,28 @@ esac case "$target_os" in #( + bsdsunix*) : + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread should be enabled by default" >&5 +$as_echo_n "checking whether pthread should be enabled by default... " >&6; } +if ${rb_cv_enable_pthread_default+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + rb_cv_enable_pthread_default=yes +else + rb_cv_enable_pthread_default=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $rb_cv_enable_pthread_default" >&5 + colorize_result "$rb_cv_enable_pthread_default" ; } + enable_pthread=$rb_cv_enable_pthread_default + ;; #( freebsd*) : { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread should be enabled by default" >&5 @@ -9555,7 +9577,7 @@ $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h ac_cv_sizeof_rlim_t=8 ;; #( - freebsd*) : + bsdsunix*|freebsd*) : LIBS="-lm $LIBS" ac_cv_func_getpeername=no ac_cv_func_getsockname=no @@ -20124,7 +20146,7 @@ esac case "$target_os" in #( - freebsd*) : + bsdsunix*|freebsd*) : $as_echo "#define BROKEN_CLOSE 1" >>confdefs.h @@ -24512,7 +24534,7 @@ XLDFLAGS="$XLDFLAGS -Wl,-E" LIBPATHFLAG=" -L%1\$-s" rb_cv_dlopen=yes ;; #( - freebsd*|dragonfly*) : + bsdsunix*|freebsd*|dragonfly*) : : ${LDSHARED='$(CC) -shared'} if test "$rb_cv_binary_elf" = yes; then @@ -24712,7 +24734,7 @@ fi case "$target_os" in #( - freebsd*) : + bsdsunix*|freebsd*) : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for procstat_open_sysctl in -lprocstat" >&5 $as_echo_n "checking for procstat_open_sysctl in -lprocstat... " >&6; } @@ -24850,7 +24872,7 @@ done fi ;; #( - *-freebsd*|x86_64-netbsd*) : + *-bsdsunix*|*-freebsd*|x86_64-netbsd*) : for ac_header in execinfo.h do : @@ -25542,7 +25564,7 @@ libdir_basename="${libdir_basename}"${multiarch+'/${arch}'} case "$target_os" in #( - freebsd*|dragonfly*) : + bsdsunix*|freebsd*|dragonfly*) : ;; #( *) : @@ -25634,7 +25656,7 @@ LIBRUBY_RELATIVE=yes fi ;; #( - freebsd*|dragonfly*) : + bsdsunix*|freebsd*|dragonfly*) : SOLIBS='$(LIBS)' LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)' @@ -26076,7 +26098,7 @@ fi case "${target_os}" in #( - freebsd*) : + bsdsunix*|freebsd*) : # FreeBSD's dtrace requires libelf LIBS="-lelf $LIBS" ;; #(