FFI question. Is it possible to unload loaded external library

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

FFI question. Is it possible to unload loaded external library

Denis Kudriashov
Hello,

I need implement remote updating some dll's for running pharo application. This dll's used by FFI.
I want done this by unloading dll from VM. Then loading new updated dll. And then continue app execution.
Is it possible?

Or only way is to restart pharo?
Reply | Threaded
Open this post in threaded view
|

Re: FFI question. Is it possible to unload loaded external library

Mariano Martinez Peck


On Tue, Nov 30, 2010 at 9:35 PM, Denis Kudriashov <[hidden email]> wrote:
Hello,

I need implement remote updating some dll's for running pharo application. This dll's used by FFI.
I want done this by unloading dll from VM. Then loading new updated dll. And then continue app execution.
Is it possible?

what does it mean exactly to "load" a dll and "unload" ??
cheers

mariano
 

Or only way is to restart pharo?

Reply | Threaded
Open this post in threaded view
|

Re: FFI question. Is it possible to unload loaded external library

Igor Stasenko
On 1 December 2010 15:57, Mariano Martinez Peck <[hidden email]> wrote:

>
>
> On Tue, Nov 30, 2010 at 9:35 PM, Denis Kudriashov <[hidden email]>
> wrote:
>>
>> Hello,
>>
>> I need implement remote updating some dll's for running pharo application.
>> This dll's used by FFI.
>> I want done this by unloading dll from VM. Then loading new updated dll.
>> And then continue app execution.
>> Is it possible?
>
see #unloadModule:
it should work for modules, loaded via  FFI i think. But i never tried
to do that.

> what does it mean exactly to "load" a dll and "unload" ??
> cheers
>
> mariano
>
>>
>> Or only way is to restart pharo?
>
>



--
Best regards,
Igor Stasenko AKA sig.

Reply | Threaded
Open this post in threaded view
|

Re: FFI question. Is it possible to unload loaded external library

Denis Kudriashov
In reply to this post by Mariano Martinez Peck
By loaded dll I mean what happens when I call some dll function.
After this I can't update this dll.

I will try #unloadModule: as Igor adviced

2010/12/1 Mariano Martinez Peck <[hidden email]>


On Tue, Nov 30, 2010 at 9:35 PM, Denis Kudriashov <[hidden email]> wrote:
Hello,

I need implement remote updating some dll's for running pharo application. This dll's used by FFI.
I want done this by unloading dll from VM. Then loading new updated dll. And then continue app execution.
Is it possible?

what does it mean exactly to "load" a dll and "unload" ??
cheers

mariano
 

Or only way is to restart pharo?


Reply | Threaded
Open this post in threaded view
|

Re: FFI question. Is it possible to unload loaded external library

Mariano Martinez Peck


On Wed, Dec 1, 2010 at 10:44 PM, Denis Kudriashov <[hidden email]> wrote:
By loaded dll I mean what happens when I call some dll function.

Ok.....but this is done automatically by FFI. I mean, you don't need to code something to get the library loaded.
 
After this I can't update this dll.

By updating you mean that you would like to change the library to a new version while pharo is running and you would like to use the new version?
 

I will try #unloadModule: as Igor adviced

2010/12/1 Mariano Martinez Peck <[hidden email]>



On Tue, Nov 30, 2010 at 9:35 PM, Denis Kudriashov <[hidden email]> wrote:
Hello,

I need implement remote updating some dll's for running pharo application. This dll's used by FFI.
I want done this by unloading dll from VM. Then loading new updated dll. And then continue app execution.
Is it possible?

what does it mean exactly to "load" a dll and "unload" ??
cheers

mariano
 

Or only way is to restart pharo?