lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Wed, 14 Jun 2017 02:35:38 -0400, Sean Conner <> wrote:

> [...]
>   -spc (Who thinks that executables should also be shared libraries ... )

This is doable at least when dealing with ELF objects. Of course the binary
has to _both_ provide a program entry point (likely as a weak symbol, so it
can be overriden when the ELF object is linked in as a shared library), and
also export dynamic symbols. You can try this today, by going ahead and
executing the glibc main binary:

  % /lib/

Of course, building such a binary can get tricky (symbol visibility, weak
symbols) and most likely it will be a portability nightmare. Still doable,


 Adrián 🎩

Attachment: pgp0sl07F1bbX.pgp
Description: PGP signature