[maplab-users] Internal server error with Maplab 2.1-rc3

Jean-Rene Cormier jean-rene.cormier at cipanb.ca
Tue May 25 14:14:09 EDT 2004


On Tue, 2004-05-25 at 14:41, Daniel Morissette wrote:
> Jean-Rene Cormier wrote:
> > 
> > Well I recompiled both PHP and mapserver/mapscript making sure they both
> > used the same GD lib but I still get those errors. I'll try to give a
> > bit more info but I'm not sure what info you need.
> > 
> > I have added this to my Apache config so the phtml files are processed
> > through the standalone php executable and not the module.
> > 
> > AddHandler phtml-script .phtml
> > Action phtml-script /cgi-bin/php
> > 
> > Though /cgi-bin/php is not the actual php executable, it's a script that
> > calls php. I had some trouble at first that I've solved with this:
> > 
> > http://lists.maptools.org/pipermail/maplab-users/2002-July/000153.html
> > 
> 
> Are we sure that this script calls the php cgi that you just recompiled 
> and doesn't call an old one previously compiled with the bundled GD or 
> that shipped with Fedora?

Yes I made sure of that, the original php binary didn't had libgd
dynamically linked to it and the new one does, also the binary has
today's date.

> If you recompiled PHP as a CGI, then you can directly copy the file 
> php-4.3.x/sapi/cgi/php to your cgi-bin directory and it should work 
> without any script.

This is what I get when I use the php binary directly:

Warning: Unexpected character in input: '' (ASCII=15) state=1 in
/var/www/cgi-bin/php on line 4430

Parse error: parse error in /var/www/cgi-bin/php on line 4430

Though I'm pretty much using the FC1 php because all I did is install
the SRPM, modify the spec file to add "--enable-xslt
--with-xslt-sablot=/usr --enable-dbase" and rebuild it. Also I modified
the "--with-gd" to "--with-gd=/usr" to use the system library instead of
the PHP included one. So it's still pretty close to a RedHat php binary.

> I still suspect a GD problem.  To make sure that your PHP was not built 
> with PHP's bundled GD, look for the HAVE_GD_BUNDLED symbol in the file 
> main/php_config.h (part of the PHP headers).
> 
> You should find it commented out:
> 
>    /* #undef HAVE_GD_BUNDLED */
> 
> If it is set to something as follows then you are still building with 
> the bundled GD and you need to find out why:
> 
>    #define HAVE_GD_BUNDLED 1

I have /* #undef HAVE_GD_BUNDLED */ in my php_config.h

> You could also try to not include GD at all in your PHP build, and see 
> if you still get the error.  That may not solve all your problems since 
> I think that MapLab requires GD, but at least that would tell us whether 
> the problem is really conflicting versions of GD or not.

You mean not include GD in PHP but include it in MapLab? Or not include
GD in both of them?

Thanks for your help!

Jean-Rene Cormier




More information about the Maplab-users mailing list