This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by configure, which was
generated by GNU Autoconf 2.52.  Invocation command line was

  $ ./configure --prefix=/boot/home/config

## ---------- ##
## Platform.  ##
## ---------- ##

hostname = linuix
uname -m = BePC
uname -r = 5.0
uname -s = BeOS
uname -v = 1000009

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = unknown
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
hostinfo               = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH = .:/boot/home/config/bin:/bin:/boot/apps:/boot/preferences:/boot/beos/apps:/boot/beos/preferences:/boot/develop/tools/gnupro/bin

## ------------ ##
## Core tests.  ##
## ------------ ##

configure:1090: PATH=".;."; conftest.sh
./configure: conftest.sh: command not found
configure:1093: $? = 127
configure:1185: checking for a BSD compatible install
configure:1234: result: /boot/home/config/bin/install -c
configure:1245: checking whether build environment is sane
configure:1288: result: yes
configure:1321: checking for mawk
configure:1347: result: no
configure:1321: checking for gawk
configure:1336: found /boot/home/config/bin/gawk
configure:1344: result: gawk
configure:1354: checking whether make sets ${MAKE}
configure:1374: result: yes
configure:1508: checking for gcc
configure:1531: result: gcc -Wall
configure:1759: checking for C compiler version
configure:1762: gcc -Wall --version </dev/null >&5
2.9-beos-991026
configure:1765: $? = 0
configure:1767: gcc -Wall -v </dev/null >&5
Reading specs from /boot/develop/tools/gnupro/lib/gcc-lib/i586-beos/2.9-beos-991026/specs
gcc version 2.9-beos-991026
configure:1770: $? = 0
configure:1772: gcc -Wall -V </dev/null >&5
gcc: argument to `-V' is missing
configure:1775: $? = 1
configure:1795: checking for C compiler default output
configure:1798: gcc -Wall    conftest.c  >&5
configure:1801: $? = 0
configure:1830: result: conftest
configure:1835: checking whether the C compiler works
configure:1841: ./conftest
configure:1844: $? = 0
configure:1859: result: yes
configure:1866: checking whether we are cross compiling
configure:1868: result: no
configure:1871: checking for executable suffix
configure:1873: gcc -Wall -o conftest    conftest.c  >&5
configure:1876: $? = 0
configure:1898: result: 
configure:1904: checking for object suffix
configure:1922: gcc -Wall -c   conftest.c >&5
configure:1925: $? = 0
configure:1944: result: o
configure:1948: checking whether we are using the GNU C compiler
configure:1969: gcc -Wall -c   conftest.c >&5
configure:1972: $? = 0
configure:1975: test -s conftest.o
configure:1978: $? = 0
configure:1990: result: yes
configure:1996: checking whether gcc -Wall accepts -g
configure:2014: gcc -Wall -c -g  conftest.c >&5
configure:2017: $? = 0
configure:2020: test -s conftest.o
configure:2023: $? = 0
configure:2033: result: yes
configure:2060: gcc -Wall -c -g -O2  conftest.c >&5
/boot/home/gnubuild/libsigsegv-1.96/conftest.c:2: parse error before `me'
configure:2063: $? = 1
configure: failed program was:
#ifndef __cplusplus
  choke me
#endif
configure:2169: checking for style of include used by make
configure:2196: result: GNU
configure:2202: checking dependency style of gcc -Wall
configure:2264: result: none
configure:2273: checking how to run the C preprocessor
configure:2299: gcc -Wall -E  conftest.c
configure:2305: $? = 0
configure:2332: gcc -Wall -E  conftest.c
/boot/home/gnubuild/libsigsegv-1.96/configure:2329: ac_nonexistent.h: No such file or directory
configure:2338: $? = 1
configure: failed program was:
#line 2328 "configure"
#include "confdefs.h"
#include <ac_nonexistent.h>
configure:2375: result: gcc -Wall -E
configure:2390: gcc -Wall -E  conftest.c
configure:2396: $? = 0
configure:2423: gcc -Wall -E  conftest.c
/boot/home/gnubuild/libsigsegv-1.96/configure:2420: ac_nonexistent.h: No such file or directory
configure:2429: $? = 1
configure: failed program was:
#line 2419 "configure"
#include "confdefs.h"
#include <ac_nonexistent.h>
configure:2474: checking build system type
configure:2492: result: i586-pc-beos
configure:2499: checking host system type
configure:2513: result: i586-pc-beos
configure:2520: checking host platform
configure:2539: result: i586-pc-beos
configure:2555: checking for a BSD compatible install
configure:2604: result: /boot/home/config/bin/install -c
configure:2702: checking for ld used by GCC
configure:2765: result: /boot/develop/tools/gnupro/bin/ld
configure:2774: checking if the linker (/boot/develop/tools/gnupro/bin/ld) is GNU ld
GNU ld version 2.9-beos-991026 (with BFD 2.9-beos-991026)
configure:2786: result: yes
configure:2790: checking for /boot/develop/tools/gnupro/bin/ld option to reload object files
configure:2797: result: -r
configure:2802: checking for BSD-compatible nm
configure:2838: result: /boot/develop/tools/gnupro/bin/nm -B
configure:2841: checking whether ln -s works
configure:2845: result: yes
configure:2852: checking how to recognise dependant libraries
configure:3030: result: pass_all
configure:3036: checking command to parse /boot/develop/tools/gnupro/bin/nm -B output
configure:3117: gcc -Wall -c -g -O2  conftest.c >&5
configure:3120: $? = 0
configure:3124: /boot/develop/tools/gnupro/bin/nm -B conftest.o \| sed -n -e 's/^.*[ 	]\([ABCDGISTW][ABCDGISTW]*\)[ 	][ 	]*\(\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p' \> conftest.nm
configure:3127: $? = 0
configure:3179: gcc -Wall -o conftest -g -O2   conftest.c conftstm.o >&5
/boot/home/gnubuild/libsigsegv-1.96/conftest.c:6: warning: `main' is usually a function
configure:3182: $? = 0
configure:3226: result: ok
configure:3233: checking for dlfcn.h
configure:3243: gcc -Wall -E  conftest.c
/boot/home/gnubuild/libsigsegv-1.96/configure:3240: dlfcn.h: No such file or directory
configure:3249: $? = 1
configure: failed program was:
#line 3239 "configure"
#include "confdefs.h"
#include <dlfcn.h>
configure:3268: result: no
configure:3455: checking for ranlib
configure:3470: found /boot/develop/tools/gnupro/bin/ranlib
configure:3479: result: ranlib
configure:3529: checking for strip
configure:3544: found /boot/develop/tools/gnupro/bin/strip
configure:3553: result: strip
configure:3755: checking for objdir
configure:3766: result: .libs
configure:3781: checking for gcc option to produce PIC
configure:3941: result: none
configure:4029: checking if gcc static flag -static works
configure:4050: gcc -Wall -o conftest -g -O2   -static conftest.c  >&5
configure:4053: $? = 0
configure:4056: test -s conftest
configure:4059: $? = 0
configure:4073: result: yes
configure:4084: checking if gcc supports -c -o file.o
configure:4104: gcc -Wall -c -g -O2 -o out/conftest2.o  conftest.c >&5
configure:4128: result: yes
configure:4133: checking if gcc supports -c -o file.lo
configure:4157: gcc -Wall -c -g -O2 -c -o conftest.lo  conftest.c >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:4150: warning: unused variable `some_variable'
configure:4160: $? = 0
configure:4163: test -s conftest.lo
configure:4166: $? = 0
configure:4187: result: yes
configure:4218: checking if gcc supports -fno-rtti -fno-exceptions
configure:4237: gcc -Wall -c -g -O2 -fno-rtti -fno-exceptions -c conftest.c  conftest.c >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:4230: warning: unused variable `some_variable'
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:4230: warning: unused variable `some_variable'
configure:4240: $? = 0
configure:4243: test -s conftest.o
configure:4246: $? = 0
configure:4262: result: yes
configure:4273: checking whether the linker (/boot/develop/tools/gnupro/bin/ld) supports shared libraries
configure:4953: result: yes
configure:4958: checking how to hardcode library paths into programs
configure:4982: result: immediate
configure:4987: checking whether stripping libraries is possible
configure:4992: result: yes
configure:5003: checking dynamic linker characteristics
configure:5408: result: beos ld.so
configure:5413: checking if libtool supports shared libraries
configure:5415: result: yes
configure:5418: checking whether to build shared libraries
configure:5439: result: no
configure:5442: checking whether to build static libraries
configure:5446: result: yes
configure:6695: checking for unistd.h
configure:6705: gcc -Wall -E  conftest.c
configure:6711: $? = 0
configure:6730: result: yes
configure:6740: checking for getpagesize
configure:6764: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:6757: warning: implicit declaration of function `getpagesize'
/boot/home/gnubuild/libsigsegv-1.96/configure:6757: warning: unused variable `pgsz'
/tmp/ccHB2M0d.o: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:6757: undefined reference to `getpagesize'
collect2: ld returned 1 exit status
configure:6767: $? = 1
configure: failed program was:
#line 6747 "configure"
#include "confdefs.h"

#if HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif

int
main ()
{
int pgsz = getpagesize();
  ;
  return 0;
}
configure:6783: result: no
configure:6793: checking for sysconf(_SC_PAGESIZE)
configure:6817: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:6810: `_SC_PAGESIZE' undeclared (first use in this function)
/boot/home/gnubuild/libsigsegv-1.96/configure:6810: (Each undeclared identifier is reported only once
/boot/home/gnubuild/libsigsegv-1.96/configure:6810: for each function it appears in.)
/boot/home/gnubuild/libsigsegv-1.96/configure:6810: warning: unused variable `pgsz'
configure:6820: $? = 1
configure: failed program was:
#line 6800 "configure"
#include "confdefs.h"

#if HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif

int
main ()
{
int pgsz = sysconf (_SC_PAGESIZE);
  ;
  return 0;
}
configure:6836: result: no
configure:6846: checking for PAGESIZE in limits.h
configure:6865: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:6858: `PAGESIZE' undeclared (first use in this function)
/boot/home/gnubuild/libsigsegv-1.96/configure:6858: (Each undeclared identifier is reported only once
/boot/home/gnubuild/libsigsegv-1.96/configure:6858: for each function it appears in.)
/boot/home/gnubuild/libsigsegv-1.96/configure:6858: warning: unused variable `pgsz'
configure:6868: $? = 1
configure: failed program was:
#line 6853 "configure"
#include "confdefs.h"
#include <limits.h>
int
main ()
{
int pgsz = PAGESIZE;
  ;
  return 0;
}
configure:6884: result: no
configure:6898: checking for mmap with MAP_ANON
configure:6961: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:6952: sys/mman.h: No such file or directory
configure:6964: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 6949 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/mman.h>
int main ()
{
  void *p = mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0);
  return (p == (void *)(-1));
}
configure:6982: result: no
configure:6992: checking for mmap with MAP_ANONYMOUS
configure:7055: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7046: sys/mman.h: No such file or directory
configure:7058: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7043 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/mman.h>
int main ()
{
  void *p = mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0);
  return (p == (void *)(-1));
}
configure:7076: result: no
configure:7086: checking for mmap of /dev/zero
configure:7160: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7143: sys/mman.h: No such file or directory
configure:7163: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7140 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/mman.h>
#include <fcntl.h>
#ifndef MAP_FILE
#define MAP_FILE 0
#endif
int main ()
{
  int fd;
  void *p;
  fd = open ("/dev/zero", O_RDONLY, 0666);
  if (fd < 0) return 1;
  p = mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_FILE | MAP_PRIVATE, fd, 0);
  return (p == (void *)(-1));
}
configure:7181: result: no
configure:7193: checking whether a fault handler according to POSIX works
configure:7324: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7254: sys/mman.h: No such file or directory
configure:7327: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7248 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, siginfo_t *sip, void *ucp)
{
  void *fault_address = (void *) (sip->si_addr);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);
action.sa_sigaction = &sigsegv_handler;
   action.sa_flags = SA_SIGINFO;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:7345: result: no
configure:7348: checking whether a fault handler according to Linux/i386 works
configure:7480: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7406: asm/sigcontext.h: No such file or directory
/boot/home/gnubuild/libsigsegv-1.96/configure:7408: sys/mman.h: No such file or directory
configure:7483: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7402 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <asm/sigcontext.h>
#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, struct sigcontext sc)
{
  void *fault_address = (void *) (sc.cr2);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:7501: result: no
configure:7504: checking whether a fault handler according to old Linux/i386 works
configure:7636: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7564: sys/mman.h: No such file or directory
configure:7639: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7558 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, unsigned int more)
{
  void *fault_address = (void *) (((unsigned long *) &more) [21]);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:7657: result: no
configure:7660: checking whether a fault handler according to BSD works
configure:7792: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7720: sys/mman.h: No such file or directory
configure:7795: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7714 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, int code, struct sigcontext *scp, void *addr)
{
  void *fault_address = (void *) (addr);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:7813: result: no
configure:7816: checking whether a fault handler according to IRIX works
configure:7948: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:7876: sys/mman.h: No such file or directory
configure:7951: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 7870 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, int code, struct sigcontext *scp)
{
  void *fault_address = (void *) ((unsigned long) scp->sc_badvaddr);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:7969: result: no
configure:7972: checking whether a fault handler according to HP-UX HPPA works
configure:8104: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:8032: sys/mman.h: No such file or directory
configure:8107: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 8026 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, int code, struct sigcontext *scp)
{
  void *fault_address = (void *) (scp->sc_sl.sl_ss.ss_narrow.ss_cr21);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:8125: result: no
configure:8128: checking whether a fault handler according to OSF/1 Alpha works
configure:8260: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:8188: sys/mman.h: No such file or directory
configure:8263: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 8182 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, int code, struct sigcontext *scp)
{
  void *fault_address = (void *) (scp->sc_traparg_a0);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:8281: result: no
configure:8284: checking whether a fault handler according to AIX works
configure:8416: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:8344: sys/mman.h: No such file or directory
configure:8419: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 8338 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>

#include <sys/types.h>
#include <sys/mman.h>
#if HAVE_MMAP_DEVZERO
# include <fcntl.h>
# ifndef MAP_FILE
#  define MAP_FILE 0
# endif
#endif
#ifndef PROT_NONE
# define PROT_NONE 0
#endif
#if HAVE_MMAP_ANON
# define zero_fd -1
# define map_flags MAP_ANON | MAP_PRIVATE
#elif HAVE_MMAP_ANONYMOUS
# define zero_fd -1
# define map_flags MAP_ANONYMOUS | MAP_PRIVATE
#elif HAVE_MMAP_DEVZERO
static int zero_fd;
# define map_flags MAP_FILE | MAP_PRIVATE
#endif
unsigned long page;
int handler_called = 0;
void sigsegv_handler (int sig, int code, struct sigcontext *scp)
{
  void *fault_address = (void *) (scp->sc_jmpbuf.jmp_context.o_vaddr);
  handler_called++;
  if (fault_address != (void*)(page + 0x678))
    exit (1);
  if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
    exit (2);
}
void crasher (unsigned long p)
{
  *(int *) (p + 0x678) = 42;
}
int main ()
{
  void *p;
  struct sigaction action;
  /* Preparations.  */
#if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
  zero_fd = open ("/dev/zero", O_RDONLY, 0644);
#endif
  /* Setup some mmaped memory.  */
  p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
  if (p == (void *)(-1))
    exit (2);
  page = (unsigned long) p;
  /* Make it read-only.  */
  if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
    exit (2);
  /* Install the SIGSEGV handler.  */
  sigemptyset(&action.sa_mask);

  action.sa_handler = (void (*) (int)) &sigsegv_handler;
  action.sa_flags = 0;

  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* The first write access should invoke the handler and then complete.  */
  crasher (page);
  /* The second write access should not invoke the handler.  */
  crasher (page);
  /* Check that the handler was called only once.  */
  if (handler_called != 1)
    exit (1);
  /* Test passed!  */
  return 0;
}
configure:8437: result: no
configure:8586: checking for the fault handler specifics
configure:8593: result: fault-beos-i386.h
configure:8603: checking if the system supports catching SIGSEGV
configure:8605: result: no
configure:8613: checking for stack direction
configure:8710: result: grows down
configure:8717: checking for PIOCMAP in sys/procfs.h
configure:8736: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:8725: sys/procfs.h: No such file or directory
configure:8739: $? = 1
configure: failed program was:
#line 8724 "configure"
#include "confdefs.h"
#include <sys/procfs.h>
int
main ()
{
int x = PIOCNMAP + PIOCMAP; prmap_t y;
  ;
  return 0;
}
configure:8756: result: no
configure:8779: checking for getrlimit
configure:8816: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/tmp/cctgo5I7.o: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:8807: undefined reference to `getrlimit'
collect2: ld returned 1 exit status
configure:8819: $? = 1
configure: failed program was:
#line 8785 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char getrlimit (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char getrlimit ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_getrlimit) || defined (__stub___getrlimit)
choke me
#else
f = getrlimit;
#endif

  ;
  return 0;
}
configure:8835: result: no
configure:8779: checking for setrlimit
configure:8816: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/tmp/ccy5Rke2.o: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:8807: undefined reference to `setrlimit'
collect2: ld returned 1 exit status
configure:8819: $? = 1
configure: failed program was:
#line 8785 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char setrlimit (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char setrlimit ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_setrlimit) || defined (__stub___setrlimit)
choke me
#else
f = setrlimit;
#endif

  ;
  return 0;
}
configure:8835: result: no
configure:8848: checking for sigaltstack
configure:8885: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/tmp/ccMKpKXC.o: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:8876: undefined reference to `sigaltstack'
collect2: ld returned 1 exit status
configure:8888: $? = 1
configure: failed program was:
#line 8854 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char sigaltstack (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char sigaltstack ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_sigaltstack) || defined (__stub___sigaltstack)
choke me
#else
f = sigaltstack;
#endif

  ;
  return 0;
}
configure:8904: result: no
configure:8914: checking for working sigaltstack
configure:9038: result: no
configure:9048: checking if the system supports catching stack overflow
configure:9064: result: yes
configure:9075: checking whether a signal handler can be left through longjmp
configure:9157: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:9140: `SA_ONSTACK' undeclared (first use in this function)
/boot/home/gnubuild/libsigsegv-1.96/configure:9140: (Each undeclared identifier is reported only once
/boot/home/gnubuild/libsigsegv-1.96/configure:9140: for each function it appears in.)
configure:9160: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 9089 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <setjmp.h>

#if HAVE_SETRLIMIT
# include <sys/types.h>
# include <sys/time.h>
# include <sys/resource.h>
#endif
jmp_buf mainloop;
sigset_t mainsigset;
int pass = 0;
void stackoverflow_handler (int sig)
{
  pass++;
  sigprocmask (SIG_SETMASK, &mainsigset, NULL);
  {  }
  longjmp (mainloop, pass);
}
int recurse (int n)
{
  if (n >= 0)
    return n + recurse (n + 1);
  else
    return 0;
}
int main ()
{
  char mystack[16384];
  stack_t altstack;
  struct sigaction action;
  sigset_t emptyset;
#if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
  /* Before starting the endless recursion, try to be friendly to the user's
     machine.  On some Linux 2.2.x systems, there is no stack limit for user
     processes at all.  We don't want to kill such systems.  */
  struct rlimit rl;
  rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
  setrlimit (RLIMIT_STACK, &rl);
#endif
  /* Install the alternate stack.  */
  altstack.ss_sp = mystack;
  altstack.ss_size = sizeof (mystack);
  altstack.ss_flags = 0; /* no SS_DISABLE */
  if (sigaltstack (&altstack, NULL) < 0)
    exit (1);
  /* Install the SIGSEGV handler.  */
  sigemptyset (&action.sa_mask);
  action.sa_handler = &stackoverflow_handler;
  action.sa_flags = SA_ONSTACK;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* Save the current signal mask.  */
  sigemptyset (&emptyset);
  sigprocmask (SIG_BLOCK, &emptyset, &mainsigset);
  /* Provoke two stack overflows in a row.  */
  if (setjmp (mainloop) < 2)
    {
      recurse (0);
      exit (2);
    }
  exit (0);
}
configure:9178: result: no
configure:9181: checking whether a signal handler can be left through longjmp and sigaltstack
configure:9269: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `stackoverflow_handler':
/boot/home/gnubuild/libsigsegv-1.96/configure:9216: `SS_ONSTACK' undeclared (first use in this function)
/boot/home/gnubuild/libsigsegv-1.96/configure:9216: (Each undeclared identifier is reported only once
/boot/home/gnubuild/libsigsegv-1.96/configure:9216: for each function it appears in.)
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:9252: `SA_ONSTACK' undeclared (first use in this function)
configure:9272: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 9195 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <setjmp.h>

