Return-Path: Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 73694 invoked from network); 26 Jul 2000 08:49:08 -0000 Received: from mail2.netcologne.de (194.8.194.103) by locus.apache.org with SMTP; 26 Jul 2000 08:49:08 -0000 Received: from tbilz ([213.168.75.26]) by mail2.netcologne.de (8.9.3/8.9.3) with SMTP id KAA10428 for ; Wed, 26 Jul 2000 10:49:05 +0200 (MET DST) From: "Thomas Bilz" To: Subject: RE: JNI & Tomcat Date: Wed, 26 Jul 2000 10:46:26 +0200 Message-ID: <000201bff6de$58c06680$662ca8c0@tbilz.koeln> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit In-Reply-To: X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N You are right, on Solaris you'll have to place it in LD_LIB.... So I placed the file libNativeCalculator.so in /usr/local/lib, part of LD_LIB.... I think the library is found, because when I delete the library common.so in /usr/local/lib the error changes to: ------------- java.lang.UnsatisfiedLinkError: no NativeCalculator in shared library path at java.lang.Throwable.(Compiled Code) at java.lang.Error.(Compiled Code) at java.lang.LinkageError.(Compiled Code) at java.lang.UnsatisfiedLinkError.(Compiled Code) at java.lang.Runtime.loadLibrary(Compiled Code) at java.lang.System.loadLibrary(Compiled Code) at de.xplain.GenericCalculator.OutputParams.getErrorMessage(Compiled Code) at de.xplain.GenericCalculator.Calculator.computeInternal(Compiled Code) at de.xplain.GenericCalculator.Calculator.compute(Compiled Code) at de.xplain.GenericCalculator.Calculators.BarwertCalculator.compute(Compiled Code) ..... ------------- In my opinion the system can find the library, when it is placed in /usr/local/lib, but JVM can't get the right function 'compute'. Do you work with JNI and Tomcat? No problems in that? Thanks for spending your time on that problem, Tom > -----Original Message----- > From: Amos Shapira [mailto:amos.shapira@webcollage.com] > Sent: Tuesday, July 25, 2000 7:18 PM > To: 'tomcat-user@jakarta.apache.org' > Subject: RE: JNI & Tomcat > > > Hmm, how do you expect Tomcat to find the .so? (I assume this is > UNIX). > > At least on Windows 2000, the .DLL files must be on the PATH > in order to be found by JNI, I think for Solaris it is enough > for them to > be on LD_LIBRARYPATH (or somesuch). > > Hope this helps, > > --Amos Shapira > WebCollage > > > -----Original Message----- > > From: Thomas Bilz [mailto:thomas.bilz@xplain.de] > > Sent: Tuesday, July 25, 2000 6:12 PM > > To: tomcat-user@jakarta.apache.org > > Subject: JNI & Tomcat > > > > > > Yesterday I installed Tomcat and most things seem to work, > > but I have a > > problem with JNI in an old Servlet that ran on JServ before. > > I have a shared library, which is loaded, and I have a > > wrapper-class for it. > > But I can't use this wrapper: every access to my servlet ends with a > > java.lang.UnsatisfiedLinkError. > > ------------- > > Error: 500 > > Location: servlet/de.rechentools.servlets.Barwert > > Internal Servlet Error: > > > > java.lang.UnsatisfiedLinkError: compute > > at > > > de.xplain.GenericCalculator.Calculator.computeInternal(Compiled Code) > > at de.xplain.GenericCalculator.Calculator.compute(Compiled Code) > > at > > de.xplain.GenericCalculator.Calculators.BarwertCalculator.comp > > ute(Compiled > > Code) > > at > > de.rechentools.servlets.Barwert.createReplaceList(Compiled Code) > > at > > de.xplain.GenericServlets.RechenModulServlet.doGet(Compiled Code) > > at > > de.xplain.GenericServlets.RechenModulServlet.doPost(Compiled Code) > > at javax.servlet.http.HttpServlet.service(Compiled Code) > > at javax.servlet.http.HttpServlet.service(Compiled Code) > > at > > org.apache.tomcat.core.ServletWrapper.handleRequest(Compiled Code) > > at org.apache.tomcat.core.ContextManager.service(Compiled Code) > > at > > org.apache.tomcat.service.connector.Ajp12ConnectionHandler.pro > > cessConnection > > (Compiled Code) > > at > > org.apache.tomcat.service.TcpConnectionThread.run(Compiled Code) > > at java.lang.Thread.run(Compiled Code)