Skip to main content



      Home
Home » Eclipse Projects » Equinox » How to manage dependent dlls to a bundle
How to manage dependent dlls to a bundle [message #96170] Wed, 29 August 2007 04:32 Go to next message
Eclipse UserFriend
Hi,

I am trying to set a bundle that uses a DLL 'A' that is linked to DLL
'B'. The DLL 'A' is found correctly but can not be loaded because the
system does not found DLL 'B'. The only way I have found is to add DLL 'B'
to the system path...

Is is possible to do this using the "Bundle-NativeCode" property or
with an other method??

Xavier
Re: How to manage dependent dlls to a bundle [message #96203 is a reply to message #96170] Wed, 29 August 2007 11:25 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alex_blewitt.yahoo.com

Do a call to System.loadLibrary(B) first, then System.loadLibrary(A). B will be cached, and A will see B in memory when it's loaded. You'll still need to use the Bundle-NativeCode header for both DLLs.

Alex.
Re: How to manage dependent dlls to a bundle [message #97681 is a reply to message #96203] Wed, 19 September 2007 16:49 Go to previous messageGo to next message
Eclipse UserFriend
> Do a call to System.loadLibrary(B) first, then System.loadLibrary(A). B will be cached, and A will see B in memory when it's loaded. You'll still need to use the Bundle-NativeCode header for both DLLs.
>
> Alex.

This seems to work in a windows environment and maybe mac. But I've
found this does not work so well on Linux systems. There is an open
issue against OSGi for this, but it looks like we cannot solve it in a
good way unless the VM is enhanced.

Tom.
Re: How to manage dependent dlls to a bundle [message #97799 is a reply to message #97681] Wed, 19 September 2007 17:41 Go to previous message
Eclipse UserFriend
Originally posted by: alex_blewitt.yahoo.com

There was a workaround; set LD_LIBRARY_PATH prior to calling the actual loadLibrary() to include the extracted dll's directory, and then reset it afterwards. I don't know if you can do such a thing on Windows though.

Alex
Previous Topic:How can a bundle update itself?
Next Topic:Is Declarative Services viable
Goto Forum:
  


Current Time: Mon May 12 19:01:04 EDT 2025

Powered by FUDForum. Page generated in 0.03563 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top