#if HAVE_SETRLIMIT
# include <sys/types.h>
# include <sys/time.h>
# include <sys/resource.h>
#endif
jmp_buf mainloop;
sigset_t mainsigset;
int pass = 0;
void stackoverflow_handler (int sig)
{
  pass++;
  sigprocmask (SIG_SETMASK, &mainsigset, NULL);
  { stack_t ss;
   if (sigaltstack (NULL, &ss) >= 0)
     {
       ss.ss_flags &= ~SS_ONSTACK;
       sigaltstack (&ss, NULL);
     }
   }
  longjmp (mainloop, pass);
}
int recurse (int n)
{
  if (n >= 0)
    return n + recurse (n + 1);
  else
    return 0;
}
int main ()
{
  char mystack[16384];
  stack_t altstack;
  struct sigaction action;
  sigset_t emptyset;
#if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
  /* Before starting the endless recursion, try to be friendly to the user's
     machine.  On some Linux 2.2.x systems, there is no stack limit for user
     processes at all.  We don't want to kill such systems.  */
  struct rlimit rl;
  rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
  setrlimit (RLIMIT_STACK, &rl);
#endif
  /* Install the alternate stack.  */
  altstack.ss_sp = mystack;
  altstack.ss_size = sizeof (mystack);
  altstack.ss_flags = 0; /* no SS_DISABLE */
  if (sigaltstack (&altstack, NULL) < 0)
    exit (1);
  /* Install the SIGSEGV handler.  */
  sigemptyset (&action.sa_mask);
  action.sa_handler = &stackoverflow_handler;
  action.sa_flags = SA_ONSTACK;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* Save the current signal mask.  */
  sigemptyset (&emptyset);
  sigprocmask (SIG_BLOCK, &emptyset, &mainsigset);
  /* Provoke two stack overflows in a row.  */
  if (setjmp (mainloop) < 2)
    {
      recurse (0);
      exit (2);
    }
  exit (0);
}
configure:9290: result: no
configure:9293: checking whether a signal handler can be left through longjmp and setcontext
configure:9386: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:9312: ucontext.h: No such file or directory
configure:9389: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 9307 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <setjmp.h>
#include <ucontext.h>
#if HAVE_SETRLIMIT
# include <sys/types.h>
# include <sys/time.h>
# include <sys/resource.h>
#endif
jmp_buf mainloop;
sigset_t mainsigset;
int pass = 0;
void stackoverflow_handler (int sig)
{
  pass++;
  sigprocmask (SIG_SETMASK, &mainsigset, NULL);
  { static int fl;
   static ucontext_t uc;
   fl = 0;
   if (getcontext (&uc) >= 0)
     if (fl == 0)
       if (uc.uc_stack.ss_flags & SS_ONSTACK)
         {
           uc.uc_stack.ss_flags &= ~SS_ONSTACK;
           fl = 1;
           setcontext (&uc);
         }
   }
  longjmp (mainloop, pass);
}
int recurse (int n)
{
  if (n >= 0)
    return n + recurse (n + 1);
  else
    return 0;
}
int main ()
{
  char mystack[16384];
  stack_t altstack;
  struct sigaction action;
  sigset_t emptyset;
#if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
  /* Before starting the endless recursion, try to be friendly to the user's
     machine.  On some Linux 2.2.x systems, there is no stack limit for user
     processes at all.  We don't want to kill such systems.  */
  struct rlimit rl;
  rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
  setrlimit (RLIMIT_STACK, &rl);
#endif
  /* Install the alternate stack.  */
  altstack.ss_sp = mystack;
  altstack.ss_size = sizeof (mystack);
  altstack.ss_flags = 0; /* no SS_DISABLE */
  if (sigaltstack (&altstack, NULL) < 0)
    exit (1);
  /* Install the SIGSEGV handler.  */
  sigemptyset (&action.sa_mask);
  action.sa_handler = &stackoverflow_handler;
  action.sa_flags = SA_ONSTACK;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* Save the current signal mask.  */
  sigemptyset (&emptyset);
  sigprocmask (SIG_BLOCK, &emptyset, &mainsigset);
  /* Provoke two stack overflows in a row.  */
  if (setjmp (mainloop) < 2)
    {
      recurse (0);
      exit (2);
    }
  exit (0);
}
configure:9407: result: no
configure:9413: checking whether a signal handler can be left through siglongjmp
configure:9493: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:9479: `SA_ONSTACK' undeclared (first use in this function)
/boot/home/gnubuild/libsigsegv-1.96/configure:9479: (Each undeclared identifier is reported only once
/boot/home/gnubuild/libsigsegv-1.96/configure:9479: for each function it appears in.)
configure:9496: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 9427 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <setjmp.h>

#if HAVE_SETRLIMIT
# include <sys/types.h>
# include <sys/time.h>
# include <sys/resource.h>
#endif
sigjmp_buf mainloop;
int pass = 0;
void stackoverflow_handler (int sig)
{
  pass++;
  {  }
  siglongjmp (mainloop, pass);
}
int recurse (int n)
{
  if (n >= 0)
    return n + recurse (n + 1);
  else
    return 0;
}
int main ()
{
  char mystack[16384];
  stack_t altstack;
  struct sigaction action;
#ifdef __BEOS__
  /* On BeOS, this would hang, burning CPU time.  Better fail than hang.  */
  exit (1);
#endif
#if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
  /* Before starting the endless recursion, try to be friendly to the user's
     machine.  On some Linux 2.2.x systems, there is no stack limit for user
     processes at all.  We don't want to kill such systems.  */
  struct rlimit rl;
  rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
  setrlimit (RLIMIT_STACK, &rl);
#endif
  /* Install the alternate stack.  */
  altstack.ss_sp = mystack;
  altstack.ss_size = sizeof (mystack);
  altstack.ss_flags = 0; /* no SS_DISABLE */
  if (sigaltstack (&altstack, NULL) < 0)
    exit (1);
  /* Install the SIGSEGV handler.  */
  sigemptyset (&action.sa_mask);
  action.sa_handler = &stackoverflow_handler;
  action.sa_flags = SA_ONSTACK;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* Provoke two stack overflows in a row.  */
  if (sigsetjmp (mainloop, 1) < 2)
    {
      recurse (0);
      exit (2);
    }
  exit (0);
}
configure:9514: result: no
configure:9517: checking whether a signal handler can be left through siglongjmp and sigaltstack
configure:9603: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `stackoverflow_handler':
/boot/home/gnubuild/libsigsegv-1.96/configure:9550: `SS_ONSTACK' undeclared (first use in this function)
/boot/home/gnubuild/libsigsegv-1.96/configure:9550: (Each undeclared identifier is reported only once
/boot/home/gnubuild/libsigsegv-1.96/configure:9550: for each function it appears in.)
/boot/home/gnubuild/libsigsegv-1.96/configure: In function `main':
/boot/home/gnubuild/libsigsegv-1.96/configure:9589: `SA_ONSTACK' undeclared (first use in this function)
configure:9606: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 9531 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <setjmp.h>

#if HAVE_SETRLIMIT
# include <sys/types.h>
# include <sys/time.h>
# include <sys/resource.h>
#endif
sigjmp_buf mainloop;
int pass = 0;
void stackoverflow_handler (int sig)
{
  pass++;
  { stack_t ss;
   if (sigaltstack (NULL, &ss) >= 0)
     {
       ss.ss_flags &= ~SS_ONSTACK;
       sigaltstack (&ss, NULL);
     }
   }
  siglongjmp (mainloop, pass);
}
int recurse (int n)
{
  if (n >= 0)
    return n + recurse (n + 1);
  else
    return 0;
}
int main ()
{
  char mystack[16384];
  stack_t altstack;
  struct sigaction action;
#ifdef __BEOS__
  /* On BeOS, this would hang, burning CPU time.  Better fail than hang.  */
  exit (1);
#endif
#if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
  /* Before starting the endless recursion, try to be friendly to the user's
     machine.  On some Linux 2.2.x systems, there is no stack limit for user
     processes at all.  We don't want to kill such systems.  */
  struct rlimit rl;
  rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
  setrlimit (RLIMIT_STACK, &rl);
#endif
  /* Install the alternate stack.  */
  altstack.ss_sp = mystack;
  altstack.ss_size = sizeof (mystack);
  altstack.ss_flags = 0; /* no SS_DISABLE */
  if (sigaltstack (&altstack, NULL) < 0)
    exit (1);
  /* Install the SIGSEGV handler.  */
  sigemptyset (&action.sa_mask);
  action.sa_handler = &stackoverflow_handler;
  action.sa_flags = SA_ONSTACK;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* Provoke two stack overflows in a row.  */
  if (sigsetjmp (mainloop, 1) < 2)
    {
      recurse (0);
      exit (2);
    }
  exit (0);
}
configure:9624: result: no
configure:9627: checking whether a signal handler can be left through siglongjmp and setcontext
configure:9718: gcc -Wall -o conftest -g -O2   conftest.c  >&5
/boot/home/gnubuild/libsigsegv-1.96/configure:9646: ucontext.h: No such file or directory
configure:9721: $? = 1
configure: program exited with status 1
configure: failed program was:
#line 9641 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <signal.h>
#include <setjmp.h>
#include <ucontext.h>
#if HAVE_SETRLIMIT
# include <sys/types.h>
# include <sys/time.h>
# include <sys/resource.h>
#endif
sigjmp_buf mainloop;
int pass = 0;
void stackoverflow_handler (int sig)
{
  pass++;
  { static int fl;
   static ucontext_t uc;
   fl = 0;
   if (getcontext(&uc) >= 0)
     if (fl == 0)
       if (uc.uc_stack.ss_flags & SS_ONSTACK)
         {
           uc.uc_stack.ss_flags &= ~SS_ONSTACK;
           fl = 1;
           setcontext(&uc);
         }
   }
  siglongjmp (mainloop, pass);
}
int recurse (int n)
{
  if (n >= 0)
    return n + recurse (n + 1);
  else
    return 0;
}
int main ()
{
  char mystack[16384];
  stack_t altstack;
  struct sigaction action;
#ifdef __BEOS__
  /* On BeOS, this would hang, burning CPU time.  Better fail than hang.  */
  exit (1);
#endif
#if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
  /* Before starting the endless recursion, try to be friendly to the user's
     machine.  On some Linux 2.2.x systems, there is no stack limit for user
     processes at all.  We don't want to kill such systems.  */
  struct rlimit rl;
  rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
  setrlimit (RLIMIT_STACK, &rl);
#endif
  /* Install the alternate stack.  */
  altstack.ss_sp = mystack;
  altstack.ss_size = sizeof (mystack);
  altstack.ss_flags = 0; /* no SS_DISABLE */
  if (sigaltstack (&altstack, NULL) < 0)
    exit (1);
  /* Install the SIGSEGV handler.  */
  sigemptyset (&action.sa_mask);
  action.sa_handler = &stackoverflow_handler;
  action.sa_flags = SA_ONSTACK;
  sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
  sigaction (SIGBUS, &action, (struct sigaction *) NULL);
  /* Provoke two stack overflows in a row.  */
  if (sigsetjmp (mainloop, 1) < 2)
    {
      recurse (0);
      exit (2);
    }
  exit (0);
}
configure:9739: result: no
configure:9866: creating ./config.status

## ----------------------- ##
## Running config.status.  ##
## ----------------------- ##

This file was extended by config.status 2.52, executed with
  CONFIG_FILES    = 
  CONFIG_HEADERS  = 
  CONFIG_LINKS    = 
  CONFIG_COMMANDS = 
  > ./config.status 
on linuix

config.status:10359: creating Makefile
config.status:10359: creating src/Makefile
config.status:10359: creating src/sigsegv.h
config.status:10359: creating m4/Makefile
config.status:10359: creating tests/Makefile
config.status:10451: creating config.h

## ----------------- ##
## Cache variables.  ##
## ----------------- ##

ac_cv_build=i586-pc-beos
ac_cv_build_alias=i586-pc-beos
ac_cv_c_compiler_gnu=yes
ac_cv_env_CC_set=set
ac_cv_env_CC_value='gcc -Wall'
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_func_getrlimit=no
ac_cv_func_setrlimit=no
ac_cv_func_sigaltstack=no
ac_cv_header_dlfcn_h=no
ac_cv_header_unistd_h=yes
ac_cv_host=i586-pc-beos
ac_cv_host_alias=i586-pc-beos
ac_cv_objext=o
ac_cv_path_install='/boot/home/config/bin/install -c'
ac_cv_prog_AWK=gawk
ac_cv_prog_CPP='gcc -Wall -E'
ac_cv_prog_ac_ct_CC='gcc -Wall'
ac_cv_prog_ac_ct_RANLIB=ranlib
ac_cv_prog_ac_ct_STRIP=strip
ac_cv_prog_cc_g=yes
ac_cv_prog_make_make_set=yes
am_cv_CC_dependencies_compiler_type=none
lt_cv_compiler_c_o=yes
lt_cv_compiler_o_lo=yes
lt_cv_deplibs_check_method=pass_all
lt_cv_file_magic_cmd='$MAGIC_CMD'
lt_cv_file_magic_test_file=
lt_cv_global_symbol_to_c_name_address='sed -n -e '\''s/^: \([^ ]*\) $/  {\"\1\", (lt_ptr) 0},/p'\'' -e '\''s/^[BCDEGRST] \([^ ]*\) \([^ ]*\)$/  {"\2", (lt_ptr) \&\2},/p'\'''
lt_cv_global_symbol_to_cdecl='sed -n -e '\''s/^. .* \(.*\)$/extern char \1;/p'\'''
lt_cv_ld_reload_flag=-r
lt_cv_path_LD=/boot/develop/tools/gnupro/bin/ld
lt_cv_path_NM='/boot/develop/tools/gnupro/bin/nm -B'
lt_cv_prog_cc_can_build_shared=yes
lt_cv_prog_cc_no_builtin=
lt_cv_prog_cc_pic=
lt_cv_prog_cc_shlib=
lt_cv_prog_cc_static=-static
lt_cv_prog_cc_static_works=yes
lt_cv_prog_cc_wl=-Wl,
lt_cv_prog_gnu_ld=yes
lt_cv_sys_global_symbol_pipe='sed -n -e '\''s/^.*[ 	]\([ABCDGISTW][ABCDGISTW]*\)[ 	][ 	]*\(\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p'\'''
lt_cv_sys_path_separator=:
sv_cv_fault_aix=no
sv_cv_fault_bsd=no
sv_cv_fault_hpux_hppa=no
sv_cv_fault_include=fault-beos-i386.h
sv_cv_fault_irix=no
sv_cv_fault_linux_i386=no
sv_cv_fault_linux_i386_old=no
sv_cv_fault_osf_alpha=no
sv_cv_fault_posix=no
sv_cv_func_getpagesize=no
sv_cv_func_mmap_anon=no
sv_cv_func_mmap_anonymous=no
sv_cv_func_mmap_devzero=no
sv_cv_func_sysconf_pagesize=no
sv_cv_have_sigsegv_recovery=no
sv_cv_have_stack_overflow_recovery=yes
sv_cv_host=i586-pc-beos
sv_cv_leave_handler_longjmp=no
sv_cv_leave_handler_longjmp_setcontext=no
sv_cv_leave_handler_longjmp_sigaltstack=no
sv_cv_leave_handler_siglongjmp=no
sv_cv_leave_handler_siglongjmp_setcontext=no
sv_cv_leave_handler_siglongjmp_sigaltstack=no
sv_cv_macro_pagesize=no
sv_cv_procfsvma=no
sv_cv_sigaltstack=no
sv_cv_stack_direction=-1
sv_cv_stack_direction_msg='grows down'

## ------------ ##
## confdefs.h.  ##
## ------------ ##

#define PACKAGE "libsigsegv"
#define VERSION "1.96"
#define CFG_SIGNALS "signals.h"
#define HAVE_UNISTD_H 1
#define CFG_FAULT "fault-beos-i386.h"
#define STACK_DIRECTION -1
#define CFG_STACKVMA "stackvma-beos.c"
#define CFG_LEAVE "leave-nop.c"
#define CFG_HANDLER "handler-unix.c"


configure: exit 0
