Allow compiling from a shared library

Very early code, doesn't work just yet.

Version: 1.alpha.14.02

Signed-off-by: GreatEmerald <pastas4@gmail.com>