On 08/03/11 12:30, Stevan Bajić wrote: > On Wed, 03 Aug 2011 11:59:06 -0600 > Jeff Ross<[email protected]> wrote: > >> On 08/03/11 11:41, Stevan Bajić wrote: >>> On Wed, 03 Aug 2011 11:13:28 -0600 Jeff Ross<[email protected]> >>> wrote: >>> >>>> On 08/03/11 10:47, Stevan Bajić wrote: >>>>> On Wed, 03 Aug 2011 09:49:49 -0600 Jeff Ross<[email protected]> >>>>> wrote: >>>>> >>>>>> On 08/03/11 08:59, Tom Hendrikx wrote: >>>>>>> On 03/08/11 16:08, Jeff Ross wrote: >>>>>>>> With PostgreSQL 9.0.4 freshly installed, I'm trying to >>>>>>>> build Dspam-3.10.0 with this configuration: >>>>>>>> >>>>>>>> >>>>>>>> # cat my.configure #!/bin/sh ./configure \ >>>>>>>> --with-storage-driver=pgsql_drv >>>>>>>> --with-pgsql-includes=/usr/local/include/postgresql/ \ >>>>>>>> --with-pgsql-libraries=/usr/local/lib/postgresql/ \ >>>>>>>> --enable-preferences-extension >>>>>>>> >>>>>>>> >>>>>>>> The paths are correct. >>>>>>>> >>>>>>>> # ls -al /usr/local/include/postgresql/libpq-fe.h >>>>>>>> -rw-r--r-- 1 root wheel 20004 Jul 29 17:31 >>>>>>>> /usr/local/include/postgresql/libpq-fe.h >>>>>>>> >>>>>>>> but configure errors out with the following: >>>>>>>> >>>>>>>> checking where to find PostgreSQL headers... compiler >>>>>>>> default paths checking libpq-fe.h usability... no checking >>>>>>>> libpq-fe.h presence... no checking for libpq-fe.h... no >>>>>>>> configure: error: Required version of libpq not found + >>>>>>>> --with-pgsql-includes=/usr/local/include/postgresql/ >>>>>>>> --with-pgsql-libraries=/usr/local/lib/postgresql/ >>>>>>>> --enable-preferences-extension ./my.configure[6]: >>>>>>>> --with-pgsql-includes=/usr/local/include/postgresql/: not >>>>>>>> found >>>>>>>> >>>>>>> >>>>>>> Hi, >>>>>>> >>>>>>> What happens if you pass >>>>>>> --with-pgsql-includes=/usr/local/include/ ? >>>>>>> >>>>>>> >>>>>> >>>>>> Thanks for the thought, but the same error occurs. >>>>>> >>>>> - What system/OS is this? >>>> >>>> OpenBSD heinlein.openvistas.net 5.0 GENERIC.MP#31 i386 >>>> >>>>> - What is the output of 'whereis libpq-fe.h' >>>> >>>> Nothing. locate correctly finds it, though. >>>> >>>>> - Can you post the whole configure log? >>>> >>>> http://www.wykids.org/config.log >>>> >>> Okay. I have read that file and know now what the problem is. The >>> problem is this here: >>> >>> # cat my.configure #!/bin/sh ./configure \ >>> --with-storage-driver=pgsql_drv >>> --with-pgsql-includes=/usr/local/include/postgresql/ \ >>> --with-pgsql-libraries=/usr/local/lib/postgresql/ \ >>> --enable-preferences-extension >>> >>> >>> On the second line you are missing a '\' at the end of the line. That >>> missing backslash is equivalent to the following command: ./configure >>> --with-storage-driver=pgsql_drv >>> >>> The other --with-pgsql-xxxx are not used at all. >>> >> >> Ouch! Sorry about that. >> > Hmmm... I don't say anything. > > >> Now I'm getting a different error: >> >> checking where to find PostgreSQL headers... /usr/local/include/postgresql/ >> checking libpq-fe.h usability... yes >> checking libpq-fe.h presence... yes >> checking for libpq-fe.h... yes >> checking where to find PostgreSQL libraries... /usr/local/lib/postgresql/ >> checking for library containing inet_ntoa... (cached) none required >> checking for library containing socket... (cached) none required >> checking for PQconnectdb in libpq... no >> configure: error: Required version of libpq not found >> > Well... configure is trying to compile this here (conftest.c file): > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > /* confdefs.h */ > #define PACKAGE_NAME "dspam" > #define PACKAGE_TARNAME "dspam" > #define PACKAGE_VERSION "3.10.0" > #define PACKAGE_STRING "dspam 3.10.0" > #define PACKAGE_BUGREPORT "[email protected]" > #define PACKAGE_URL "" > #define PACKAGE "dspam" > #define VERSION "3.10.0" > #define STDC_HEADERS 1 > #define HAVE_SYS_TYPES_H 1 > #define HAVE_SYS_STAT_H 1 > #define HAVE_STDLIB_H 1 > #define HAVE_STRING_H 1 > #define HAVE_MEMORY_H 1 > #define HAVE_STRINGS_H 1 > #define HAVE_INTTYPES_H 1 > #define HAVE_STDINT_H 1 > #define HAVE_UNISTD_H 1 > #define HAVE_DLFCN_H 1 > #define LT_OBJDIR ".libs/" > #define CONFIGURE_ARGS " '--with-storage-driver=pgsql_drv' > '--with-pgsql-includes=/usr/local/include/postgresql/' > '--with-pgsql-libraries=/usr/local/lib/postgresql/' > '--enable-preferences-extension'" > #define HAVE_ISO_VARARGS 1 > #define HAVE_STRING_H 1 > #define HAVE_MATH_H 1 > #define HAVE_SYS_TIME_H 1 > #define TIME_WITH_SYS_TIME 1 > #define HAVE_STRLCPY 1 > #define HAVE_STRSEP 1 > #define HAVE_STRTOK_R 1 > #define HAVE_GETPWNAM_R 1 > #define HAVE_GETPWUID_R 1 > #define HAVE_MEMCPY 1 > #define HAVE_MEMSET 1 > #define HAVE_LOCALTIME_R 1 > #define HAVE_SYS_TYPES_H 1 > #define HAVE_SYS_SOCKET_H 1 > #define HAVE_NETINET_IN_H 1 > #define HAVE_ARPA_INET_H 1 > #define HAVE_STRCASESTR 1 > #define HAVE_SYS_TYPES_H 1 > #define HAVE_SYS_SOCKET_H 1 > #define HAVE_NETINET_IN_H 1 > #define HAVE_ARPA_INET_H 1 > #define TRUSTED_USER_SECURITY 1 > #define USE_SYSLOG 1 > #define MYSQL4_INITIALIZATION 1 > #define PREFERENCES_EXTENSION 1 > /* end confdefs.h. */ > > #include<stdlib.h> > #include<libpq-fe.h> > > int > main () > { > > PGconn *pgsql = PQconnectdb(NULL); > PQfinish(pgsql); > > ; > return 0; > } > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > > With this command: > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > gcc -o conftest -g -O2 -I/usr/local/include/postgresql/ > -L/usr/local/lib/postgresql/ conftest.c -lpq > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > > And is getting this error: > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > /usr/bin/ld: cannot find -lpq > collect2: ld returned 1 exit status > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > > Basically telling you that '-lpq' is a not known parameter because it can not > find the library 'libpq.so'. > > When I test this on my setup with 9.0.4 using different paths then I get: > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > alekto jeff # gcc -o conftest -I/usr/include/postgresql -L/usr/lib conftest.c > -lpq ; echo ${?} > 0 > alekto jeff # > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > > This is because my libpq.so is in /usr/lib: > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > alekto jeff # ls -lah /usr/lib/libpq.so* > lrwxrwxrwx 1 root root 36 Aug 3 19:41 /usr/lib/libpq.so -> > /usr/lib/postgresql-9.0/lib/libpq.so > lrwxrwxrwx 1 root root 38 Aug 3 19:41 /usr/lib/libpq.so.5 -> > /usr/lib/postgresql-9.0/lib/libpq.so.5 > lrwxrwxrwx 1 root root 40 Aug 3 19:41 /usr/lib/libpq.so.5.3 -> > /usr/lib/postgresql-9.0/lib/libpq.so.5.3 > alekto jeff # > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > > Are you sure your libpq.so is in /usr/local/lib/postgresql/? Can you please > issue the following commands and verify that libpq.so is there? > > 1) ls -lah /usr/local/lib/postgresql/libpq.so* > 2) find /usr/local/lib/ -name "libpq.so*"
I am sorely out of practice when it comes to building anything from source. You are right, my libpq file is in /usr/local/lib/. Configure went just fine, now, and dspam.3.10.0 with a postgresql backend is installed! Jeff ------------------------------------------------------------------------------ BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos & much more. Register early & save! http://p.sf.net/sfu/rim-blackberry-1 _______________________________________________ Dspam-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/dspam-user
