1 dnl Process this file with autoconf to produce a configure script.
18 # The 3-argument open happens to go along with the O_* defines,
19 # which are easier to check for.
20 AC_HEADER_CHECK(fcntl.h, open_header=fcntl.h, open_header=sys/file.h)
21 AC_COMPILE_CHECK(3-argument open,
22 [#include <$open_header>], [int x = O_RDONLY;], , AC_DEFINE(EMUL_OPEN3))
27 echo checking for getgrgid declaration
28 AC_HEADER_EGREP(getgrgid, grp.h, AC_DEFINE(HAVE_GETGRGID))
29 echo checking for getpwuid declaration
30 AC_HEADER_EGREP(getpwuid, pwd.h, AC_DEFINE(HAVE_GETPWUID))
31 AC_HAVE_HEADERS(string.h limits.h)
32 echo checking default archive
33 # This might guess wrong, but it's not very important.
34 for dev in rmt8 rmt0 rmt0h rct0 rst0 tape rct/c7d0s2
36 if test -n "`ls /dev/$dev 2>/dev/null`"; then
41 if test -z "$DEF_AR_FILE"; then
45 AC_SUBST(DEF_AR_FILE)dnl
46 AC_HAVE_FUNCS(strstr valloc mkdir mknod rename ftruncate ftime getcwd)
50 ( test -f /vmunix || test -f /sdmach || test -f /../../mach ) && AC_DEFINE(BSD42)
51 echo checking for HP-UX
52 test "`(uname -s) 2> /dev/null`" = 'HP-UX' && MALLOC=malloc.o
55 AC_HAVE_LIBRARY(socket, [LIBS="$LIBS -lsocket"])
56 AC_HAVE_LIBRARY(nsl, [LIBS="$LIBS -lnsl"])