1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
|
# $Id$
# configure.in for the autofs daemon
#
# Disable caching (the script is tiny, and it doesn't work with --with-path)
# then start autofs
#
define([AC_CACHE_LOAD], )dnl
define([AC_CACHE_SAVE], )dnl
AC_INIT(.autofs-3.1.0)
#
# autofs installs by default in /usr
#
AC_PREFIX_DEFAULT(/usr)
#
# The user can specify --with-path=PATH rather than relying on the default
#
searchpath="/usr/bin:/bin:/usr/sbin:/sbin"
AC_ARG_WITH(path,
--with-path=PATH look in PATH for binaries needed by the automounter,
if test -z "$withval" -o "$withval" = "yes" -o "$withval" = "no"
then
:
else
searchpath="${withval}"
fi
)
AC_MSG_CHECKING([for binaries in])
AC_MSG_RESULT([$searchpath])
#
# Programs needed for various system functions or modules
#
AF_PATH_INCLUDE(MOUNT, mount, /bin/mount, $searchpath)
AF_PATH_INCLUDE(UMOUNT, umount, /bin/umount, $searchpath)
AF_PATH_INCLUDE(E2FSCK, fsck.ext2 e2fsck, , $searchpath)
AF_PATH_INCLUDE(SMBMOUNT, smbmount, , $searchpath)
AC_SUBST(HAVE_SMBMOUNT)
#
# Newer mounts have the -s (sloppy) option to ignore unknown options,
# good for portability
#
AF_SLOPPY_MOUNT()
#
# glibc/libc 6 new libraries
#
AC_CHECK_LIB(nsl, yp_match, LIBNSL="-lnsl")
AC_SUBST(LIBNSL)
AC_CHECK_LIB(resolv, res_query, LIBRESOLV="-lresolv")
AC_SUBST(LIBRESOLV)
#
# Hesiod support? Hesiod is tricky, because it may live in /usr/athena
# or some equally weird place; if so, have the user specify
# --with-hesiod=/usr/athena
#
AF_tmp_ldflags="$LDFLAGS"
AC_ARG_WITH(hesiod,
--with-hesiod=DIR enable Hesiod support (libs and includes in DIR),
if test -z "$withval" -o "$withval" = "yes" -o "$withval" = "no"
then
LIBHESIOD=""
else
LDFLAGS="$LDFLAGS -L${withval}/lib"
LIBHESIOD="-L${withval}/lib"
HESIOD_FLAGS="-I${withval}/include"
fi
)
HAVE_HESIOD=0
AC_CHECK_LIB(hesiod, hes_resolve, HAVE_HESIOD=1 LIBHESIOD="$LIBHESIOD -lhesiod", , $LIBRESOLV)
AC_SUBST(HAVE_HESIOD)
AC_SUBST(LIBHESIOD)
AC_SUBST(HESIOD_FLAGS)
LDFLAGS="${AF_tmp_ldflags}"
# NIS+ support?
HAVE_NISPLUS=0
AC_CHECK_HEADER(rpcsvc/nis.h, HAVE_NISPLUS=1)
AC_SUBST(HAVE_NISPLUS)
#
# Location of init.d directory?
#
AF_INIT_D()
AC_SUBST(initdir)
#
# Write Makefile.conf and include/config.h
#
AC_CONFIG_HEADER(include/config.h)
AC_OUTPUT(Makefile.conf)
#
# Run make clean since we don't explicitly code the header file dependencies
#
AC_OUTPUT_COMMANDS([make clean])
|