Hello.  I finally got a chance to try playing with the new SASL support in
nmh 1.0.4+dev, but while trying to build I discovered nmh is currently
broken.  Using cyrus-sasl, gcc and Sun ld on Solaris 2.6, the build got to
this point and then died:

    gcc -s -o post post.o aliasbr.o ../config/version.o ../config/config.o\
     ../sbr/libmh.a ../mts/libmts.a   -L/usr/local/lib -lsasl  -lsocket -lnsl 
    Undefined                       first referenced
     symbol                             in file
    ruserpass                           ../mts/libmts.a(smtp.o)
    ld: fatal: Symbol referencing errors. No output written to post
    collect2: ld returned 1 exit status
    make[1]: *** [post] Error 1
    make[1]: Leaving directory `/usr/local/src/nmh-cvs/nmh/uip'

There's no ruserpass() on Solaris, so libmts.a has to get it out of libmh.a
(and indeed even if there were an ruserpass() on Solaris, it has to get it
out of libmh.a anyway, as Shantonu changed things on May 7 so that we never
use the OS ruserpass()).  However, since the linker does its final pull of
symbols out of a library at the point it appears on the commandline, it's
too late to get ruserpass() out of libmh.a, as it appeared before libmts.a
on the commandline.

I looked at the CVS log for uip/Makefile.in and I see that on July 20, I
applied a patch from Ken Hornstein which fixed problems caused by Kimmo not
integrating Ken's SASL patches correctly with Ruud's mts/sendmail + mts/smtp
merge.  This patch, among other things, swapped libmh.a and $(MTSLIB) to
have libmh.a come second, which is as it should be, so ruserpass() can be
found correctly.

However, on September 8, when Shantonu made the new libmts.a, he reversed
the order again, so that now libmh.a comes first, which is no good because
nmh's ruserpass() can't be found correctly.  Shantonu, were you by any
chance doing all your testing on an OS with a native ruserpass()?

In any case, I commited a fix that put libmh.a second again, and now Solaris
builds correctly, but when I tried building this version on my local
workstation, an AIX 4.1 machine (with gcc and GNU ld, and without
cyrus-sasl), the build failed thusly:

    gcc -g -o anno anno.o annosbr.o ../config/version.o ../config/config.o\
     ../mts/libmts.a  ../sbr/libmh.a    
    ../sbr/libmh.a(m_getfld.o): In function `m_unknown':
    m_getfld.c:555: undefined reference to `mmdlm2'
    m_getfld.c(.pr+0xd62): undefined reference to `mmdlm2'
    m_getfld.c:556: undefined reference to `mmdlm2'
    m_getfld.c:557: undefined reference to `mmdlm2'
    ../sbr/libmh.a(m_getfld.o)(.tc+0x0):m_getfld.c: undefined reference to\
     `mmdlm2'
    make[1]: *** [anno] Error 1
    make[1]: Leaving directory `/usr/local/src/nmh-cvs/nmh/uip'

Putting libmts.a second lets it go on, but clearly something is wrong here,
if one library order doesn't work on all platforms.

I haven't tried going back to earlier source out of CVS to test this theory,
but I'm guessing Shantonu didn't do his libsmtp.a + libzot.a = libmts.a
merge correctly and that there are circular dependencies between it and
libmh.a.  Shantonu, can you look at this?

-----------------------------------------------------------------------
Dan Harkless                   | To prevent SPAM contamination, please 
[EMAIL PROTECTED]      | do not post this private email address
SpeedGate Communications, Inc. | to the USENET or WWW.  Thank you.     

Reply via email to