Backported changes needed for xcode 6.1