summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2012-11-19 16:04:54 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-11-19 17:00:05 +0000
commit64c77bf395310e55b4d8e0ec754fa19e9034ab35 (patch)
tree291b79cd922cbe455c1e45461cb571c933292ea7
parenta1d93e6383396dc3ff7cd3a4fccf27895e80af8a (diff)
downloadopenembedded-core-64c77bf395310e55b4d8e0ec754fa19e9034ab35.tar.gz
openembedded-core-64c77bf395310e55b4d8e0ec754fa19e9034ab35.tar.bz2
openembedded-core-64c77bf395310e55b4d8e0ec754fa19e9034ab35.zip
mesa: add -mesa suffix to GL packages, RPROVIDE their generic names
When Debian-renaming, all packages that provide GL libraries get renamed to the same name, and it's entirley possible for a feed to have multiple GL libraries in. This obviously creates conflicts. Resolve this for Mesa by forcing the package names to be of the form libgl-mesa, and RPROVIDE libgl. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-graphics/mesa/mesa-common.inc46
-rw-r--r--meta/recipes-graphics/mesa/mesa-dri_8.0.4.bb2
-rw-r--r--meta/recipes-graphics/mesa/mesa-dri_git.bb2
3 files changed, 36 insertions, 14 deletions
diff --git a/meta/recipes-graphics/mesa/mesa-common.inc b/meta/recipes-graphics/mesa/mesa-common.inc
index 460877ccfb..8e7137818b 100644
--- a/meta/recipes-graphics/mesa/mesa-common.inc
+++ b/meta/recipes-graphics/mesa/mesa-common.inc
@@ -41,13 +41,13 @@ EXCLUDE_FROM_WORLD = "1"
# Remove the mesa-dri dependency on mesa-dri-dev, as mesa-dri is empty
RDEPENDS_${PN}-dev = ""
-PACKAGES =+ "libegl libegl-dev \
+PACKAGES =+ "libegl-mesa libegl-mesa-dev \
libosmesa libosmesa-dev \
- libgl libgl-dev \
+ libgl-mesa libgl-mesa-dev \
libglapi libglapi-dev \
libgbm libgbm-dev \
- libgles1 libgles1-dev \
- libgles2 libgles2-dev \
+ libgles1-mesa libgles1-mesa-dev \
+ libgles2-mesa libgles2-mesa-dev \
"
do_install_append () {
@@ -55,20 +55,42 @@ do_install_append () {
rm -f ${D}${includedir}/GL/glu*
}
-FILES_libegl = "${libdir}/libEGL.so.* ${libdir}/egl/*.so"
+# 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.
+python __anonymous() {
+ for p in (("libegl", "libegl1"), ("libgl", "libgl1"),
+ ("libgles1", "libglesv1-cm1"), ("libgles2", "libglesv2-2")):
+ fullp = p[0] + "-mesa"
+ pkgs = " ".join(p)
+ d.setVar("DEBIAN_NOAUTONAME_" + fullp, "1")
+ d.appendVar("RREPLACES_" + fullp, pkgs)
+ d.appendVar("RPROVIDES_" + fullp, pkgs)
+ d.appendVar("RCONFLICTS_" + fullp, pkgs)
+
+ # For -dev, the first element is both the Debian and original name
+ fullp += "-dev"
+ pkgs = p[0]
+ d.setVar("DEBIAN_NOAUTONAME_" + fullp, "1")
+ d.appendVar("RREPLACES_" + fullp, pkgs)
+ d.appendVar("RPROVIDES_" + fullp, pkgs)
+ d.appendVar("RCONFLICTS_" + fullp, pkgs)
+}
+
+FILES_libegl-mesa = "${libdir}/libEGL.so.* ${libdir}/egl/*.so"
FILES_libgbm = "${libdir}/libgbm.so.*"
-FILES_libgles1 = "${libdir}/libGLESv1*.so.*"
-FILES_libgles2 = "${libdir}/libGLESv2.so.*"
-FILES_libgl = "${libdir}/libGL.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_libegl-dev = "${libdir}/libEGL.* ${includedir}/EGL ${includedir}/KHR ${libdir}/pkgconfig/egl.pc"
+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-dev = "${libdir}/libGL.* ${includedir}/GL ${libdir}/pkgconfig/gl.pc"
+FILES_libgl-mesa-dev = "${libdir}/libGL.* ${includedir}/GL ${libdir}/pkgconfig/gl.pc"
FILES_libglapi-dev = "${libdir}/libglapi.*"
-FILES_libgles1-dev = "${libdir}/libGLESv1*.* ${includedir}/GLES ${libdir}/pkgconfig/glesv1*.pc"
-FILES_libgles2-dev = "${libdir}/libGLESv2.* ${includedir}/GLES2 ${libdir}/pkgconfig/glesv2.pc"
+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"
FILES_${PN}-dbg += "${libdir}/dri/.debug/* ${libdir}/egl/.debug/*"
diff --git a/meta/recipes-graphics/mesa/mesa-dri_8.0.4.bb b/meta/recipes-graphics/mesa/mesa-dri_8.0.4.bb
index fb356764bf..fabb99d59a 100644
--- a/meta/recipes-graphics/mesa/mesa-dri_8.0.4.bb
+++ b/meta/recipes-graphics/mesa/mesa-dri_8.0.4.bb
@@ -1,4 +1,4 @@
require mesa-common.inc
require mesa-${PV}.inc
require mesa-dri.inc
-PR = "${INC_PR}.2"
+PR = "${INC_PR}.3"
diff --git a/meta/recipes-graphics/mesa/mesa-dri_git.bb b/meta/recipes-graphics/mesa/mesa-dri_git.bb
index de1aa14cc1..5f8697a1dd 100644
--- a/meta/recipes-graphics/mesa/mesa-dri_git.bb
+++ b/meta/recipes-graphics/mesa/mesa-dri_git.bb
@@ -5,4 +5,4 @@ require mesa-dri.inc
# this needs to be lower than -1 because all mesa-dri have -1 and git version has highest PV, but shouldn't be default
DEFAULT_PREFERENCE = "-2"
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"