Jonathan McDowell <[EMAIL PROTECTED]> writes:
> Running ./configure I get:
>
> checking for BSD pty names... sort: read error: Bad file descriptor
> done
I seem to recall a bug in some version of /bin/sh. Can you try running
bash ./configure
and see if that works better?
> Then a 'make':
>
> unix_user.c:393: structure has no member named `ut_user'
Seems I missed that usage of ut_user. I'm checking in this patch:
diff -u -a -r1.14 unix_user.c
--- unix_user.c 2000/05/08 20:17:26 1.14
+++ unix_user.c 2000/05/09 08:29:18
@@ -390,7 +390,12 @@
if (log)
/* FIXME: It should be safe to perform a blocking reverse dns lookup here,
* as we have forked. */
+#if HAVE_UT_NAME
+ logwtmp(log->ut_line, log->ut_name, log->ut_host);
+#elif HAVE_UT_USER
logwtmp(log->ut_line, log->ut_user, log->ut_host);
+#endif
+
#endif /* WITH_UTMP && HAVE_LOGWTMP */
if (getuid() != user->super.uid)
> <utmp.h> needs <sys/types.h>; could be causing problems in the configure
> script?
To me, the configure problem seems unrelated to the tests for utmp
members. If you got HAVE_UT_* defined properly, that part of the
configure script seems to work.
> If I define PTY_BSD_SCHEME_FIRST_CHARS and PTY_BSD_SCHEME_SECOND_CHARS
> in config.h then I get listed in 'last' but not 'w' (so that's wtmp
> stuff working, but not utmp, right?) and I get a prompt ok.
Correct. That's as good as it gets with the current version.
> Getting there. I'll see if I can figure out why the configure script
> doesn't grab the PTY stuff properly and also poke utmp.
Better utmp support would be great. Please send patches (preferably in
unified format, as produced by diff -u) to the list, as I will be
unavailable for some time.
Happy hacking,
/Niels