Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: DBMail: users

dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries

 

 

DBMail users RSS feed   Index | Next | Previous | View Threaded


loupicciano at comcast

Feb 23, 2010, 5:56 AM

Post #1 of 5 (643 views)
Permalink
dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries

Hello dbmailers!


Has anyone had luck compiling dbmail against PostgreSQL not located in /usr/? We've tried various options to the ./configure script, but config always reports:



checking PostgreSQL headers... -I/usr/include/pgsql
checking PostgreSQL libraries... -L/usr/lib -lpq


Have tried a CPPFLAGS approach; this hasn't worked.


Also tried directing the --with-pgsql option directly to pg_config, or to the libraries...


Have even tried fiddling with the Makefiles directly, so far with no joy.


Is there a direct way to do this? We keep PostgreSQL in any of several other locations...


Platform: Solaris 10 SPARC


Thanks, Lou


paul at nfg

Feb 23, 2010, 6:41 AM

Post #2 of 5 (618 views)
Permalink
Re: dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries [In reply to]

Lou,

Apparently you already have a postgres development environment
installed. Dbmail's autoconfigure will locate and use pg_config as
available in the PATH. If you want to use an other pg_config located
elsewhere you may need to tweak the path, move the default pg_config
elsewhere, or use a combination.


Lou Picciano wrote:
> Hello dbmailers!
>
> Has anyone had luck compiling dbmail against PostgreSQL /not/ located in
> /usr/? We've tried various options to the ./configure script, but
> config always reports:
>
> checking PostgreSQL headers... -I/usr/include/pgsql
> checking PostgreSQL libraries... -L/usr/lib -lpq
>
> Have tried a CPPFLAGS approach; this hasn't worked.
>
> Also tried directing the --with-pgsql option directly to pg_config, or
> to the libraries...
>
> Have even tried fiddling with the Makefiles directly, so far with no joy.
>
> Is there a direct way to do this? We keep PostgreSQL in any of several
> other locations...
>
> Platform: Solaris 10 SPARC
>
> Thanks, Lou
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> DBmail mailing list
> DBmail [at] dbmail
> http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail


--
________________________________________________________________
Paul Stevens paul at nfg.nl
NET FACILITIES GROUP GPG/PGP: 1024D/11F8CD31
The Netherlands________________________________http://www.nfg.nl
_______________________________________________
DBmail mailing list
DBmail [at] dbmail
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail


loupicciano at comcast

Feb 23, 2010, 6:56 AM

Post #3 of 5 (624 views)
Permalink
Re: dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries [In reply to]

Paul -


Thanks for getting back. By 'tweaking the path', presumably you are suggesting I tweak the PATH variable itself - which I haven't yet tried. Will do so and report back. I have not been able to pass any path option to the --with-pgsql directive. Should I be able to? If so, to what exactly should it point?


I believe, in one of my earlier tests, that I simply moved the pg_config for our desired link target into the path .configure searches; this also did not work.


Yes, we do maintain several PostgreSQL environments; some production, others related to our testing of PostgreSQL 8.5-alpha releases.


Will post findings to the list. Lou

----- Original Message -----
From: "Paul J Stevens" <paul [at] nfg>
To: "DBMail mailinglist" <dbmail [at] dbmail>
Sent: Tuesday, February 23, 2010 9:41:41 AM GMT -05:00 US/Canada Eastern
Subject: Re: [Dbmail] dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries

Lou,

Apparently you already have a postgres development environment
installed. Dbmail's autoconfigure will locate and use pg_config as
available in the PATH. If you want to use an other pg_config located
elsewhere you may need to tweak the path, move the default pg_config
elsewhere, or use a combination.


Lou Picciano wrote:
> Hello dbmailers!
>
> Has anyone had luck compiling dbmail against PostgreSQL /not/ located in
> /usr/? We've tried various options to the ./configure script, but
> config always reports:
>
> checking PostgreSQL headers... -I/usr/include/pgsql
> checking PostgreSQL libraries... -L/usr/lib -lpq
>
> Have tried a CPPFLAGS approach; this hasn't worked.
>
> Also tried directing the --with-pgsql option directly to pg_config, or
> to the libraries...
>
> Have even tried fiddling with the Makefiles directly, so far with no joy.
>
> Is there a direct way to do this? We keep PostgreSQL in any of several
> other locations...
>
> Platform: Solaris 10 SPARC
>
> Thanks, Lou
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> DBmail mailing list
> DBmail [at] dbmail
> http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail


--
________________________________________________________________
Paul Stevens paul at nfg.nl
NET FACILITIES GROUP GPG/PGP: 1024D/11F8CD31
The Netherlands________________________________http://www.nfg.nl
_______________________________________________
DBmail mailing list
DBmail [at] dbmail
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail


