Update for changes to Objective-C runtime.
Fix OpenGL-related compile issues on iOS.