Check the names of your native methods in .java, .h and .cxx files
Are they the same (with respect to JNI requirements)?

Jacob Nikom

Raj Patel wrote:
> 
> Hi everybody,
>                             I am having trouble linking/loading  *.so
> objects that are used by my C++ code.  Does anybody know how should i
> load them??
> 
> I have a java program and  a C++ file.
> Using JNI i created .so object and loaded using loadLibrary() in my java
> program.
> Now the problem is i can not access my .so objects(not the one i created
> using JNI but the other one that is used by my C++ code) from my java
> program it hangs there and does not do anything!!  So i tried to load
> all other .so objects used by C++ code using loadLibrary in my java
> program but then i get the errors shown at the end.
> 
> How do i include other .so objects used by my C++ file??
> I tried to use loadLibrary() to load other .so objects but it can not
> load one of my .so object!!  Is this the right way to deal with it??  If
> so why it is not loading it??
> 
> /usr/safdevel/RTI13v6/rti/lang/C++/lib/Linux-2.0/libfedtime.so:
> undefined symbol: __tiQ23RTI9Exception (libfedtime.so)
> java.lang.UnsatisfiedLinkError: no fedtime in shared library path
> Error loading libfedtime.so
> SIGSEGV   11*  segmentation violation
>         stackbase=0x413e3000, stackpointer=0x413e2150
> 
> Full thread dump:
>     "TimerQueue" (TID:0x406690a0, sys_thread_t:0x41487e0c, state:CW)
> prio=5
>         javax.swing.TimerQueue.run(TimerQueue.java:236)
>         java.lang.Thread.run(Thread.java)
>     "AWT-Finalizer" (TID:0x406694a0, sys_thread_t:0x41466e0c, state:CW)
> prio=9
>         java.lang.Object.wait(Object.java)
>         sun.awt.AWTFinalizer.run(AWTFinalizer.java:40)
>     "Screen Updater" (TID:0x40668db0, sys_thread_t:0x41445e0c, state:CW)
> prio=4
>         java.lang.Object.wait(Object.java)
>         sun.awt.ScreenUpdater.nextEntry(ScreenUpdater.java:70)
>         sun.awt.ScreenUpdater.run(ScreenUpdater.java:90)
>     "AWT-Motif" (TID:0x4065b668, sys_thread_t:0x41424e0c, state:CW)
> prio=5
>         java.lang.Thread.run(Thread.java)
>     "AWT-Input" (TID:0x4065b628, sys_thread_t:0x41403e0c, state:R)
> prio=5
>     "AWT-EventQueue-0" (TID:0x4065c3e8, sys_thread_t:0x413e2e0c,
> state:R) prio=5 *current thread*
>         java.lang.Runtime.loadLibrary(Runtime.java)
>         java.lang.System.loadLibrary(System.java)
>         FSDBconnect.<clinit>(FSDBconnect.java:22)
> 
> I know i don't have any trouble with my shared object used by C++ code
> because i tried to run my C++ part from test C++ code and everything
> works fine.  So i believe i am missing how should i load or include
> those .so objects used by C++ code?
> 
> -Raj
> 
> ----------------------------------------------------------------------
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to