From fdd0467bcd46ea0d472111adedd21f43d6d4d15e Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 15 Oct 2017 22:36:07 -0700 Subject: On UN*X, always use sigaction(), and always have signal handlers return void. Some time between the mid 1980's and 1990 called; they want their old-fashioned UNIX signal handling back. ANSI C has had signal handlers returning void sincer, well, 1989, and POSIX has had sigaction() since close to forever. No need to worry about really old UN*Xes here. On Windows, it's also void (as per ANSI C); use signal(). --- configure | 79 --------------------------------------------------------------- 1 file changed, 79 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 6e98d577..e359c868 100755 --- a/configure +++ b/configure @@ -5102,85 +5102,6 @@ esac fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 -$as_echo_n "checking return type of signal handlers... " >&6; } -if ${ac_cv_type_signal+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include - -int -main () -{ -return *(signal (0, 0)) (0) == 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_type_signal=int -else - ac_cv_type_signal=void -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 -$as_echo "$ac_cv_type_signal" >&6; } - -cat >>confdefs.h <<_ACEOF -#define RETSIGTYPE $ac_cv_type_signal -_ACEOF - - - if test "$ac_cv_type_signal" = void ; then - -$as_echo "#define RETSIGVAL /**/" >>confdefs.h - - else - -$as_echo "#define RETSIGVAL (0)" >>confdefs.h - - fi - case "$host_os" in - - irix*) - -$as_echo "#define _BSD_SIGNALS 1" >>confdefs.h - - ;; - - *) - for ac_func in sigaction -do : - ac_fn_c_check_func "$LINENO" "sigaction" "ac_cv_func_sigaction" -if test "x$ac_cv_func_sigaction" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SIGACTION 1 -_ACEOF - -fi -done - - if test $ac_cv_func_sigaction = no ; then - for ac_func in sigset -do : - ac_fn_c_check_func "$LINENO" "sigset" "ac_cv_func_sigset" -if test "x$ac_cv_func_sigset" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SIGSET 1 -_ACEOF - -fi -done - - fi - ;; - esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dnet_htoa" >&5 $as_echo_n "checking for library containing dnet_htoa... " >&6; } if ${ac_cv_search_dnet_htoa+:} false; then : -- cgit v1.2.1