[mapserver-users] AGG Compile error with PHP Mapscript

Andreas Albarello andreas.albarello at territoriumonline.com
Tue Apr 1 03:49:50 EDT 2008


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,
-- 
--------------------------------------------------------------------
Andreas Albarello
Analysis & SW Development

Territorium Online srl/GmbH
Via Buozzi/Buozzistraße 12 - I 39100 Bolzano/Bozen
email: andreas.albarello at territoriumonline.com
web:   www.territoriumonline.com
--------------------------------------------------------------------


More information about the mapserver-users mailing list