Add preprocessor check for OS X