Trying to adapt the build to OSX Mavericks while keeping compatibility with previous versions + Linux