[mapserver-users] AGG Compile error with PHP Mapscript

Nicol Hermann mapserver at geoworld.de
Tue Apr 1 05:52:09 EDT 2008


Hi Andreas,

many thanks for  your hint.
I manage to compile PHP Mapscript with AGG support!
Do you know a way to compile the AGG lib with the standard debian way
(dpkg-buildpackage)?
I had to compile the library with 
./configure && make & make install
Using 'dpkg-buildpackage' did not work.
In both cases i added -fPIC to Makefile.in.Linux.

Thanks again
Nicol

On Di, 2008-04-01 at 09:49 +0200, Andreas Albarello wrote:
> Nicol Hermann wrote:
> > Whenever i include PHP Mapscript support (--with-php=/usr/local/php5) i
> > get the following error message: (PHP 5.2.2)
> > 
> > /usr/bin/ld: /usr/lib64/libagg.a(agg_arc.o): relocation R_X86_64_32
> > against `__gxx_personality_v0' can not be used when making a shared
> > object; recompile with -fPIC
> > /usr/lib64/libagg.a: could not read symbols: Bad value
> > collect2: ld returned 1 exit status
> > make[1]: *** [php_mapscript.so] Fehler 1
> > make[1]: Leaving directory
> > `/usr/local/src/mapserver/mapserver-5.0.2/mapscript/php3'
> 
> You have to compile AGG by hand with -fPIC for position independent code 
> as the error message itself suggests. Just add -fPIC to the AGGCXXFLAGS 
> in Makefile.in.Linux. Using the debian binaries is probably not going to 
> work.
> 
> Best regards,



More information about the mapserver-users mailing list