[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [equinox-dev] Problem loading Native Library

Hi,

>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

I do not really how LIRC packages work, so maybe they have other
dependencies to other natives libraries which I do not know, I will try to
review the LIRC packages code and look for something which could cause the
Exception.


Thank you 

David


-----Mensaje original-----
De: equinox-dev-bounces@xxxxxxxxxxx [mailto:equinox-dev-bounces@xxxxxxxxxxx]
En nombre de Karl Pauls
Enviado el: martes, 25 de agosto de 2009 22:17
Para: Equinox development mailing list
Asunto: Re: [equinox-dev] Problem loading Native Library

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
_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev