Re: Can we do shared objects with Rumprun unikernel?

  • From: Antti Kantee <pooka@xxxxxx>
  • To: rumpkernel-users@xxxxxxxxxxxxx
  • Date: Sat, 11 Jun 2016 17:01:36 +0000

On 11/06/16 16:54, Neeraj Sharma wrote:

I don't quite follow why dynamically loading something is necessary. Why
can't you link the objects into the binary before you run it?


The design of dynamically loading is to enable clean design and not
force user to recompile the Erlang VM for their custom NIFs (or C
code). It can be argued that for Rumprun this design be broken, but
that will be too intrusive to the base design. I am in the process of
understanding and brainstorming if at all this could be done in the
least intrusive way, but having said that I want to go down the path
of dynamic loadable objects within the Rumprun unikernel as well.

The good thing about using clean design as an argument is that you can justify anything with it ;)

Snarkiness aside, you don't need compile anything, you need to link things. As it happens, for Rumprun you need to link things anyway after you've built the binary. Try to link your NIFs at the bake-stage, see where it gets you, and then we can figure out how to turn your experiment into clean design.

Other related posts: