GLX library location is wrong on Mac OS X Sierra
Original Reporter info from Mantis: Michalis @michaliskambi
-
Reporter name: Michalis Kamburelis
Original Reporter info from Mantis: Michalis @michaliskambi
- Reporter name: Michalis Kamburelis
Description:
The Glx unit contains a hardcoded path to the library on Mac OS X:
OurLibGL := LoadLibrary('/usr/X11R6/lib/libGL.dylib');
On macOS Sierra with XQuartz 2.7.11, the directory is X11, not X11R6. (It seems that the upgrade from Mac OS X El Capitan -> macOS Sierra causes this change, not upgrade of XQuartz. But I cannot say for sure.)
As a consequence, the FPC programs using Glx unit think that the glx library is missing.
Attaching a trivial patch to packages/opengl/src/glx.pp that fixes it.
(Tested with FPC 3.0.2, which cannot be selected in the bugtracker. I looked at GLX unit sources in trunk http://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/packages/opengl/src/glx.pp?view=log and they are the same, so they still have this bug.)
Mantis conversion info:
- Mantis ID: 31651
- OS: Mac OS X
- OS Build: Sierra
- Platform: i386
- Version: 3.0.0