Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 01 Dec 2010 16:16:17 +0200
From:      Andriy Gapon <avg@freebsd.org>
To:        gnome@freebsd.org
Cc:        Joe Marcus Clarke <marcus@freebsd.org>
Subject:   Re: databases/evolution-data-server, base kerberos and security/openssl
Message-ID:  <4CF658B1.2060102@freebsd.org>
In-Reply-To: <4CF52E61.9090405@freebsd.org>
References:  <4CF52E61.9090405@freebsd.org>

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

devel/bug-buddy is affected by the same issue (via evolution-data-server
dependency, I think).

on 30/11/2010 19:03 Andriy Gapon said the following:
> 
> It seems that databases/evolution-data-server fails the configure stage if
> 1. a base system does have kerberos in it;
> 2. security/heimdal is not installed;
> 3. there are no special flags like NO_KERBEROS in make.conf;
> 4. security/openssl (openssl-1.0.0*) is installed.
> 
> Excerpts from config.log:
> ...
> $ ./configure --enable-static --enable-gnome-keyring=yes --with-openldap=yes
> --with-libdb=/usr/local --with-krb5=/usr --without-weather
> --localstatedir=/usr/local/share --with-html-dir=/usr/local/share/doc
> --disable-gtk-doc
> --with-gconf-source=xml:merged:/usr/local/etc/gconf/gconf.xml.defaults
> --prefix=/usr/local --mandir=/usr/local/man --infodir=/usr/local/info/
> --build=amd64-portbld-freebsd8.1
> ...
> configure:16108: cc -o conftest -O2 -pipe -O2 -fno-strict-aliasing -pipe
> -march=nocona -DLDAP_DEPRECATED -I/usr/local/include -I/usr/local/include/db41
> -L/usr/local/lib -pthread  conftest.c  -L/usr/lib -L/usr/lib -lgssapi -lheimntlm
> -lkrb5 -lhx509 -lcom_err -lcrypto -lasn1 -lroken -lcrypt >&5
> /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'
> ...
> 
> The problem is that -L/usr/local/lib comes before -L/usr/lib and as such
> libcrypto.so from openssl-1.0.0* wins over libcrypto.so from the base, but the
> former has an incompatible API and doesn't provide the quoted above symbols.
> 
> The reason that /usr/local/lib appears sooner in the library search path is in the
> port's Makefile:
> CONFIGURE_ENV=	... \
> 		LDFLAGS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
> It seems that LDFLAGS passed via configure's environment get prepended before any
> linker flags tested/discovered by configure.
> 
> I am sure that there is a reason to have -L${LOCALBASE}/lib explicitly specified
> in the LDFLAGS.  The following modification fixes the port build in the specified
> environment:
> CONFIGURE_ENV=	... \
> 		LDFLAGS="-L/usr/lib -L${LOCALBASE}/lib ${PTHREAD_LIBS}"
> 
> Perhaps this modification should be conditional in the same way as --with-krb5
> setting in CONFIGURE_ARGS.
> 
> Thanks!


-- 
Andriy Gapon



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