Add compilation support for Mac OSX