1 dnl Process this file with autoconf to produce a configure script for gzip
3 dnl Same as AC_RETSIGTYPE, but use a void default.
6 [AC_COMPILE_CHECK([return type of signal handlers],
7 [#include <sys/types.h>
12 extern void (*signal ()) ();],
15 [AC_DEFINE(RETSIGTYPE, int)],
19 dnl End of local macros
25 dnl Try to assemble match.S with and without leading underline.
26 dnl cc -E produces incorrect asm files on SVR4, we must use /lib/cpp.
27 dnl Also, "gcc -E match.s" ignores -E, so we must use match.S.
28 echo checking for underline in external names
29 test -z "$ASCPP" -a -f /lib/cpp && ASCPP=/lib/cpp
30 test -z "$ASCPP" && ASCPP="$CC -E"
31 cat > conftest.c <<EOF
34 eval "$CC -c conftest.c > /dev/null 2>&1"
35 if nm conftest.o | grep _foo > /dev/null 2>&1 ; then
38 ASCPP="${ASCPP} -DNO_UNDERLINE"
40 rm -f _match.o conftest.c conftest.o
41 if echo "$DEFS" | grep NO_ASM >/dev/null; then
44 echo checking for assembler
46 if eval "$ASCPP $srcdir/match.S > _match.s 2>/dev/null"; then
47 if test ! -s _match.s || grep error < _match.s > /dev/null; then
49 elif eval "$CC -c _match.s >/dev/null 2>&1" && test -f _match.o; then
54 rm -f _match.s _match.o
63 dnl if STDC_HEADERS can't be defined, look for special files:
64 AC_HEADER_CHECK(string.h, ,AC_DEFINE(NO_STRING_H))
65 AC_HEADER_CHECK(stdlib.h, ,AC_DEFINE(NO_STDLIB_H))
66 AC_HEADER_CHECK(memory.h, ,AC_DEFINE(NO_MEMORY_H))
67 AC_HEADER_CHECK(fcntl.h, ,AC_DEFINE(NO_FCNTL_H))
68 AC_HEADER_CHECK(time.h, ,AC_DEFINE(NO_TIME_H))
69 AC_HAVE_HEADERS(unistd.h)
71 AC_HEADER_CHECK(utime.h, utime=1 ,AC_DEFINE(NO_UTIME_H))
72 if test $utime -eq 0; then
73 AC_HAVE_HEADERS(sys/utime.h)
79 AC_HEADER_EGREP(off_t, sys/types.h, ,AC_DEFINE(NO_OFF_T))
80 AC_HAVE_POUNDBANG([SEDCMD="1d"], [SEDCMD=""])
82 if test -z "$G" -a -n "$prefix" -a -f $prefix/bin/gznew; then
85 if test -z "$ZCAT"; then
86 if test -n "$prefix" -a -f $prefix/bin/gzcat; then