Java Mapscript
Ryan Ollerenshaw
ollerery at ENGR.ORST.EDU
Thu Aug 3 14:28:10 PDT 2006
Alejandro Rico wrote:
> Hi Ryan!!
>
> You must add the file libmapscript.so to your tomcat shared folder.
>
> Check http://mapserver.gis.umn.edu/docs/howto/java_mapscript_Tomcat_55
> <http://mapserver.gis.umn.edu/docs/howto/java_mapscript_Tomcat_55>,
> here explain the correct configuration for use javamapscript
Thanks for the help but still no luck,
I only see a libmapscript.so in the PHP section of my MapServer download
directory structure. But i used it anyway and copied the directory
structure shown on the link that you sent. But i am still getting:
java.lang.UnsatisfiedLinkError: no mapscript in java.library.path
> On 8/3/06, *Ryan Ollerenshaw* <ollerery at engr.orst.edu
> <mailto:ollerery at engr.orst.edu>> wrote:
>
> I am trying to use MapServer's java Mapscript and keep getting the
> following error:
>
> Java.lang.UnsatisfiedLinkError: no mapscript in java.library.path
>
> I have added mapscript.jar to my WEB-INF/lib directory, but i am not
> sure what else i should do. I am using eclipse with the Tomcat
> plug in,
> so i have also added the .jar file to eclipse but i dont think that
> makes a difference when using tomcat.
>
> Here is my java code:
>
> import java.io.*;
> import javax.servlet.*;
> import javax.servlet.http.* ;
> import edu.umn.gis.mapscript.*;
>
> public class MapServerTest extends HttpServlet {
>
> public void doGet ( HttpServletRequest request,
> HttpServletResponse
> response )
> throws ServletException, IOException {
>
> response.setContentType("text/html");
> PrintWriter out = response.getWriter();
>
> System.loadLibrary("mapscript");
>
> out.println("<html>");
> out.println("<head><title>Hello World!</title></head>");
> out.println("<body>");
> out.println("<h1>aa Hello, World !</h1>");
>
> //mapObj map = new
> mapObj("var/www/html/mapserver/htdocs/display.map");
> }// end doGet
>
> }///:~
>
>
>
>
> --
> Alejandro Rico
More information about the MapServer-users
mailing list