diff --git a/src/c/stacks.d b/src/c/stacks.d index e14d52fd3..2f025b464 100644 --- a/src/c/stacks.d +++ b/src/c/stacks.d @@ -582,7 +582,7 @@ init_stacks(cl_env_ptr env, char *new_cs_org) #endif cs_set_size(env, ecl_get_option(ECL_OPT_C_STACK_SIZE)); -#if defined(HAVE_SIGPROCMASK) && defined(SA_SIGINFO) +#if defined(HAVE_SIGPROCMASK) && defined(SA_SIGINFO) && defined(SA_ONSTACK) if (ecl_get_option(ECL_OPT_SIGALTSTACK_SIZE)) { stack_t new_stack; cl_index size = ecl_get_option(ECL_OPT_SIGALTSTACK_SIZE); diff --git a/src/c/unixint.d b/src/c/unixint.d index 2e338cea9..d8d66a06f 100644 --- a/src/c/unixint.d +++ b/src/c/unixint.d @@ -161,9 +161,11 @@ mysignal(int code, void (*handler)(int, siginfo_t *, void*)) new_action.sa_sigaction = handler; sigemptyset(&new_action.sa_mask); new_action.sa_flags = SA_SIGINFO; +# ifdef SA_ONSTACK if (code == SIGSEGV) { new_action.sa_flags |= SA_ONSTACK; } +# endif #else new_action.sa_handler = handler; sigemptyset(&new_action.sa_mask); diff --git a/src/compile.lsp.in b/src/compile.lsp.in index dda274245..45ef95ef1 100644 --- a/src/compile.lsp.in +++ b/src/compile.lsp.in @@ -178,7 +178,7 @@ ;;; ;;; * PROFILE ;;; -#+WANTS-PROFILE +#+(and WANTS-PROFILE (not cygwin)) (build-module "profile" '("ext:profile;profile.lisp") :dir "build:ext;"