summaryrefslogtreecommitdiffstats
path: root/recipes-graphics/wayland
diff options
context:
space:
mode:
authorTom Hochstein <tom.hochstein@nxp.com>2023-05-17 10:00:42 -0700
committerTom Hochstein <tom.hochstein@nxp.com>2023-05-17 13:24:46 -0700
commit016e9bcbf71218a210c7173c33cdbff1ec3d8d2f (patch)
treeba5bc2da488c301c9080fcca3a50ce799bebc817 /recipes-graphics/wayland
parente7ff896868a592dcba3ce2b549116c1e4e7fec11 (diff)
downloadmeta-freescale-016e9bcbf71218a210c7173c33cdbff1ec3d8d2f.tar.gz
weston: Upgrade 10.0.3.imx -> 11.0.1.imx for i.MX 8 and 9
This upgrade does not support i.MX 6 and 7 due to the removal of fbdev support, so the 10.0.3.imx recipe is kept for 6 and 7. Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
Diffstat (limited to 'recipes-graphics/wayland')
-rw-r--r--recipes-graphics/wayland/weston-10.0.3.imx/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch40
-rw-r--r--recipes-graphics/wayland/weston-10.0.3.imx/0001-g2d-renderer.c-Include-sys-stat.h.patch (renamed from recipes-graphics/wayland/weston/0001-g2d-renderer.c-Include-sys-stat.h.patch)0
-rw-r--r--recipes-graphics/wayland/weston/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch8
-rw-r--r--recipes-graphics/wayland/weston/0001-tests-Add-dependency-on-screenshooter-client-protoco.patch33
-rw-r--r--recipes-graphics/wayland/weston/xwayland.weston-start3
-rw-r--r--recipes-graphics/wayland/weston_11.0.1.imx.bb182
6 files changed, 228 insertions, 38 deletions
diff --git a/recipes-graphics/wayland/weston-10.0.3.imx/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch b/recipes-graphics/wayland/weston-10.0.3.imx/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch
new file mode 100644
index 00000000..676d0338
--- /dev/null
+++ b/recipes-graphics/wayland/weston-10.0.3.imx/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch
@@ -0,0 +1,40 @@
1From 77eba6f6b04ff21b77c41500657495b4fd12a5f6 Mon Sep 17 00:00:00 2001
2From: Max Krummenacher <max.krummenacher@toradex.com>
3Date: Mon, 11 Jul 2022 19:38:19 +0000
4Subject: [PATCH] Revert "protocol: no found wayland-scanner with Yocto
5 toolchain"
6
7This reverts commit 7859a762617682bd804e210ad3bda6bdcd3ea24a.
8
9With openembedded commit e525db4eb9 ("wayland: update 1.20.0 -> 1.21.0")
10package config seems no longer to provide the path to the native
11weston scanner.
12
13Thus the build fails with:
14
15| Run-time dependency wayland-scanner found: YES 1.21.0
16| Program /usr/bin/wayland-scanner found: NO
17|
18| ../git/protocol/meson.build:2:0: ERROR: Program '/usr/bin/wayland-scanner' not found or not executable
19
20Dropping weston 9.0.0-imx commit 7859a762 (protocol: no found
21wayland-scanner with Yocto toolchain") fixes the issue.
22
23Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
24---
25 protocol/meson.build | 2 +-
26 1 file changed, 1 insertion(+), 1 deletion(-)
27
28diff --git a/protocol/meson.build b/protocol/meson.build
29index bdd322ac..e50b23bb 100644
30--- a/protocol/meson.build
31+++ b/protocol/meson.build
32@@ -1,4 +1,4 @@
33-dep_scanner = dependency('wayland-scanner', native: false)
34+dep_scanner = dependency('wayland-scanner', native: true)
35 prog_scanner = find_program(dep_scanner.get_pkgconfig_variable('wayland_scanner'))
36
37 dep_wp = dependency('wayland-protocols', version: '>= 1.24')
38--
392.17.1
40
diff --git a/recipes-graphics/wayland/weston/0001-g2d-renderer.c-Include-sys-stat.h.patch b/recipes-graphics/wayland/weston-10.0.3.imx/0001-g2d-renderer.c-Include-sys-stat.h.patch
index b9cb31fb..b9cb31fb 100644
--- a/recipes-graphics/wayland/weston/0001-g2d-renderer.c-Include-sys-stat.h.patch
+++ b/recipes-graphics/wayland/weston-10.0.3.imx/0001-g2d-renderer.c-Include-sys-stat.h.patch
diff --git a/recipes-graphics/wayland/weston/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch b/recipes-graphics/wayland/weston/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch
index 676d0338..39439ce1 100644
--- a/recipes-graphics/wayland/weston/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch
+++ b/recipes-graphics/wayland/weston/0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch
@@ -1,4 +1,4 @@
1From 77eba6f6b04ff21b77c41500657495b4fd12a5f6 Mon Sep 17 00:00:00 2001 1From 3aa4024ac4107e68552be4dfe5fce511900629c9 Mon Sep 17 00:00:00 2001
2From: Max Krummenacher <max.krummenacher@toradex.com> 2From: Max Krummenacher <max.krummenacher@toradex.com>
3Date: Mon, 11 Jul 2022 19:38:19 +0000 3Date: Mon, 11 Jul 2022 19:38:19 +0000
4Subject: [PATCH] Revert "protocol: no found wayland-scanner with Yocto 4Subject: [PATCH] Revert "protocol: no found wayland-scanner with Yocto
@@ -26,7 +26,7 @@ Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
26 1 file changed, 1 insertion(+), 1 deletion(-) 26 1 file changed, 1 insertion(+), 1 deletion(-)
27 27
28diff --git a/protocol/meson.build b/protocol/meson.build 28diff --git a/protocol/meson.build b/protocol/meson.build
29index bdd322ac..e50b23bb 100644 29index e8698530..ba52089b 100644
30--- a/protocol/meson.build 30--- a/protocol/meson.build
31+++ b/protocol/meson.build 31+++ b/protocol/meson.build
32@@ -1,4 +1,4 @@ 32@@ -1,4 +1,4 @@
@@ -34,7 +34,7 @@ index bdd322ac..e50b23bb 100644
34+dep_scanner = dependency('wayland-scanner', native: true) 34+dep_scanner = dependency('wayland-scanner', native: true)
35 prog_scanner = find_program(dep_scanner.get_pkgconfig_variable('wayland_scanner')) 35 prog_scanner = find_program(dep_scanner.get_pkgconfig_variable('wayland_scanner'))
36 36
37 dep_wp = dependency('wayland-protocols', version: '>= 1.24') 37 dep_wp = dependency('wayland-protocols', version: '>= 1.26',
38-- 38--
392.17.1 392.25.1
40 40
diff --git a/recipes-graphics/wayland/weston/0001-tests-Add-dependency-on-screenshooter-client-protoco.patch b/recipes-graphics/wayland/weston/0001-tests-Add-dependency-on-screenshooter-client-protoco.patch
deleted file mode 100644
index 46538600..00000000
--- a/recipes-graphics/wayland/weston/0001-tests-Add-dependency-on-screenshooter-client-protoco.patch
+++ /dev/null
@@ -1,33 +0,0 @@
1From 2ac6b6b084a877adde64db7faff2ed22eb3ea97a Mon Sep 17 00:00:00 2001
2From: Daniel Stone <daniels@collabora.com>
3Date: Tue, 8 Feb 2022 22:39:42 +0000
4Subject: [PATCH] tests: Add dependency on screenshooter client protocol
5
6Given that the test-helper code relies on the screenshooter protocol,
7make sure it's available for us to build, and the dependency ensures we
8build in order.
9
10Fixes: #588
11
12Signed-off-by: Daniel Stone <daniels@collabora.com>
13---
14 tests/meson.build | 3 ++-
15 1 file changed, 2 insertions(+), 1 deletion(-)
16
17diff --git a/tests/meson.build b/tests/meson.build
18index 2d464ddcc..222091cd1 100644
19--- a/tests/meson.build
20+++ b/tests/meson.build
21@@ -29,8 +29,9 @@ lib_test_client = static_library(
22 'weston-test-client-helper.c',
23 'weston-test-fixture-compositor.c',
24 weston_test_client_protocol_h,
25- weston_screenshooter_protocol_c,
26 weston_test_protocol_c,
27+ weston_screenshooter_client_protocol_h,
28+ weston_screenshooter_protocol_c,
29 viewporter_client_protocol_h,
30 viewporter_protocol_c,
31 'color_util.h',
32
33
diff --git a/recipes-graphics/wayland/weston/xwayland.weston-start b/recipes-graphics/wayland/weston/xwayland.weston-start
index db384b1a..342ac8d1 100644
--- a/recipes-graphics/wayland/weston/xwayland.weston-start
+++ b/recipes-graphics/wayland/weston/xwayland.weston-start
@@ -1,5 +1,6 @@
1#!/bin/sh 1#!/bin/sh
2 2
3if type Xwayland >/dev/null 2>/dev/null; then 3if type Xwayland >/dev/null 2>/dev/null; then
4 mkdir -p /tmp/.X11-unix 4 mkdir -m 775 -p /tmp/.X11-unix
5 chown root:video /tmp/.X11-unix
5fi 6fi
diff --git a/recipes-graphics/wayland/weston_11.0.1.imx.bb b/recipes-graphics/wayland/weston_11.0.1.imx.bb
new file mode 100644
index 00000000..a14f8d99
--- /dev/null
+++ b/recipes-graphics/wayland/weston_11.0.1.imx.bb
@@ -0,0 +1,182 @@
1# This recipe is for the i.MX fork of weston. For ease of
2# maintenance, the top section is a verbatim copy of an OE-core
3# recipe. The second section customizes the recipe for i.MX.
4
5########### OE-core copy ##################
6# Upstream hash: eb00d50e5da97a726eb6290317a3ef7d8e1b90a3
7
8SUMMARY = "Weston, a Wayland compositor"
9DESCRIPTION = "Weston is the reference implementation of a Wayland compositor"
10HOMEPAGE = "http://wayland.freedesktop.org"
11LICENSE = "MIT"
12LIC_FILES_CHKSUM = "file://LICENSE;md5=d79ee9e66bb0f95d3386a7acae780b70 \
13 file://libweston/compositor.c;endline=27;md5=eb6d5297798cabe2ddc65e2af519bcf0 \
14 "
15
16SRC_URI = "https://gitlab.freedesktop.org/wayland/weston/-/releases/${PV}/downloads/${BPN}-${PV}.tar.xz \
17 file://weston.png \
18 file://weston.desktop \
19 file://xwayland.weston-start \
20 file://systemd-notify.weston-start \
21 "
22
23SRC_URI[sha256sum] = "a6138d4dc9554560ac304312df456019f4be025ec79130f05fb5f2e41c091e1d"
24
25UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html"
26UPSTREAM_CHECK_REGEX = "weston-(?P<pver>\d+\.\d+\.(?!9\d+)\d+)"
27
28inherit meson pkgconfig useradd
29
30# depends on virtual/egl
31#
32require ${THISDIR}/required-distro-features.inc
33
34DEPENDS = "libxkbcommon gdk-pixbuf pixman cairo glib-2.0"
35DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native"
36
37LDFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'lto', '-Wl,-z,undefs', '', d)}"
38
39WESTON_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:1])}"
40
41EXTRA_OEMESON += "-Dpipewire=false"
42
43PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms wayland egl clients', '', d)} \
44 ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \
45 ${@bb.utils.filter('DISTRO_FEATURES', 'systemd x11', d)} \
46 ${@bb.utils.contains_any('DISTRO_FEATURES', 'wayland x11', '', 'headless', d)} \
47 ${@oe.utils.conditional('VIRTUAL-RUNTIME_init_manager', 'sysvinit', 'launcher-libseat', '', d)} \
48 image-jpeg \
49 screenshare \
50 shell-desktop \
51 shell-fullscreen \
52 shell-ivi"
53
54# Can be 'damage', 'im', 'egl', 'shm', 'touch', 'dmabuf-feedback', 'dmabuf-v4l', 'dmabuf-egl' or 'all'
55SIMPLECLIENTS ?= "all"
56
57#
58# Compositor choices
59#
60# Weston on KMS
61PACKAGECONFIG[kms] = "-Dbackend-drm=true,-Dbackend-drm=false,drm udev virtual/egl virtual/libgles2 virtual/libgbm mtdev"
62# Weston on Wayland (nested Weston)
63PACKAGECONFIG[wayland] = "-Dbackend-wayland=true,-Dbackend-wayland=false,virtual/egl virtual/libgles2"
64# Weston on X11
65PACKAGECONFIG[x11] = "-Dbackend-x11=true,-Dbackend-x11=false,virtual/libx11 libxcb libxcb libxcursor cairo"
66# Headless Weston
67PACKAGECONFIG[headless] = "-Dbackend-headless=true,-Dbackend-headless=false"
68# Weston on RDP
69PACKAGECONFIG[rdp] = "-Dbackend-rdp=true,-Dbackend-rdp=false,freerdp"
70# VA-API desktop recorder
71PACKAGECONFIG[vaapi] = "-Dbackend-drm-screencast-vaapi=true,-Dbackend-drm-screencast-vaapi=false,libva"
72# Weston with EGL support
73PACKAGECONFIG[egl] = "-Drenderer-gl=true,-Drenderer-gl=false,virtual/egl"
74# Weston with lcms support
75PACKAGECONFIG[lcms] = "-Dcolor-management-lcms=true,-Dcolor-management-lcms=false,lcms"
76# Weston with webp support
77PACKAGECONFIG[webp] = "-Dimage-webp=true,-Dimage-webp=false,libwebp"
78# Weston with systemd-login support
79PACKAGECONFIG[systemd] = "-Dsystemd=true -Dlauncher-logind=true,-Dsystemd=false -Dlauncher-logind=false,systemd dbus"
80# Weston with Xwayland support (requires X11 and Wayland)
81PACKAGECONFIG[xwayland] = "-Dxwayland=true,-Dxwayland=false"
82# colord CMS support
83PACKAGECONFIG[colord] = "-Ddeprecated-color-management-colord=true,-Ddeprecated-color-management-colord=false,colord"
84# Clients support
85PACKAGECONFIG[clients] = "-Dsimple-clients=${SIMPLECLIENTS} -Ddemo-clients=true,-Dsimple-clients= -Ddemo-clients=false"
86# Virtual remote output with GStreamer on DRM backend
87PACKAGECONFIG[remoting] = "-Dremoting=true,-Dremoting=false,gstreamer1.0 gstreamer1.0-plugins-base"
88# Weston with screen-share support
89PACKAGECONFIG[screenshare] = "-Dscreenshare=true,-Dscreenshare=false"
90# Traditional desktop shell
91PACKAGECONFIG[shell-desktop] = "-Dshell-desktop=true,-Dshell-desktop=false"
92# Fullscreen shell
93PACKAGECONFIG[shell-fullscreen] = "-Dshell-fullscreen=true,-Dshell-fullscreen=false"
94# In-Vehicle Infotainment (IVI) shell
95PACKAGECONFIG[shell-ivi] = "-Dshell-ivi=true,-Dshell-ivi=false"
96# JPEG image loading support
97PACKAGECONFIG[image-jpeg] = "-Dimage-jpeg=true,-Dimage-jpeg=false, jpeg"
98# support libseat based launch
99PACKAGECONFIG[launcher-libseat] = "-Dlauncher-libseat=true,-Dlauncher-libseat=false,seatd"
100
101do_install:append() {
102 # Weston doesn't need the .la files to load modules, so wipe them
103 rm -f ${D}/${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.la
104
105 # If X11, ship a desktop file to launch it
106 if [ "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" ]; then
107 install -d ${D}${datadir}/applications
108 install ${WORKDIR}/weston.desktop ${D}${datadir}/applications
109
110 install -d ${D}${datadir}/icons/hicolor/48x48/apps
111 install ${WORKDIR}/weston.png ${D}${datadir}/icons/hicolor/48x48/apps
112 fi
113
114 if [ "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'yes', 'no', d)}" = "yes" ]; then
115 install -Dm 644 ${WORKDIR}/xwayland.weston-start ${D}${datadir}/weston-start/xwayland
116 fi
117
118 if [ "${@bb.utils.contains('PACKAGECONFIG', 'systemd', 'yes', 'no', d)}" = "yes" ]; then
119 install -Dm 644 ${WORKDIR}/systemd-notify.weston-start ${D}${datadir}/weston-start/systemd-notify
120 fi
121
122 if [ "${@bb.utils.contains('PACKAGECONFIG', 'launch', 'yes', 'no', d)}" = "yes" ]; then
123 chmod u+s ${D}${bindir}/weston-launch
124 fi
125}
126
127PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', '${PN}-xwayland', '', d)} \
128 libweston-${WESTON_MAJOR_VERSION} ${PN}-examples"
129
130FILES:${PN}-dev += "${libdir}/${BPN}/libexec_weston.so"
131FILES:${PN} = "${bindir}/weston ${bindir}/weston-terminal ${bindir}/weston-info ${bindir}/weston-launch ${bindir}/wcap-decode ${libexecdir} ${libdir}/${BPN}/*.so* ${datadir}"
132
133FILES:libweston-${WESTON_MAJOR_VERSION} = "${libdir}/lib*${SOLIBS} ${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.so"
134SUMMARY:libweston-${WESTON_MAJOR_VERSION} = "Helper library for implementing 'wayland window managers'."
135
136FILES:${PN}-examples = "${bindir}/*"
137
138FILES:${PN}-xwayland = "${libdir}/libweston-${WESTON_MAJOR_VERSION}/xwayland.so"
139RDEPENDS:${PN}-xwayland += "xwayland"
140
141RDEPENDS:${PN} += "xkeyboard-config"
142RRECOMMENDS:${PN} = "weston-init liberation-fonts"
143RRECOMMENDS:${PN}-dev += "wayland-protocols"
144
145USERADD_PACKAGES = "${PN}"
146GROUPADD_PARAM:${PN} = "--system weston-launch"
147
148########### End of OE-core copy ###########
149
150########### i.MX overrides ################
151
152SUMMARY = "Weston, a Wayland compositor, i.MX fork"
153
154DEFAULT_PREFERENCE = "-1"
155
156SRC_URI:remove = "https://gitlab.freedesktop.org/wayland/weston/-/releases/${PV}/downloads/${BPN}-${PV}.tar.xz"
157SRC_URI:prepend = "git://github.com/nxp-imx/weston-imx.git;protocol=https;branch=${SRCBRANCH} "
158SRC_URI += "file://0001-Revert-protocol-no-found-wayland-scanner-with-Yocto-.patch"
159SRCBRANCH = "weston-imx-11.0.1"
160SRCREV = "36ab06f0ad8e8981a482df6a08f39e1ae2a6a2dd"
161S = "${WORKDIR}/git"
162
163PACKAGECONFIG_IMX_REMOVALS ?= "wayland x11"
164PACKAGECONFIG:remove = "${PACKAGECONFIG_IMX_REMOVALS}"
165
166PACKAGECONFIG:append:imxgpu2d = " imxg2d"
167PACKAGECONFIG:append:mx93-nxp-bsp = " imxg2d"
168
169# Override
170PACKAGECONFIG[xwayland] = "-Dxwayland=true,-Dxwayland=false,libxcursor xwayland"
171
172# Weston with i.MX G2D renderer
173PACKAGECONFIG[imxg2d] = "-Drenderer-g2d=true,-Drenderer-g2d=false,virtual/libg2d"
174
175# links with imx-gpu libs which are pre-built for glibc
176# gcompat will address it during runtime
177LDFLAGS:append:imxgpu:libc-musl = " -Wl,--allow-shlib-undefined"
178
179PACKAGE_ARCH = "${MACHINE_SOCARCH}"
180COMPATIBLE_MACHINE = "(imx-nxp-bsp)"
181
182########### End of i.MX overrides #########