[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[List Home]
|
Re: [equinox-dev] Problem loading Native Library
|
- From: Karl Pauls <karlpauls@xxxxxxxxx>
- Date: Tue, 25 Aug 2009 22:17:03 +0200
- Delivered-to: equinox-dev@eclipse.org
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=9qkNNVgRlEYd3xIZ8X+4ks3S5avEryx/VLVL0NYaBbE=; b=B2k83jjn9X5O5Y0sYo48UjetsuWHrV7qn5DyaQ0Xg41Y0lNUAHzdlbT/exml6nuuBk x6VPVxRumiVJPx3+lRVerJkhqm26MonGNqXjacYagDuyZ4IC7lQkjdHPtNpZ4bowvnMt 2ITJ826FQPE6/1FlluT9aHhfeZc2/LkqYo9yU=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=WQeXpkYC+YluKyXdMQF6Xt/esH8L8/YU0vayyHkXF+r7q0Xm4wlC8FKCMDVRzsmvFm loHWaly3FKUqQElaFM/OrIaEOVA3/OVGcMHADafWwv1Cgm5PpPPv/+KwlAQIYakOeGgK 9BZCzLwGRyBUX4/RRXZvnhGgUxpcfmO6admbI=
Not sure whether that is any help but you are _not_ supposed to
specify the java.library.path. The idea of the native header in the
manifest is that the framework takes care that the native library
_inside_ you bundle is used automatically.
There must be a different reason why you are getting the exception. Is
it possible for you to show us the stacktrace/message of the
exception? Furthermore, is it possible that the native library has a
dependency on another native library?
regards,
Karl
On Mon, Aug 24, 2009 at 2:58 PM, David Conde<dconde@xxxxxxxx> wrote:
> Hi,
>
>
>
> Some days ago I tried to load LIRC packages in a bundle in order to other
> bundles were able to use them, the problem was that these packages used
> libjunixsocket.so native library, so I tried to include this library in my
> bundle adding Bundle-NativeCode: header in the Manifest.MF.
>
>
>
> My manifest is as shown below:
>
>
>
> Bundle-NativeCode: libjunixsocket.so ;
>
> processor = i386 ; osname = Linux,*
>
>
>
> I export from Eclipse this bundle and I get a .jar file where If I unzip it,
> I get three files:
>
> -META-INF folder
>
> -org packages where are the classes which other bundles need
>
> -libjunixsocket.so
>
>
>
> I also typed -vmargs -Djava.library.path=path_where_libjunixsocket.so_is
> when I launch Equinox.jar framework in order to say Ubuntu where
> libjunixsocket.so is.
>
>
>
> But I have always the same result:
>
>
>
> Error: BundleException:….
>
> Caused by: java.lang.ExceptionInInitializaerError
>
> …
>
>
>
> I think it is caused by the Native library, because of I have launched a
> simple java application without Equinox with this packages and it worked
> fine.
>
>
>
>
>
> Am I missing something?
>
>
>
> Should I include Bundle-Classpath: header?
>
>
>
> Thank you in advance
>
>
>
> My steps are the next:
>
>
>
> 1- I use Eclipse on Windows XP.
>
> 2- I export the bundles using Export funtion in eclipse
>
> 3- I install the jar files in Equinox framework using console mode in
> Ubuntu
>
> 4- I launch Equinox in console mode in Ubuntu
>
>
>
> Could it be a problem to compile the Jar files with the packages which
> generate the Native.so file in Windows while I am going to use in Ubuntu?
>
>
>
> Thank you in advance
>
>
>
>
>
> _______________________________________________
> equinox-dev mailing list
> equinox-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/equinox-dev
>
>
--
Karl Pauls
karlpauls@xxxxxxxxx