summaryrefslogtreecommitdiffstats
path: root/recipes-graphics
diff options
context:
space:
mode:
authorAndrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>2020-04-13 22:22:08 +0000
committerOtavio Salvador <otavio@ossystems.com.br>2020-04-16 10:32:45 -0300
commit7022e8e1c77c9e0511f26668b08bc4f132a85a26 (patch)
tree5470bdd19ddac2ce9d1a4d083d0a256067a1f470 /recipes-graphics
parent4b58d344e9ea45e43ec74b869766cb80b116d999 (diff)
downloadmeta-freescale-7022e8e1c77c9e0511f26668b08bc4f132a85a26.tar.gz
weston: upgrade recipe to version 8.0.0 from NXP
Upgrade weston recipe version 6.0.1 -> 8.0.0 with following modifications performed: - Transition build system to meson, replace autotools references with meson options; - Align recipe with the latest version from oe-core, include all configuration changes done upstream into this recipe; - Drop patches applied upstream and those related to autotools; Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
Diffstat (limited to 'recipes-graphics')
-rw-r--r--recipes-graphics/wayland/weston/0001-make-error-portable.patch78
-rw-r--r--recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch126
-rw-r--r--recipes-graphics/wayland/weston/0003-weston-touch-calibrator-Advertise-the-touchscreen-ca.patch30
-rw-r--r--recipes-graphics/wayland/weston_8.0.0.imx.bb (renamed from recipes-graphics/wayland/weston_6.0.1.imx.bb)80
4 files changed, 112 insertions, 202 deletions
diff --git a/recipes-graphics/wayland/weston/0001-make-error-portable.patch b/recipes-graphics/wayland/weston/0001-make-error-portable.patch
deleted file mode 100644
index 4132d871..00000000
--- a/recipes-graphics/wayland/weston/0001-make-error-portable.patch
+++ /dev/null
@@ -1,78 +0,0 @@
1From 74469d3a5965560a83f1d51c50d3cd1fa4e96fe6 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Fri, 29 May 2015 20:56:00 -0700
4Subject: [PATCH] make error() portable
5
6error() is not posix but gnu extension so may not be available on all
7kind of systemsi e.g. musl.
8
9Upstream-Status: Submitted
10
11Signed-off-by: Khem Raj <raj.khem@gmail.com>
12
13---
14 configure.ac | 2 ++
15 libweston/weston-error.h | 20 ++++++++++++++++++++
16 libweston/weston-launch.c | 2 +-
17 3 files changed, 23 insertions(+), 1 deletion(-)
18 create mode 100644 libweston/weston-error.h
19
20diff --git a/configure.ac b/configure.ac
21index cdd0a87f..2396cba5 100644
22--- a/configure.ac
23+++ b/configure.ac
24@@ -126,6 +126,8 @@ AC_CHECK_DECL(CLOCK_MONOTONIC,[],
25 [AC_MSG_ERROR("CLOCK_MONOTONIC is needed to compile weston")],
26 [[#include <time.h>]])
27
28+AC_CHECK_HEADERS([error.h])
29+
30 AC_CHECK_FUNCS([mkostemp strchrnul initgroups posix_fallocate])
31
32 # check for libdrm as a build-time dependency only
33diff --git a/libweston/weston-error.h b/libweston/weston-error.h
34new file mode 100644
35index 00000000..2089d02c
36--- /dev/null
37+++ b/libweston/weston-error.h
38@@ -0,0 +1,20 @@
39+#ifndef _WESTON_ERROR_H
40+#define _WESTON_ERROR_H
41+
42+#if defined(HAVE_ERROR_H)
43+#include <error.h>
44+#else
45+#include <err.h>
46+#include <string.h>
47+#define _weston_error(S, E, F, ...) do { \
48+ if (E) \
49+ err(S, F ": %s", ##__VA_ARGS__, strerror(E)); \
50+ else \
51+ err(S, F, ##__VA_ARGS__); \
52+} while(0)
53+
54+#define error _weston_error
55+#endif
56+
57+#endif
58+
59diff --git a/libweston/weston-launch.c b/libweston/weston-launch.c
60index dff83cca..bd0015e6 100644
61--- a/libweston/weston-launch.c
62+++ b/libweston/weston-launch.c
63@@ -33,7 +33,6 @@
64 #include <poll.h>
65 #include <errno.h>
66
67-#include <error.h>
68 #include <getopt.h>
69
70 #include <sys/types.h>
71@@ -59,6 +58,7 @@
72 #endif
73
74 #include "weston-launch.h"
75+#include "weston-error.h"
76
77 #define DRM_MAJOR 226
78
diff --git a/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch b/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch
index 70f9fbd2..62b864c1 100644
--- a/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch
+++ b/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch
@@ -1,4 +1,4 @@
1From 124cdabedd4aa0836480942537f6eea67347e80e Mon Sep 17 00:00:00 2001 1From 5f2d71998eb77068cbaee2d468cbb296a42d5739 Mon Sep 17 00:00:00 2001
2From: Tom Hochstein <tom.hochstein@nxp.com> 2From: Tom Hochstein <tom.hochstein@nxp.com>
3Date: Wed, 22 Feb 2017 15:53:30 +0200 3Date: Wed, 22 Feb 2017 15:53:30 +0200
4Subject: [PATCH] weston-launch: Provide a default version that doesn't require 4Subject: [PATCH] weston-launch: Provide a default version that doesn't require
@@ -15,46 +15,49 @@ Upstream-Status: Pending
15Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com> 15Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
16Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com> 16Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
17Signed-off-by: Denys Dmytriyenko <denys@ti.com> 17Signed-off-by: Denys Dmytriyenko <denys@ti.com>
18Signed-off-by: Ming Liu <ming.liu@toradex.com>
18 19
19--- 20---
20 configure.ac | 9 +++++++-- 21 libweston/meson.build | 16 ++++++++++++----
21 libweston/weston-launch.c | 20 ++++++++++++++++++++ 22 libweston/weston-launch.c | 21 +++++++++++++++++++++
22 2 files changed, 27 insertions(+), 2 deletions(-) 23 meson_options.txt | 7 +++++++
24 3 files changed, 40 insertions(+), 4 deletions(-)
23 25
24diff --git a/configure.ac b/configure.ac 26diff --git a/libweston/meson.build b/libweston/meson.build
25index 2396cba5..1f1242bb 100644 27index 08d23ec..cb9fd3f 100644
26--- a/configure.ac 28--- a/libweston/meson.build
27+++ b/configure.ac 29+++ b/libweston/meson.build
28@@ -539,13 +539,17 @@ AC_ARG_ENABLE(resize-optimization, 30@@ -216,16 +216,24 @@ dep_vertex_clipping = declare_dependency(
29 AS_IF([test "x$enable_resize_optimization" = "xyes"], 31 )
30 [AC_DEFINE([USE_RESIZE_POOL], [1], [Use resize memory pool as a performance optimization])]) 32
31 33 if get_option('weston-launch')
32+AC_ARG_WITH(pam, 34- dep_pam = cc.find_library('pam')
33+ AS_HELP_STRING([--with-pam], [Use PAM]), 35+ deps_weston_launch = [systemd_dep, dep_libdrm]
34+ [use_pam=$withval], [use_pam=yes]) 36
35 AC_ARG_ENABLE(weston-launch, [ --enable-weston-launch],, enable_weston_launch=yes) 37- if not cc.has_function('pam_open_session', dependencies: dep_pam)
36 AM_CONDITIONAL(BUILD_WESTON_LAUNCH, test x$enable_weston_launch = xyes) 38- error('pam_open_session not found for weston-launch')
37-if test x$enable_weston_launch = xyes; then 39+ if get_option('pam')
38+if test x$enable_weston_launch = xyes -a x$use_pam = xyes; then 40+ dep_pam = cc.find_library('pam')
39 WESTON_SEARCH_LIBS([PAM], [pam], [pam_open_session], [have_pam=yes], [have_pam=no]) 41+ if not cc.has_function('pam_open_session', dependencies: dep_pam)
40 if test x$have_pam = xno; then 42+ error('pam_open_session not found for weston-launch')
41- AC_ERROR([weston-launch requires pam]) 43+ endif
42+ AC_ERROR([PAM support is explicitly requested, but libpam couldn't be found]) 44+
43 fi 45+ if dep_pam.found()
44+ AC_DEFINE([HAVE_PAM], [1], [Define if PAM is available]) 46+ deps_weston_launch += dep_pam
45 fi 47+ config_h.set('HAVE_PAM', '1')
46 48+ endif
47 AM_CONDITIONAL(HAVE_PANGO, test "x$have_pango" = "xyes") 49 endif
48@@ -794,6 +798,7 @@ AC_MSG_RESULT([ 50
49 Enable developer documentation ${enable_devdocs} 51 executable(
50 52 'weston-launch',
51 weston-launch utility ${enable_weston_launch} 53 'weston-launch.c',
52+ PAM support ${use_pam} 54- dependencies: [dep_pam, systemd_dep, dep_libdrm],
53 systemd-login support ${have_systemd_login} 55+ dependencies: deps_weston_launch,
54 systemd notify support ${enable_systemd_notify} 56 include_directories: common_inc,
55 57 install: true
58 )
56diff --git a/libweston/weston-launch.c b/libweston/weston-launch.c 59diff --git a/libweston/weston-launch.c b/libweston/weston-launch.c
57index bd0015e6..706b80fd 100644 60index 8a711b4..54c567a 100644
58--- a/libweston/weston-launch.c 61--- a/libweston/weston-launch.c
59+++ b/libweston/weston-launch.c 62+++ b/libweston/weston-launch.c
60@@ -51,7 +51,9 @@ 63@@ -51,7 +51,9 @@
@@ -67,7 +70,7 @@ index bd0015e6..706b80fd 100644
67 70
68 #ifdef HAVE_SYSTEMD_LOGIN 71 #ifdef HAVE_SYSTEMD_LOGIN
69 #include <systemd/sd-login.h> 72 #include <systemd/sd-login.h>
70@@ -101,8 +103,10 @@ drmSetMaster(int drm_fd) 73@@ -100,8 +102,10 @@ drmSetMaster(int drm_fd)
71 #endif 74 #endif
72 75
73 struct weston_launch { 76 struct weston_launch {
@@ -78,7 +81,7 @@ index bd0015e6..706b80fd 100644
78 int tty; 81 int tty;
79 int ttynr; 82 int ttynr;
80 int sock[2]; 83 int sock[2];
81@@ -193,6 +197,7 @@ weston_launch_allowed(struct weston_launch *wl) 84@@ -192,6 +196,7 @@ weston_launch_allowed(struct weston_launch *wl)
82 return false; 85 return false;
83 } 86 }
84 87
@@ -86,7 +89,7 @@ index bd0015e6..706b80fd 100644
86 static int 89 static int
87 pam_conversation_fn(int msg_count, 90 pam_conversation_fn(int msg_count,
88 const struct pam_message **messages, 91 const struct pam_message **messages,
89@@ -233,6 +238,7 @@ setup_pam(struct weston_launch *wl) 92@@ -232,6 +237,7 @@ setup_pam(struct weston_launch *wl)
90 93
91 return 0; 94 return 0;
92 } 95 }
@@ -94,7 +97,7 @@ index bd0015e6..706b80fd 100644
94 97
95 static int 98 static int
96 setup_launcher_socket(struct weston_launch *wl) 99 setup_launcher_socket(struct weston_launch *wl)
97@@ -426,6 +432,7 @@ quit(struct weston_launch *wl, int status) 100@@ -431,6 +437,7 @@ quit(struct weston_launch *wl, int status)
98 close(wl->signalfd); 101 close(wl->signalfd);
99 close(wl->sock[0]); 102 close(wl->sock[0]);
100 103
@@ -102,7 +105,7 @@ index bd0015e6..706b80fd 100644
102 if (wl->new_user) { 105 if (wl->new_user) {
103 err = pam_close_session(wl->ph, 0); 106 err = pam_close_session(wl->ph, 0);
104 if (err) 107 if (err)
105@@ -433,6 +440,7 @@ quit(struct weston_launch *wl, int status) 108@@ -438,6 +445,7 @@ quit(struct weston_launch *wl, int status)
106 err, pam_strerror(wl->ph, err)); 109 err, pam_strerror(wl->ph, err));
107 pam_end(wl->ph, err); 110 pam_end(wl->ph, err);
108 } 111 }
@@ -110,7 +113,7 @@ index bd0015e6..706b80fd 100644
110 113
111 if (ioctl(wl->tty, KDSKBMUTE, 0) && 114 if (ioctl(wl->tty, KDSKBMUTE, 0) &&
112 ioctl(wl->tty, KDSKBMODE, wl->kb_mode)) 115 ioctl(wl->tty, KDSKBMODE, wl->kb_mode))
113@@ -614,6 +622,7 @@ setup_session(struct weston_launch *wl, char **child_argv) 116@@ -666,6 +674,7 @@ setup_session(struct weston_launch *wl, char **child_argv)
114 setenv("HOME", wl->pw->pw_dir, 1); 117 setenv("HOME", wl->pw->pw_dir, 1);
115 setenv("SHELL", wl->pw->pw_shell, 1); 118 setenv("SHELL", wl->pw->pw_shell, 1);
116 119
@@ -118,7 +121,7 @@ index bd0015e6..706b80fd 100644
118 env = pam_getenvlist(wl->ph); 121 env = pam_getenvlist(wl->ph);
119 if (env) { 122 if (env) {
120 for (i = 0; env[i]; ++i) { 123 for (i = 0; env[i]; ++i) {
121@@ -622,6 +631,7 @@ setup_session(struct weston_launch *wl, char **child_argv) 124@@ -674,6 +683,7 @@ setup_session(struct weston_launch *wl, char **child_argv)
122 } 125 }
123 free(env); 126 free(env);
124 } 127 }
@@ -126,7 +129,7 @@ index bd0015e6..706b80fd 100644
126 129
127 /* 130 /*
128 * We open a new session, so it makes sense 131 * We open a new session, so it makes sense
129@@ -689,8 +699,10 @@ static void 132@@ -745,8 +755,10 @@ static void
130 help(const char *name) 133 help(const char *name)
131 { 134 {
132 fprintf(stderr, "Usage: %s [args...] [-- [weston args..]]\n", name); 135 fprintf(stderr, "Usage: %s [args...] [-- [weston args..]]\n", name);
@@ -137,7 +140,7 @@ index bd0015e6..706b80fd 100644
137 fprintf(stderr, " -t, --tty Start session on alternative tty,\n" 140 fprintf(stderr, " -t, --tty Start session on alternative tty,\n"
138 " e.g. -t /dev/tty4, requires -u option.\n"); 141 " e.g. -t /dev/tty4, requires -u option.\n");
139 fprintf(stderr, " -v, --verbose Be verbose\n"); 142 fprintf(stderr, " -v, --verbose Be verbose\n");
140@@ -704,7 +716,9 @@ main(int argc, char *argv[]) 143@@ -760,7 +772,9 @@ main(int argc, char *argv[])
141 int i, c; 144 int i, c;
142 char *tty = NULL; 145 char *tty = NULL;
143 struct option opts[] = { 146 struct option opts[] = {
@@ -147,21 +150,24 @@ index bd0015e6..706b80fd 100644
147 { "tty", required_argument, NULL, 't' }, 150 { "tty", required_argument, NULL, 't' },
148 { "verbose", no_argument, NULL, 'v' }, 151 { "verbose", no_argument, NULL, 'v' },
149 { "help", no_argument, NULL, 'h' }, 152 { "help", no_argument, NULL, 'h' },
150@@ -716,9 +730,13 @@ main(int argc, char *argv[]) 153@@ -772,11 +786,16 @@ main(int argc, char *argv[])
151 while ((c = getopt_long(argc, argv, "u:t:vh", opts, &i)) != -1) { 154 while ((c = getopt_long(argc, argv, "u:t:vh", opts, &i)) != -1) {
152 switch (c) { 155 switch (c) {
153 case 'u': 156 case 'u':
154+#ifdef HAVE_PAM 157+#ifdef HAVE_PAM
155 wl.new_user = optarg; 158 wl.new_user = optarg;
156 if (getuid() != 0) 159 if (getuid() != 0) {
157 error(1, 0, "Permission denied. -u allowed for root only"); 160 fprintf(stderr, "weston: Permission denied. -u allowed for root only\n");
161 exit(EXIT_FAILURE);
162 }
158+#else 163+#else
159+ error(1, 0, "-u is unsupported in this weston-launch build"); 164+ fprintf(stderr, "weston: -u is unsupported in this weston-launch build\n");
165+ exit(EXIT_FAILURE);
160+#endif 166+#endif
161 break; 167 break;
162 case 't': 168 case 't':
163 tty = optarg; 169 tty = optarg;
164@@ -759,8 +777,10 @@ main(int argc, char *argv[]) 170@@ -828,8 +847,10 @@ main(int argc, char *argv[])
165 if (setup_tty(&wl, tty) < 0) 171 if (setup_tty(&wl, tty) < 0)
166 exit(EXIT_FAILURE); 172 exit(EXIT_FAILURE);
167 173
@@ -172,3 +178,21 @@ index bd0015e6..706b80fd 100644
172 178
173 if (setup_launcher_socket(&wl) < 0) 179 if (setup_launcher_socket(&wl) < 0)
174 exit(EXIT_FAILURE); 180 exit(EXIT_FAILURE);
181diff --git a/meson_options.txt b/meson_options.txt
182index c862ecc..73ef2c3 100644
183--- a/meson_options.txt
184+++ b/meson_options.txt
185@@ -73,6 +73,13 @@ option(
186 )
187
188 option(
189+ 'pam',
190+ type: 'boolean',
191+ value: true,
192+ description: 'Define if PAM is available'
193+)
194+
195+option(
196 'xwayland',
197 type: 'boolean',
198 value: true,
diff --git a/recipes-graphics/wayland/weston/0003-weston-touch-calibrator-Advertise-the-touchscreen-ca.patch b/recipes-graphics/wayland/weston/0003-weston-touch-calibrator-Advertise-the-touchscreen-ca.patch
deleted file mode 100644
index 46c6ec17..00000000
--- a/recipes-graphics/wayland/weston/0003-weston-touch-calibrator-Advertise-the-touchscreen-ca.patch
+++ /dev/null
@@ -1,30 +0,0 @@
1From 1e848706739d3155e7cec07bf5af6ff4c3ff810c Mon Sep 17 00:00:00 2001
2From: Jun Zhu <junzhu@nxp.com>
3Date: Sun, 30 Sep 2018 15:31:26 +0800
4Subject: [PATCH] weston-touch-calibrator: Advertise the touchscreen calibrator
5 interface to all clients. [YOCIMX-2963]
6
7Set touchscreen_calibrator to true in the section "libinput" of the configure file
8 /etc/xdg/weston/weston.ini.
9Otherwise, it will report that the new-added interface "weston-touch-calibration" cannot be found.
10
11Signed-off-by: Jun Zhu <junzhu@nxp.com>
12
13---
14 weston.ini.in | 3 +++
15 1 file changed, 3 insertions(+)
16
17diff --git a/weston.ini.in b/weston.ini.in
18index aa8666e1..9e8bde4d 100644
19--- a/weston.ini.in
20+++ b/weston.ini.in
21@@ -8,6 +8,9 @@ idle-time=0
22 #[shell]
23 #size=1920x1080
24
25+[libinput]
26+touchscreen_calibrator=true
27+
28 #[output]
29 #name=HDMI-A-1
30 #mode=1920x1080@60
diff --git a/recipes-graphics/wayland/weston_6.0.1.imx.bb b/recipes-graphics/wayland/weston_8.0.0.imx.bb
index a8d11196..c56bef61 100644
--- a/recipes-graphics/wayland/weston_6.0.1.imx.bb
+++ b/recipes-graphics/wayland/weston_8.0.0.imx.bb
@@ -7,21 +7,19 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=d79ee9e66bb0f95d3386a7acae780b70 \
7 7
8DEFAULT_PREFERENCE = "-1" 8DEFAULT_PREFERENCE = "-1"
9 9
10SRCBRANCH = "weston-imx-6.0.1" 10SRCBRANCH = "weston-imx-8.0"
11SRC_URI = "git://source.codeaurora.org/external/imx/weston-imx.git;protocol=https;branch=${SRCBRANCH} \ 11SRC_URI = "git://source.codeaurora.org/external/imx/weston-imx.git;protocol=https;branch=${SRCBRANCH} \
12 file://weston.png \ 12 file://weston.png \
13 file://weston.desktop \ 13 file://weston.desktop \
14 file://0001-make-error-portable.patch \
15 file://xwayland.weston-start \ 14 file://xwayland.weston-start \
16 file://0001-weston-launch-Provide-a-default-version-that-doesn-t.patch \ 15 file://0001-weston-launch-Provide-a-default-version-that-doesn-t.patch \
17 file://0003-weston-touch-calibrator-Advertise-the-touchscreen-ca.patch \
18" 16"
19SRCREV = "4ee0a1da010053b35495e82ad30aa5a8b1c34e6c" 17SRCREV = "f6a7d35650121fbe7c20d4cbe0eaac730fab3b2a"
20S = "${WORKDIR}/git" 18S = "${WORKDIR}/git"
21 19
22UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html" 20UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html"
23 21
24inherit autotools pkgconfig useradd features_check 22inherit meson pkgconfig useradd features_check
25 23
26# Disable OpenGL for parts with GPU support for 2D but not 3D 24# Disable OpenGL for parts with GPU support for 2D but not 3D
27REQUIRED_DISTRO_FEATURES = "opengl" 25REQUIRED_DISTRO_FEATURES = "opengl"
@@ -36,68 +34,59 @@ DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native"
36 34
37WESTON_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:1])}" 35WESTON_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:1])}"
38 36
39EXTRA_OECONF = "--enable-setuid-install \ 37EXTRA_OEMESON += "-Dbackend-default=auto -Dbackend-rdp=false -Dpipewire=false"
40 --disable-rdp-compositor \ 38
41 --enable-autotools \ 39PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms fbdev wayland egl clients', '', d)} \
42 "
43EXTRA_OECONF_append_qemux86 = " \
44 WESTON_NATIVE_BACKEND=fbdev-backend.so \
45 "
46EXTRA_OECONF_append_qemux86-64 = " \
47 WESTON_NATIVE_BACKEND=fbdev-backend.so \
48 "
49EXTRA_OECONF_append_imxfbdev = " \
50 WESTON_NATIVE_BACKEND=fbdev-backend.so \
51 "
52PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms fbdev wayland egl', '', d)} \
53 ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \ 40 ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \
54 ${@bb.utils.filter('DISTRO_FEATURES', '${PACKAGECONFIG_OPENGL} pam systemd x11', d)} \ 41 ${@bb.utils.filter('DISTRO_FEATURES', '${PACKAGECONFIG_OPENGL} pam systemd x11', d)} \
55 clients launch" 42 ${@bb.utils.contains_any('DISTRO_FEATURES', 'wayland x11', '', 'headless', d)} \
43 launch"
44
56PACKAGECONFIG_remove_imxfbdev = "kms" 45PACKAGECONFIG_remove_imxfbdev = "kms"
46PACKAGECONFIG_append_imxfbdev = " fbdev"
57PACKAGECONFIG_append_imxgpu = " imxgpu" 47PACKAGECONFIG_append_imxgpu = " imxgpu"
58PACKAGECONFIG_append_imxgpu2d = " imxg2d" 48PACKAGECONFIG_append_imxgpu2d = " imxg2d"
59PACKAGECONFIG_append_imxgpu3d = " cairo-glesv2"
60# 49#
61# Compositor choices 50# Compositor choices
62# 51#
63# Weston on KMS 52# Weston on KMS
64PACKAGECONFIG[kms] = "--enable-drm-compositor,--disable-drm-compositor,drm udev virtual/mesa mtdev" 53PACKAGECONFIG[kms] = "-Dbackend-drm=true,-Dbackend-drm=false,drm udev virtual/egl virtual/libgles2 virtual/libgbm mtdev"
65# Weston on Wayland (nested Weston) 54# Weston on Wayland (nested Weston)
66PACKAGECONFIG[wayland] = "--enable-wayland-compositor,--disable-wayland-compositor,virtual/mesa" 55PACKAGECONFIG[wayland] = "-Dbackend-wayland=true,-Dbackend-wayland=false,virtual/egl virtual/libgles2"
67# Weston on X11 56# Weston on X11
68PACKAGECONFIG[x11] = "--enable-x11-compositor,--disable-x11-compositor,virtual/libx11 libxcb libxcb libxcursor cairo" 57PACKAGECONFIG[x11] = "-Dbackend-x11=true,-Dbackend-x11=false,virtual/libx11 libxcb libxcb libxcursor cairo"
69# Headless Weston 58# Headless Weston
70PACKAGECONFIG[headless] = "--enable-headless-compositor,--disable-headless-compositor" 59PACKAGECONFIG[headless] = "-Dbackend-headless=true,-Dbackend-headless=false"
71# Weston on framebuffer 60# Weston on framebuffer
72PACKAGECONFIG[fbdev] = "--enable-fbdev-compositor,--disable-fbdev-compositor,udev mtdev" 61PACKAGECONFIG[fbdev] = "-Dbackend-fbdev=true,-Dbackend-fbdev=false,udev mtdev"
73# weston-launch 62# weston-launch
74PACKAGECONFIG[launch] = "--enable-weston-launch,--disable-weston-launch,drm" 63PACKAGECONFIG[launch] = "-Dweston-launch=true,-Dweston-launch=false,drm"
75# VA-API desktop recorder 64# VA-API desktop recorder
76PACKAGECONFIG[vaapi] = "--enable-vaapi-recorder,--disable-vaapi-recorder,libva" 65PACKAGECONFIG[vaapi] = "-Dbackend-drm-screencast-vaapi=true,-Dbackend-drm-screencast-vaapi=false,libva"
77# Weston with EGL support 66# Weston with EGL support
78PACKAGECONFIG[egl] = "--enable-egl --enable-simple-egl-clients,--disable-egl --disable-simple-egl-clients,virtual/egl" 67PACKAGECONFIG[egl] = "-Drenderer-gl=true,-Drenderer-gl=false,virtual/egl"
79# Weston with cairo glesv2 support
80PACKAGECONFIG[cairo-glesv2] = "--with-cairo-glesv2,--with-cairo=image,cairo"
81# Weston with lcms support 68# Weston with lcms support
82PACKAGECONFIG[lcms] = "--enable-lcms,--disable-lcms,lcms" 69PACKAGECONFIG[lcms] = "-Dcolor-management-lcms=true,-Dcolor-management-lcms=false,lcms"
83# Weston with webp support 70# Weston with webp support
84PACKAGECONFIG[webp] = "--with-webp,--without-webp,libwebp" 71PACKAGECONFIG[webp] = "-Dimage-webp=true,-Dimage-webp=false,libwebp"
85# Weston with systemd-login support 72# Weston with systemd-login support
86PACKAGECONFIG[systemd] = "--enable-systemd-login,--disable-systemd-login,systemd dbus" 73PACKAGECONFIG[systemd] = "-Dsystemd=true -Dlauncher-logind=true,-Dsystemd=false -Dlauncher-logind=false,systemd dbus"
87# Weston with Xwayland support (requires X11 and Wayland) 74# Weston with Xwayland support (requires X11 and Wayland)
88PACKAGECONFIG[xwayland] = "--enable-xwayland,--disable-xwayland" 75PACKAGECONFIG[xwayland] = "-Dxwayland=true,-Dxwayland=false"
89# colord CMS support 76# colord CMS support
90PACKAGECONFIG[colord] = "--enable-colord,--disable-colord,colord" 77PACKAGECONFIG[colord] = "-Dcolor-management-colord=true,-Dcolor-management-colord=false,colord"
91# Clients support 78# Clients support
92PACKAGECONFIG[clients] = "--enable-clients --enable-simple-clients --enable-demo-clients-install,--disable-clients --disable-simple-clients" 79PACKAGECONFIG[clients] = "-Dsimple-clients=all -Ddemo-clients=true,-Dsimple-clients= -Ddemo-clients=false"
80# Virtual remote output with GStreamer on DRM backend
81PACKAGECONFIG[remoting] = "-Dremoting=true,-Dremoting=false,gstreamer-1.0"
93# Weston with PAM support 82# Weston with PAM support
94PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam" 83PACKAGECONFIG[pam] = "-Dpam=true,-Dpam=false,libpam"
95# Weston with i.MX GPU support 84# Weston with i.MX GPU support
96PACKAGECONFIG[imxgpu] = "--enable-imxgpu,--disable-imxgpu" 85PACKAGECONFIG[imxgpu] = "-Dimxgpu=true,-Dimxgpu=false,virtual/egl"
97# Weston with i.MX G2D renderer 86# Weston with i.MX G2D renderer
98PACKAGECONFIG[imxg2d] = "--enable-imxg2d,--disable-imxg2d,virtual/libg2d" 87PACKAGECONFIG[imxg2d] = "-Drenderer-g2d=true,-Drenderer-g2d=false,virtual/libg2d"
99# Weston with OpenGL support 88# Weston with OpenGL support
100PACKAGECONFIG[opengl] = "--enable-opengl,--disable-opengl" 89PACKAGECONFIG[opengl] = "-Dopengl=true,--Dopengl=false"
101 90
102do_install_append() { 91do_install_append() {
103 # Weston doesn't need the .la files to load modules, so wipe them 92 # Weston doesn't need the .la files to load modules, so wipe them
@@ -115,12 +104,17 @@ do_install_append() {
115 if [ "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'yes', 'no', d)}" = "yes" ]; then 104 if [ "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'yes', 'no', d)}" = "yes" ]; then
116 install -Dm 644 ${WORKDIR}/xwayland.weston-start ${D}${datadir}/weston-start/xwayland 105 install -Dm 644 ${WORKDIR}/xwayland.weston-start ${D}${datadir}/weston-start/xwayland
117 fi 106 fi
107
108 if [ "${@bb.utils.contains('PACKAGECONFIG', 'launch', 'yes', 'no', d)}" = "yes" ]; then
109 chmod u+s ${D}${bindir}/weston-launch
110 fi
118} 111}
119 112
120PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', '${PN}-xwayland', '', d)} \ 113PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', '${PN}-xwayland', '', d)} \
121 libweston-${WESTON_MAJOR_VERSION} ${PN}-examples" 114 libweston-${WESTON_MAJOR_VERSION} ${PN}-examples"
122 115
123FILES_${PN} = "${bindir}/weston ${bindir}/weston-terminal ${bindir}/weston-info ${bindir}/weston-launch ${bindir}/wcap-decode ${libexecdir} ${libdir}/${BPN}/*.so ${datadir} ${sysconfdir}/xdg/weston" 116FILES_${PN}-dev += "${libdir}/${BPN}/libexec_weston.so"
117FILES_${PN} = "${bindir}/weston ${bindir}/weston-terminal ${bindir}/weston-info ${bindir}/weston-launch ${bindir}/wcap-decode ${libexecdir} ${libdir}/${BPN}/*.so* ${datadir} ${sysconfdir}/xdg/weston"
124 118
125FILES_libweston-${WESTON_MAJOR_VERSION} = "${libdir}/lib*${SOLIBS} ${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.so" 119FILES_libweston-${WESTON_MAJOR_VERSION} = "${libdir}/lib*${SOLIBS} ${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.so"
126SUMMARY_libweston-${WESTON_MAJOR_VERSION} = "Helper library for implementing 'wayland window managers'." 120SUMMARY_libweston-${WESTON_MAJOR_VERSION} = "Helper library for implementing 'wayland window managers'."
@@ -131,7 +125,7 @@ FILES_${PN}-xwayland = "${libdir}/libweston-${WESTON_MAJOR_VERSION}/xwayland.so"
131RDEPENDS_${PN}-xwayland += "xserver-xorg-xwayland" 125RDEPENDS_${PN}-xwayland += "xserver-xorg-xwayland"
132 126
133RDEPENDS_${PN} += "xkeyboard-config" 127RDEPENDS_${PN} += "xkeyboard-config"
134RRECOMMENDS_${PN} = "liberation-fonts" 128RRECOMMENDS_${PN} = "weston-init liberation-fonts"
135RRECOMMENDS_${PN}-dev += "wayland-protocols" 129RRECOMMENDS_${PN}-dev += "wayland-protocols"
136 130
137USERADD_PACKAGES = "${PN}" 131USERADD_PACKAGES = "${PN}"