CHECK_FUNCTION_EXISTS_GLIBC(select HAVE_SELECT)
CHECK_FUNCTION_EXISTS_GLIBC(setenv HAVE_SETENV)
CHECK_FUNCTION_EXISTS_GLIBC(setlocale HAVE_SETLOCALE)
+CHECK_FUNCTION_EXISTS_GLIBC(sigaction HAVE_SIGACTION)
CHECK_FUNCTION_EXISTS_GLIBC(strchr HAVE_STRCHR)
CHECK_FUNCTION_EXISTS_GLIBC(strdup HAVE_STRDUP)
CHECK_FUNCTION_EXISTS_GLIBC(strerror HAVE_STRERROR)
# the C code tests these macros we preserve previous behavior
# for the autotools build by hard-coding availability.
if test "$ac_cv_header_openssl_sha_h" = "yes"; then
- AC_DEFINE(HAVE_OPENSSL_SHA256_INIT, 1, [Define to 1 if your openssl has the `SHA256_Init' function.])
- AC_DEFINE(HAVE_OPENSSL_SHA384_INIT, 1, [Define to 1 if your openssl has the `SHA384_Init' function.])
- AC_DEFINE(HAVE_OPENSSL_SHA512_INIT, 1, [Define to 1 if your openssl has the `SHA512_Init' function.])
+ AC_DEFINE(HAVE_OPENSSL_SHA256_INIT, 1,
+ [Define to 1 if your openssl has the `SHA256_Init' function.])
+ AC_DEFINE(HAVE_OPENSSL_SHA384_INIT, 1,
+ [Define to 1 if your openssl has the `SHA384_Init' function.])
+ AC_DEFINE(HAVE_OPENSSL_SHA512_INIT, 1,
+ [Define to 1 if your openssl has the `SHA512_Init' function.])
fi
fi
fi
AC_CHECK_FUNCS([fstat ftruncate futimens futimes geteuid getpid])
AC_CHECK_FUNCS([lchflags lchmod lchown link lstat])
AC_CHECK_FUNCS([lutimes memmove memset mkdir mkfifo mknod])
-AC_CHECK_FUNCS([nl_langinfo pipe poll readlink select setenv setlocale])
+AC_CHECK_FUNCS([nl_langinfo pipe poll readlink])
+AC_CHECK_FUNCS([select setenv setlocale sigaction])
AC_CHECK_FUNCS([strchr strdup strerror strncpy_s strrchr symlink timegm])
AC_CHECK_FUNCS([tzset unsetenv utime utimensat utimes vfork])
AC_CHECK_FUNCS([wcrtomb wcscpy wcslen wctomb wmemcmp wmemcpy])
static struct bsdtar *_bsdtar;
-#if defined(SIGINFO) || defined(SIGUSR1)
+#if defined(HAVE_SIGACTION) && (defined(SIGINFO) || defined(SIGUSR1))
static volatile int siginfo_occurred;
static void
bsdtar->fd = -1; /* Mark as "unused" */
option_o = 0;
-#if defined(SIGINFO) || defined(SIGUSR1)
+#if defined(HAVE_SIGACTION) && (defined(SIGINFO) || defined(SIGUSR1))
{ /* Catch SIGINFO and SIGUSR1, if they exist. */
struct sigaction sa;
sa.sa_handler = siginfo_handler;