#12 apply patch on OSX only
Use logging instead of print