In perl5 it was easy to link in libperl.so, set some variables and run some code, with callbacks. Is there a story for doing this in perl6?
This isn't an answer, but suppose I've got an already existing C program which is designed to use plugins which are .dlls or .sos, and they get loaded via dlopen or LoadLibrary, an API entry point is found using dlsym or GetProcAddress, then that entry point is called with some sort of handle for the plugin to make calls back into the main process.
Now, suppose I want my plugin (inside of this .dll or .so) to load moarvm, and then run some perl6 script, which in turn uses NativeCall to call back into the main process. How would I go about doing this?
Alternatively, suppose I want my plugin (inside of this .dll or .so) to load the jvm, then run some perl6 script, etc. How would I go about doing this?
Loading perl5 just to load perl6 seems like a silly solution. It might work, but...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With