[FGS] Problems with pgsql

Guillaume Dallaire gdallaire at mapgears.com
Thu Mar 23 15:48:00 EST 2006


Felipe Costa wrote:
> I'm having this problem in fgs:
> *Fatal error*: Call to undefined function: pg_connect() in 
> */opt/fgs/www/htdocs/tcc2/webmapa/funbanco.php* on line *52
>
> I wrote a phpinfo file and I saw this:
> * './configure' '--with-regex=system' 
> '--with-freetype-dir=/home/users/gdallaire/fgs-dev/built/freetype' 
> '--with-dbase' '--prefix=/home/users/gdallaire/fgs-dev/built/php' 
> '--with-mysql=shared,/home/users/gdallaire/fgs-dev/built/mysql-standard-4.1.14-pc-linux-gnu-i686' 
> '--with-pgsql=shared,/home/users/gdallaire/fgs-dev/built/postgresql' 
> '--with-pdflib=shared,/home/users/gdallaire/fgs-dev/built/pdflib_lite' 
> '--with-png-dir=/home/users/gdallaire/fgs-dev/built/libpng' 
> '--with-jpeg-dir=/home/users/gdallaire/fgs-dev/built/jpeg' 
> '--with-tiff-dir=/home/users/gdallaire/fgs-dev/built/tiff' 
> '--with-gd=/home/users/gdallaire/fgs-dev/built/gd' '--with-zlib' 
> '-enable-track-vars' '--enable-sockets' '--enable-wddx=shared' 
> '--with-xmlrpc=shared' '--enable-calendar' 
> '--with-dom=shared,/home/users/gdallaire/fgs-dev/libxml2' 
> '--with-expat-dir=/home/users/gdallaire/fgs-dev/built/expat' 
> '--with-iconv-dir=/home/users/gdallaire/fgs-dev/built/libiconv' 
> '--with-curl=shared,/home/users/gdallaire/fgs-dev/built/curl' 
> '--with-iconv=/home/users/gdallaire/fgs-dev/built/libiconv' '--enable-cgi'
>
> I believe that /home/users/gdallaire is not right.
> My mapserver version is this one...
> MapServer version 4.6.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP 
> OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER 
> SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT 
> INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE
> What can I do?
Hi Felipe,

edit the file $FGS_HOME/www/conf/php.ini.template

and add this line:

extension=pgsql.so

(near other lines that begin by ";extension=...")

Then, restart your Apache (to regenerate the php.ini file) :

$ fgs stop apache ; fgs start apache

Guillaume







More information about the Foss-gis-suite mailing list