How can an applet (NO APPLICATION !!) gets remote objects from any
computer not only from computer from which the aplete was downloaded ?
For ex. RMI can invoke remote methods only on computer from which
applet was downloaded.
I dont know how is with CORBA products ?
Thank you
Bogdan JERAM
I use the Sun java tutorial to try JNI with the Hello World example.
It works fine with the printf to display "Hello World". But then I change
to use cout << "Hello World" << endl; and add #include <iostream.h>
in the source code.
When I run it: the following message is generated, I can't figure out the
reason
ld.so.1: /homes/fychien/java/bin/../bin/sparc/green_threads/java: fatal: relocation error: symbol not found: cout: referenced in ./libhello.so (libhello.so)
java.lang.UnsatisfiedLinkError: no hello in shared library path
at java.lang.Runtime.loadLibrary(Runtime.java)
at java.lang.System.loadLibrary(System.java)
at
at java.lang.Thread.init(Thread.java)
If I just include the <iostream.h> to the source file without doing
cout << "Hello World" << endl; Then it generates the following message:
ld.so.1: /homes/fychien/java/bin/../bin/sparc/green_threads/java: fatal: relocation error: symbol not found: __0oNIostream_initctv: referenced in ./libhello.so
Killed
Could someone point out what is the problem? I am using jdk1.1.1 on
Solaris 2.4.
Thanks,
I remember I got errors like these with some of the more elderly
versions of the SunSoft C++ compilers. Maybe you should check with Sun
support on this one.
To double check, try creating a simple C++ program that uses your new
shared library. If you get the same symptoms, you don't have a Java
problem, which means SunSoft and JavaSoft don't get the chance to play
tennis with you. If you don't get the same symptoms then it is purely a
Java problem and I'm talking out of my **** :)
Hope this helps and good luck
Andy M
--------------9DD9117ABC63D5A4B6C23770
Content-Type: text/x-vcard; charset=us-ascii; name="vcard.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Andrew Meredith
Content-Disposition: attachment; filename="vcard.vcf"
begin:vcard
fn:Andrew Meredith
n:Meredith;Andrew
org:Motorola GSM Products Division
adr:16 Euroway;;Blagrove;Swindon;Wiltshire;SN5 8YQ;UK
email;internet:mere...@mot.com
title:Senior Systems Engineer
tel;work:+44 (0)1793 565377
tel;fax:+44 (0)1793 565161
x-mozilla-cpt:;0
x-mozilla-html:TRUE
end:vcard
--------------9DD9117ABC63D5A4B6C23770--
> ld.so.1: /homes/fychien/java/bin/../bin/sparc/green_threads/java: fatal: relocation error: symbol not found: cout: referenced in ./libhello.so (libhello.so)
>
> ld.so.1: /homes/fychien/java/bin/../bin/sparc/green_threads/java: fatal: relocation error: symbol not found: __0oNIostream_initctv: referenced in ./libhello.so
Those problems indicate that you need to link your libhello.so module
against some other shared library from which it imports its symbols.
I'd guess it's /usr/lib/libC.so (the C++ runtime support library).
Something like this:
cc -G -o libhello.so foo.o -lC