Skip to contentSkip to conversation

cogl: GL/GLX feature cleanup

PATCH Superseded Ross Burton 2 participants 2 messages Aug 12, 2013

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 cogl: GL/GLX feature cleanup

Separate GL and GLX flags don't make sense, as on Linux GL means GLX and GLX means GL.

So, default to GLESv2 and GLX if X11 is enabled. EGL on X11 doesn't have feature parity yet so leave it disabled by default.

---
 meta/recipes-graphics/cogl/cogl-1.0.inc |   17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)
meta/recipes-graphics/cogl/cogl-1.0.inc +9 -8
index c0d410e..c189e95 100644
@@ -28,16 +28,17 @@ EDEPENDS_WAYLAND = "wayland"
 ERDEPENDS_GL    = "libgl"
 ERDEPENDS_GLES2 = "libgles2"
 
++# GLESv1 is rarely tested, so disable it
 EXTRA_OECONF += "--disable-introspection	\
 	       	 --enable-examples-install	\
 	       	 --enable-debug		 	\
 	       	 --disable-gles1		\
 	    	"
 
-PACKAGECONFIG[cogl-pango] = "--enable-cogl-pango,--disable-cogl-pango,pango"
+# OpenGL/GLX
+PACKAGECONFIG[glx] = "--enable-gl --enable-glx,--disable-gl --disable-glx,${EDEPENDS_GL} ${EDEPENDS_X11},${ERDEPENDS_GL}"
 
-# GL flavours
-PACKAGECONFIG[gl] = "--enable-gl,--disable-gl,${EDEPENDS_GL},${ERDEPENDS_GL}"
+# GLESv2
 PACKAGECONFIG[gles2] = "--enable-gles2,--disable-gles2,${EDEPENDS_GLES2}, ${ERDEPENDS_GLES2}"
 
 # EGL backends
@@ -46,15 +47,15 @@ PACKAGECONFIG[egl-null] = "--enable-null-egl-platform,--disable-null-egl-platfor
 PACKAGECONFIG[egl-x11] = "--enable-xlib-egl-platform,--disable-xlib-egl-platform,${EDEPENDS_X11}"
 PACKAGECONFIG[egl-wayland] = "--enable-wayland-egl-platform,--disable-wayland-egl-platform,${EDEPENDS_WAYLAND}"
 
-# GLX
-PACKAGECONFIG[glx] = "--enable-glx,--disable-glx,${EDEPENDS_GL} ${EDEPENDS_X11}"
-
-# Wayland server-side
+# Wayland (server-side)
 PACKAGECONFIG[wayland-server] = "--enable-wayland-egl-server,--disable-wayland-egl-server,${EDEPENDS_WAYLAND}"
 
+# Support rendering text directly with Pango
+PACKAGECONFIG[cogl-pango] = "--enable-cogl-pango,--disable-cogl-pango,pango"
+
 # Respect the DISTRO_FEATURES to pull in GLX or Wayland as appropriate by
 # default.
-PACKAGECONFIG ??= "cogl-pango gl \
+PACKAGECONFIG ??= "cogl-pango gles2 \
                    ${@base_contains('DISTRO_FEATURES', 'wayland', 'egl-wayland', '', d)} \
                    ${@base_contains('DISTRO_FEATURES', 'x11', 'glx', '', d)}"
 
Signature · 1 line
1.7.10.4
#1 lore raw
Quoted 16 lines · Ross Burton

Separate GL and GLX flags don't make sense, as on Linux GL means GLX and GLX means GL.

So, default to GLESv2 and GLX if X11 is enabled. EGL on X11 doesn't have feature parity yet so leave it disabled by default.

---
  meta/recipes-graphics/cogl/cogl-1.0.inc |   17 +++++++++--------
  1 file changed, 9 insertions(+), 8 deletions(-)
meta/recipes-graphics/cogl/cogl-1.0.inc +0 -0
index c0d410e..c189e95 100644

meta/recipes-graphics/cogl/cogl-1.0.inc EDEPENDS_WAYLAND = "wayland" · line 31

Quoted 4 lines
meta/recipes-graphics/cogl/cogl-1.0.inc +1 -0
@@ -28,16 +28,17 @@ EDEPENDS_WAYLAND = "wayland"
  ERDEPENDS_GL    = "libgl"
  ERDEPENDS_GLES2 = "libgles2"
 
++# GLESv1 is rarely tested, so disable it

Seems to be a patch issue here with the ++

Sau!

Quoted 38 lines
meta/recipes-graphics/cogl/cogl-1.0.inc +8 -8
  EXTRA_OECONF += "--disable-introspection	\
  	       	 --enable-examples-install	\
  	       	 --enable-debug		 	\
  	       	 --disable-gles1		\
  	    	"
 
-PACKAGECONFIG[cogl-pango] = "--enable-cogl-pango,--disable-cogl-pango,pango"
+# OpenGL/GLX
+PACKAGECONFIG[glx] = "--enable-gl --enable-glx,--disable-gl --disable-glx,${EDEPENDS_GL} ${EDEPENDS_X11},${ERDEPENDS_GL}"
 
-# GL flavours
-PACKAGECONFIG[gl] = "--enable-gl,--disable-gl,${EDEPENDS_GL},${ERDEPENDS_GL}"
+# GLESv2
  PACKAGECONFIG[gles2] = "--enable-gles2,--disable-gles2,${EDEPENDS_GLES2}, ${ERDEPENDS_GLES2}"
 
  # EGL backends
@@ -46,15 +47,15 @@ PACKAGECONFIG[egl-null] = "--enable-null-egl-platform,--disable-null-egl-platfor
  PACKAGECONFIG[egl-x11] = "--enable-xlib-egl-platform,--disable-xlib-egl-platform,${EDEPENDS_X11}"
  PACKAGECONFIG[egl-wayland] = "--enable-wayland-egl-platform,--disable-wayland-egl-platform,${EDEPENDS_WAYLAND}"
 
-# GLX
-PACKAGECONFIG[glx] = "--enable-glx,--disable-glx,${EDEPENDS_GL} ${EDEPENDS_X11}"
-
-# Wayland server-side
+# Wayland (server-side)
  PACKAGECONFIG[wayland-server] = "--enable-wayland-egl-server,--disable-wayland-egl-server,${EDEPENDS_WAYLAND}"
 
+# Support rendering text directly with Pango
+PACKAGECONFIG[cogl-pango] = "--enable-cogl-pango,--disable-cogl-pango,pango"
+
  # Respect the DISTRO_FEATURES to pull in GLX or Wayland as appropriate by
  # default.
-PACKAGECONFIG ??= "cogl-pango gl \
+PACKAGECONFIG ??= "cogl-pango gles2 \
                     ${@base_contains('DISTRO_FEATURES', 'wayland', 'egl-wayland', '', d)} \
                     ${@base_contains('DISTRO_FEATURES', 'x11', 'glx', '', d)}"