2014-10-22 14:50 GMT+02:00 Annick Fron <[email protected]>:

> Hi,
>
> I have one library which depends from another one.
> How can I force pharo to load the dependent library ?
>
> Annick
>
>

I don't think it is necessary to force pharo to load the libraries. AFAIR
the VM on linux uses dlopen() to load a module
and that should load the dependent libraries as well, *if* the library, you
are using, is linked against the others.

For example, you want to load library "testlib" which depends on "helperlib"
you have to compile and link the testlib and helperlib as follows

gcc -shared -o libhelperlib.so helperlib.c
gcc -shared -o libtestlib.so testlib.c -L. -lhelperlib

now you should be able to load testlib from pharo.

you can test if your dependent libraries can be automatically found by
dlopen with:
ldd <testlib>


nicolai

Reply via email to