4 ms·
I've been building and running OpenGL toy applications[0] on Mojave public betas without issue just to check on that. You just get lots of deprecation warnings
by lloeki 8y ago
I've been building and running OpenGL toy applications[0] on Mojave public betas without issue just to check on that. You just get lots of deprecation warnings at compile time that you can quench by defining GL_SILENCE_DEPRECATION. Excerpt:
./nsopengl_example.h:5:5: warning: 'NSOpenGLContext' is deprecated: first
deprecated in macOS 10.14 - Please use Metal or MetalKit.
[-Wdeprecated-declarations]
NSOpenGLContext* _openGLContext;
^
/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:202:12: note:
'NSOpenGLContext' has been explicitly marked deprecated here
@interface NSOpenGLContext : NSObject <NSLocking>
^
nsopengl_example.m:97:9: warning: 'glVertex3f' is deprecated: first deprecated
in macOS 10.14 - OpenGL API deprecated. (Define GL_SILENCE_DEPRECATION to
silence these warnings) [-Wdeprecated-declarations]
glVertex3f( 0.0, 0.6, 0.0);
^
Nothing is gone yet.
I suspect they'll proceed in a similar way as with OpenSSL, first deprecate, then remove headers, and keep the libs around for quite some time for legacy applications. In Mojave public beta /usr/lib still contains libssl.0.9.7.dylib and libssl.0.9.8.dylib, and it's been quite some time (El Capitan [1]) since you haven't been able to build against them.
The trickier part with OpenGL though is the graphic drivers. I suppose at some point in the future drivers for fresh new GPUs won't include OpenGL support. Maybe they'll include a GL-to-Metal akin to MoltenGL in that case, maybe not, or a third-party will create just that to run legacy applications. Anyway I bet it's a long road ahead and won't happen overnight.
[0]: https://gitlab.com/lloeki/nsopengl_example https://gitlab.com/lloeki/nsopengl_example
[1]: https://github.com/rbenv/ruby-build/issues/797 https://github.com/rbenv/ruby-build/issues/797