Add preprocessor conditionals to fix iOS 6.1 errors.