Return-Path: Delivered-To: apmail-apr-dev-archive@www.apache.org Received: (qmail 77583 invoked from network); 16 May 2008 10:27:20 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 16 May 2008 10:27:20 -0000 Received: (qmail 967 invoked by uid 500); 16 May 2008 10:27:21 -0000 Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 915 invoked by uid 500); 16 May 2008 10:27:21 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Id: Delivered-To: mailing list dev@apr.apache.org Received: (qmail 903 invoked by uid 99); 16 May 2008 10:27:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 May 2008 03:27:21 -0700 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=FM_FAKE_HELO_VERIZON,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [206.46.173.1] (HELO vms173001pub.verizon.net) (206.46.173.1) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 May 2008 10:26:27 +0000 Received: from black ([71.245.67.80]) by vms173001.mailsrvcs.net (Sun Java System Messaging Server 6.2-6.01 (built Apr 3 2006)) with ESMTPA id <0K0Y00GQVIBUHF88@vms173001.mailsrvcs.net> for dev@apr.apache.org; Fri, 16 May 2008 05:26:19 -0500 (CDT) Received: from bob by black with local (Exim 4.69) (envelope-from ) id 1Jwx8k-00070y-F4; Fri, 16 May 2008 06:26:18 -0400 Date: Fri, 16 May 2008 06:26:18 -0400 From: Bob Rossi Subject: Re: dbd pgsql autotools patch In-reply-to: <1210908869.2743.13.camel@shrek.rexursive.com> To: Bojan Smojver Cc: dev@apr.apache.org Mail-followup-to: Bojan Smojver , dev@apr.apache.org Message-id: <20080516102618.GD23354@brasko.net> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-disposition: inline References: <20080515130851.GC19638@brasko.net> <1210900906.2743.6.camel@shrek.rexursive.com> <20080516031849.GC23354@brasko.net> <1210908869.2743.13.camel@shrek.rexursive.com> User-Agent: Mutt/1.5.17+20080114 (2008-01-14) X-Virus-Checked: Checked by ClamAV on apache.org On Fri, May 16, 2008 at 01:34:29PM +1000, Bojan Smojver wrote: > On Thu, 2008-05-15 at 23:18 -0400, Bob Rossi wrote: > > > Ubuntu 7.04, /lib/libcrypt-2.5.so > > OK. > > > OK, perhaps we should just add -lcrypt to the pg line? I could check to > > see if this works on my system if you think this is a good idea. > > Hmm, not sure if hardcoding here is the right thing to do. I don't see > how that got omitted from the set of libraries that are required. What > do you get when you run apr-1-config --libs (make sure you run > apr-1-config of the one you used to build apr-util)? This is before my patch to the apr-util build system, $ ./apu-1-config --libs -lsqlite3 -lexpat This is after, $ ./apu-1-config --libs -lpq -lpgport -lz -lreadline -lcrypt -ldl -lm -lsqlite3 -lexpat Here is the check for the link against postgresql in my config.log at line 184. configure:34071: checking for PQsendQueryPrepared in -lpq configure:34106: gcc -o conftest -g -Wall -pthread -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -Ipostgresql/postgresql-8.3.1/lib conftest.c -lpq -lpgport -lz -lreadline -lcrypt -ldl -lm >&5 note this is my modified version, the original version only had -lpq, which caused the link to fail. Here is the check for crypt in my config.log, on line 415, configure:40238: checking for library containing crypt configure:40279: gcc -o conftest -g -Wall -pthread -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE conftest.c >&5 /tmp/ccMsXBwK.o: In function `main': conftest.c:35: undefined reference to `crypt' collect2: ld returned 1 exit status configure:40279: gcc -o conftest -g -Wall -pthread -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE conftest.c -lcrypt >&5 configure:40285: $? = 0 configure:40313: result: -lcrypt So, a couple things to note. The apr build system knows that I need -lcrypt in order to get a link against that symbol. It checks for -lcrypt after -lpq. If we reversed the order, we could pass -lcrypt to the postgresql test, if the users system needs that. (I'm just brainstorming here) Bob Rossi