ID:               30938
 Updated by:       [EMAIL PROTECTED]
 Reported By:      bgriffin at gracenote dot com
-Status:           Open
+Status:           Bogus
 Bug Type:         *Configuration Issues
 Operating System: linux (Red Hat Linux release 7.1
 PHP Version:      4.3.9
 New Comment:

It is user error to have multiple versions of same libraries hanging
around in your system. We can't do anything about it.



Previous Comments:
------------------------------------------------------------------------

[2004-11-30 00:45:35] bgriffin at gracenote dot com

Description:
------------
I found the problem in configure by looking at helpful comments for bug
number 19856.

I, too, was wondering why my copy of php was lacking pg_escape_string()
even though I had just installed the latest version of Postgres
(7.4.6).

It turns out that configure, when compling the conftest program to
check for PQescapeString(), did this:

configure:70469: checking for PQescapeString in -lpq
configure:70488: gcc -o conftest -g -O2  -L/usr/lib -ldb-3.1 
-Wl,-rpath,/usr//l
ib/mysql -L/usr//lib/mysql -L/usr/local/pgsql/lib conftest.c -lpq 
-lmysqlclient
 -ldb-3.1 -lgdbm -lresolv -lm -ldl -lnsl  1>&5

There was an old copy of postgres in /usr/lib and that extra -L/usr/lib
was causing gcc to favor it. This would be okay if the PHP build favored
that, too, since I'd see in the postgres section of phpinfo() that the
wrong version had been used. But the real compile of PHP doesn't use
-L/usr/lib and finds the correct postgres install, yet wrongly does not
include pg_escape_string().

I resolved this for myself by adding a "#define HAVE_PQESCAPE 1" in
main/php_config.h by hand. 



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=30938&edit=1

Reply via email to