]> code.ossystems Code Review - meta-freescale.git/commitdiff
wayland: Backport recipe for version 1.15
authorFabio Berton <fabio.berton@ossystems.com.br>
Thu, 5 Jul 2018 18:04:35 +0000 (15:04 -0300)
committerOtavio Salvador <otavio@ossystems.com.br>
Thu, 5 Jul 2018 18:49:58 +0000 (15:49 -0300)
From OE-Core commit: 6e5952fcfc13ff4b63c9376bd41a1dbba957f425

Package libwayland-egl has been moved to wayland on version 1.15+
and we need to use wayland 1.15+ to build weston i.MX 4

Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
conf/machine/include/imx-base.inc
recipes-graphics/mesa/mesa_%.bbappend
recipes-graphics/wayland/wayland/fixpathinpcfiles.patch [new file with mode: 0644]
recipes-graphics/wayland/wayland_1.15.0.bb [new file with mode: 0644]

index bd2a2aa3565aead4949b7487a68271404dd88f35..b44f8a49953ee35289170864131137fced1b417f 100644 (file)
@@ -247,6 +247,8 @@ PREFERRED_PROVIDER_virtual/libg2d_mx6ul = ""
 PREFERRED_PROVIDER_virtual/libg2d_mx6ull = ""
 PREFERRED_PROVIDER_virtual/libg2d_mx7ulp ?= "imx-gpu-viv"
 
+PREFERRED_VERSION_wayland_imxgpu ?= "1.15.0"
+
 PREFERRED_VERSION_weston_mx6 ?= "4.0.0.imx"
 PREFERRED_VERSION_weston_mx7 ?= "4.0.0.imx"
 PREFERRED_VERSION_weston_mx8 ?= "4.0.0.imx"
index 60eaf8393fd2989a5334e8be499472db3db3cb8c..abd6dbf056d7a5811c6b3e2cd6f9dba21adfa017 100644 (file)
@@ -40,4 +40,9 @@ do_install_append_imxgpu () {
     if [ "${BACKEND}" = "wayland" ]; then
         rm -f ${D}${libdir}/pkgconfig/wayland-egl.pc
     fi
+
+    # libwayland-egl has been moved to wayland 1.15+
+    rm -f ${D}${libdir}/libwayland-egl*
+    rm -f ${D}${libdir}/pkgconfig/wayland-egl.pc
+    rmdir --ignore-fail-on-non-empty ${D}${libdir}/pkgconfig
 }
diff --git a/recipes-graphics/wayland/wayland/fixpathinpcfiles.patch b/recipes-graphics/wayland/wayland/fixpathinpcfiles.patch
new file mode 100644 (file)
index 0000000..ad3526d
--- /dev/null
@@ -0,0 +1,32 @@
+Fix wayland-client and wayland-scanner pc files
+
+Upstream-Status: Pending
+
+Signed-off-by: Fabien Lahoudere <fabien.lahoudere@collabora.co.uk>
+
+Index: wayland-1.14.0/src/wayland-client.pc.in
+===================================================================
+--- wayland-1.14.0.orig/src/wayland-client.pc.in
++++ wayland-1.14.0/src/wayland-client.pc.in
+@@ -1,7 +1,7 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+ datarootdir=@datarootdir@
+-pkgdatadir=@datadir@/@PACKAGE@
++pkgdatadir=${pc_sysrootdir}@datadir@/@PACKAGE@
+ libdir=@libdir@
+ includedir=@includedir@
+Index: wayland-1.14.0/src/wayland-scanner.pc.in
+===================================================================
+--- wayland-1.14.0.orig/src/wayland-scanner.pc.in
++++ wayland-1.14.0/src/wayland-scanner.pc.in
+@@ -2,7 +2,7 @@ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+ datarootdir=@datarootdir@
+ pkgdatadir=@datadir@/@PACKAGE@
+-wayland_scanner=@bindir@/wayland-scanner
++wayland_scanner=wayland-scanner
+ Name: Wayland Scanner
+ Description: Wayland scanner
diff --git a/recipes-graphics/wayland/wayland_1.15.0.bb b/recipes-graphics/wayland/wayland_1.15.0.bb
new file mode 100644 (file)
index 0000000..3cef27e
--- /dev/null
@@ -0,0 +1,46 @@
+SUMMARY = "Wayland, a protocol between a compositor and clients"
+DESCRIPTION = "Wayland is a protocol for a compositor to talk to its clients \
+as well as a C library implementation of that protocol. The compositor can be \
+a standalone display server running on Linux kernel modesetting and evdev \
+input devices, an X application, or a wayland client itself. The clients can \
+be traditional applications, X servers (rootless or fullscreen) or other \
+display servers."
+HOMEPAGE = "http://wayland.freedesktop.org"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b31d8f53b6aaf2b4985d7dd7810a70d1 \
+                    file://src/wayland-server.c;endline=24;md5=b8e046164a766bb1ede8ba38e9dcd7ce"
+
+DEFAULT_PREFERENCE = "-1"
+
+DEPENDS = "expat libxml2 libffi wayland-native"
+
+SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
+          file://fixpathinpcfiles.patch \
+           "
+SRC_URI[md5sum] = "b7393c17fdce9a8d383edab656c92fd2"
+SRC_URI[sha256sum] = "eb3fbebb8559d56a80ad3753ec3db800f587329067962dbf65e14488b4b7aeb0"
+
+UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-documentation --with-host-scanner"
+EXTRA_OECONF_class-native = "--disable-documentation --disable-libraries"
+
+# Wayland installs a M4 macro for other projects to use, which uses the target
+# pkg-config to find files.  Replace pkg-config with pkg-config-native.
+do_install_append_class-native() {
+  sed -e 's,PKG_CHECK_MODULES(.*),,g' \
+      -e 's,$PKG_CONFIG,pkg-config-native,g' \
+      -i ${D}/${datadir}/aclocal/wayland-scanner.m4
+}
+
+sysroot_stage_all_append_class-target () {
+       rm ${SYSROOT_DESTDIR}/${datadir}/aclocal/wayland-scanner.m4
+       cp ${STAGING_DATADIR_NATIVE}/aclocal/wayland-scanner.m4 ${SYSROOT_DESTDIR}/${datadir}/aclocal/
+}
+
+FILES_${PN} = "${libdir}/*${SOLIBS}"
+FILES_${PN}-dev += "${bindir} ${datadir}/wayland"
+
+BBCLASSEXTEND = "native nativesdk"