Corrected order of initialization
Added signing support for Mac. There are still a lot of limitations that need to be taken care of.