blob: ca433e569ff0193de46c2e8aafb0c8f6ad374fcb [file] [log] [blame]
Damien Millerab18c411999-11-11 10:40:23 +11001AC_INIT(ssh.c)
Damien Miller7f6ea021999-10-28 13:25:17 +10002
3AC_CONFIG_HEADER(config.h)
Damien Miller856799b2000-03-15 21:18:10 +11004AC_PROG_CC
Damien Miller76112de1999-12-21 11:18:08 +11005AC_CANONICAL_HOST
Damien Miller7f6ea021999-10-28 13:25:17 +10006
Damien Millera22ba012000-03-02 23:09:20 +11007# Checks for programs.
Damien Millerab18c411999-11-11 10:40:23 +11008AC_PROG_CPP
Damien Miller7f6ea021999-10-28 13:25:17 +10009AC_PROG_RANLIB
Damien Millerd8087f61999-11-25 12:31:26 +110010AC_PROG_INSTALL
Damien Millerc7b38ce1999-11-09 10:28:04 +110011AC_CHECK_PROG(AR, ar, ar)
Damien Millere79334a1999-12-29 10:03:37 +110012AC_PATH_PROG(PERL, perl)
13AC_SUBST(PERL)
Damien Miller8d1fd572000-05-17 21:34:07 +100014AC_PATH_PROG(ENT, ent)
15AC_SUBST(ENT)
Damien Miller2e1b0821999-12-25 10:11:29 +110016
Damien Miller166bd442000-03-16 10:48:25 +110017if test -z "$LD" ; then
18 LD=$CC
19fi
20AC_SUBST(LD)
21
22# C Compiler features
23AC_C_INLINE
24if test "$GCC" = "yes"; then
25 CFLAGS="$CFLAGS -Wall"
26fi
27
Damien Millera22ba012000-03-02 23:09:20 +110028# Check for some target-specific stuff
Damien Miller76112de1999-12-21 11:18:08 +110029case "$host" in
Damien Miller75b1d102000-01-07 14:01:41 +110030*-*-aix*)
31 AFS_LIBS="-lld"
Damien Millerdb819592000-03-14 13:44:01 +110032 CFLAGS="$CFLAGS -I/usr/local/include"
33 LDFLAGS="$LDFLAGS -L/usr/local/lib"
Damien Milleredb82922000-06-20 13:25:52 +100034 if (test "$LD" != "gcc" && test -z "$blibpath"); then
Damien Miller29ea30d2000-03-17 10:54:15 +110035 blibpath="/usr/lib:/lib:/usr/local/lib"
36 fi
Damien Millerd2c208a2000-05-17 22:00:02 +100037 AC_CHECK_FUNC(authenticate, [AC_DEFINE(WITH_AIXAUTHENTICATE)])
Damien Millereca71f82000-01-20 22:38:27 +110038 AC_DEFINE(BROKEN_GETADDRINFO)
andree441aa32000-06-12 22:34:38 +000039 MANTYPE='$(CATMAN)'
40 mansubdir=cat
andre60f3c982000-06-03 16:18:19 +000041 dnl AIX handles lastlog as part of its login message
42 AC_DEFINE(DISABLE_LASTLOG)
Damien Miller75b1d102000-01-07 14:01:41 +110043 ;;
Damien Miller76112de1999-12-21 11:18:08 +110044*-*-hpux10*)
45 if test -z "$GCC"; then
Damien Millerfda78d92000-05-20 15:33:44 +100046 CFLAGS="$CFLAGS -Ae"
Damien Miller76112de1999-12-21 11:18:08 +110047 fi
48 CFLAGS="$CFLAGS -D_HPUX_SOURCE"
49 AC_DEFINE(IPADDR_IN_DISPLAY)
50 AC_MSG_CHECKING(for HPUX trusted system password database)
51 if test -f /tcb/files/auth/system/default; then
52 AC_MSG_RESULT(yes)
53 AC_DEFINE(HAVE_HPUX_TRUSTED_SYSTEM_PW)
54 LIBS="$LIBS -lsec"
Damien Miller105b7f02000-01-07 08:45:55 +110055 AC_MSG_WARN([This configuration is untested])
Damien Miller76112de1999-12-21 11:18:08 +110056 else
57 AC_MSG_RESULT(no)
58 AC_DEFINE(DISABLE_SHADOW)
59 fi
Damien Miller670a4b82000-01-22 13:53:11 +110060 MANTYPE='$(CATMAN)'
61 mansubdir=cat
Damien Miller76112de1999-12-21 11:18:08 +110062 ;;
Damien Miller1bead332000-04-30 00:47:29 +100063*-*-hpux11*)
64 if test -z "$GCC"; then
65 CFLAGS="$CFLAGS -Ae"
66 fi
67 CFLAGS="$CFLAGS -D_HPUX_SOURCE"
Damien Miller1bead332000-04-30 00:47:29 +100068 AC_DEFINE(IPADDR_IN_DISPLAY)
Damien Miller1bead332000-04-30 00:47:29 +100069 AC_MSG_CHECKING(for HPUX trusted system password database)
70 if test -f /tcb/files/auth/system/default; then
71 AC_MSG_RESULT(yes)
72 AC_DEFINE(HAVE_HPUX_TRUSTED_SYSTEM_PW)
73 LIBS="$LIBS -lsec"
74 AC_MSG_WARN([This configuration is untested])
75 else
76 AC_MSG_RESULT(no)
77 AC_DEFINE(DISABLE_SHADOW)
78 fi
79 MANTYPE='$(CATMAN)'
80 mansubdir=cat
81 ;;
Damien Millerbeb4ba51999-12-28 15:09:35 +110082*-*-irix5*)
Damien Millerdb819592000-03-14 13:44:01 +110083 CFLAGS="$CFLAGS -I/usr/local/include"
Damien Miller9e110892000-06-07 21:05:46 +100084 LDFLAGS="$LDFLAGS"
Damien Miller07278932000-01-22 14:05:37 +110085 MANTYPE='$(CATMAN)'
Damien Miller1808f382000-01-06 12:03:12 +110086 no_libsocket=1
87 no_libnsl=1
88 ;;
89*-*-irix6*)
Damien Millerdb819592000-03-14 13:44:01 +110090 CFLAGS="$CFLAGS -I/usr/local/include"
Damien Miller9e110892000-06-07 21:05:46 +100091 LDFLAGS="$LDFLAGS"
Damien Miller07278932000-01-22 14:05:37 +110092 MANTYPE='$(CATMAN)'
93 AC_MSG_WARN([*** Irix 6.x is not tested, please report you experiences *** ])
Damien Millerbeb4ba51999-12-28 15:09:35 +110094 no_libsocket=1
95 no_libnsl=1
96 ;;
Damien Millerb29ea912000-01-15 14:12:03 +110097*-*-linux*)
98 no_dev_ptmx=1
Damien Miller7bcb0892000-03-11 20:45:40 +110099 AC_DEFINE(DONT_TRY_OTHER_AF)
100 inet6_default_4in6=yes
Damien Millerb29ea912000-01-15 14:12:03 +1100101 ;;
Damien Milleree1c0b32000-01-21 00:18:15 +1100102*-*-netbsd*)
Damien Millera22ba012000-03-02 23:09:20 +1100103 need_dash_r=1
Damien Milleree1c0b32000-01-21 00:18:15 +1100104 ;;
Damien Miller0f91b4e2000-06-18 15:43:25 +1000105*-next-*)
106 # hardwire lastlog location (can't detect it on some versions)
107 conf_lastlog_location="/usr/adm/lastlog"
108 AC_DEFINE(HAVE_NEXT)
109 CFLAGS="$CFLAGS -I/usr/local/include"
110 MAIL=/usr/spool/mail
111 conf_utmp_location=/etc/utmp
112 AC_MSG_WARN([*** Tested: PA-RISC/m68k Untested: Sparc/Intel])
113 AC_MSG_WARN([*** Expect 'scp' to fail!])
114 AC_MSG_WARN([*** Please report any problems, thanks])
115 ;;
Damien Miller75b1d102000-01-07 14:01:41 +1100116*-*-solaris*)
Damien Millerdb819592000-03-14 13:44:01 +1100117 CFLAGS="$CFLAGS -I/usr/local/include"
Damien Miller08c788a2000-03-16 07:52:29 +1100118 LDFLAGS="$LDFLAGS -L/usr/local/lib -R/usr/local/lib -L/usr/ucblib -R/usr/ucblib"
Damien Millera22ba012000-03-02 23:09:20 +1100119 need_dash_r=1
andre2ff7b5d2000-06-03 14:57:40 +0000120 # hardwire lastlog location (can't detect it on some versions)
121 conf_lastlog_location="/var/adm/lastlog"
Damien Millera1cb6442000-06-09 11:58:35 +1000122 AC_MSG_CHECKING(for obsolete utmp and wtmp in solaris2.x)
123 sol2ver=`echo "$host"| sed -e 's/.*[[0-9]]\.//'`
124 if test "$sol2ver" -ge 8; then
125 AC_MSG_RESULT(yes)
126 AC_DEFINE(DISABLE_UTMP)
127 AC_DEFINE(DISABLE_WTMP)
128 else
129 AC_MSG_RESULT(no)
130 fi
Damien Miller75b1d102000-01-07 14:01:41 +1100131 ;;
Damien Millerdfc83f42000-05-20 15:02:59 +1000132*-*-sunos4*)
133 CFLAGS="$CFLAGS -DSUNOS4"
134 AC_CHECK_FUNCS(getpwanam)
135 ;;
Damien Miller75b1d102000-01-07 14:01:41 +1100136*-*-sysv*)
Damien Millerdb819592000-03-14 13:44:01 +1100137 CFLAGS="$CFLAGS -I/usr/local/include"
138 LDFLAGS="$LDFLAGS -L/usr/local/lib"
Damien Miller0e1cf7c2000-01-26 12:15:30 +1100139 MANTYPE='$(CATMAN)'
140 mansubdir=cat
Damien Miller75b1d102000-01-07 14:01:41 +1100141 LIBS="$LIBS -lgen -lsocket"
142 ;;
Damien Millera66626b2000-06-13 18:57:53 +1000143*-*-sco3*)
144 CFLAGS="$CFLAGS -I/usr/local/include"
145 LDFLAGS="$LDFLAGS -L/usr/local/lib"
146 MANTYPE='$(CATMAN)'
147 mansubdir=cat
148 LIBS="$LIBS -lgen -lsocket"
149 no_dev_ptmx=1
150 ;;
Damien Miller76112de1999-12-21 11:18:08 +1100151esac
152
Damien Millere37bfc12000-06-05 09:37:43 +1000153# Allow user to specify flags
154AC_ARG_WITH(cflags,
155 [ --with-cflags Specify additional flags to pass to compiler],
156 [
157 if test "x$withval" != "xno" ; then
158 CFLAGS="$CFLAGS $withval"
159 fi
160 ]
161)
162AC_ARG_WITH(ldflags,
163 [ --with-ldlags Specify additional flags to pass to linker],
164 [
165 if test "x$withval" != "xno" ; then
166 LDFLAGS="$LDFLAGS $withval"
167 fi
168 ]
169)
170AC_ARG_WITH(libs,
171 [ --with-libs Specify additional libraries to link with],
172 [
173 if test "x$withval" != "xno" ; then
174 LIBS="$LIBS $withval"
175 fi
176 ]
177)
178
179
Damien Millera22ba012000-03-02 23:09:20 +1100180# Checks for libraries.
Damien Millerab18c411999-11-11 10:40:23 +1100181AC_CHECK_LIB(z, deflate, ,AC_MSG_ERROR([*** zlib missing - please install first ***]))
182AC_CHECK_LIB(util, login, AC_DEFINE(HAVE_LIBUTIL_LOGIN) LIBS="$LIBS -lutil")
Damien Millerab18c411999-11-11 10:40:23 +1100183
Damien Millerbeb4ba51999-12-28 15:09:35 +1100184if test -z "$no_libsocket" ; then
185 AC_CHECK_LIB(nsl, yp_match, , )
186fi
187if test -z "$no_libnsl" ; then
188 AC_CHECK_LIB(socket, main, , )
Damien Miller32b3cf21999-12-26 10:21:48 +1100189fi
Damien Millerab18c411999-11-11 10:40:23 +1100190
Damien Millera22ba012000-03-02 23:09:20 +1100191# Checks for header files.
Damien Miller0f91b4e2000-06-18 15:43:25 +1000192AC_CHECK_HEADERS(bstring.h endian.h lastlog.h limits.h login.h maillock.h netdb.h netgroup.h netinet/in_systm.h paths.h poll.h pty.h shadow.h security/pam_appl.h sys/bitypes.h sys/bsdtty.h sys/cdefs.h sys/poll.h sys/select.h sys/stat.h sys/stropts.h sys/sysmacros.h sys/time.h sys/ttcompat.h stddef.h time.h util.h utmp.h utmpx.h)
Damien Millerab18c411999-11-11 10:40:23 +1100193
Damien Millera22ba012000-03-02 23:09:20 +1100194# Checks for library functions.
andre2ff7b5d2000-06-03 14:57:40 +0000195AC_CHECK_FUNCS(arc4random atexit b64_ntop bcopy bindresvport_af clock freeaddrinfo gai_strerror getaddrinfo getnameinfo getrusage innetgr md5_crypt memmove mkdtemp on_exit openpty rresvport_af setenv seteuid setlogin setproctitle setreuid snprintf strlcat strlcpy vsnprintf vhangup _getpty __b64_ntop)
196dnl checks for time functions
197AC_CHECK_FUNCS(gettimeofday time)
198dnl checks for libutil functions
199AC_CHECK_FUNCS(login logout updwtmp logwtmp)
200dnl checks for utmp functions
201AC_CHECK_FUNCS(entutent getutent getutid getutline pututline setutent)
202AC_CHECK_FUNCS(utmpname)
203dnl checks for utmpx functions
204AC_CHECK_FUNCS(entutxent getutxent getutxid getutxline pututxline )
205AC_CHECK_FUNCS(setutxent utmpxname)
Damien Millercedfecc1999-11-15 14:36:53 +1100206
Damien Miller04f80141999-11-19 15:32:34 +1100207AC_CHECK_FUNC(login,
208 [AC_DEFINE(HAVE_LOGIN)],
209 [AC_CHECK_LIB(bsd, login, [LIBS="$LIBS -lbsd"; AC_DEFINE(HAVE_LOGIN)])]
210)
211
212AC_CHECK_FUNC(daemon,
213 [AC_DEFINE(HAVE_DAEMON)],
214 [AC_CHECK_LIB(bsd, daemon, [LIBS="$LIBS -lbsd"; AC_DEFINE(HAVE_DAEMON)])]
215)
216
Damien Miller9fb07e42000-03-05 16:22:59 +1100217AC_CHECK_FUNC(getpagesize,
218 [AC_DEFINE(HAVE_GETPAGESIZE)],
219 [AC_CHECK_LIB(ucb, getpagesize, [LIBS="$LIBS -lucb"; AC_DEFINE(HAVE_GETPAGESIZE)])]
220)
221
Damien Miller7b22d652000-06-18 14:07:04 +1000222PAM_MSG="no"
Damien Millera22ba012000-03-02 23:09:20 +1100223AC_ARG_WITH(pam,
224 [ --without-pam Disable PAM support ],
225 [
226 if test "x$withval" = "xno" ; then
227 no_pam=1
228 AC_DEFINE(DISABLE_PAM)
Damien Miller7b22d652000-06-18 14:07:04 +1000229 PAM_MSG="disabled"
Damien Millera22ba012000-03-02 23:09:20 +1100230 fi
231 ]
232)
Damien Milleredb82922000-06-20 13:25:52 +1000233if (test -z "$no_pam" && test "x$ac_cv_header_security_pam_appl_h" = "xyes") ; then
Damien Millera22ba012000-03-02 23:09:20 +1100234 AC_CHECK_LIB(dl, dlopen, , )
235 LIBS="$LIBS -lpam"
236
Damien Miller0e65eed2000-05-17 22:16:05 +1000237 AC_CHECK_FUNCS(pam_getenvlist)
Damien Miller1bead332000-04-30 00:47:29 +1000238
Damien Miller1f335fb2000-06-26 11:31:33 +1000239 disable_shadow=yes
240
Damien Miller7b22d652000-06-18 14:07:04 +1000241 PAM_MSG="yes"
242
Damien Millera22ba012000-03-02 23:09:20 +1100243 # Check PAM strerror arguments (old PAM)
244 AC_MSG_CHECKING([whether pam_strerror takes only one argument])
245 AC_TRY_COMPILE(
246 [
Damien Miller81171112000-04-23 11:14:01 +1000247#include <stdlib.h>
248#include <security/pam_appl.h>
Damien Millera22ba012000-03-02 23:09:20 +1100249 ],
250 [(void)pam_strerror((pam_handle_t *)NULL, -1);],
251 [AC_MSG_RESULT(no)],
252 [
253 AC_DEFINE(HAVE_OLD_PAM)
254 AC_MSG_RESULT(yes)
Damien Miller7b22d652000-06-18 14:07:04 +1000255 PAM_MSG="yes (old library)"
Damien Millera22ba012000-03-02 23:09:20 +1100256 ]
257 )
258fi
259
260# The big search for OpenSSL
261AC_ARG_WITH(ssl-dir,
262 [ --with-ssl-dir=PATH Specify path to OpenSSL installation ],
263 [
264 if test "x$withval" != "$xno" ; then
265 tryssldir=$withval
266 fi
267 ]
268)
269
270saved_LIBS="$LIBS"
Damien Millera1ad4802000-03-15 10:04:54 +1100271saved_LDFLAGS="$LDFLAGS"
Damien Millera22ba012000-03-02 23:09:20 +1100272saved_CFLAGS="$CFLAGS"
273if test "x$prefix" != "xNONE" ; then
274 tryssldir="$tryssldir $prefix"
275fi
Damien Miller61e50f12000-05-08 20:49:37 +1000276AC_CACHE_CHECK([for OpenSSL directory], ac_cv_openssldir, [
Damien Millera22ba012000-03-02 23:09:20 +1100277
Damien Miller61e50f12000-05-08 20:49:37 +1000278 for ssldir in "" $tryssldir /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do
279 if test ! -z "$ssldir" ; then
280 LDFLAGS="$saved_LDFLAGS -L$ssldir/lib -L$ssldir"
281 CFLAGS="$saved_CFLAGS -I$ssldir/include"
282 if test ! -z "$need_dash_r" ; then
283 LDFLAGS="$LDFLAGS -R$ssldir/lib -R$ssldir"
284 fi
Damien Millera1ad4802000-03-15 10:04:54 +1100285 else
Damien Miller61e50f12000-05-08 20:49:37 +1000286 LDFLAGS="$saved_LDFLAGS"
Damien Millerb85dcad2000-03-11 11:37:00 +1100287 fi
288
Damien Miller3b512e12000-05-17 23:29:18 +1000289 LIBS="$saved_LIBS -lcrypto"
Damien Miller61e50f12000-05-08 20:49:37 +1000290
Damien Miller3b512e12000-05-17 23:29:18 +1000291 # Basic test to check for compatible version and correct linking
292 # *does not* test for RSA - that comes later.
293 AC_TRY_RUN(
294 [
Damien Millere59ce622000-05-01 20:54:17 +1000295#include <string.h>
296#include <openssl/rand.h>
Damien Miller81171112000-04-23 11:14:01 +1000297int main(void)
298{
Damien Miller3b512e12000-05-17 23:29:18 +1000299 char a[2048];
300 memset(a, 0, sizeof(a));
Damien Miller81171112000-04-23 11:14:01 +1000301 RAND_add(a, sizeof(a), sizeof(a));
Damien Miller3b512e12000-05-17 23:29:18 +1000302 return(RAND_status() <= 0);
Damien Miller81171112000-04-23 11:14:01 +1000303}
Damien Miller3b512e12000-05-17 23:29:18 +1000304 ],
305 [
306 found_crypto=1
307 break;
308 ], []
309 )
Damien Miller61e50f12000-05-08 20:49:37 +1000310
311 if test ! -z "$found_crypto" ; then
312 break;
313 fi
Damien Millerb85dcad2000-03-11 11:37:00 +1100314 done
315
Damien Miller61e50f12000-05-08 20:49:37 +1000316 if test -z "$found_crypto" ; then
317 AC_MSG_ERROR([Could not find working SSLeay / OpenSSL libraries, please install])
Damien Millerb85dcad2000-03-11 11:37:00 +1100318 fi
Damien Miller61e50f12000-05-08 20:49:37 +1000319 if test -z "$ssldir" ; then
320 ssldir="(system)"
321 fi
Damien Millera22ba012000-03-02 23:09:20 +1100322
Damien Miller61e50f12000-05-08 20:49:37 +1000323 ac_cv_openssldir=$ssldir
324])
325
Damien Milleredb82922000-06-20 13:25:52 +1000326if (test ! -z "$ac_cv_openssldir" && test "x$ac_cv_openssldir" != "x(system)") ; then
Damien Miller61e50f12000-05-08 20:49:37 +1000327 AC_DEFINE(HAVE_OPENSSL)
328 dnl Need to recover ssldir - test above runs in subshell
329 ssldir=$ac_cv_openssldir
Damien Millera1ad4802000-03-15 10:04:54 +1100330 CFLAGS="$saved_CFLAGS -I$ssldir/include"
331 LDFLAGS="$saved_LDFLAGS -L$ssldir/lib -L$ssldir"
332 if test ! -z "$need_dash_r" ; then
333 LDFLAGS="$LDFLAGS -R$ssldir/lib -R$ssldir"
Damien Millera22ba012000-03-02 23:09:20 +1100334 fi
Damien Miller29ea30d2000-03-17 10:54:15 +1100335 if test ! -z "$blibpath" ; then
336 blibpath="$blibpath:$ssldir:$ssldir/lib"
337 fi
Damien Millera22ba012000-03-02 23:09:20 +1100338fi
Damien Miller3b512e12000-05-17 23:29:18 +1000339LIBS="$saved_LIBS -lcrypto"
Damien Miller61e50f12000-05-08 20:49:37 +1000340
Damien Miller3b512e12000-05-17 23:29:18 +1000341# Now test RSA support
342saved_LIBS="$LIBS"
343AC_MSG_CHECKING([for RSA support])
344for WANTS_RSAREF in "" 1 ; do
345 if test -z "$WANTS_RSAREF" ; then
346 LIBS="$saved_LIBS"
347 else
348 LIBS="$saved_LIBS -lRSAglue -lrsaref"
349 fi
350 AC_TRY_RUN([
351#include <string.h>
352#include <openssl/rand.h>
353#include <openssl/rsa.h>
354#include <openssl/bn.h>
355#include <openssl/sha.h>
356int main(void)
357{
358 int num; RSA *key; static unsigned char p_in[] = "blahblah";
359 unsigned char c[256], p[256];
360 memset(c, 0, sizeof(c)); RAND_add(c, sizeof(c), sizeof(c));
361 if ((key=RSA_generate_key(512, 3, NULL, NULL))==NULL) return(1);
362 num = RSA_public_encrypt(sizeof(p_in) - 1, p_in, c, key, RSA_PKCS1_PADDING);
363 return(-1 == RSA_private_decrypt(num, c, p, key, RSA_PKCS1_PADDING));
364}
365 ],
366 [
367 rsa_works=1
368 break;
369 ], [])
370done
371
372if test ! -z "$no_rsa" ; then
373 AC_MSG_RESULT(disabled)
Damien Miller7b22d652000-06-18 14:07:04 +1000374 RSA_MSG="disabled"
Damien Miller3b512e12000-05-17 23:29:18 +1000375else
376 if test -z "$rsa_works" ; then
377 AC_MSG_WARN([*** No RSA support found *** ])
Damien Miller7b22d652000-06-18 14:07:04 +1000378 RSA_MSG="no"
Damien Miller3b512e12000-05-17 23:29:18 +1000379 else
380 if test -z "$WANTS_RSAREF" ; then
381 AC_MSG_RESULT(yes)
Damien Miller7b22d652000-06-18 14:07:04 +1000382 RSA_MSG="yes"
Damien Miller3b512e12000-05-17 23:29:18 +1000383 else
Damien Miller7b22d652000-06-18 14:07:04 +1000384 RSA_MSG="yes (using RSAref)"
Damien Miller3b512e12000-05-17 23:29:18 +1000385 AC_MSG_RESULT(using RSAref)
386 LIBS="$saved_LIBS -lcrypto -lRSAglue -lrsaref"
387 fi
388 fi
389fi
Damien Millera22ba012000-03-02 23:09:20 +1100390
391# Checks for data types
Damien Millere0f45742000-01-18 09:12:06 +1100392AC_CHECK_SIZEOF(char, 1)
Damien Millerc6398ef1999-11-20 12:18:40 +1100393AC_CHECK_SIZEOF(short int, 2)
394AC_CHECK_SIZEOF(int, 4)
395AC_CHECK_SIZEOF(long int, 4)
396AC_CHECK_SIZEOF(long long int, 8)
397
Damien Millera22ba012000-03-02 23:09:20 +1100398# More checks for data types
Damien Miller61e50f12000-05-08 20:49:37 +1000399AC_CACHE_CHECK([for intXX_t types], ac_cv_have_intxx_t, [
400 AC_TRY_COMPILE(
401 [ #include <sys/types.h> ],
402 [ int8_t a; int16_t b; int32_t c; a = b = c = 1;],
403 [ ac_cv_have_intxx_t="yes" ],
404 [ ac_cv_have_intxx_t="no" ]
405 )
406])
407if test "x$ac_cv_have_intxx_t" = "xyes" ; then
408 AC_DEFINE(HAVE_INTXX_T)
409 have_intxx_t=1
410fi
411
412AC_CACHE_CHECK([for u_intXX_t types], ac_cv_have_u_intxx_t, [
413 AC_TRY_COMPILE(
414 [ #include <sys/types.h> ],
415 [ u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1;],
416 [ ac_cv_have_u_intxx_t="yes" ],
417 [ ac_cv_have_u_intxx_t="no" ]
418 )
419])
420if test "x$ac_cv_have_u_intxx_t" = "xyes" ; then
421 AC_DEFINE(HAVE_U_INTXX_T)
422 have_u_intxx_t=1
423fi
Damien Millerc6398ef1999-11-20 12:18:40 +1100424
Damien Millerc6398ef1999-11-20 12:18:40 +1100425
Damien Milleredb82922000-06-20 13:25:52 +1000426if (test -z "$have_u_intxx_t" || test -z "$have_intxx_t" && \
427 test "x$ac_cv_header_sys_bitypes_h" = "xyes")
Damien Millerb29ea912000-01-15 14:12:03 +1100428then
429 AC_MSG_CHECKING([for intXX_t and u_intXX_t types in sys/bitypes.h])
430 AC_TRY_COMPILE(
Damien Miller61e50f12000-05-08 20:49:37 +1000431 [
432#include <sys/bitypes.h>
433 ],
Damien Millerb29ea912000-01-15 14:12:03 +1100434 [
Damien Miller70494d12000-04-03 15:57:06 +1000435 int8_t a; int16_t b; int32_t c;
436 u_int8_t e; u_int16_t f; u_int32_t g;
437 a = b = c = e = f = g = 1;
Damien Millerb29ea912000-01-15 14:12:03 +1100438 ],
439 [
440 AC_DEFINE(HAVE_U_INTXX_T)
441 AC_DEFINE(HAVE_INTXX_T)
442 AC_MSG_RESULT(yes)
443 ],
444 [AC_MSG_RESULT(no)]
445 )
446fi
447
Damien Millerd6121d22000-03-17 23:26:46 +1100448if test -z "$have_u_intxx_t" ; then
Damien Miller61e50f12000-05-08 20:49:37 +1000449 AC_CACHE_CHECK([for uintXX_t types], ac_cv_have_uintxx_t, [
450 AC_TRY_COMPILE(
451 [
452#include <sys/types.h>
453 ],
454 [ uint8_t a; uint16_t b; uint32_t c; a = b = c = 1; ],
455 [ ac_cv_have_uintxx_t="yes" ],
456 [ ac_cv_have_uintxx_t="no" ]
457 )
458 ])
459 if test "x$ac_cv_have_uintxx_t" = "xyes" ; then
460 AC_DEFINE(HAVE_UINTXX_T)
461 fi
Damien Millerd6121d22000-03-17 23:26:46 +1100462fi
Damien Millerc6398ef1999-11-20 12:18:40 +1100463
Damien Miller61e50f12000-05-08 20:49:37 +1000464AC_CACHE_CHECK([for socklen_t], ac_cv_have_socklen_t, [
465 AC_TRY_COMPILE(
466 [
Damien Miller81171112000-04-23 11:14:01 +1000467#include <sys/types.h>
468#include <sys/socket.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000469 ],
470 [socklen_t foo; foo = 1235;],
471 [ ac_cv_have_socklen_t="yes" ],
472 [ ac_cv_have_socklen_t="no" ]
473 )
474])
475if test "x$ac_cv_have_socklen_t" = "xyes" ; then
476 AC_DEFINE(HAVE_SOCKLEN_T)
477fi
Damien Miller74d0d4a1999-12-29 02:24:35 +1100478
Damien Miller61e50f12000-05-08 20:49:37 +1000479AC_CACHE_CHECK([for size_t], ac_cv_have_size_t, [
480 AC_TRY_COMPILE(
481 [
482#include <sys/types.h>
483 ],
484 [ size_t foo; foo = 1235; ],
485 [ ac_cv_have_size_t="yes" ],
486 [ ac_cv_have_size_t="no" ]
487 )
488])
489if test "x$ac_cv_have_size_t" = "xyes" ; then
490 AC_DEFINE(HAVE_SIZE_T)
491fi
Damien Miller95058511999-12-29 10:36:45 +1100492
Damien Miller615f9392000-05-17 22:53:33 +1000493AC_CACHE_CHECK([for ssize_t], ac_cv_have_ssize_t, [
494 AC_TRY_COMPILE(
495 [
496#include <sys/types.h>
497 ],
498 [ ssize_t foo; foo = 1235; ],
499 [ ac_cv_have_ssize_t="yes" ],
500 [ ac_cv_have_ssize_t="no" ]
501 )
502])
503if test "x$ac_cv_have_ssize_t" = "xyes" ; then
504 AC_DEFINE(HAVE_SSIZE_T)
505fi
506
Damien Millerb54b40e2000-06-23 08:23:34 +1000507AC_CACHE_CHECK([for sa_family_t], ac_cv_have_sa_family_t, [
508 AC_TRY_COMPILE(
509 [
510#include <sys/types.h>
511#include <sys/socket.h>
512 ],
513 [ sa_family_t foo; foo = 1235; ],
514 [ ac_cv_have_sa_family_t="yes" ],
515 [ ac_cv_have_sa_family_t="no" ]
516 )
517])
518if test "x$ac_cv_have_sa_family_t" = "xyes" ; then
519 AC_DEFINE(HAVE_SA_FAMILY_T)
520fi
521
Damien Miller0f91b4e2000-06-18 15:43:25 +1000522AC_CACHE_CHECK([for pid_t], ac_cv_have_pid_t, [
523 AC_TRY_COMPILE(
524 [
525#include <sys/types.h>
526 ],
527 [ pid_t foo; foo = 1235; ],
528 [ ac_cv_have_pid_t="yes" ],
529 [ ac_cv_have_pid_t="no" ]
530 )
531])
532if test "x$ac_cv_have_pid_t" = "xyes" ; then
533 AC_DEFINE(HAVE_PID_T)
534fi
535
536AC_CACHE_CHECK([for mode_t], ac_cv_have_mode_t, [
537 AC_TRY_COMPILE(
538 [
539#include <sys/types.h>
540 ],
541 [ mode_t foo; foo = 1235; ],
542 [ ac_cv_have_mode_t="yes" ],
543 [ ac_cv_have_mode_t="no" ]
544 )
545])
546if test "x$ac_cv_have_mode_t" = "xyes" ; then
547 AC_DEFINE(HAVE_MODE_T)
548fi
549
Damien Miller61e50f12000-05-08 20:49:37 +1000550
551AC_CACHE_CHECK([for struct sockaddr_storage], ac_cv_have_struct_sockaddr_storage, [
552 AC_TRY_COMPILE(
553 [
Damien Miller81171112000-04-23 11:14:01 +1000554#include <sys/types.h>
555#include <sys/socket.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000556 ],
557 [ struct sockaddr_storage s; ],
558 [ ac_cv_have_struct_sockaddr_storage="yes" ],
559 [ ac_cv_have_struct_sockaddr_storage="no" ]
560 )
561])
562if test "x$ac_cv_have_struct_sockaddr_storage" = "xyes" ; then
563 AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE)
564fi
Damien Miller34132e52000-01-14 15:45:46 +1100565
Damien Miller61e50f12000-05-08 20:49:37 +1000566AC_CACHE_CHECK([for struct sockaddr_in6], ac_cv_have_struct_sockaddr_in6, [
567 AC_TRY_COMPILE(
568 [
Damien Miller7b22d652000-06-18 14:07:04 +1000569#include <sys/types.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000570#include <netinet/in.h>
571 ],
572 [ struct sockaddr_in6 s; s.sin6_family = 0; ],
573 [ ac_cv_have_struct_sockaddr_in6="yes" ],
574 [ ac_cv_have_struct_sockaddr_in6="no" ]
575 )
576])
577if test "x$ac_cv_have_struct_sockaddr_in6" = "xyes" ; then
578 AC_DEFINE(HAVE_STRUCT_SOCKADDR_IN6)
579fi
Damien Miller34132e52000-01-14 15:45:46 +1100580
Damien Miller61e50f12000-05-08 20:49:37 +1000581AC_CACHE_CHECK([for struct in6_addr], ac_cv_have_struct_in6_addr, [
582 AC_TRY_COMPILE(
583 [
Damien Miller7b22d652000-06-18 14:07:04 +1000584#include <sys/types.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000585#include <netinet/in.h>
586 ],
587 [ struct in6_addr s; s.s6_addr[0] = 0; ],
588 [ ac_cv_have_struct_in6_addr="yes" ],
589 [ ac_cv_have_struct_in6_addr="no" ]
590 )
591])
592if test "x$ac_cv_have_struct_in6_addr" = "xyes" ; then
593 AC_DEFINE(HAVE_STRUCT_IN6_ADDR)
594fi
Damien Miller34132e52000-01-14 15:45:46 +1100595
Damien Miller61e50f12000-05-08 20:49:37 +1000596AC_CACHE_CHECK([for struct addrinfo], ac_cv_have_struct_addrinfo, [
597 AC_TRY_COMPILE(
598 [
Damien Miller81171112000-04-23 11:14:01 +1000599#include <sys/types.h>
600#include <sys/socket.h>
601#include <netdb.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000602 ],
603 [ struct addrinfo s; s.ai_flags = AI_PASSIVE; ],
604 [ ac_cv_have_struct_addrinfo="yes" ],
605 [ ac_cv_have_struct_addrinfo="no" ]
606 )
607])
608if test "x$ac_cv_have_struct_addrinfo" = "xyes" ; then
609 AC_DEFINE(HAVE_STRUCT_ADDRINFO)
610fi
611
Damien Miller34132e52000-01-14 15:45:46 +1100612
Damien Millera22ba012000-03-02 23:09:20 +1100613# Checks for structure members
Damien Miller34132e52000-01-14 15:45:46 +1100614
Damien Miller61e50f12000-05-08 20:49:37 +1000615OSSH_CHECK_HEADER_FOR_FIELD(ut_host, utmp.h, HAVE_HOST_IN_UTMP)
616OSSH_CHECK_HEADER_FOR_FIELD(ut_host, utmpx.h, HAVE_HOST_IN_UTMPX)
617OSSH_CHECK_HEADER_FOR_FIELD(syslen, utmpx.h, HAVE_SYSLEN_IN_UTMPX)
618OSSH_CHECK_HEADER_FOR_FIELD(ut_pid, utmp.h, HAVE_PID_IN_UTMP)
619OSSH_CHECK_HEADER_FOR_FIELD(ut_type, utmp.h, HAVE_TYPE_IN_UTMP)
Damien Millerad1bc5f2000-05-20 14:53:09 +1000620OSSH_CHECK_HEADER_FOR_FIELD(ut_type, utmpx.h, HAVE_TYPE_IN_UTMPX)
Damien Miller61e50f12000-05-08 20:49:37 +1000621OSSH_CHECK_HEADER_FOR_FIELD(ut_tv, utmp.h, HAVE_TV_IN_UTMP)
622OSSH_CHECK_HEADER_FOR_FIELD(ut_id, utmp.h, HAVE_ID_IN_UTMP)
623OSSH_CHECK_HEADER_FOR_FIELD(ut_addr, utmp.h, HAVE_ADDR_IN_UTMP)
624OSSH_CHECK_HEADER_FOR_FIELD(ut_addr, utmpx.h, HAVE_ADDR_IN_UTMPX)
625OSSH_CHECK_HEADER_FOR_FIELD(ut_addr_v6, utmp.h, HAVE_ADDR_V6_IN_UTMP)
626OSSH_CHECK_HEADER_FOR_FIELD(ut_addr_v6, utmpx.h, HAVE_ADDR_V6_IN_UTMPX)
andre2ff7b5d2000-06-03 14:57:40 +0000627OSSH_CHECK_HEADER_FOR_FIELD(ut_exit, utmp.h, HAVE_EXIT_IN_UTMP)
628OSSH_CHECK_HEADER_FOR_FIELD(ut_time, utmp.h, HAVE_TIME_IN_UTMP)
629OSSH_CHECK_HEADER_FOR_FIELD(ut_time, utmpx.h, HAVE_TIME_IN_UTMPX)
630OSSH_CHECK_HEADER_FOR_FIELD(ut_tv, utmpx.h, HAVE_TV_IN_UTMPX)
631
Damien Miller61e50f12000-05-08 20:49:37 +1000632AC_CACHE_CHECK([for ss_family field in struct sockaddr_storage],
633 ac_cv_have_ss_family_in_struct_ss, [
634 AC_TRY_COMPILE(
635 [
Damien Miller81171112000-04-23 11:14:01 +1000636#include <sys/types.h>
637#include <sys/socket.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000638 ],
639 [ struct sockaddr_storage s; s.ss_family = 1; ],
640 [ ac_cv_have_ss_family_in_struct_ss="yes" ],
641 [ ac_cv_have_ss_family_in_struct_ss="no" ],
642 )
643])
644if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then
645 AC_DEFINE(HAVE_SS_FAMILY_IN_SS)
646fi
647
Damien Miller61e50f12000-05-08 20:49:37 +1000648AC_CACHE_CHECK([for __ss_family field in struct sockaddr_storage],
649 ac_cv_have___ss_family_in_struct_ss, [
650 AC_TRY_COMPILE(
651 [
Damien Miller81171112000-04-23 11:14:01 +1000652#include <sys/types.h>
653#include <sys/socket.h>
Damien Miller61e50f12000-05-08 20:49:37 +1000654 ],
655 [ struct sockaddr_storage s; s.__ss_family = 1; ],
656 [ ac_cv_have___ss_family_in_struct_ss="yes" ],
657 [ ac_cv_have___ss_family_in_struct_ss="no" ]
658 )
659])
660if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then
661 AC_DEFINE(HAVE___SS_FAMILY_IN_SS)
662fi
Damien Millerbf1c9b21999-12-09 10:16:54 +1100663
Damien Miller61e50f12000-05-08 20:49:37 +1000664
665AC_CACHE_CHECK([if libc defines __progname], ac_cv_libc_defines___progname, [
666 AC_TRY_LINK([],
667 [ extern char *__progname; printf("%s", __progname); ],
668 [ ac_cv_libc_defines___progname="yes" ],
669 [ ac_cv_libc_defines___progname="no" ]
670 )
671])
672if test "x$ac_cv_libc_defines___progname" = "xyes" ; then
673 AC_DEFINE(HAVE___PROGNAME)
674fi
675
Damien Millera22ba012000-03-02 23:09:20 +1100676
677# Looking for programs, paths and files
678AC_ARG_WITH(rsh,
679 [ --with-rsh=PATH Specify path to remote shell program ],
680 [
Damien Millerb85dcad2000-03-11 11:37:00 +1100681 if test "x$withval" != "$no" ; then
Damien Miller7b22d652000-06-18 14:07:04 +1000682 rsa_path=$withval
Damien Millera22ba012000-03-02 23:09:20 +1100683 fi
684 ],
685 [
686 AC_PATH_PROG(rsh_path, rsh)
687 ]
688)
689
690AC_ARG_WITH(xauth,
691 [ --with-xauth=PATH Specify path to xauth program ],
692 [
693 if test "x$withval" != "$xno" ; then
Damien Miller7b22d652000-06-18 14:07:04 +1000694 xauth_path=$withval
Damien Millera22ba012000-03-02 23:09:20 +1100695 fi
696 ],
697 [
698 AC_PATH_PROG(xauth_path, xauth)
Damien Milleredb82922000-06-20 13:25:52 +1000699 if (test ! -z "$xauth_path" && test -x "/usr/openwin/bin/xauth") ; then
Damien Millera22ba012000-03-02 23:09:20 +1100700 xauth_path="/usr/openwin/bin/xauth"
701 fi
702 ]
703)
704
705if test ! -z "$xauth_path" ; then
706 AC_DEFINE_UNQUOTED(XAUTH_PATH, "$xauth_path")
707fi
708if test ! -z "$rsh_path" ; then
709 AC_DEFINE_UNQUOTED(RSH_PATH, "$rsh_path")
710fi
711
712# Check for mail directory (last resort if we cannot get it from headers)
713if test ! -z "$MAIL" ; then
714 maildir=`dirname $MAIL`
715 AC_DEFINE_UNQUOTED(MAIL_DIRECTORY, "$maildir")
716fi
717
Damien Millera22ba012000-03-02 23:09:20 +1100718if test -z "$no_dev_ptmx" ; then
Damien Miller204ad072000-03-02 23:56:12 +1100719 AC_CHECK_FILE("/dev/ptmx",
720 [
721 AC_DEFINE_UNQUOTED(HAVE_DEV_PTMX)
722 have_dev_ptmx=1
723 ]
724 )
Damien Millera22ba012000-03-02 23:09:20 +1100725fi
Damien Miller204ad072000-03-02 23:56:12 +1100726AC_CHECK_FILE("/dev/ptc",
727 [
728 AC_DEFINE_UNQUOTED(HAVE_DEV_PTS_AND_PTC)
729 have_dev_ptc=1
730 ]
731)
732
Damien Millera22ba012000-03-02 23:09:20 +1100733# Options from here on. Some of these are preset by platform above
734
Damien Millera22ba012000-03-02 23:09:20 +1100735# Check for user-specified random device, otherwise check /dev/urandom
736AC_ARG_WITH(random,
737 [ --with-random=FILE read randomness from FILE (default=/dev/urandom)],
738 [
Damien Miller040f3832000-04-03 14:50:43 +1000739 if test "x$withval" != "xno" ; then
740 RANDOM_POOL="$withval";
741 AC_DEFINE_UNQUOTED(RANDOM_POOL, "$RANDOM_POOL")
742 fi
Damien Millera22ba012000-03-02 23:09:20 +1100743 ],
744 [
745 # Check for random device
746 AC_CHECK_FILE("/dev/urandom",
747 [
748 RANDOM_POOL="/dev/urandom";
749 AC_SUBST(RANDOM_POOL)
750 AC_DEFINE_UNQUOTED(RANDOM_POOL, "$RANDOM_POOL")
751 ]
752 )
753 ]
754)
755
756# Check for EGD pool file
757AC_ARG_WITH(egd-pool,
758 [ --with-egd-pool=FILE read randomness from EGD pool FILE (default none)],
759 [
Damien Miller040f3832000-04-03 14:50:43 +1000760 if test "x$withval" != "xno" ; then
761 EGD_SOCKET="$withval";
762 AC_DEFINE_UNQUOTED(EGD_SOCKET, "$EGD_SOCKET")
763 fi
Damien Millera22ba012000-03-02 23:09:20 +1100764 ]
765)
766
Damien Miller0437b332000-05-02 09:56:41 +1000767# detect pathnames for entropy gathering commands, if we need them
768INSTALL_SSH_PRNG_CMDS=""
769rm -f prng_commands
Damien Milleredb82922000-06-20 13:25:52 +1000770if (test -z "$RANDOM_POOL" && test -z "$EGD_SOCKET") ; then
Damien Miller11e37f62000-04-08 18:23:30 +1000771 # Use these commands to collect entropy
Damien Miller61e50f12000-05-08 20:49:37 +1000772 OSSH_PATH_ENTROPY_PROG(PROG_LS, ls)
773 OSSH_PATH_ENTROPY_PROG(PROG_NETSTAT, netstat)
774 OSSH_PATH_ENTROPY_PROG(PROG_ARP, arp)
775 OSSH_PATH_ENTROPY_PROG(PROG_IFCONFIG, ifconfig)
776 OSSH_PATH_ENTROPY_PROG(PROG_PS, ps)
777 OSSH_PATH_ENTROPY_PROG(PROG_W, w)
778 OSSH_PATH_ENTROPY_PROG(PROG_WHO, who)
779 OSSH_PATH_ENTROPY_PROG(PROG_LAST, last)
780 OSSH_PATH_ENTROPY_PROG(PROG_LASTLOG, lastlog)
781 OSSH_PATH_ENTROPY_PROG(PROG_DF, df)
782 OSSH_PATH_ENTROPY_PROG(PROG_VMSTAT, vmstat)
783 OSSH_PATH_ENTROPY_PROG(PROG_UPTIME, uptime)
784 OSSH_PATH_ENTROPY_PROG(PROG_IPCS, ipcs)
785 OSSH_PATH_ENTROPY_PROG(PROG_TAIL, tail)
786 OSSH_PATH_ENTROPY_PROG(PROG_LS, ls)
Damien Miller0437b332000-05-02 09:56:41 +1000787
788 INSTALL_SSH_PRNG_CMDS="yes"
Damien Miller11e37f62000-04-08 18:23:30 +1000789fi
Damien Miller0437b332000-05-02 09:56:41 +1000790AC_SUBST(INSTALL_SSH_PRNG_CMDS)
791
Damien Miller11e37f62000-04-08 18:23:30 +1000792
Damien Miller670a4b82000-01-22 13:53:11 +1100793AC_ARG_WITH(catman,
794 [ --with-catman=man|cat Install preformatted manpages[no]],
795 [
796 MANTYPE='$(CATMAN)'
797 if test x"$withval" != x"yes" ; then
798 mansubdir=$withval
799 else
800 mansubdir=cat
801 fi
802 ], [
803 if test -z "$MANTYPE" ; then
804 MANTYPE='$(TROFFMAN)'
805 mansubdir=man
806 fi
807 ]
808)
809AC_SUBST(MANTYPE)
810AC_SUBST(mansubdir)
Damien Miller8bdeee21999-12-30 15:50:54 +1100811
Damien Millera22ba012000-03-02 23:09:20 +1100812# Check whether user wants Kerberos support
Damien Miller7b22d652000-06-18 14:07:04 +1000813KRB4_MSG="no"
Damien Miller80297751999-11-19 13:03:25 +1100814AC_ARG_WITH(kerberos4,
Damien Miller105b7f02000-01-07 08:45:55 +1100815 [ --with-kerberos4=PATH Enable Kerberos 4 support],
Damien Miller80297751999-11-19 13:03:25 +1100816 [
Damien Millerb85dcad2000-03-11 11:37:00 +1100817 if test "x$withval" != "xno" ; then
Damien Miller105b7f02000-01-07 08:45:55 +1100818
819 if test "x$withval" != "$xyes" ; then
820 CFLAGS="$CFLAGS -I${withval}/include"
821 LDFLAGS="$LDFLAGS -L${withval}/lib"
Damien Miller29ea30d2000-03-17 10:54:15 +1100822 if test ! -z "$need_dash_r" ; then
823 LDFLAGS="$LDFLAGS -R${withval}/lib"
824 fi
825 if test ! -z "$blibpath" ; then
826 blibpath="$blibpath:${withval}/lib"
827 fi
Damien Miller105b7f02000-01-07 08:45:55 +1100828 else
829 if test -d /usr/include/kerberosIV ; then
830 CFLAGS="$CFLAGS -I/usr/include/kerberosIV"
831 fi
832 fi
833
834 AC_CHECK_HEADERS(krb.h)
835 AC_CHECK_LIB(krb, main)
836 if test "$ac_cv_header_krb_h" != yes; then
837 AC_MSG_WARN([Cannot find krb.h, build may fail])
838 fi
839 if test "$ac_cv_lib_krb_main" != yes; then
840 AC_MSG_WARN([Cannot find libkrb, build may fail])
841 fi
842
Damien Millerc85f9b42000-01-29 10:20:21 +1100843 KLIBS="-lkrb -ldes"
Damien Miller105b7f02000-01-07 08:45:55 +1100844 AC_CHECK_LIB(resolv, dn_expand, , )
845 KRB4=yes
Damien Miller7b22d652000-06-18 14:07:04 +1000846 KRB4_MSG="yes"
Damien Miller8bdeee21999-12-30 15:50:54 +1100847 AC_DEFINE(KRB4)
Damien Miller8bdeee21999-12-30 15:50:54 +1100848 fi
Damien Miller80297751999-11-19 13:03:25 +1100849 ]
850)
851
Damien Millera22ba012000-03-02 23:09:20 +1100852# Check whether user wants AFS support
Damien Miller7b22d652000-06-18 14:07:04 +1000853AFS_MSG="no"
Damien Millerc6398ef1999-11-20 12:18:40 +1100854AC_ARG_WITH(afs,
Damien Miller105b7f02000-01-07 08:45:55 +1100855 [ --with-afs=PATH Enable AFS support],
Damien Miller80297751999-11-19 13:03:25 +1100856 [
Damien Millerb85dcad2000-03-11 11:37:00 +1100857 if test "x$withval" != "xno" ; then
Damien Miller105b7f02000-01-07 08:45:55 +1100858
859 if test "x$withval" != "$xyes" ; then
860 CFLAGS="$CFLAGS -I${withval}/include"
861 LFLAGS="$LFLAGS -L${withval}/lib"
862 fi
863
864 if test -z "$KRB4" ; then
865 AC_MSG_WARN([AFS requires Kerberos IV support, build may fail])
866 fi
867
Damien Miller8bdeee21999-12-30 15:50:54 +1100868 LIBS="$LIBS -lkafs"
Damien Miller105b7f02000-01-07 08:45:55 +1100869 if test ! -z "$AFS_LIBS" ; then
870 LIBS="$LIBS $AFS_LIBS"
871 fi
872 AC_DEFINE(AFS)
Damien Miller7b22d652000-06-18 14:07:04 +1000873 AFS_MSG="yes"
Damien Miller8bdeee21999-12-30 15:50:54 +1100874 fi
Damien Miller80297751999-11-19 13:03:25 +1100875 ]
876)
Damien Millerc85f9b42000-01-29 10:20:21 +1100877LIBS="$LIBS $KLIBS"
Damien Miller80297751999-11-19 13:03:25 +1100878
Damien Millera22ba012000-03-02 23:09:20 +1100879# Check whether user wants S/Key support
Damien Miller7b22d652000-06-18 14:07:04 +1000880SKEY_MSG="no"
Damien Miller80297751999-11-19 13:03:25 +1100881AC_ARG_WITH(skey,
882 [ --with-skey Enable S/Key support],
883 [
Damien Millerb85dcad2000-03-11 11:37:00 +1100884 if test "x$withval" != "xno" ; then
Damien Miller8bdeee21999-12-30 15:50:54 +1100885 AC_DEFINE(SKEY)
886 LIBS="$LIBS -lskey"
Damien Miller7b22d652000-06-18 14:07:04 +1000887 SKEY_MSG="yes"
Damien Miller8bdeee21999-12-30 15:50:54 +1100888 fi
Damien Miller80297751999-11-19 13:03:25 +1100889 ]
890)
891
Damien Millera22ba012000-03-02 23:09:20 +1100892# Check whether user wants TCP wrappers support
Damien Miller7b22d652000-06-18 14:07:04 +1000893TCPW_MSG="no"
Damien Millerf7c0f821999-11-22 22:31:49 +1100894AC_ARG_WITH(tcp-wrappers,
Damien Miller80297751999-11-19 13:03:25 +1100895 [ --with-tcp-wrappers Enable tcpwrappers support],
896 [
Damien Millerb85dcad2000-03-11 11:37:00 +1100897 if test "x$withval" != "xno" ; then
Damien Miller65165f82000-03-05 17:02:45 +1100898 saved_LIBS="$LIBS"
Damien Miller105b7f02000-01-07 08:45:55 +1100899 LIBS="$LIBS -lwrap"
Damien Miller65165f82000-03-05 17:02:45 +1100900 AC_MSG_CHECKING(for libwrap)
901 AC_TRY_LINK(
902 [
Damien Miller81171112000-04-23 11:14:01 +1000903#include <tcpd.h>
Damien Miller65165f82000-03-05 17:02:45 +1100904 int deny_severity = 0, allow_severity = 0;
905 ],
906 [hosts_access(0);],
907 [
908 AC_MSG_RESULT(yes)
909 AC_DEFINE(LIBWRAP)
Damien Miller7b22d652000-06-18 14:07:04 +1000910 TCPW_MSG="yes"
Damien Miller65165f82000-03-05 17:02:45 +1100911 ],
912 [
Damien Miller7b22d652000-06-18 14:07:04 +1000913 AC_MSG_ERROR([*** libwrap missing])
Damien Miller65165f82000-03-05 17:02:45 +1100914 ]
915 )
Damien Miller8bdeee21999-12-30 15:50:54 +1100916 fi
Damien Miller80297751999-11-19 13:03:25 +1100917 ]
918)
919
Damien Millera22ba012000-03-02 23:09:20 +1100920# Check whether to enable MD5 passwords
Damien Miller7b22d652000-06-18 14:07:04 +1000921MD5_MSG="no"
Damien Millerf7c0f821999-11-22 22:31:49 +1100922AC_ARG_WITH(md5-passwords,
Damien Millerdd1c7ba1999-11-19 15:53:20 +1100923 [ --with-md5-passwords Enable use of MD5 passwords],
Damien Miller8bdeee21999-12-30 15:50:54 +1100924 [
Damien Millerb85dcad2000-03-11 11:37:00 +1100925 if test "x$withval" != "xno" ; then
Damien Miller8bdeee21999-12-30 15:50:54 +1100926 AC_DEFINE(HAVE_MD5_PASSWORDS)
Damien Miller7b22d652000-06-18 14:07:04 +1000927 MD5_MSG="yes"
Damien Miller8bdeee21999-12-30 15:50:54 +1100928 fi
929 ]
Damien Millerdd1c7ba1999-11-19 15:53:20 +1100930)
931
Damien Millera22ba012000-03-02 23:09:20 +1100932# Whether to disable shadow password support
Damien Miller76112de1999-12-21 11:18:08 +1100933AC_ARG_WITH(shadow,
934 [ --without-shadow Disable shadow password support],
935 [
936 if test "x$withval" = "xno" ; then
937 AC_DEFINE(DISABLE_SHADOW)
Damien Miller1f335fb2000-06-26 11:31:33 +1000938 disable_shadow=yes
Damien Miller76112de1999-12-21 11:18:08 +1100939 fi
940 ]
941)
942
Damien Miller1f335fb2000-06-26 11:31:33 +1000943if test -z "$disable_shadow" ; then
944 AC_MSG_CHECKING([if the systems has expire shadow information])
945 AC_TRY_COMPILE(
946 [
947#include <sys/types.h>
948#include <shadow.h>
949 struct spwd sp;
950 ],[ sp.sp_expire = sp.sp_lstchg = sp.sp_inact = 0; ],
951 [ sp_expire_available=yes ], []
952 )
953
954 if test "x$sp_expire_available" = "xyes" ; then
955 AC_MSG_RESULT(yes)
956 AC_DEFINE(HAS_SHADOW_EXPIRE)
957 else
958 AC_MSG_RESULT(no)
959 fi
960fi
961
Damien Millera22ba012000-03-02 23:09:20 +1100962# Use ip address instead of hostname in $DISPLAY
Damien Miller7b22d652000-06-18 14:07:04 +1000963DISPLAY_HACK_MSG="no"
Damien Miller76112de1999-12-21 11:18:08 +1100964AC_ARG_WITH(ipaddr-display,
965 [ --with-ipaddr-display Use ip address instead of hostname in \$DISPLAY],
966 [
Damien Miller66409952000-01-17 21:40:06 +1100967 if test "x$withval" = "xno" ; then
Damien Miller76112de1999-12-21 11:18:08 +1100968 AC_DEFINE(IPADDR_IN_DISPLAY)
Damien Miller7b22d652000-06-18 14:07:04 +1000969 DISPLAY_HACK_MSG="yes"
Damien Miller76112de1999-12-21 11:18:08 +1100970 fi
971 ]
972)
973
Damien Millera22ba012000-03-02 23:09:20 +1100974# Whether to mess with the default path
Damien Miller7b22d652000-06-18 14:07:04 +1000975SERVER_PATH_MSG="(default)"
Damien Millere7f626c1999-12-31 09:49:44 +1100976AC_ARG_WITH(default-path,
Damien Miller5a3e6831999-12-27 09:48:56 +1100977 [ --with-default-path=PATH Specify default \$PATH environment for server],
978 [
979 if test "x$withval" != "xno" ; then
Damien Miller9550a761999-12-29 02:32:22 +1100980 AC_DEFINE_UNQUOTED(USER_PATH, "$withval")
Damien Miller7b22d652000-06-18 14:07:04 +1000981 SERVER_PATH_MSG="$withval"
Damien Miller5a3e6831999-12-27 09:48:56 +1100982 fi
983 ]
984)
985
Damien Millera22ba012000-03-02 23:09:20 +1100986# Whether to force IPv4 by default (needed on broken glibc Linux)
Damien Miller7b22d652000-06-18 14:07:04 +1000987IPV4_HACK_MSG="no"
Damien Miller7d80e342000-01-19 14:36:49 +1100988AC_ARG_WITH(ipv4-default,
989 [ --with-ipv4-default Use IPv4 by connections unless '-6' specified],
990 [
991 if test "x$withval" != "xno" ; then
992 AC_DEFINE(IPV4_DEFAULT)
Damien Miller7b22d652000-06-18 14:07:04 +1000993 IPV4_HACK_MSG="yes"
Damien Miller7d80e342000-01-19 14:36:49 +1100994 fi
995 ]
996)
997
Damien Miller61e50f12000-05-08 20:49:37 +1000998AC_MSG_CHECKING([if we need to convert IPv4 in IPv6-mapped addresses])
Damien Miller7b22d652000-06-18 14:07:04 +1000999IPV4_IN6_HACK_MSG="no"
Damien Miller7bcb0892000-03-11 20:45:40 +11001000AC_ARG_WITH(4in6,
1001 [ --with-4in6 Check for and convert IPv4 in IPv6 mapped addresses],
1002 [
1003 if test "x$withval" != "xno" ; then
1004 AC_MSG_RESULT(yes)
1005 AC_DEFINE(IPV4_IN_IPV6)
Damien Miller7b22d652000-06-18 14:07:04 +10001006 IPV4_IN6_HACK_MSG="yes"
Damien Miller7bcb0892000-03-11 20:45:40 +11001007 else
1008 AC_MSG_RESULT(no)
1009 fi
1010 ],[
1011 if test "x$inet6_default_4in6" = "xyes"; then
1012 AC_MSG_RESULT([yes (default)])
1013 AC_DEFINE(IPV4_IN_IPV6)
Damien Miller7b22d652000-06-18 14:07:04 +10001014 IPV4_IN6_HACK_MSG="yes"
Damien Miller7bcb0892000-03-11 20:45:40 +11001015 else
1016 AC_MSG_RESULT([no (default)])
1017 fi
1018 ]
1019)
1020
Damien Millera22ba012000-03-02 23:09:20 +11001021# Where to place sshd.pid
Damien Millerb13c73e2000-01-17 22:02:17 +11001022piddir=/var/run
Damien Miller5eed6a22000-01-16 12:05:18 +11001023AC_ARG_WITH(pid-dir,
1024 [ --with-pid-dir=PATH Specify location of ssh.pid file],
1025 [
1026 if test "x$withval" != "xno" ; then
Damien Millerb13c73e2000-01-17 22:02:17 +11001027 piddir=$withval
Damien Miller5eed6a22000-01-16 12:05:18 +11001028 fi
1029 ]
1030)
Damien Miller4018c192000-04-30 09:30:44 +10001031
Damien Millerdbd250f2000-01-18 08:57:14 +11001032AC_DEFINE_UNQUOTED(PIDDIR, "$piddir")
Damien Millerb13c73e2000-01-17 22:02:17 +11001033AC_SUBST(piddir)
Damien Miller5eed6a22000-01-16 12:05:18 +11001034
andre2ff7b5d2000-06-03 14:57:40 +00001035dnl allow user to disable some login recording features
1036AC_ARG_ENABLE(lastlog,
andre43ca7e22000-06-19 08:23:46 +00001037 [ --disable-lastlog disable use of lastlog even if detected [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001038 [ AC_DEFINE(DISABLE_LASTLOG) ]
1039)
1040AC_ARG_ENABLE(utmp,
andre43ca7e22000-06-19 08:23:46 +00001041 [ --disable-utmp disable use of utmp even if detected [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001042 [ AC_DEFINE(DISABLE_UTMP) ]
1043)
1044AC_ARG_ENABLE(utmpx,
andre43ca7e22000-06-19 08:23:46 +00001045 [ --disable-utmpx disable use of utmpx even if detected [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001046 [ AC_DEFINE(DISABLE_UTMPX) ]
1047)
1048AC_ARG_ENABLE(wtmp,
andre43ca7e22000-06-19 08:23:46 +00001049 [ --disable-wtmp disable use of wtmp even if detected [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001050 [ AC_DEFINE(DISABLE_WTMP) ]
1051)
1052AC_ARG_ENABLE(wtmpx,
andre43ca7e22000-06-19 08:23:46 +00001053 [ --disable-wtmpx disable use of wtmpx even if detected [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001054 [ AC_DEFINE(DISABLE_WTMPX) ]
1055)
1056AC_ARG_ENABLE(libutil,
andre43ca7e22000-06-19 08:23:46 +00001057 [ --disable-libutil disable use of libutil (login() etc.) [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001058 [ AC_DEFINE(DISABLE_LOGIN) ]
1059)
1060AC_ARG_ENABLE(pututline,
andre43ca7e22000-06-19 08:23:46 +00001061 [ --disable-pututline disable use of pututline() etc. ([uw]tmp) [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001062 [ AC_DEFINE(DISABLE_PUTUTLINE) ]
1063)
1064AC_ARG_ENABLE(pututxline,
andre43ca7e22000-06-19 08:23:46 +00001065 [ --disable-pututxline disable use of pututxline() etc. ([uw]tmpx) [no]],
andre2ff7b5d2000-06-03 14:57:40 +00001066 [ AC_DEFINE(DISABLE_PUTUTXLINE) ]
1067)
1068AC_ARG_WITH(lastlog,
andre43ca7e22000-06-19 08:23:46 +00001069 [ --with-lastlog=FILE|DIR specify lastlog location [common locations]],
andre2ff7b5d2000-06-03 14:57:40 +00001070 [ conf_lastlog_location="$withval"; ],)
1071
1072dnl lastlog, [uw]tmpx? detection
1073dnl NOTE: set the paths in the platform section to avoid the
1074dnl need for command-line parameters
1075dnl lastlog and [uw]tmp are subject to a file search if all else fails
1076
1077dnl lastlog detection
1078dnl NOTE: the code itself will detect if lastlog is a directory
1079AC_MSG_CHECKING([if your system defines LASTLOG_FILE])
1080AC_TRY_COMPILE([
1081#include <sys/types.h>
1082#include <utmp.h>
1083#ifdef HAVE_LASTLOG_H
1084# include <lastlog.h>
1085#endif
Damien Miller2994e082000-06-04 15:51:47 +10001086#ifdef HAVE_PATHS_H
andre2ff7b5d2000-06-03 14:57:40 +00001087# include <paths.h>
1088#endif
1089 ],
1090 [ char *lastlog = LASTLOG_FILE; ],
1091 [ AC_MSG_RESULT(yes) ],
Damien Miller2994e082000-06-04 15:51:47 +10001092 [
1093 AC_MSG_RESULT(no)
1094 AC_MSG_CHECKING([if your system defines _PATH_LASTLOG])
1095 AC_TRY_COMPILE([
1096#include <sys/types.h>
1097#include <utmp.h>
1098#ifdef HAVE_LASTLOG_H
1099# include <lastlog.h>
1100#endif
1101#ifdef HAVE_PATHS_H
1102# include <paths.h>
1103#endif
1104 ],
1105 [ char *lastlog = _PATH_LASTLOG; ],
1106 [ AC_MSG_RESULT(yes) ],
1107 [
andree441aa32000-06-12 22:34:38 +00001108 AC_MSG_RESULT(no)
Damien Miller2994e082000-06-04 15:51:47 +10001109 system_lastlog_path=no
1110 ])
1111 ]
andre2ff7b5d2000-06-03 14:57:40 +00001112)
Damien Miller2994e082000-06-04 15:51:47 +10001113
andre2ff7b5d2000-06-03 14:57:40 +00001114if test -z "$conf_lastlog_location"; then
1115 if test x"$system_lastlog_path" = x"no" ; then
1116 for f in /var/log/lastlog /usr/adm/lastlog /var/adm/lastlog /etc/security/lastlog ; do
Damien Milleredb82922000-06-20 13:25:52 +10001117 if (test -d "$f" || test -f "$f") ; then
andre2ff7b5d2000-06-03 14:57:40 +00001118 conf_lastlog_location=$f
1119 fi
1120 done
1121 if test -z "$conf_lastlog_location"; then
andre45cad512000-06-12 23:27:31 +00001122 AC_MSG_WARN([** Cannot find lastlog **])
1123 dnl Don't define DISABLE_LASTLOG - that means we don't try wtmp/wtmpx
andre2ff7b5d2000-06-03 14:57:40 +00001124 fi
1125 fi
1126fi
1127
1128if test -n "$conf_lastlog_location"; then
1129 AC_DEFINE_UNQUOTED(CONF_LASTLOG_FILE, "$conf_lastlog_location")
1130fi
1131
1132dnl utmp detection
1133AC_MSG_CHECKING([if your system defines UTMP_FILE])
1134AC_TRY_COMPILE([
1135#include <sys/types.h>
1136#include <utmp.h>
Damien Miller2994e082000-06-04 15:51:47 +10001137#ifdef HAVE_PATHS_H
andre2ff7b5d2000-06-03 14:57:40 +00001138# include <paths.h>
1139#endif
1140 ],
1141 [ char *utmp = UTMP_FILE; ],
1142 [ AC_MSG_RESULT(yes) ],
1143 [ AC_MSG_RESULT(no)
1144 system_utmp_path=no ]
1145)
1146if test -z "$conf_utmp_location"; then
1147 if test x"$system_utmp_path" = x"no" ; then
1148 for f in /etc/utmp /usr/adm/utmp /var/run/utmp; do
1149 if test -f $f ; then
1150 conf_utmp_location=$f
1151 fi
1152 done
1153 if test -z "$conf_utmp_location"; then
1154 AC_DEFINE(DISABLE_UTMP)
1155 fi
1156 fi
1157fi
1158if test -n "$conf_utmp_location"; then
1159 AC_DEFINE_UNQUOTED(CONF_UTMP_FILE, "$conf_utmp_location")
1160fi
1161
1162dnl wtmp detection
1163AC_MSG_CHECKING([if your system defines WTMP_FILE])
1164AC_TRY_COMPILE([
1165#include <sys/types.h>
1166#include <utmp.h>
Damien Miller2994e082000-06-04 15:51:47 +10001167#ifdef HAVE_PATHS_H
andre2ff7b5d2000-06-03 14:57:40 +00001168# include <paths.h>
1169#endif
1170 ],
1171 [ char *wtmp = WTMP_FILE; ],
1172 [ AC_MSG_RESULT(yes) ],
1173 [ AC_MSG_RESULT(no)
1174 system_wtmp_path=no ]
1175)
1176if test -z "$conf_wtmp_location"; then
1177 if test x"$system_wtmp_path" = x"no" ; then
1178 for f in /usr/adm/wtmp /var/log/wtmp; do
1179 if test -f $f ; then
1180 conf_wtmp_location=$f
1181 fi
1182 done
1183 if test -z "$conf_wtmp_location"; then
1184 AC_DEFINE(DISABLE_WTMP)
1185 fi
1186 fi
1187fi
1188if test -n "$conf_wtmp_location"; then
1189 AC_DEFINE_UNQUOTED(CONF_WTMP_FILE, "$conf_wtmp_location")
1190fi
1191
1192
1193dnl utmpx detection - I don't know any system so perverse as to require
1194dnl utmpx, but not define UTMPX_FILE (ditto wtmpx.) No doubt it's out
1195dnl there, though.
1196AC_MSG_CHECKING([if your system defines UTMPX_FILE])
1197AC_TRY_COMPILE([
1198#include <sys/types.h>
1199#include <utmp.h>
1200#ifdef HAVE_UTMPX_H
1201#include <utmpx.h>
1202#endif
Damien Miller2994e082000-06-04 15:51:47 +10001203#ifdef HAVE_PATHS_H
andre2ff7b5d2000-06-03 14:57:40 +00001204# include <paths.h>
1205#endif
1206 ],
1207 [ char *utmpx = UTMPX_FILE; ],
1208 [ AC_MSG_RESULT(yes) ],
1209 [ AC_MSG_RESULT(no)
1210 system_utmpx_path=no ]
1211)
1212if test -z "$conf_utmpx_location"; then
1213 if test x"$system_utmpx_path" = x"no" ; then
1214 AC_DEFINE(DISABLE_UTMPX)
1215 fi
1216else
1217 AC_DEFINE_UNQUOTED(CONF_UTMPX_FILE, "$conf_utmpx_location")
1218fi
1219
1220dnl wtmpx detection
1221AC_MSG_CHECKING([if your system defines WTMPX_FILE])
1222AC_TRY_COMPILE([
1223#include <sys/types.h>
1224#include <utmp.h>
1225#ifdef HAVE_UTMPX_H
1226#include <utmpx.h>
1227#endif
Damien Miller2994e082000-06-04 15:51:47 +10001228#ifdef HAVE_PATHS_H
andre2ff7b5d2000-06-03 14:57:40 +00001229# include <paths.h>
1230#endif
1231 ],
1232 [ char *wtmpx = WTMPX_FILE; ],
1233 [ AC_MSG_RESULT(yes) ],
1234 [ AC_MSG_RESULT(no)
1235 system_wtmpx_path=no ]
1236)
1237if test -z "$conf_wtmpx_location"; then
1238 if test x"$system_wtmpx_path" = x"no" ; then
1239 AC_DEFINE(DISABLE_WTMPX)
1240 fi
1241else
1242 AC_DEFINE_UNQUOTED(CONF_WTMPX_FILE, "$conf_wtmpx_location")
1243fi
1244
Damien Miller4018c192000-04-30 09:30:44 +10001245
1246# Change default command timeout for builtin PRNG
Damien Miller14c12cb2000-06-07 22:20:23 +10001247entropy_timeout=200
Damien Miller4018c192000-04-30 09:30:44 +10001248AC_ARG_WITH(entropy-timeout,
1249 [ --with-entropy-timeout Specify entropy gathering command timeout (msec)],
1250 [
1251 if test "x$withval" != "xno" ; then
1252 entropy_timeout=$withval
1253 fi
1254 ]
1255)
1256AC_DEFINE_UNQUOTED(ENTROPY_TIMEOUT_MSEC, $entropy_timeout)
1257
1258
Damien Miller29ea30d2000-03-17 10:54:15 +11001259if test ! -z "$blibpath" ; then
1260 LDFLAGS="$LDFLAGS -blibpath:$blibpath"
1261 AC_MSG_WARN([Please check and edit -blibpath in LDFLAGS in Makefile])
1262fi
1263
Damien Miller0437b332000-05-02 09:56:41 +10001264AC_OUTPUT(Makefile ssh_prng_cmds)
1265
Damien Miller7b22d652000-06-18 14:07:04 +10001266# Print summary of options
1267
1268if test x$MANTYPE = x'$(CATMAN)' ; then
1269 MAN_MSG=cat
1270else
1271 MAN_MSG=man
1272fi
1273if test ! -z "$RANDOM_POOL" ; then
1274 RAND_MSG="Device ($RANDOM_POOL)"
1275else
1276 if test ! -z "$EGD_SOCKET" ; then
1277 RAND_MSG="EGD ($EGD_SOCKET)"
1278 else
1279 RAND_MSG="Builtin (timeout $entropy_timeout)"
1280 fi
1281fi
1282
1283# Someone please show me a better way :)
1284A=`eval echo ${prefix}` ; A=`eval echo ${A}`
1285B=`eval echo ${bindir}` ; B=`eval echo ${B}`
1286C=`eval echo ${sbindir}` ; C=`eval echo ${C}`
1287D=`eval echo ${sysconfdir}` ; D=`eval echo ${D}`
1288E=`eval echo ${libexecdir}/ssh/ssh-askpass` ; E=`eval echo ${E}`
1289F=`eval echo ${mandir}/${mansubdir}X` ; F=`eval echo ${F}`
1290G=`eval echo ${piddir}` ; G=`eval echo ${G}`
1291
1292echo ""
1293echo "OpenSSH configured has been configured with the following options."
1294echo " User binaries: $B"
1295echo " System binaries: $C"
1296echo " Configuration files: $D"
1297echo " Askpass program: $E"
1298echo " Manual pages: $F"
1299echo " PID file: $G"
1300echo " Random number collection: $RAND_MSG"
1301echo " Manpage format: $MAN_MSG"
1302echo " PAM support: ${PAM_MSG}"
1303echo " KerberosIV support: $KRB4_MSG"
1304echo " AFS support: $AFS_MSG"
1305echo " S/KEY support: $SKEY_MSG"
1306echo " TCP Wrappers support: $TCPW_MSG"
1307echo " MD5 password support: $MD5_MSG"
1308echo " IP address in \$DISPLAY hack: $DISPLAY_HACK_MSG"
1309echo " Use IPv4 by default hack: $IPV4_HACK_MSG"
1310echo " Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG"
1311
1312echo ""
1313
1314echo "Compiler flags: ${CFLAGS}"
1315echo "Linker flags: ${LDFLAGS}"
1316echo "Libraries: ${LIBS}"
1317
1318echo ""
1319