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