paul at nfg

Feb 23, 2010, 7:15 AM

Post #4 of 5 (619 views)
Permalink
Re: dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries [In reply to]

Lou Picciano wrote:
> Paul -
>
> Thanks for getting back. By 'tweaking the path', presumably you are
> suggesting I tweak the PATH variable itself - which I haven't yet tried.
> Will do so and report back. I have not been able to pass any path
> option to the --with-pgsql directive. Should I be able to? If so, to
> what exactly should it point?

As I said, configure simply runs pg_config to find the include files and
libs. No arguments or options. You'll have to edit acinclude.m4 and
re-run autoreconf -i

>
> I believe, in one of my earlier tests, that I simply moved the pg_config
> for our desired link target into the path .configure searches; this also
> did not work.

Does the pg_config of the target postgres installation return the
correct values for pg_config --includedir and pg_config --libs?

>
> Yes, we do maintain several PostgreSQL environments; some production,
> others related to our testing of PostgreSQL 8.5-alpha releases.

chroot maybe?



--
________________________________________________________________
Paul Stevens paul at nfg.nl
NET FACILITIES GROUP GPG/PGP: 1024D/11F8CD31
The Netherlands________________________________http://www.nfg.nl
_______________________________________________
DBmail mailing list
DBmail [at] dbmail
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail


loupicciano at comcast

Feb 23, 2010, 8:07 AM

Post #5 of 5 (614 views)
Permalink
Re: dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries [In reply to]

Paul, before getting your last email, tried a modification of my PATH env variable in this environment:


# export PATH=/usr/local/postgres/8.5-alpha2/bin:$PATH


Pls note the following output from ./configure script:


checking for pg_config... /usr/local/postgres/8.5-alpha2/bin/pg_config
checking PostgreSQL headers... -I/usr/local/postgres/8.5-alpha2/include
checking PostgreSQL libraries... -L/usr/local/postgres/8.5-alpha2/lib -lpq
....
PGSQL: -L/usr/local/postgres/8.5-alpha2/lib -lpq


Looked pretty good, right? configs and compiles quite nicely.


However, built libs seem to still be linked to wrong PostgreSQL libs (further, this seems to uncover the add'l problem of linking to the wrong SSL and crytp libs - that's next!):



# ldd /usr/local/lib/dbmail/libpgsql.so
....
libpq.so.4 => /usr/lib/libpq.so.4
....
libssl.so.0.9.7 => /usr/sfw/lib/libssl.so.0.9.7
libcrypto.so.0.9.7 => /usr/sfw/lib/libcrypto.so.0.9.7
....
libssl_extra.so.0.9.7 => /usr/sfw/lib/libssl_extra.so.0.9.7
libcrypto_extra.so.0.9.7 => /usr/sfw/lib/libcrypto_extra.so.0.9.7


Yes, the pg_config of the target PostgreSQL does emit all the right paths... However, how do I 'point' to it correctly (other than copying it directly into /usr/bin, where configure is looking for it)? Next, I'll try your suggestion about editing acinclude.m4 and re-running autoreconf -i


More testing to follow. Lou

----- Original Message -----
From: "Paul J Stevens" <paul [at] nfg>
To: "DBMail mailinglist" <dbmail [at] dbmail>
Sent: Tuesday, February 23, 2010 10:15:05 AM GMT -05:00 US/Canada Eastern
Subject: Re: [Dbmail] dbmail 2.2.15 - want to compile against diferent PostgreSQL libraries

Lou Picciano wrote:
> Paul -
>
> Thanks for getting back. By 'tweaking the path', presumably you are
> suggesting I tweak the PATH variable itself - which I haven't yet tried.
> Will do so and report back. I have not been able to pass any path
> option to the --with-pgsql directive. Should I be able to? If so, to
> what exactly should it point?

As I said, configure simply runs pg_config to find the include files and
libs. No arguments or options. You'll have to edit acinclude.m4 and
re-run autoreconf -i

>
> I believe, in one of my earlier tests, that I simply moved the pg_config
> for our desired link target into the path .configure searches; this also
> did not work.

Does the pg_config of the target postgres installation return the
correct values for pg_config --includedir and pg_config --libs?

>
> Yes, we do maintain several PostgreSQL environments; some production,
> others related to our testing of PostgreSQL 8.5-alpha releases.

chroot maybe?



--
________________________________________________________________
Paul Stevens paul at nfg.nl
NET FACILITIES GROUP GPG/PGP: 1024D/11F8CD31
The Netherlands________________________________http://www.nfg.nl
_______________________________________________
DBmail mailing list
DBmail [at] dbmail
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail

DBMail users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.