@@ -197,26 +197,26 @@ def fatal(required, msg):
197
197
198
198
if 'TARGET_GL' in magnum_config :
199
199
# to-do: make it work for other platforms; now only for desktop and only for GL
200
- conf .start_msg ('Magnum: Checking for OpenGL includes' )
201
- opengl_files = ['GL/gl.h' , 'gl.h' ]
202
- gl_not_found = False
203
- for gl_file in opengl_files :
204
- try :
205
- opengl_include_dir = get_directory (gl_file , includes_check )
206
- gl_not_found = False
207
- break
208
- except :
209
- gl_not_found = True
210
- if gl_not_found :
211
- fatal (required , 'Not found' )
212
- return
213
- magnum_includes = magnum_includes + [opengl_include_dir ]
214
- conf .end_msg (opengl_include_dir )
215
-
216
200
# no need to check on osx (it works anyway)
217
201
# Osx 11.3 (Big Sur) does not have libGL.dylib anymore (there is libGL.tbd)
218
202
# but at any rate, OpenGL is a framework so checking the dylib is not really what we need
219
203
if conf .env ['DEST_OS' ] != 'darwin' :
204
+ conf .start_msg ('Magnum: Checking for OpenGL includes' )
205
+ opengl_files = ['GL/gl.h' , 'gl.h' ]
206
+ gl_not_found = False
207
+ for gl_file in opengl_files :
208
+ try :
209
+ opengl_include_dir = get_directory (gl_file , includes_check )
210
+ gl_not_found = False
211
+ break
212
+ except :
213
+ gl_not_found = True
214
+ if gl_not_found :
215
+ fatal (required , 'Not found' )
216
+ return
217
+ magnum_includes = magnum_includes + [opengl_include_dir ]
218
+ conf .end_msg (opengl_include_dir )
219
+
220
220
conf .start_msg ('Magnum: Checking for OpenGL lib' )
221
221
opengl_lib_dir = get_directory ('libGL.' + suffix , libs_check )
222
222
magnum_libpaths = magnum_libpaths + [opengl_lib_dir ]
0 commit comments