--- origsrc/libsigsegv-2.10/configure.ac 2011-04-03 17:30:16.000000000 +0200 +++ src/libsigsegv-2.10/configure.ac 2015-07-15 14:30:22.264452393 +0200 @@ -419,6 +419,9 @@ if test -z "$CFG_FAULT" && test "$sv_cv_ ;; esac ;; + cygwin*) + CFG_FAULT=fault-cygwin-i386.h + ;; *) CFG_FAULT=fault-posix-ucontext.h ;; @@ -522,16 +525,6 @@ case "$host_os" in FAULT_CONTEXT_INCLUDE='#include ' CFG_FAULT=fault-win32.h # nonexistent, just a dummy ;; - cygwin*) - FAULT_CONTEXT='CONTEXT' - FAULT_CONTEXT_INCLUDE='#include ' - # Cygwin 1.7 uses fault-posix.h. Cygwin 1.5.x needs a hacky workaround. - if test -z "$CFG_FAULT"; then - CFG_FAULT=fault-cygwin-old.h - AC_DEFINE([OLD_CYGWIN_WORKAROUND], [1], - [Define to 1 on Cygwin versions older than 1.7.]) - fi - ;; esac if test -n "$CFG_FAULT"; then sv_cv_have_sigsegv_recovery=yes @@ -858,7 +851,7 @@ AC_CACHE_CHECK([if the system supports c sv_cv_have_stack_overflow_recovery=yes else case "$host_os" in - mingw* | cygwin*) sv_cv_have_stack_overflow_recovery=yes ;; + mingw*) sv_cv_have_stack_overflow_recovery=yes ;; *) if test "$CFG_LEAVE" != 'leave-none.c'; then if test "$sv_cv_sigaltstack" != no; then @@ -927,7 +920,7 @@ dnl Requires AC_CANONICAL_HOST, CFG_HAND dnl HAVE_SIGSEGV_RECOVERY, HAVE_STACK_OVERFLOW_RECOVERY. case "$host_os" in - mingw* | cygwin*) CFG_HANDLER=handler-win32.c ;; + mingw*) CFG_HANDLER=handler-win32.c ;; *) if test -z "$CFG_HANDLER"; then if test $sv_cv_have_sigsegv_recovery = no \ --- origsrc/libsigsegv-2.10/src/fault-cygwin-i386.h 1970-01-01 01:00:00.000000000 +0100 +++ src/libsigsegv-2.10/src/fault-cygwin-i386.h 2015-07-15 14:30:47.562341412 +0200 @@ -0,0 +1,33 @@ +/* Fault handler information. Cygwin/i386 and Cygwin/x86_64 version. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software Foundation, + Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ + +#include "fault-posix-ucontext.h" + +#if defined __x86_64__ +/* 64 bit registers */ + +/* See winsup/cygwin/include/cygwin/signal.h */ + +# define SIGSEGV_FAULT_STACKPOINTER ((ucontext_t *) ucp)->uc_mcontext.rsp + +#else +/* 32 bit registers */ + +/* See winsup/cygwin/include/cygwin/signal.h */ + +# define SIGSEGV_FAULT_STACKPOINTER ((ucontext_t *) ucp)->uc_mcontext.esp + +#endif