Changes for static Windows and OS X builds

This is not meant to be directly merged, as I don't know how do you want to build the static examples, but these are the changes that I needed to make the build the binaries at http://build.oxygene.sk/view/Essentia/

Merge or cherry-pick as you want.