PageRenderTime 16ms CodeModel.GetById 12ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/crypto/heimdal/cf/telnet.m4

https://bitbucket.org/freebsd/freebsd-head/
m4 | 78 lines | 56 code | 8 blank | 14 comment | 0 complexity | 01fb94846186bb5a5576ecd6eb69a9de MD5 | raw file
 1dnl
 2dnl $Id: telnet.m4 15435 2005-06-16 19:45:52Z lha $
 3dnl
 4dnl stuff used by telnet
 5
 6AC_DEFUN([rk_TELNET],[
 7AC_DEFINE(AUTHENTICATION, 1, 
 8	[Define if you want authentication support in telnet.])dnl
 9AC_DEFINE(ENCRYPTION, 1,
10	[Define if you want encryption support in telnet.])dnl
11AC_DEFINE(DES_ENCRYPTION, 1,
12	[Define if you want to use DES encryption in telnet.])dnl
13AC_DEFINE(DIAGNOSTICS, 1,
14	[Define this to enable diagnostics in telnet.])dnl
15AC_DEFINE(OLD_ENVIRON, 1,
16	[Define this to enable old environment option in telnet.])dnl
17if false; then
18	AC_DEFINE(ENV_HACK, 1,
19		[Define this if you want support for broken ENV_{VAR,VAL} telnets.])
20fi
21
22# Simple test for streamspty, based on the existance of getmsg(), alas
23# this breaks on SunOS4 which have streams but BSD-like ptys
24#
25# And also something wierd has happend with dec-osf1, fallback to bsd-ptys
26
27case "$host" in
28*-*-aix3*|*-*-sunos4*|*-*-osf*|*-*-hpux1[[01]]*)
29	;;
30*)
31	AC_CHECK_FUNC(getmsg)
32	if test "$ac_cv_func_getmsg" = "yes"; then
33		AC_CACHE_CHECK([if getmsg works], ac_cv_func_getmsg_works,
34		AC_RUN_IFELSE([AC_LANG_SOURCE([[
35			#include <stdio.h>
36			#include <errno.h>
37
38			int main(int argc, char **argv)
39			{
40			  int ret;
41			  ret = getmsg(open("/dev/null", 0), NULL, NULL, NULL);
42			  if(ret < 0 && errno == ENOSYS)
43			    return 1;
44			  return 0;
45			}
46			]])], [ac_cv_func_getmsg_works=yes], 
47			[ac_cv_func_getmsg_works=no],
48			[ac_cv_func_getmsg_works=no]))
49		if test "$ac_cv_func_getmsg_works" = "yes"; then
50			AC_DEFINE(HAVE_GETMSG, 1,
51				[Define if you have a working getmsg.])
52			AC_DEFINE(STREAMSPTY, 1,
53				[Define if you have streams ptys.])
54		fi
55	fi
56	;;
57esac
58
59AH_BOTTOM([
60#if defined(ENCRYPTION) && !defined(AUTHENTICATION)
61#define AUTHENTICATION 1
62#endif
63
64/* Set this to the default system lead string for telnetd 
65 * can contain %-escapes: %s=sysname, %m=machine, %r=os-release
66 * %v=os-version, %t=tty, %h=hostname, %d=date and time
67 */
68#undef USE_IM
69
70/* Used with login -p */
71#undef LOGIN_ARGS
72
73/* set this to a sensible login */
74#ifndef LOGIN_PATH
75#define LOGIN_PATH BINDIR "/login"
76#endif
77])
78])