[mapserver-users] Compiling PHP Mapscript on Cygwin.... grrrrrrr

C F gis_consultant at hotmail.com
Wed Jun 19 08:45:01 PDT 2002


Hi gang...
I've been successful in compiling and developing mapserver on Linux.  Now 
I'd like to be able to do some development on my win2k laptop so I'm taking 
a shot at Cygwin.... well... I'm not proud to say that I've actually been 
trying for about a week now!  I'm ready to give up, but thought I'd take a 
shot in here first.
After trying several times on my own with newer versions of supporting 
libraries I finally gave up (could not get GD 2 compiled) and used the 
Cygwin compilation instructions on the mapserver web site.  Using those 
instructions and those libraries, I've finally been able to get MapServer 
3.6 compiled *and* running on Cygwin (withouth TTF support, but I can deal 
with that).  However, when I run through the same configure/make routine 
with php-mapscript turned on, it bombs and I can't get seem to get past it.  
  The error occurs in the DLLWrap call because it's looking for a "export 
definition file", then it tries unsuccessfully to create one.  Here's what I 
do (I've also tried with MapSever 3.5... different error, but no success):

1)
./configure --with-gd=../gd-1.8.4 --with-proj --with-postgis 
--with-php=/usr/src/php-4.2.0-1/main

Here's the relevant php output from the configure command:
----------------------------------------------------------
checking for location of config.h or php_config.h... 
/usr/src/php-4.2.0-1/main/php_config.h
checking whether we have PHP3 or PHP4... -DPHP4
checking whether we should use PHP's regex... no
        PHP/MapScript module configured.
updating cache ./config.cache
creating ./config.status
creating Makefile
creating mapscript/php3/Makefile


2)
I edit the php3/makefile changing line:
-from-
CC =     gcc  gcc -I. -I..
-to-
CC =     gcc -I. -I..


3)
make
... compiles for a while... then BOOM... this output:

dllwrap --dllname php_mapscript.dll --driver-name gcc --dlltool dlltool 
--export-all-symbols --as as --output-def libphp_mapscript.def --output-lib 
libphp_mapscript.a \
-s -L/usr/local/lib -s  php_mapscript_util.o php_mapscript.o mapscript_i.o 
-L/usr/src/projects/mapserver-3.6.0 -lmap -L/usr/lib -lpq -lproj -ltiff 
-ljpeg -L/lib -lpng -L/lib -lz 
-L/usr/src/projects/mapserver-3.6.0/../gd-1.8.4/.libs -lgd -ljpeg -L/lib 
-lpng -L/lib -lz -ljpeg -lm

dllwrap: no export definition file provided

dllwrap: creating one, but that may not be what you want

php_mapscript_util.o(.text+0x41):php_mapscript_util.c: undefined reference 
to `zend_error'
.
.
.
... a whole bunch of these "undefined reference" errors
.
.
.
collect2: ld returned 1 exit status
dllwrap: gcc exited with status 1
perlld: *** system() failed to execute


When it's done, mapscript/php3/libphp_mapscript.def is created but with no 
content.

I'm using PHP 4.2... is that the problem?  I don't know.
Any ideas?????   Thank you!


_________________________________________________________________
Send and receive Hotmail on your mobile device: http://mobile.msn.com




More information about the MapServer-users mailing list