ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libptytty/ptytty.m4
(Generate patch)

Comparing libptytty/ptytty.m4 (file contents):
Revision 1.4 by ayin, Mon Jan 23 10:10:50 2006 UTC vs.
Revision 1.9 by ayin, Mon May 7 13:46:06 2007 UTC

15 revoke \ 15 revoke \
16 _getpty \ 16 _getpty \
17 getpt \ 17 getpt \
18 posix_openpt \ 18 posix_openpt \
19 isastream \ 19 isastream \
20 setuid \
21 seteuid \
22 setreuid \
23 setresuid \
20) 24)
21 25
22have_clone=no 26have_clone=no
23 27
24AC_MSG_CHECKING(for /dev/ptym/clone) 28AC_MSG_CHECKING(for /dev/ptym/clone)
74fi 78fi
75]) 79])
76 80
77AC_DEFUN([UTMP_CHECK], 81AC_DEFUN([UTMP_CHECK],
78[ 82[
83support_utmp=yes
84support_wtmp=yes
85support_lastlog=yes
86
79AC_ARG_ENABLE(utmp, 87AC_ARG_ENABLE(utmp,
80 [ --enable-utmp enable utmp (utmpx) support], 88 [ --enable-utmp enable utmp (utmpx) support],
81 [if test x$enableval = xyes -o x$enableval = xno; then 89 [if test x$enableval = xyes -o x$enableval = xno; then
82 support_utmp=$enableval 90 support_utmp=$enableval
83 fi]) 91 fi])
204dnl# -------------------------------------------------------------------------- 212dnl# --------------------------------------------------------------------------
205 213
206dnl# find utmp 214dnl# find utmp
207AC_CACHE_CHECK(where utmp is located, path_utmp, 215AC_CACHE_CHECK(where utmp is located, path_utmp,
208[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 216[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
217#include <stdlib.h>
209#include <sys/types.h> 218#include <sys/types.h>
210#include <utmp.h> 219#include <utmp.h>
211#include <errno.h> 220#include <errno.h>
212main() 221main()
213{ 222{
240 249
241dnl# find utmpx - if a utmp file exists at the same location and is more than 250dnl# find utmpx - if a utmp file exists at the same location and is more than
242dnl# a day newer, then dump the utmpx. People leave lots of junk around. 251dnl# a day newer, then dump the utmpx. People leave lots of junk around.
243AC_CACHE_CHECK(where utmpx is located, path_utmpx, 252AC_CACHE_CHECK(where utmpx is located, path_utmpx,
244[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 253[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
254#include <stdlib.h>
245#include <sys/types.h> 255#include <sys/types.h>
246#include <utmpx.h> 256#include <utmpx.h>
247#include <errno.h> 257#include <errno.h>
248#include <sys/stat.h> 258#include <sys/stat.h>
249#ifdef HAVE_STRING_H 259#ifdef HAVE_STRING_H
285dnl# -------------------------------------------------------------------------- 295dnl# --------------------------------------------------------------------------
286 296
287dnl# find wtmp 297dnl# find wtmp
288AC_CACHE_CHECK(where wtmp is located, path_wtmp, 298AC_CACHE_CHECK(where wtmp is located, path_wtmp,
289[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 299[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
300#include <stdlib.h>
290#include <sys/types.h> 301#include <sys/types.h>
291#ifdef HAVE_UTMP_H 302#ifdef HAVE_UTMP_H
292#include <utmp.h> 303#include <utmp.h>
293#endif 304#endif
294#include <errno.h> 305#include <errno.h>
321dnl# -------------------------------------------------------------------------- 332dnl# --------------------------------------------------------------------------
322 333
323dnl# find wtmpx 334dnl# find wtmpx
324AC_CACHE_CHECK(where wtmpx is located, path_wtmpx, 335AC_CACHE_CHECK(where wtmpx is located, path_wtmpx,
325[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 336[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
337#include <stdlib.h>
326#ifdef HAVE_UTMPX_H 338#ifdef HAVE_UTMPX_H
327#include <utmpx.h> 339#include <utmpx.h>
328#endif 340#endif
329#include <errno.h> 341#include <errno.h>
330main() 342main()
356dnl# -------------------------------------------------------------------------- 368dnl# --------------------------------------------------------------------------
357 369
358dnl# find lastlog 370dnl# find lastlog
359AC_CACHE_CHECK(where lastlog is located, path_lastlog, 371AC_CACHE_CHECK(where lastlog is located, path_lastlog,
360[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 372[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
373#include <stdlib.h>
361#include <sys/types.h> 374#include <sys/types.h>
362#ifdef HAVE_UTMPX_H 375#ifdef HAVE_UTMPX_H
363#include <utmpx.h> 376#include <utmpx.h>
364#elif defined(HAVE_UTMP_H) 377#elif defined(HAVE_UTMP_H)
365#include <utmp.h> 378#include <utmp.h>
399dnl# -------------------------------------------------------------------------- 412dnl# --------------------------------------------------------------------------
400 413
401dnl# find lastlogx 414dnl# find lastlogx
402AC_CACHE_CHECK(where lastlogx is located, path_lastlogx, 415AC_CACHE_CHECK(where lastlogx is located, path_lastlogx,
403[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 416[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
417#include <stdlib.h>
404#ifdef HAVE_UTMPX_H 418#ifdef HAVE_UTMPX_H
405#include <utmpx.h> 419#include <utmpx.h>
406#endif 420#endif
407#include <errno.h> 421#include <errno.h>
408main() 422main()
428}]])],[path_lastlogx=`cat conftestval`],[path_lastlogx=],[dnl 442}]])],[path_lastlogx=`cat conftestval`],[path_lastlogx=],[dnl
429 AC_MSG_WARN(Define LASTLOGX_FILE in config.h manually)])]) 443 AC_MSG_WARN(Define LASTLOGX_FILE in config.h manually)])])
430if test x$path_lastlogx != x; then 444if test x$path_lastlogx != x; then
431 AC_DEFINE_UNQUOTED(LASTLOGX_FILE, "$path_lastlogx", Define location of lastlogx) 445 AC_DEFINE_UNQUOTED(LASTLOGX_FILE, "$path_lastlogx", Define location of lastlogx)
432fi 446fi
433
434if test x$support_utmp != xyes; then
435 echo " utmp support: disabled"
436 echo
437else
438 echo " utmp support: enabled
439 utmp file: $path_utmp
440 utmpx file: $path_utmpx
441 wtmp file: $path_wtmp
442 wtmpx file: $path_wtmpx
443 lastlog file: $path_lastlog
444 lastlogx file: $path_lastlogx"
445fi
446]) 447])
447 448
448AC_DEFUN([SCM_RIGHTS_CHECK], 449AC_DEFUN([SCM_RIGHTS_CHECK],
449[ 450[
450AC_CACHE_CHECK(for unix-compliant filehandle passing ability, can_pass_fds, 451AC_CACHE_CHECK(for unix-compliant filehandle passing ability, can_pass_fds,
451[AC_TRY_LINK([ 452[AC_TRY_LINK([
452#include <cstddef> // broken bsds (is that redundant) need this 453#include <cstddef> // broken bsds (is that redundant?) need this
453#include <sys/types.h> 454#include <sys/types.h>
454#include <sys/socket.h> 455#include <sys/socket.h>
455#include <sys/uio.h> 456#include <sys/uio.h>
456],[ 457],[
457{ 458{

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines