[Mapserver-users] Error compiling java mapscript classes (Mapserver 4.0)

unicoletti at prometeo.it unicoletti at prometeo.it
Mon Sep 29 09:16:26 EDT 2003


Hi Andreas,
have a look at the HOWTO I posted last Friday.

There are patches to makefile and instructions on how to generate a working java
module.

HTH,
umberto


Quoting GeoIT <info at geo-it.com>:

> Dear list,
> 
> While making java mapscript module I receive the following errors:
>  
> pooka at mobilix:~/MS40/mapserver-4.0/mapscript/java
> <mailto:pooka at mobilix:~/MS40/mapserver-4.0/mapscript/java>> make
> /usr/local/bin/swig -java -shadow -package edu.umn.gis.mapscript mapscript.i
> Deprecated command line option: -shadow. Proxy classes are now generated by
> default.
> gcc -fpic -c -DIGNORE_MISSING_DATA -DUSE_EPPL -DUSE_PROJ -DUSE_PROJ_API_H
> -DUSE_TIFF -DUSE_JPEG -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG -DUSE_GD_WBMP
> -DUSE_GD_FT -DGD_HAS_GDIMAGEGIFPTR -DUSE_OGR -DUSE_GDAL -I.
> -I../../../gd-2.0.15gif -I/usr/local/include -I/usr/lib/java/include
> -I/usr/lib/java/include/linux mapscript_wrap.c
> gcc -fpic -shared mapscript_wrap.o -o libmapscript.so -L../.. -lmap
> -L../../../gd-2.0.15gif -lgd -ljpeg -lfreetype -lpng -lz -ltiff -ljpeg
> -lfreetype -lpng -lz -lproj -ljpeg -L/usr/local/lib -lgdal.1.1
> -L/usr/local/pgsql/lib -lpq -L/usr/local/lib -lcurl -lz -lssl -lcrypto -ldl
> -lz -lpthread -lm -lstdc++ -lstdc++
> /usr/lib/java/bin/javac -d . *.java
> outputFormatObj.java:134: setExtension(java.lang.String) is already defined
> in edu.umn.gis.mapscript.outputFormatObj
> public void setExtension(String extension) {
>                 ^
> outputFormatObj.java:138: setMimetype(java.lang.String) is already defined
> in edu.umn.gis.mapscript.outputFormatObj
> public void setMimetype(String mimetype) {
>                 ^
> mapObj.java:299: clone() in edu.umn.gis.mapscript.mapObj cannot override
> clone() in java.lang.Object; attempting to use incompatible return type
> found   : edu.umn.gis.mapscript.mapObj
> required: java.lang.Object
> public mapObj clone() {
>               ^
> 3 errors
> make: *** [mapscript_java] Fehler 1
> 
> Which occurence of the methods setExtension and setMimetype in class
> outputFormatObj should I remove ?
> The return Type in mapObj.clone() should be set to Object instead of mapObj.
> Is it OK to do the chanches in the java source files ? I think they should
> preferably done in the interface file, but I don't know how. Please advise !
>  
> My System configuration: 
> Mapserver 4.0
> swig 1.3.19
> Sun JDK 1.4.1_01
> ----------------------------------------------------------------------------
> ----------------
> 
> Thanks in advance for You help,
> 
> Regards,
> 
> Andreas Paukner-Ruzicka
> 
> ***************************************************
> Geo-IT GmbH   -   Geoinformatik, IT-Services
> Guggenberg 3, D-82380 Peissenberg
> Tel: 08803-498372, Fax: 08803-498373
> eMail: info at geo-it.com  -  Homepage: http://www.geo-it.com
> ***************************************************
> 
> 
> 
> 
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
> 



----- End forwarded message -----






More information about the mapserver-users mailing list