]> arthur.barton.de Git - netatalk.git/blob - configure.in
Removed legacy DEBUG declarations
[netatalk.git] / configure.in
1 dnl configure.in for netatalk
2
3 AC_INIT(bin/adv1tov2/adv1tov2.c)
4
5 NETATALK_VERSION=`cat VERSION`
6 AC_SUBST(NETATALK_VERSION)
7
8 AC_CANONICAL_SYSTEM
9 AM_INIT_AUTOMAKE(netatalk, ${NETATALK_VERSION})
10 AM_CONFIG_HEADER(config.h)
11
12 dnl Reset locations to proper places
13 AC_PREFIX_DEFAULT(/usr)
14
15 dnl Checks for programs.
16 AC_PROG_AWK
17 AC_PROG_CC
18 AC_PROG_INSTALL
19 AC_PROG_LN_S
20 AC_PROG_MAKE_SET
21 AC_PROG_LIBTOOL
22
23 dnl *********************************************************************
24 dnl FIXME! FIXME! These should be selectable properly, and should produce
25 dnl the proper flags and defines...
26 dnl *********************************************************************
27
28 dnl Checks for libraries.
29 dnl Replace `main' with a function in -labs:
30 AC_CHECK_LIB(abs, main)
31 dnl Replace `main' with a function in -latalk:
32 dnl (internal) AC_CHECK_LIB(atalk, main)
33 dnl Replace `main' with a function in -laudit:
34 AC_CHECK_LIB(audit, main)
35 dnl Replace `main' with a function in -lauth:
36 AC_CHECK_LIB(auth, main)
37 dnl Replace `main' with a function in -lcmd:
38 AC_CHECK_LIB(cmd, main)
39 dnl Replace `main' with a function in -lcom_err:
40 AC_CHECK_LIB(com_err, main)
41 dnl Replace `main' with a function in -lcrypt:
42 AC_CHECK_LIB(crypt, main)
43 dnl Replace `main' with a function in -lcrypto:
44 AC_CHECK_LIB(crypto, main)
45 dnl Replace `main' with a function in -ld:
46 AC_CHECK_LIB(d, main)
47 dnl Replace `main' with a function in -ldb:
48 AC_CHECK_LIB(db, main)
49 dnl Replace `main' with a function in -ldes:
50 AC_CHECK_LIB(des, main)
51 dnl Replace `main' with a function in -ldl:
52 AC_CHECK_LIB(dl, main)
53 dnl Replace `main' with a function in -lkauth:
54 AC_CHECK_LIB(kauth, main)
55 dnl Replace `main' with a function in -lkrb:
56 AC_CHECK_LIB(krb, main)
57 dnl Replace `main' with a function in -llwp:
58 AC_CHECK_LIB(lwp, main)
59 dnl Replace `main' with a function in -ln:
60 AC_CHECK_LIB(n, main)
61 dnl Replace `main' with a function in -lnsl:
62 AC_CHECK_LIB(nsl, main)
63 dnl Replace `main' with a function in -lprot:
64 AC_CHECK_LIB(prot, main)
65 dnl Replace `main' with a function in -lresolv:
66 AC_CHECK_LIB(resolv, main)
67 dnl Replace `main' with a function in -lrpcsvc:
68 AC_CHECK_LIB(rpcsvc, main)
69 dnl Replace `main' with a function in -lrx:
70 AC_CHECK_LIB(rx, main)
71 dnl Replace `main' with a function in -lrxkad:
72 AC_CHECK_LIB(rxkad, main)
73 dnl Replace `main' with a function in -lsocket:
74 AC_CHECK_LIB(socket, main)
75 dnl Replace `main' with a function in -lsys:
76 AC_CHECK_LIB(sys, main)
77 dnl Replace `main' with a function in -lubik:
78 AC_CHECK_LIB(ubik, main)
79
80 dnl Checks for header files.
81 AC_HEADER_DIRENT
82 AC_HEADER_STDC
83 AC_HEADER_SYS_WAIT
84 AC_CHECK_HEADERS(fcntl.h limits.h strings.h sys/file.h sys/ioctl.h sys/time.h syslog.h unistd.h)
85
86 dnl Checks for typedefs, structures, and compiler characteristics.
87 AC_C_CONST
88 AC_TYPE_UID_T
89 AC_C_INLINE
90 AC_TYPE_MODE_T
91 AC_TYPE_OFF_T
92 AC_TYPE_PID_T
93 AC_TYPE_SIZE_T
94 AC_STRUCT_ST_RDEV
95 AC_HEADER_TIME
96 AC_STRUCT_TM
97
98 dnl Checks for library functions.
99 AC_TYPE_GETGROUPS
100 AC_PROG_GCC_TRADITIONAL
101 AC_FUNC_MEMCMP
102 AC_HEADER_MAJOR
103 AC_FUNC_MMAP
104 AC_TYPE_SIGNAL
105 AC_FUNC_UTIME_NULL
106 AC_FUNC_WAIT3
107 AC_CHECK_FUNCS(getcwd gethostname gettimeofday getusershell mkdir rmdir select socket strdup strstr strtoul)
108
109 dnl --------------------------------------------------------------------------
110 dnl specific configuration comes in here:
111 dnl --------------------------------------------------------------------------
112
113 AC_ARG_ENABLE(config-dir,
114         [  --with-config-dir=path  path to config files (default is /etc/atalk)],
115                 config_dir="$withval", config_dir="/etc/atalk")
116 AC_DEFINE_UNQUOTED(CONFIG_DIR, "$config_dir",
117         [path to config dir (default is /etc/atalk)])
118 CONFIG_DIR="$config_dir"
119 AC_SUBST(CONFIG_DIR)
120
121 AC_ARG_WITH(cracklib,
122         [  --with-cracklib         enable cracklib checking support],
123         AC_CHECK_LIB(crack, main, AC_DEFINE(USE_CRACKLIB))
124 )
125
126 AC_ARG_ENABLE(debug,
127         [  --enable-debug          enable debug code],
128         AC_DEFINE(DEBUG)
129 )
130
131 AC_ARG_WITH(pam,
132         [  --with-pam              enable password authentication modules support],
133         AC_CHECK_LIB(pam, main, AC_DEFINE(USE_PAM))
134 )
135
136 AC_ARG_WITH(shadow,
137         [  --with-shadow           enable shadow password support],
138         AC_MSG_RESULT([Enabling shadow password support.])
139         AC_DEFINE(SHADOWPW)
140 )
141
142 AC_ARG_WITH(flock-locks,
143         [  --with-flock-locks      enable flock locks support],
144         AC_MSG_RESULT([Enabling flock locks.])
145         AC_DEFINE(USE_FLOCK_LOCKS)
146 )
147
148 AC_ARG_WITH(tcp-wrappers,
149         [  --with-tcp-wrappers     enable TCP wrappers support],
150         AC_CHECK_LIB(wrap, main, AC_DEFINE(TCPWRAP))
151 )
152
153 AC_ARG_WITH(uams-path,
154         [  --with-uams-path=path   path to UAMs (default is /etc/atalk/uams)],
155                 uams_path="$withval", uams_path="/etc/atalk/uams")
156 AC_DEFINE_UNQUOTED(UAMS_PATH, "$uams_path",
157         [path to UAMs (default is /etc/atalk/uams)])
158 UAMS_PATH="$uams_path"
159 AC_SUBST(UAMS_PATH)
160
161 dnl --------------------------------------------------------------------------
162 dnl specific configuration comes in here:
163 dnl --------------------------------------------------------------------------
164
165 dnl --------------------- determine operating system from "target"
166 case "$target" in
167 *linux*)   this_os=linux ;;
168 *solaris*) this_os=solaris ;;
169 esac
170
171 dnl --------------------- conditional libraries, etc from "target"
172
173 dnl List of Makefiles to generate
174
175 AC_OUTPUT([Makefile
176         bin/Makefile
177         bin/adv1tov2/Makefile
178         bin/aecho/Makefile
179         bin/afppasswd/Makefile
180         bin/getzones/Makefile
181         bin/megatron/Makefile
182         bin/nbp/Makefile
183         bin/pap/Makefile
184         bin/psorder/Makefile
185         config/Makefile
186         etc/Makefile
187         etc/afpd/Makefile
188         etc/afpd/nls/Makefile
189         etc/atalkd/Makefile
190         etc/uams/Makefile
191         etc/papd/Makefile
192         etc/psf/Makefile
193         include/Makefile
194         include/atalk/Makefile
195         libatalk/Makefile
196         libatalk/adouble/Makefile
197         libatalk/asp/Makefile
198         libatalk/atp/Makefile
199         libatalk/compat/Makefile
200         libatalk/dsi/Makefile
201         libatalk/nbp/Makefile
202         libatalk/netddp/Makefile
203         libatalk/util/Makefile
204         man/Makefile
205         man/man1/Makefile
206         man/man3/Makefile
207         man/man4/Makefile
208         man/man8/Makefile
209         sys/Makefile
210         sys/netatalk/Makefile
211 ])
212