Patchwork [1/2] mesa: merge internal libraries into mesa-dri package

login
register
mail settings
Submitter Ross Burton
Date Dec. 5, 2012, 5:18 p.m.
Message ID <1354727906-16779-1-git-send-email-ross.burton@intel.com>
Download mbox | patch
Permalink /patch/40445/
State New
Headers show

Comments

Ross Burton - Dec. 5, 2012, 5:18 p.m.
libglapi and libgbm are specific to Mesa and it's unlikely that they'll be used
on their own.  Mesa 9 also adds another internal library, libdricore, so prepare
for that by putting these mesa-specific libraries into the mesa-dri package.

Signed-off-by: Ross Burton <ross.burton@intel.com>
---
 meta/recipes-graphics/mesa/mesa-common.inc |   19 ++++++++-----------
 1 file changed, 8 insertions(+), 11 deletions(-)

Patch

diff --git a/meta/recipes-graphics/mesa/mesa-common.inc b/meta/recipes-graphics/mesa/mesa-common.inc
index d5f83e4..9113ba8 100644
--- a/meta/recipes-graphics/mesa/mesa-common.inc
+++ b/meta/recipes-graphics/mesa/mesa-common.inc
@@ -12,7 +12,7 @@  SECTION = "x11"
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://docs/license.html;md5=03ccdc4c379c4289aecfb8892c546f67"
 
-INC_PR = "r5"
+INC_PR = "r6"
 PE = "2"
 
 DEPENDS = "libxml2-native makedepend-native flex-native bison-native"
@@ -37,14 +37,9 @@  PACKAGECONFIG[x11] = "--enable-glx-tls,--disable-glx,${X11_DEPS}"
 # Multiple virtual/gl providers being built breaks staging
 EXCLUDE_FROM_WORLD = "1"
 
-# Remove the mesa-dri dependency on mesa-dri-dev, as mesa-dri is empty
-RDEPENDS_${PN}-dev = ""
-
 PACKAGES =+ "libegl-mesa libegl-mesa-dev \
              libosmesa libosmesa-dev \
              libgl-mesa libgl-mesa-dev \
-             libglapi libglapi-dev \
-             libgbm libgbm-dev \
              libgles1-mesa libgles1-mesa-dev \
              libgles2-mesa libgles2-mesa-dev \
             "
@@ -54,6 +49,10 @@  do_install_append () {
     rm -f ${D}${includedir}/GL/glu*
 }
 
+RREPLACES_${PN} = "libgbm1 libglapi0"
+RPROVIDES_${PN} = "libgbm1 libglapi0"
+RCONFLICTS_${PN} = "libgbm1 libglapi0"
+
 # For the packages that make up the OpenGL interfaces, inject variables so that
 # they don't get Debian-renamed (which would remove the -mesa suffix), and
 # RPROVIDEs/RCONFLICTs on the generic libgl name.
@@ -76,18 +75,16 @@  python __anonymous() {
         d.appendVar("RCONFLICTS_" + fullp, pkgs)
 }
 
-FILES_libegl-mesa = "${libdir}/libEGL.so.* ${libdir}/egl/*.so"
-FILES_libgbm = "${libdir}/libgbm.so.*"
+FILES_${PN} = "${libdir}/libgbm.so.* ${libdir}/libglapi.so.*"
+FILES_libegl-mesa = "${libdir}/libEGL.so.*"
 FILES_libgles1-mesa = "${libdir}/libGLESv1*.so.*"
 FILES_libgles2-mesa = "${libdir}/libGLESv2.so.*"
 FILES_libgl-mesa = "${libdir}/libGL.so.*"
-FILES_libglapi = "${libdir}/libglapi.so.*"
 FILES_libosmesa = "${libdir}/libOSMesa.so.*"
 
+FILES_${PN}-dev = "${libdir}/pkgconfig/dri.pc ${libdir}/libgbm.so ${libdir}/pkgconfig/gbm.pc ${includedir}/gbm.h ${libdir}/libglapi.so"
 FILES_libegl-mesa-dev = "${libdir}/libEGL.* ${includedir}/EGL ${includedir}/KHR ${libdir}/pkgconfig/egl.pc"
-FILES_libgbm-dev = "${libdir}/libgbm* ${libdir}/pkgconfig/gbm.pc ${includedir}/gbm.h"
 FILES_libgl-mesa-dev = "${libdir}/libGL.* ${includedir}/GL ${libdir}/pkgconfig/gl.pc"
-FILES_libglapi-dev = "${libdir}/libglapi.*"
 FILES_libgles1-mesa-dev = "${libdir}/libGLESv1*.* ${includedir}/GLES ${libdir}/pkgconfig/glesv1*.pc"
 FILES_libgles2-mesa-dev = "${libdir}/libGLESv2.* ${includedir}/GLES2 ${libdir}/pkgconfig/glesv2.pc"
 FILES_libosmesa-dev = "${libdir}/libOSMesa.* ${includedir}/osmesa.h"