summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEzra Peisach <epeisach@mit.edu>2001-06-11 22:32:19 +0000
committerEzra Peisach <epeisach@mit.edu>2001-06-11 22:32:19 +0000
commit3f3a704da40dcc424efcd8cf3a1ada9902a77989 (patch)
treee769f0f87b62e390367d8362a5a2418bfb0ea219 /src
parentaa2a375ef265c9375b9293f614eb5d848d5f1d48 (diff)
downloadkrb5-3f3a704da40dcc424efcd8cf3a1ada9902a77989.tar.gz
krb5-3f3a704da40dcc424efcd8cf3a1ada9902a77989.tar.xz
krb5-3f3a704da40dcc424efcd8cf3a1ada9902a77989.zip
* pty-int.h: Provide revoke() prototype if system headers lacking
* logwtmp.c: Provide logwtmp() prototype if needed. * configure.in: Check for system provided getutmp(), logwtmp() and revoke() prototypes. Check for util.h, libutil.h. * update_wtmp.c: Provide prototype for getutmp() if needed. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@13336 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src')
-rw-r--r--src/util/pty/ChangeLog9
-rw-r--r--src/util/pty/configure.in19
-rw-r--r--src/util/pty/logwtmp.c4
-rw-r--r--src/util/pty/pty-int.h4
4 files changed, 32 insertions, 4 deletions
diff --git a/src/util/pty/ChangeLog b/src/util/pty/ChangeLog
index 8c9f2b2d2..9f897734e 100644
--- a/src/util/pty/ChangeLog
+++ b/src/util/pty/ChangeLog
@@ -1,8 +1,13 @@
2001-06-11 Ezra Peisach <epeisach@mit.edu>
- * configure.in: Check for system provided getutmp() prototype.
+ * pty-int.h: Provide revoke() prototype if system headers lacking.
- * update_wtmp.c: Provide prototype for getutmp() if needed.
+ * logwtmp.c: Provide logwtmp() prototype if needed.
+
+ * configure.in: Check for system provided getutmp(), logwtmp() and
+ revoke() prototypes. Check for util.h, libutil.h.
+
+ * update_wtmp.c: Provide prototype for getutmp() if needed.
2001-05-15 Tom Yu <tlyu@mit.edu>
diff --git a/src/util/pty/configure.in b/src/util/pty/configure.in
index b41790b8e..385727700 100644
--- a/src/util/pty/configure.in
+++ b/src/util/pty/configure.in
@@ -55,8 +55,7 @@ AC_TYPE_MODE_T
AC_CHECK_TYPE(time_t, long)
AC_CHECK_FUNC(strsave,[AC_DEFINE(HAS_STRSAVE)])
AC_CHECK_FUNCS(setreuid gettosbyname setsid ttyname line_push ptsname grantpt openpty)
-AC_CHECK_HEADERS(unistd.h stdlib.h string.h pty.h sys/filio.h sys/sockio.h sys/label.h sys/tty.h ttyent.h lastlog.h sys/select.h sys/ptyvar.h)
-AC_CHECK_HEADERS(sys/wait.h)
+AC_CHECK_HEADERS(unistd.h stdlib.h string.h libutil.h pty.h sys/filio.h sys/sockio.h sys/label.h sys/tty.h sys/wait.h ttyent.h lastlog.h sys/select.h sys/ptyvar.h util.h)
AC_CHECK_FUNCS(waitpid)
DECLARE_SYS_ERRLIST
KRB5_SIGTYPE
@@ -202,6 +201,22 @@ KRB5_NEED_PROTO([#ifdef HAVE_UTMP_H
#endif
],getutmp)
dnl
+#########################################
+KRB5_NEED_PROTO([#include <sys/types.h>
+#ifdef HAVE_UTMP_H
+#include <utmp.h>
+#endif
+#ifdef HAVE_LIBUTIL_H
+#include <libutil.h>
+#endif
+#ifdef HAVE_UTIL_H
+#include <util.h>
+#endif
+],logwtmp)
+########################################
+KRB5_NEED_PROTO([#include <unistd.h>
+],revoke)
+########################################
dnl
AC_MSG_CHECKING([streams interface])
AC_CACHE_VAL(krb5_cv_has_streams,
diff --git a/src/util/pty/logwtmp.c b/src/util/pty/logwtmp.c
index 204727889..6cb696157 100644
--- a/src/util/pty/logwtmp.c
+++ b/src/util/pty/logwtmp.c
@@ -30,6 +30,10 @@
#define PTY_STRUCT_UTMPX struct utmp
#endif
+#ifdef NEED_LOGWTMP_PROTO
+void logwtmp(const char *, const char *, const char *);
+#endif
+
long
pty_logwtmp(const char *tty, const char *user, const char *host)
{
diff --git a/src/util/pty/pty-int.h b/src/util/pty/pty-int.h
index b3c6146a6..62798bc4b 100644
--- a/src/util/pty/pty-int.h
+++ b/src/util/pty/pty-int.h
@@ -99,6 +99,10 @@
extern void getutmpx (const struct utmp *, struct utmpx *);
#endif
+#if defined(NEED_REVOKE_PROTO)
+extern int revoke(const char *);
+#endif
+
/* Internal functions */
long ptyint_void_association(void);
long ptyint_open_ctty (char *slave, int *fd);