Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 29 May 2010 16:24:47 +1000
From:      Andrew Reilly <areilly@bigpond.net.au>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   bin/147175: libhx509.so containes references to MD2_* but doesn't reference libcrypto.so, which has them
Message-ID:  <1275114287.82624@duncan.reilly.home>
Resent-Message-ID: <201005290630.o4T6U7rR005034@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         147175
>Category:       bin
>Synopsis:       libhx509.so containes references to MD2_* but doesn't reference libcrypto.so, which has them
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat May 29 06:30:07 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Andrew Reilly
>Release:        FreeBSD 9.0-CURRENT amd64
>Organization:
>Environment:
System: FreeBSD duncan.reilly.home 9.0-CURRENT FreeBSD 9.0-CURRENT #6: Sat May 22 10:57:32 EST 2010 root@duncan.reilly.home:/nb/obj/nb/src/sys/DUNCAN amd64


	
>Description:
        When trying to build evolution-data-server (for example:
        fetchmail also has this problem), or anything that
        depends on libhx509.so, the build stops thusly:

/usr/lib/libhx509.so: undefined reference to `MD2_Init'
/usr/lib/libhx509.so: undefined reference to `MD2_Final'
/usr/lib/libhx509.so: undefined reference to `MD2_Update'

        because libhx509.so does have undefined references to
        those functions.  Previously, I've worked around this by
        nuking reference to MD2 from libhx509, on the grounds
        that it is obsolete anyway.  However I have noticed that
        libcrypto does provide these functions, and the library
        config line from krb5-config includes it.  So why are
        they not being picked up?  I don't know much about
        shared libraries, but I ran ldd on /usr/lib/libhx509.so,
        and it says only:

libhx509.so:
	libc.so.7 => /lib/libc.so.7 (0x800648000)

        could it be that the shared lib version of libhx509.so
        needs to refer to /lib/libcrypto.so.6 explicitly, even
        though it is listed on the compiler command line like
        this?

cc -o conftest -O2 -pipe -g -DLDAP_DEPRECATED -fno-strict-aliasing -I/usr/local/include -I/usr/local/include/db41 -L/usr/local/lib -pthread  conftest.c  -L/usr/local/lib -L/usr/lib -lgssapi -lheimntlm -lkrb5 -lhx509 -lcom_err -lcrypto -lasn1 -lroken -lcrypt

>How-To-Repeat:
        Compile databases/evolution-data-server with
        "NO_KERBEROS" defined in make.conf and line 16071 of
        ports/databases/work/evolution-data-server-2.30.1/config
        changed thusly:

	heimlibs="`/usr/bin/krb5-config gssapi --libs`"

        and the next few lines changed thusly (I haven't figured
        out which is the "right" one):

        mitlibs="$heimlibs"
	sunlibs="$heimlibs"

        Plenty of other builds that depend on gssapi fail the
        same way, though.  Fetchmail is the example I used in
        PR: ports/145769.

>Fix:

        Working on it.  Trying to figure out how to add
        dependencies to shared libraries...


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1275114287.82624>