From owner-freebsd-questions@FreeBSD.ORG Tue Jun 20 22:45:24 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0325C16A47A for ; Tue, 20 Jun 2006 22:45:24 +0000 (UTC) (envelope-from duane@dwpc.dwlabs.ca) Received: from smtpout.eastlink.ca (smtpout.eastlink.ca [24.222.0.30]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8F8A643D5D for ; Tue, 20 Jun 2006 22:45:18 +0000 (GMT) (envelope-from duane@dwpc.dwlabs.ca) Received: from ip02.eastlink.ca ([24.222.10.10]) by mta01.eastlink.ca (Sun Java System Messaging Server 6.2-4.03 (built Sep 22 2005)) with ESMTP id <0J160042GKK7PFB1@mta01.eastlink.ca> for freebsd-questions@freebsd.org; Tue, 20 Jun 2006 19:45:43 -0300 (ADT) Received: from blk-224-199-230.eastlink.ca (HELO dwpc.dwlabs.ca) ([24.224.199.230]) by ip02.eastlink.ca with ESMTP; Tue, 20 Jun 2006 19:45:13 -0300 Received: from dwpc.dwlabs.ca (localhost [127.0.0.1]) by dwpc.dwlabs.ca (8.13.6/8.13.6) with ESMTP id k5KMiW66095279 for ; Tue, 20 Jun 2006 19:44:32 -0300 (ADT envelope-from duane@dwpc.dwlabs.ca) Received: (from duane@localhost) by dwpc.dwlabs.ca (8.13.6/8.13.6/Submit) id k5KMiW8T095278 for freebsd-questions@freebsd.org; Tue, 20 Jun 2006 19:44:32 -0300 (ADT envelope-from duane) Date: Tue, 20 Jun 2006 19:44:32 -0300 From: Duane Whitty To: freebsd-questions@freebsd.org Message-id: <20060620224432.GA2787@dwpc.dwlabs.ca> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT Content-disposition: inline X-BrightmailFiltered: true X-Brightmail-Tracker: AAAAAQAAA+k= User-Agent: Mutt/1.4.2.1i Subject: Unable to build Sendmail with LDAP X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Jun 2006 22:45:24 -0000 Hi, I am currently unable to rebuild Sendmail with LDAP support. Unfortunately I am not sure what broke it; it could be my upgrade from OpenLDAP 2.2.30 to 2.3.24 or my upgrade from OpenSSL 0.9.8a to 0.9.8b. Foolishly, I did both at the same time without testing after each one. I do know it is not because of the recent Sendmail patch nor because of a change in 6-STABLE. As well, I am able to build Sendmail if I eliminate LDAP support. Here is what I am currently running. dwpc@ /home/build/src# uname -a FreeBSD dwpc.dwlabs.ca 6.1-STABLE FreeBSD 6.1-STABLE #1: Mon Jun 19 13:44:08 ADT 2006 duane@dwpc.dwlabs.ca:/usr/obj/usr/src/sys/DWPC-KERNEL i386 dwpc@ /home/build/src# sendmail -d0.1 -bt
dwpc@ /home/build/src# pkg_info | grep open openldap-sasl-client-2.3.24 Open source LDAP client implementation with SASL2 support openldap-server-2.3.24 Open source LDAP server implementation openssl-0.9.8b_1 SSL and crypto library /etc/make.conf KERNCONF=DWPC-KERNEL NO_PROFILE=1 # added by use.perl 2006-04-01 17:11:27 PERL_VER=5.8.8 PERL_VERSION=5.8.8 # Tried first with the following two lines uncommented # and then retried compiling with them commented out # WANT_LDAP_VER=23 # WITH_LDAP_PORT=yes SENDMAIL_CFLAGS=-I/usr/local/include -DSASL2=2 -DLDAPMAP SENDMAIL_LDFLAGS=-L/usr/local/lib SENDMAIL_LDADD=-lsasl2 -lldap -llber I first went through the compilation routine using my usual /usr/src build tree after upgrading OpenSSL and OpenLDAP. After a reboot I noticed that everything which used OpenSSL or OpenLDAP had failed so I upgraded all my ports applications. All's well, except for Sendmail. So here is the output [snipped to relevant section] of my make buildworld. The full make buildworld output is available at http://www.dwlabs.ca/freebsd/build/buildworld-1 ===> libexec/mail.local (all) cc -O2 -fno-strict-aliasing -pipe -I/home/build/src/libexec/mail.local/../../contrib/sendmail/include -I. -I/usr/local/include -DSASL2=2 -DLDAPMAP -c /home/build/src/libexec/mail.local/../../contrib/sendmail/mail.local/mail.local.c cc -O2 -fno-strict-aliasing -pipe -I/home/build/src/libexec/mail.local/../../contrib/sendmail/include -I. -I/usr/local/include -DSASL2=2 -DLDAPMAP -L/usr/local/lib -o mail.local mail.local.o /usr/obj/home/build/src/libexec/mail.local/../../lib/libsm/libsm.a -lsasl2 -lldap -llber /usr/obj/home/build/src/tmp/usr/bin/ld: warning: libssl.so.5, needed by /usr/local/lib/libldap.so, not found (try using -rpath or -rpath-link) /usr/obj/home/build/src/tmp/usr/bin/ld: warning: libcrypto.so.5, needed by /usr/local/lib/libldap.so, not found (try using -rpath or -rpath-link) /usr/local/lib/libldap.so: undefined reference to `SSL_CTX_set_tmp_rsa_callback' [snip -- more "undefined reference to ..." messages] *** Error code 1 Stop in /home/build/src/libexec/mail.local. *** Error code 1 Stop in /home/build/src/libexec. *** Error code 1 Stop in /home/build/src. *** Error code 1 Stop in /home/build/src. *** Error code 1 Stop in /home/build/src. What has me puzzled is that the shared libraries ld says it can't find are present and where they should be: dwpc@ /usr/local/lib# ll libssl* -rw-r--r-- 1 root wheel 353678 Jun 19 02:31 libssl.a lrwxr-xr-x 1 root wheel 11 Jun 19 02:31 libssl.so -> libssl.so.5 -r--r--r-- 1 root wheel 259018 Jun 19 02:31 libssl.so.5 lrwxr-xr-x 1 root wheel 12 Jun 17 07:54 libssl3.so -> libssl3.so.1 -r-xr-xr-x 1 root wheel 141960 Jun 17 07:56 libssl3.so.1 dwpc@ /usr/local/lib# ll libldap* lrwxr-xr-x 1 root wheel 16 Jun 19 03:31 libldap-2.3.so -> libldap-2.3.so.2 -rw-r--r-- 1 root wheel 229979 Jun 19 03:31 libldap-2.3.so.2 -rw-r--r-- 1 root wheel 280354 Jun 19 03:31 libldap.a -rw-r--r-- 1 root wheel 865 Jun 19 03:31 libldap.la lrwxr-xr-x 1 root wheel 16 Jun 19 03:31 libldap.so -> libldap-2.3.so.2 lrwxr-xr-x 1 root wheel 18 Jun 19 03:31 libldap_r-2.3.so -> libldap_r-2.3.so.2 -rw-r--r-- 1 root wheel 251450 Jun 19 03:31 libldap_r-2.3.so.2 -rw-r--r-- 1 root wheel 313272 Jun 19 03:31 libldap_r.a -rw-r--r-- 1 root wheel 879 Jun 19 03:31 libldap_r.la lrwxr-xr-x 1 root wheel 18 Jun 19 03:31 libldap_r.so -> libldap_r-2.3.so.2 dwpc@ /usr/local/lib# ldd /usr/local/lib/libldap.so /usr/local/lib/libldap.so: liblber-2.3.so.2 => /usr/local/lib/liblber-2.3.so.2 (0x28189000) libsasl2.so.2 => /usr/local/lib/libsasl2.so.2 (0x28194000) libssl.so.5 => /usr/local/lib/libssl.so.5 (0x281a9000) libcrypto.so.5 => /usr/local/lib/libcrypto.so.5 (0x281e1000) libc.so.6 => /lib/libc.so.6 (0x28080000) If needed I can backout the necessary ports to previous versions. However, I'd rather help anyway I can if it turns out there is a problem with OpenSSL or OpenLDAP as opposed to it just being something I did wrong. --Duane Whitty