Operating System - HP-UX
1753587 Members
6668 Online
108796 Solutions
New Discussion юеВ

Re: Problem With System.load( )

 
nallamolu
Advisor

Problem With System.load( )

Hi World,

I have a senario where
System.load("absolute Path to a .so file" ); works fine for one application & it fails for another senario of System.load("absolute Path to same .so file" ) of another application ?

1.)

String s = "/home/nalgo01/Probeing/libHpuxItanium64Stats.so"
System.out.println(System.load(s));

This senario works fine for one appication.

2.)
The same procedure for other ( same adsolute path for .so ) application fails.

It is giving error as
Error: java.lang.UnsatisfiedLinkError: Can't load library: /home/nalgo01/Probeing/libHpuxItanium64Stats.so


What may be the reason for this.

Why the same .so file being loading on one application and why it is failig on other application

Any help is appreciable.

Thanking you,
Gopi
3 REPLIES 3
Elmar P. Kolkman
Honored Contributor

Re: Problem With System.load( )

From the info you give, I would think the problem is with routines/functions which are used in the .so which are not loaded in option 2, while they are available for option 1. But more tracing info might us help you solve this.
Every problem has at least one solution. Only some solutions are harder to find.
nallamolu
Advisor

Re: Problem With System.load( )

Thanks for u r reply,

It is the same .so file which is being used.
Functions/routins are also the same which are used in both application.

Thanking you,
Gopi
Dennis Handly
Acclaimed Contributor

Re: Problem With System.load( )

>Error: java.lang.UnsatisfiedLinkError: Can't load library: .../libHpuxItanium64Stats.so

Again a useless error message without details.

>Functions/routines are also the same which are used in both application.

You exercise the same paths in each?

>Elmar: I would think the problem is with routines/functions which are used in the .so which are not loaded in option 2

This could be due to -B deferred. Where the second case calls more functions.

>But more tracing info might us help you solve this.

What kind of tracing, java?