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

Comparing libptytty/ptytty.m4 (file contents):
Revision 1.29 by sf-exg, Sun Nov 20 14:38:44 2011 UTC vs.
Revision 1.30 by sf-exg, Wed Nov 23 19:29:27 2011 UTC

4AC_DEFUN([PT_FIND_FILE], 4AC_DEFUN([PT_FIND_FILE],
5[AC_CACHE_CHECK(where $1 is located, pt_cv_path_$1, 5[AC_CACHE_CHECK(where $1 is located, pt_cv_path_$1,
6[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h> 6[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
7#include <stdlib.h> 7#include <stdlib.h>
8#include <sys/stat.h> 8#include <sys/stat.h>
9$5 9#include <sys/types.h>
10#ifdef HAVE_UTMPX_H
11#include <utmpx.h>
12#endif
13#ifdef HAVE_UTMP_H
14#include <utmp.h>
15#endif
16#ifdef HAVE_LASTLOG_H
17#include <lastlog.h>
18#endif
10int main() 19int main()
11{ 20{
12 const char **path, *list[] = { $4, NULL }; 21 const char **path, *list[] = { $4, NULL };
13 FILE *f = fopen("conftestval", "w"); 22 FILE *f = fopen("conftestval", "w");
14 if (!f) return 1; 23 if (!f) return 1;
181dnl# FIND FILES 190dnl# FIND FILES
182dnl# -------------------------------------------------------------------------- 191dnl# --------------------------------------------------------------------------
183 192
184dnl# find utmp 193dnl# find utmp
185PT_FIND_FILE([utmp], [UTMP_FILE], [_PATH_UTMP], 194PT_FIND_FILE([utmp], [UTMP_FILE], [_PATH_UTMP],
186["/var/run/utmp", "/var/adm/utmp", "/etc/utmp", "/usr/etc/utmp", "/usr/adm/utmp"],[ 195["/var/run/utmp", "/var/adm/utmp", "/etc/utmp", "/usr/etc/utmp", "/usr/adm/utmp"])
187#include <sys/types.h>
188#include <utmp.h>
189])
190 196
191dnl# -------------------------------------------------------------------------- 197dnl# --------------------------------------------------------------------------
192 198
193dnl# find wtmp 199dnl# find wtmp
194PT_FIND_FILE([wtmp], [WTMP_FILE], [_PATH_WTMP], 200PT_FIND_FILE([wtmp], [WTMP_FILE], [_PATH_WTMP],
195["/var/log/wtmp", "/var/adm/wtmp", "/etc/wtmp", "/usr/etc/wtmp", "/usr/adm/wtmp"],[ 201["/var/log/wtmp", "/var/adm/wtmp", "/etc/wtmp", "/usr/etc/wtmp", "/usr/adm/wtmp"])
196#include <sys/types.h>
197#ifdef HAVE_UTMP_H
198#include <utmp.h>
199#endif
200])
201dnl# -------------------------------------------------------------------------- 202dnl# --------------------------------------------------------------------------
202 203
203dnl# find wtmpx 204dnl# find wtmpx
204PT_FIND_FILE([wtmpx], [WTMPX_FILE], [_PATH_WTMPX], 205PT_FIND_FILE([wtmpx], [WTMPX_FILE], [_PATH_WTMPX],
205["/var/log/wtmpx", "/var/adm/wtmpx"],[ 206["/var/log/wtmpx", "/var/adm/wtmpx"])
206#ifdef HAVE_UTMPX_H
207#include <utmpx.h>
208#endif
209])
210dnl# -------------------------------------------------------------------------- 207dnl# --------------------------------------------------------------------------
211 208
212dnl# find lastlog 209dnl# find lastlog
213PT_FIND_FILE([lastlog], [LASTLOG_FILE], [_PATH_LASTLOG], 210PT_FIND_FILE([lastlog], [LASTLOG_FILE], [_PATH_LASTLOG],
214["/var/log/lastlog"],[ 211["/var/log/lastlog"])
215#include <sys/types.h>
216#ifdef HAVE_UTMP_H
217#include <utmp.h>
218#endif
219#ifdef HAVE_LASTLOG_H
220#include <lastlog.h>
221#endif
222])
223dnl# -------------------------------------------------------------------------- 212dnl# --------------------------------------------------------------------------
224 213
225dnl# find lastlogx 214dnl# find lastlogx
226PT_FIND_FILE([lastlogx], [LASTLOGX_FILE], [_PATH_LASTLOGX], 215PT_FIND_FILE([lastlogx], [LASTLOGX_FILE], [_PATH_LASTLOGX],
227["/var/log/lastlogx", "/var/adm/lastlogx"],[ 216["/var/log/lastlogx", "/var/adm/lastlogx"])
228#ifdef HAVE_UTMPX_H
229#include <utmpx.h>
230#endif
231])
232]) 217])
233 218
234AC_DEFUN([SCM_RIGHTS_CHECK], 219AC_DEFUN([SCM_RIGHTS_CHECK],
235[ 220[
236AC_CACHE_CHECK(for unix-compliant filehandle passing ability, pt_cv_can_pass_fds, 221AC_CACHE_CHECK(for unix-compliant filehandle passing ability, pt_cv_can_pass_fds,

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines