Make MagicLib a plugin

So it can be a provider for the library implementation in the absense
of Magic.