setlogin failed: Function not implemented

Eivind Magnus Hvidevold emh at hvidevold.cjb.net
Mon Oct 27 11:27:15 EST 2003


On Mon, Oct 27, 2003 at 10:10:11AM +1100, Darren Tucker wrote:
> Ben Lindstrom wrote:
> > 
> > On Mon, 27 Oct 2003, Darren Tucker wrote:
> > 
> > > Eivind Magnus Hvidevold wrote:
> > > > When configuring openssh I get this in config.log:
> > > > configure:6557: checking for setlogin
> > > > configure:6594: gcc -o conftest -g -O2 -Wall -Wpointer-arith -Wno-uninitialized   conftest.c -lutil -lz -lnsl  >&5
> > > > /tmp/cc4nGZCj.o: In function `main':
> > > > /tmp/build/openssh-3.7.1p2/configure:6585: warning: setlogin is not implemented and will always fail
> > >
> > > One other thing: maybe configure could test for errno == ENOSYS when
> > > checking for setlogin?
> > 
> > If it detects more stupid groups that don't have enough common sense to
> > not implemention an API instead of doing a stub then I say go for it.
> 
> Eivind, please try this patch.  You'll need to run "autoreconf" after
> applying it, then run "./configure && make".
> 
> If this works out I might look at doing the same thing for setresuid and
> setresgid since they have the same problem on some Linuxes.

Your patch works perfectly. Thanks!
But I think something may have gone wrong when I compiled glibc, because
/usr/include/gnu/stubs.h was empty. I tried replacing it with one from
Mandrake (9.2rc1) and then setlogin was detected as non-implemented even
without your patch. I'm using glibc-2.3.1, btw.

EMH




More information about the openssh-unix-dev mailing list