[Vm-dev] using FFI to load symbols?
Esteban Lorenzano
estebanlm at gmail.com
Wed Aug 26 14:57:14 UTC 2015
Hi,
I’m trying to access symbols through FFI (like, for instance, to access char **environ variable from libc).
I know the vm has implemented
ioLoadModule: moduleNameIndex OfLength: moduleNameLength
ioLoadSymbol: functionNameIndex OfLength: functionNameLength FromModule: moduleHandle
… but well, since this functions are implemented inside the executable and not in an external module, I cannot access them through a regular FFI call.
I suppose this can be like that because of security reasons, but I really need them (this is part of my effort to provide a replacement to NativeBoost on Pharo)… I really want to go back to use the FFI Plugin.
Is there a way to do this?
If not, would you agree if I add a primitive “loadSymbol:fromModule:” to ThreadedFFIPlugin? (I know, I could fork it, but I’m really trying to get aligned with the current implementation of the VM and I do not want to start again with the problem :P)
thanks!
Esteban
More information about the Vm-dev
mailing list