diff options
Diffstat (limited to 'meta/recipes-graphics/wayland/weston_9.0.0.bb')
-rw-r--r-- | meta/recipes-graphics/wayland/weston_9.0.0.bb | 128 |
1 files changed, 128 insertions, 0 deletions
diff --git a/meta/recipes-graphics/wayland/weston_9.0.0.bb b/meta/recipes-graphics/wayland/weston_9.0.0.bb new file mode 100644 index 0000000000..2c526e3016 --- /dev/null +++ b/meta/recipes-graphics/wayland/weston_9.0.0.bb | |||
@@ -0,0 +1,128 @@ | |||
1 | SUMMARY = "Weston, a Wayland compositor" | ||
2 | DESCRIPTION = "Weston is the reference implementation of a Wayland compositor" | ||
3 | HOMEPAGE = "http://wayland.freedesktop.org" | ||
4 | LICENSE = "MIT" | ||
5 | LIC_FILES_CHKSUM = "file://COPYING;md5=d79ee9e66bb0f95d3386a7acae780b70 \ | ||
6 | file://libweston/compositor.c;endline=27;md5=6c53bbbd99273f4f7c4affa855c33c0a" | ||
7 | |||
8 | SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \ | ||
9 | file://weston.png \ | ||
10 | file://weston.desktop \ | ||
11 | file://xwayland.weston-start \ | ||
12 | file://0001-weston-launch-Provide-a-default-version-that-doesn-t.patch \ | ||
13 | file://0001-tests-include-fcntl.h-for-open-O_RDWR-O_CLOEXEC-and-.patch \ | ||
14 | " | ||
15 | SRC_URI[sha256sum] = "5cf5d6ce192e0eb15c1fc861a436bf21b5bb3b91dbdabbdebe83e1f83aa098fe" | ||
16 | |||
17 | UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html" | ||
18 | |||
19 | inherit meson pkgconfig useradd features_check | ||
20 | # depends on virtual/egl | ||
21 | REQUIRED_DISTRO_FEATURES = "opengl" | ||
22 | |||
23 | DEPENDS = "libxkbcommon gdk-pixbuf pixman cairo glib-2.0" | ||
24 | DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native" | ||
25 | |||
26 | WESTON_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:1])}" | ||
27 | |||
28 | EXTRA_OEMESON += "-Dbackend-default=auto -Dbackend-rdp=false -Dpipewire=false" | ||
29 | |||
30 | PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms fbdev wayland egl clients', '', d)} \ | ||
31 | ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \ | ||
32 | ${@bb.utils.filter('DISTRO_FEATURES', 'pam systemd x11', d)} \ | ||
33 | ${@bb.utils.contains_any('DISTRO_FEATURES', 'wayland x11', '', 'headless', d)} \ | ||
34 | launch \ | ||
35 | image-jpeg \ | ||
36 | screenshare \ | ||
37 | shell-desktop \ | ||
38 | shell-fullscreen \ | ||
39 | shell-ivi" | ||
40 | |||
41 | # | ||
42 | # Compositor choices | ||
43 | # | ||
44 | # Weston on KMS | ||
45 | PACKAGECONFIG[kms] = "-Dbackend-drm=true,-Dbackend-drm=false,drm udev virtual/egl virtual/libgles2 virtual/libgbm mtdev" | ||
46 | # Weston on Wayland (nested Weston) | ||
47 | PACKAGECONFIG[wayland] = "-Dbackend-wayland=true,-Dbackend-wayland=false,virtual/egl virtual/libgles2" | ||
48 | # Weston on X11 | ||
49 | PACKAGECONFIG[x11] = "-Dbackend-x11=true,-Dbackend-x11=false,virtual/libx11 libxcb libxcb libxcursor cairo" | ||
50 | # Headless Weston | ||
51 | PACKAGECONFIG[headless] = "-Dbackend-headless=true,-Dbackend-headless=false" | ||
52 | # Weston on framebuffer | ||
53 | PACKAGECONFIG[fbdev] = "-Dbackend-fbdev=true,-Dbackend-fbdev=false,udev mtdev" | ||
54 | # weston-launch | ||
55 | PACKAGECONFIG[launch] = "-Dweston-launch=true,-Dweston-launch=false,drm" | ||
56 | # VA-API desktop recorder | ||
57 | PACKAGECONFIG[vaapi] = "-Dbackend-drm-screencast-vaapi=true,-Dbackend-drm-screencast-vaapi=false,libva" | ||
58 | # Weston with EGL support | ||
59 | PACKAGECONFIG[egl] = "-Drenderer-gl=true,-Drenderer-gl=false,virtual/egl" | ||
60 | # Weston with lcms support | ||
61 | PACKAGECONFIG[lcms] = "-Dcolor-management-lcms=true,-Dcolor-management-lcms=false,lcms" | ||
62 | # Weston with webp support | ||
63 | PACKAGECONFIG[webp] = "-Dimage-webp=true,-Dimage-webp=false,libwebp" | ||
64 | # Weston with systemd-login support | ||
65 | PACKAGECONFIG[systemd] = "-Dsystemd=true -Dlauncher-logind=true,-Dsystemd=false -Dlauncher-logind=false,systemd dbus" | ||
66 | # Weston with Xwayland support (requires X11 and Wayland) | ||
67 | PACKAGECONFIG[xwayland] = "-Dxwayland=true,-Dxwayland=false" | ||
68 | # colord CMS support | ||
69 | PACKAGECONFIG[colord] = "-Dcolor-management-colord=true,-Dcolor-management-colord=false,colord" | ||
70 | # Clients support | ||
71 | PACKAGECONFIG[clients] = "-Dsimple-clients=all -Ddemo-clients=true,-Dsimple-clients= -Ddemo-clients=false" | ||
72 | # Virtual remote output with GStreamer on DRM backend | ||
73 | PACKAGECONFIG[remoting] = "-Dremoting=true,-Dremoting=false,gstreamer-1.0" | ||
74 | # Weston with PAM support | ||
75 | PACKAGECONFIG[pam] = "-Dpam=true,-Dpam=false,libpam" | ||
76 | # Weston with screen-share support | ||
77 | PACKAGECONFIG[screenshare] = "-Dscreenshare=true,-Dscreenshare=false" | ||
78 | # Traditional desktop shell | ||
79 | PACKAGECONFIG[shell-desktop] = "-Dshell-desktop=true,-Dshell-desktop=false" | ||
80 | # Fullscreen shell | ||
81 | PACKAGECONFIG[shell-fullscreen] = "-Dshell-fullscreen=true,-Dshell-fullscreen=false" | ||
82 | # In-Vehicle Infotainment (IVI) shell | ||
83 | PACKAGECONFIG[shell-ivi] = "-Dshell-ivi=true,-Dshell-ivi=false" | ||
84 | # JPEG image loading support | ||
85 | PACKAGECONFIG[image-jpeg] = "-Dimage-jpeg=true,-Dimage-jpeg=false, jpeg" | ||
86 | |||
87 | do_install_append() { | ||
88 | # Weston doesn't need the .la files to load modules, so wipe them | ||
89 | rm -f ${D}/${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.la | ||
90 | |||
91 | # If X11, ship a desktop file to launch it | ||
92 | if [ "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" ]; then | ||
93 | install -d ${D}${datadir}/applications | ||
94 | install ${WORKDIR}/weston.desktop ${D}${datadir}/applications | ||
95 | |||
96 | install -d ${D}${datadir}/icons/hicolor/48x48/apps | ||
97 | install ${WORKDIR}/weston.png ${D}${datadir}/icons/hicolor/48x48/apps | ||
98 | fi | ||
99 | |||
100 | if [ "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'yes', 'no', d)}" = "yes" ]; then | ||
101 | install -Dm 644 ${WORKDIR}/xwayland.weston-start ${D}${datadir}/weston-start/xwayland | ||
102 | fi | ||
103 | |||
104 | if [ "${@bb.utils.contains('PACKAGECONFIG', 'launch', 'yes', 'no', d)}" = "yes" ]; then | ||
105 | chmod u+s ${D}${bindir}/weston-launch | ||
106 | fi | ||
107 | } | ||
108 | |||
109 | PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', '${PN}-xwayland', '', d)} \ | ||
110 | libweston-${WESTON_MAJOR_VERSION} ${PN}-examples" | ||
111 | |||
112 | FILES_${PN}-dev += "${libdir}/${BPN}/libexec_weston.so" | ||
113 | FILES_${PN} = "${bindir}/weston ${bindir}/weston-terminal ${bindir}/weston-info ${bindir}/weston-launch ${bindir}/wcap-decode ${libexecdir} ${libdir}/${BPN}/*.so* ${datadir}" | ||
114 | |||
115 | FILES_libweston-${WESTON_MAJOR_VERSION} = "${libdir}/lib*${SOLIBS} ${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.so" | ||
116 | SUMMARY_libweston-${WESTON_MAJOR_VERSION} = "Helper library for implementing 'wayland window managers'." | ||
117 | |||
118 | FILES_${PN}-examples = "${bindir}/*" | ||
119 | |||
120 | FILES_${PN}-xwayland = "${libdir}/libweston-${WESTON_MAJOR_VERSION}/xwayland.so" | ||
121 | RDEPENDS_${PN}-xwayland += "xserver-xorg-xwayland" | ||
122 | |||
123 | RDEPENDS_${PN} += "xkeyboard-config" | ||
124 | RRECOMMENDS_${PN} = "weston-init liberation-fonts" | ||
125 | RRECOMMENDS_${PN}-dev += "wayland-protocols" | ||
126 | |||
127 | USERADD_PACKAGES = "${PN}" | ||
128 | GROUPADD_PARAM_${PN} = "--system weston-launch" | ||