gl/build: also check for the GL/gl.h header
authorMatthew Waters <matthew@centricular.com>
Wed, 23 Aug 2017 06:23:07 +0000 (16:23 +1000)
committerMatthew Waters <matthew@centricular.com>
Wed, 23 Aug 2017 06:38:02 +0000 (16:38 +1000)
In order to successfully build against a detected libGL library we also need headers

gst-libs/gst/gl/meson.build

index 2c70492..78bdfd0 100644 (file)
@@ -272,6 +272,10 @@ if need_api_opengl != 'no' or need_platform_glx != 'no'
       gl_dep = cc.find_library('GL', required : false)
     endif
 
+    if not cc.has_header('GL/gl.h', required : false)
+      gl_dep = unneeded_dep
+    endif
+
     if not gl_dep.found() and need_api_opengl == 'yes'
       error ('Could not find requested OpenGL library')
     endif