(Variables/Recursion): Fix typo.
[make.git] / configure.in
blob655c4eb5af555333eb872c5f5a5a4028d5448df2
1 dnl Process this file with autoconf to produce a configure script.
2 AC_REVISION([$Id: configure.in,v 1.37 1994/06/04 05:11:12 roland Beta $])
3 AC_INIT(vpath.c)                dnl A distinctive file to look for in srcdir.
4 AC_CONFIG_HEADER(config.h)
6 # We want these before the checks, so the checks can modify their values.
7 test -z "$CFLAGS" && CFLAGS=-g AC_SUBST(CFLAGS)
8 test -z "$LDFLAGS" && LDFLAGS=-g AC_SUBST(LDFLAGS)
10 AC_SET_MAKE
11 AC_PROG_CC
12 AC_PROG_INSTALL
13 AC_PROG_RANLIB
14 AC_PROG_CPP                     dnl Later checks need this.
15 AC_AIX
16 AC_ISC_POSIX
17 AC_MINIX
18 AC_STDC_HEADERS
19 AC_DIR_HEADER
20 AC_UID_T                        dnl Also does gid_t.
21 AC_GETGROUPS_T
22 AC_PID_T
23 AC_RETSIGTYPE
24 AC_HAVE_HEADERS(unistd.h limits.h sys/param.h fcntl.h string.h memory.h \
25                 sys/timeb.h)
26 AC_MINUS_C_MINUS_O
27 AC_CONST                        dnl getopt needs this.
28 AC_STAT_MACROS_BROKEN
30 AC_SUBST(LIBOBJS)
32 AC_HAVE_FUNCS(getdtablesize psignal \
33               dup2 getcwd sigsetmask getgroups setlinebuf \
34               seteuid setegid setreuid setregid strerror)
35 AC_COMPILE_CHECK(sys_siglist, ,
36    [extern char *sys_siglist[]; puts(*sys_siglist);],
37    AC_DEFINE(HAVE_SYS_SIGLIST))
38 AC_COMPILE_CHECK(_sys_siglist, ,
39    [extern char *_sys_siglist[]; puts(*_sys_siglist);],
40    AC_DEFINE(HAVE__SYS_SIGLIST))
41 AC_ALLOCA
42 AC_VFORK
43 AC_SETVBUF_REVERSED
44 AC_GETLOADAVG
45 AC_STRCOLL
47 dnl Check out the wait reality.
48 AC_HAVE_HEADERS(sys/wait.h) AC_HAVE_FUNCS(waitpid wait3)
49 AC_COMPILE_CHECK(union wait, [#include <sys/types.h>
50 #include <sys/wait.h>],
51                  [union wait status; int pid; pid = wait (&status);
52 #ifdef WEXITSTATUS
53 /* Some POSIXoid systems have both the new-style macros and the old
54    union wait type, and they do not work together.  If union wait
55    conflicts with WEXITSTATUS et al, we don't want to use it at all.  */
56 if (WEXITSTATUS (status) != 0) pid = -1;
57 #endif
58 #ifdef HAVE_WAITPID
59 /* Make sure union wait works with waitpid.  */
60 pid = waitpid (-1, &status, 0);
61 #endif
63                  AC_DEFINE(HAVE_UNION_WAIT))
65 AC_SYS_SIGLIST_DECLARED
67 # The presence of the following is not meant to imply
68 # that make necessarily works on those systems.
69 AC_DYNIX_SEQ
70 AC_XENIX_DIR
71 AC_IRIX_SUN
73 AC_SUBST(REMOTE) REMOTE=stub
74 AC_WITH(customs, [REMOTE=cstms
75 LIBS="$LIBS libcustoms.a"])
77 echo checking for location of SCCS get command
78 if test -f /usr/sccs/get; then
79   SCCS_GET=/usr/sccs/get
80   AC_DEFINE(SCCS_GET, "/usr/sccs/get")
81 else
82   SCCS_GET=get
83   AC_DEFINE(SCCS_GET, "get")
85 ac_clean_files="$ac_clean_files s.conftest conftoast" # Remove these later.
86 if ( /usr/sccs/admin -n s.conftest || admin -n s.conftest ) >/dev/null 2>&1 &&
87    test -f s.conftest; then
88   # We successfully created an SCCS file.
89   echo checking if SCCS get command understands -G
90   if $SCCS_GET -Gconftoast s.conftest >/dev/null 2>&1 &&
91      test -f conftoast; then
92     AC_DEFINE(SCCS_GET_MINUS_G)
93   fi
95 rm -f s.conftest conftoast
97 AC_OUTPUT(Makefile build.sh glob/Makefile, [
98 # Makefile uses this timestamp file to know when to remake Makefile,
99 # build.sh, and glob/Makefile.
100 touch stamp-config])
102 dnl Local Variables:
103 dnl comment-start: "dnl "
104 dnl comment-end: ""
105 dnl comment-start-skip: "\\bdnl\\b\\s *"
106 dnl compile-command: "make configure config.h.in"
107 dnl End: