[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
|
[news.eclipse.technology.equinox] Re: Can't find dependent libraries of native module (DLL)
|
I am using the Bundle-NativeCode myself to use a dll/so and another one it
depends on. Conveniently one can specify multiple libs within the
native-code manifest entry. That solved the problem of getting ld.so (or
the equivalent runtime-linker on windows) to load native code which i have
in my plugin.
I do have my native libs in subdirectories and not the root-dir of a
plugin, so i guess for that to work the bundle-nativepath is mandatory.
Apparently the swt-win32 plugin doesn't need that manifest entry. I wonder
how that works out since the library is called swt-win32-3139.dll from
the win32 swt fragment.
public class OS extends Platform {
static {
Library.loadLibrary ("swt"); //$NON-NLS-1$
}
..
The code above loads just "swt" though. This is probably related to how
windows resolves and loads dlls and it is definately confusing to me.
Anyhow, OSGI copies those dlls to the configuration area and loads them
from there ... eg when i start eclipse i have the swt library copied to
eclipse\configuration\org.eclipse.osgi\bundles\4\1\.cp\swt-win32-3139.dll
and loaded from there. Looks like the runtime-linker knows that path as
one of the paths to search for libs (afaik PATH on windows and
LD_LIBRARY_PATH on linux).
Hope this helps you a bit at least, i am myself more confused than 5
minutes ago
Stepan