pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: scott.marlowe <scott.marlowe@ihs.com>
To: David Busby <busby@pnts.com>
Cc: pgsql-php@postgresql.org
Subject: Re: Inquiry From Form [pgsql]
Date: Fri, 16 May 2003 13:51:04 -0600 (MDT)
Message-ID: <Pine.LNX.4.33.0305161350080.6494-100000@css120.ihs.com> (raw)
In-Reply-To: <035801c31be3$fc2fe7f0$1100000a@busbydev>

The way I "show" linux where to find the libs for postgresql is to edit 
/etc/ld.so.conf to have a line like /usr/local/pgsql/lib and then run 
ldconfig.

Otherwise PHP will compile, but apache won't start.

On Fri, 16 May 2003, David Busby wrote:

> Look for the files libpq.h  and also libpq-fe??? something like that.  Those
> are the PostgreSQL headers (.h) and libraires (.so)  You'll have to have
> those for pg_connect to work.  When PHP is built it needs to know where
> those are (in path with other includes and libraries? or something else
> (/usr/local?/opt/postgre)).
> 
> /B
> 
> 
> 
> ----- Original Message ----- 
> From: "scott.marlowe" <scott.marlowe@ihs.com>
> To: "Mark" <mbergman@brunson.us>
> Cc: <info@pgsql.com>; "Marc G. Fournier" <scrappy@hub.org>;
> <pgsql-php@postgresql.org>
> Sent: Friday, May 16, 2003 11:48
> Subject: Re: [PHP] Inquiry From Form [pgsql]
> 
> 
> > On Thu, 15 May 2003, Mark wrote:
> >
> > > I have a Raq4i and I am trying to write PHP 4 to the PostgreSQL.  But I
> > > keep getting undefined function: pg_connect() .  I have the extension
> > > enabled and the PHP was compiled for postgreSQL.  I do not understand
> > > what is going on?
> >
> > If PHP says pg_connect is undefined, then the php the RAQ is running isn't
> > compiled for postgresql connectivity.
> >
> > There are two common causes of this:
> >
> > 1:  You compiled one build of PHP, the RAQ is running on another build.
> >
> > 2:  You told PHP to build in postgresql connectivity, it couldn't find the
> > right header file, failed, writing an error message to the screen during
> > configuration, saying something along the lines of "could not find file
> > xxxxx.h" skipping postgresql configuration.
> >
> > PHP will then happily build and run, without postgresql capabilities.
> >
> > Try this:
> >
> > write a web page with this in it:
> >
> > <?php
> > phpinfo();
> > ?>
> >
> > Look through the page to see if it mentions postgresql.  At the top will
> > be a list of all the switches it was configged with.  If you have a
> > --with-pgsql there, but no pgsql section in phpinfo, then the configure
> > script couldn't find the right headers.  Make sure you're running a fairly
> > late model version of both PHP and postgresql, as there was a bit of an
> > issue about a year ago when postgresql changed the name of one of it's
> > connection headers.
> >
> >
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 2: you can get off all lists at once with the unregister command
> >     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@postgresql.org so that your
> message can get through to the mailing list cleanly
> 




view thread (10+ messages)

Message-ID: <Pine.LNX.4.33.0305161350080.6494-100000@css120.ihs.com>
Permalink:  ../Pine.LNX.4.33.0305161350080.6494-100000@css120.ihs.com/
Also on:    postgresql.org/message-id/Pine.LNX.4.33.0305161350080.6494-100000@css120.ihs.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-php@postgresql.org
  Cc: scott.marlowe@ihs.com, busby@pnts.com
  Subject: Re: Inquiry From Form [pgsql]
  In-Reply-To: <Pine.LNX.4.33.0305161350080.6494-100000@css120.ihs.com>
  References: <035801c31be3$fc2fe7f0$1100000a@busbydev> <Pine.LNX.4.33.0305161350080.6494-100000@css120.ihs.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox