Subject: pkg/32969: problems building mail/gld with pgsql
To: None <firstname.lastname@example.org, email@example.com,>
From: None <firstname.lastname@example.org>
Date: 03/02/2006 19:25:00
>Synopsis: problems building mail/gld with pgsql
>Arrival-Date: Thu Mar 02 19:25:00 +0000 2006
>Release: NetBSD 3.0
System: NetBSD mickey 3.0 NetBSD 3.0 (GENERIC) #0: Sun Dec 18 12:14:58 CST 2005 oster@gonzo:/u1/builds/build94/src/sys/arch/i386/compile/GENERIC i386
gld should be able to work with a pgsql database instead of a mysql
database. And even though there are hints that mail/gld should be
easily configurable for pgsql, that doesn't currently seem to be the case.
Items of lossage include:
in /etc/mk.conf gets me:
===> Choose one option: mysql or pgsql.
*** Error code 1
gets me further along, but in the end it tries to link with
mysqlclient, and I end up with:
cc -O2 -DHAVE_SYS_TIME_H=1 -DHAVE_SYSLOG_H=1 -DHAVE_NETDB_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_SELECT=1 -DHAVE_STRSTR=1 -DHAVE_FORK=1 -DHAVE_ACCEPT=1 -DHAVE_WAIT=1 -DHAVE_SHUTDOWN=1 -DHAVE_GETHOSTBYNAME=1 -DHAVE_BZERO=1 -DHAVE_BCOPY=1 -DHAVE_CONNECT=1 -DHAVE_BIND=1 -DHAVE_SENDTO=1 -DHAVE_GETHOSTBYADDR=1 -DHAVE_GETPEERNAME=1 -DHAVE_SETSOCKOPT=1 -DHAVE_WAITPID=1 -DHAVE_SSCANF=1 -Wall server.o sql.o sockets.o cnf.o greylist.o -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -L/usr/lib -Wl,-R/usr/lib -lmysqlclient -o gld
ld: cannot find -lmysqlclient
*** Error code 1
Also note from the above that no "-lpq" appears in the above, so even
if "-lmysqlclient" is removed, the postgresql libraries would not be
3) If I bash options.mk to add:
for the ".if !empty(PKG_OPTIONS:Mpgsql)" case, and remove
"-lmysqlclient" from patches/patch-aa , and then change options.mk
so it reads:
then it will build+link gld with the postgresql bits. However, when
it prints the MESSAGE file, it only prints the information related to
the mysql setup. (i.e. it doesn't talk about pgsql, or about the
existence of tables.pgsql )
All this said, I havn't actually tested gld with postgresql at this
point -- all I've done is got it to build and link.
workarounds above. I doubt they are entirely the proper fix.