RE: How to install SASL 2.1.18 in an environment with multiple ve rsions of BerkeleyDB?

From: Lim, Keh Boon (KehBoon dot Lim at atosorigin dot com)
Date: Wed Jun 09 2004 - 00:05:38 EDT

  • Next message: amendola maurizio: "problem cyrus-sasl with berkeley db 3.3 and db4.2.52"

    It works! Jeremy, thanks again!

    Here is the ldd output:
    [root at mail1 cyrus-sasl-2.1.18]# ldd /usr/local/sasl/sbin/saslpasswd2
    libpthread.so.0 => /lib/tls/libpthread.so.0 (0xb75ca000)
            libresolv.so.2 => /lib/libresolv.so.2 (0xb75b8000)
            libsasl2.so.2 => /usr/local/sasl/lib/libsasl2.so.2 (0xb75a5000)
            libdl.so.2 => /lib/libdl.so.2 (0xb75a2000)
            libdb-4.2.so => /usr/local/BerkeleyDB.4.2/lib/libdb-4.2.so
    (0xb74f6000)
            libc.so.6 => /lib/tls/libc.so.6 (0xb73be000)
            /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0xb75eb000)

    Somtimes it is really difficult for administrator without much programming
    experience to build certain application from the source. Sometimes I'm
    totally lost in trying to set these setting: LD_RUN_PATH, LD_LIBRARY_PATH,
    CPPFLAGS, LDFLAGS, ld.so.conf, with-bdb-inc=..., etc.

    -----Original Message-----
    From: Jeremy Rumpf [mailto:jrumpf at heavyload dot net]
    Sent: Wednesday, June 09, 2004 11:41 AM
    To: Lim, Keh Boon
    Cc: 'cyrus-sasl at lists dot andrew dot cmu dot edu'
    Subject: Re: How to install SASL 2.1.18 in an environment with multiple
    ve rsions of BerkeleyDB?

    On Tuesday 08 June 2004 11:13 pm, Lim, Keh Boon wrote:
    > Jeremy, thank for your reply.
    >
    > With "export CC='gcc -lpthread'", the "undefined reference" error is
    > resolved. However, SASL still can't be compiled against the new Berekey DB
    > library.
    >
    > Take saslpasswd2 for example, the ldd output shows that the program is
    > linked against the bdb library that comes with RHEL 3.0, not the one I
    > installed from tar ball (version 4.2.52, in the /usr/local/BerkeleyDB.4.2
    > directory).
    >
    > # ldd /usr/local/sasl/sbin/saslpasswd2
    > libpthread.so.0 => /lib/tls/libpthread.so.0 (0xb75ca000)
    > libresolv.so.2 => /lib/libresolv.so.2 (0xb75b8000)
    > libsasl2.so.2 => /usr/local/sasl/lib/libsasl2.so.2 (0xb75a5000)
    > libdl.so.2 => /lib/libdl.so.2 (0xb75a2000)
    > libdb-4.1.so => /lib/libdb-4.1.so (0xb74df000)
    > libc.so.6 => /lib/tls/libc.so.6 (0xb73a7000)
    > /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0xb75eb000)
    >
    > The same "configure" command works fine in Redhat 8.0 environment, in
    which
    > there are also with two versions of Berkeley DB library: the one that
    comes
    > with Redhat 8.0 (version 4.0.14); the other one that I installed from tar
    > ball (version 4.2.52, in the /usr/local/BerkeleyDB.4.2 directory).
    >
    > # ldd /usr/local/sasl/sbin/saslpasswd2
    > libresolv.so.2 => /lib/libresolv.so.2 (0x4001e000)
    > libsasl2.so.2 => /usr/local/sasl/lib/libsasl2.so.2 (0x40031000)
    > libdl.so.2 => /lib/libdl.so.2 (0x40044000)
    > libdb-4.2.so => /usr/local/BerkeleyDB.4.2/lib/libdb-4.2.so
    > (0x40047000)
    > libc.so.6 => /lib/i686/libc.so.6 (0x42000000)
    > /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
    >
    > I suspect the problem lies in the configure script comes with SASL
    library,
    > but I don't know how to fix it. I tried CPPFLAGS and LDFLAGS and got the
    > same result.
    >
    > I notice that of all sasl libraries and programs, only sasldblistusers2
    and
    > saslpasswd2 are linked aginst dbd library, and that I need saslpasswd2
    only
    > if I use sasldb as pwcheck_method.
    >
    > So if I can't resolve the SASL issue in RHEL 3.0, can I compile sasl
    > library against os bdb (db 4.1) and other applications (e.g. openLDAP,
    > sendmail, Squirrelmail) against db 4.2? I've heard of the "sasl mismatch"
    > problem with openLDAP.
    >
    >
    ^^^^^^^^^^^__________________ I'm not sure I can comment on using different
    versions of Berkeley (no experience in doing it), but my advice would be to
    avoid it if possible.

    The CC var is run throughout the configure script, it's the best place to
    put
    broad library defines and such. A lot of times, LDFLAGS is only taken into
    account during the compile and not the configure checks.

    With that in mind, let's get heavy handed with this:

    export LD_LIBRARY_PATH="/usr/local/BerkeleyDB.4.2/lib:$LD_LIBRARY_PATH"
    export CC='gcc -lpthread -L/usr/local/BerkeleyDB.4.2/lib'

    ./configure --enable-plain --enable-login
    --disable-krb4 --disable-otp --disable-cram --disable-digest
    --with-saslauthd=/var/run/saslauthd --with-pam=/lib/security
    --with-dblib=berkeley --with-bdb-libdir=/usr/local/BerkeleyDB.4.2/lib
    --with-bdb-incdir=/usr/local/BerkeleyDB.4.2/include
    --with-openssl=/usr/local/ssl --with-plugindir=/usr/local/lib/sasl2

    Cheers,
    Jeremy


  • Next message: amendola maurizio: "problem cyrus-sasl with berkeley db 3.3 and db4.2.52"





    Hosted Email Solutions

    Invaluement Anti-Spam DNSBLs



    Powered By FreeBSD   Powered By FreeBSD