On 10/6/22 5:04 AM, Paul Barker wrote:
On 05/10/2022 17:23, Andrew Davis wrote:
On 10/5/22 7:47 AM, Paul Barker wrote:
On 28/09/2022 15:21, Paul Barker wrote:
Hi Andrew,
On 27/09/2022 18:53, Andrew Davis wrote:
On 9/27/22 12:01 PM, Paul Barker wrote:
Hi folks,
I'm trying to add support for the Yocto Project kirkstone release to our
meta-sancloud BSP layer and I'm facing a build issue. I've reproduced the
issue using just the meta-ti layer and its dependencies, targeting the
beaglebone machine. I've used the kirkstone-next branch of meta-ti as
the kirkstone branch has not been updated in 5 months and has the same
issue.
The build fails due to a lack of buildable providers for virtual/libgl.
Is this a known issue?
I've run into this before, Cairo package pulls in desktop OpenGL when
GLES2 would be more appropriate. I'll look for the exact fix but
you can try putting this in your distro .conf file:
PACKAGECONFIG_remove_pn-cairo = "opengl"
PACKAGECONFIG_append_pn-cairo = " egl"
PACKAGECONFIG_append_pn-cairo = " glesv2"
If these settings are required they should be applied by default (perhaps via a
MACHINE_FEATURE). I would expect the beaglebone machine to build
"out-of-the-box" with the poky distro. If that really isn't possible then
necessary settings should be documented in the readme file for the layer, added
to a local.conf.sample file or applied via a setup script.
Thanks
Looking at this again today, I attempted to try the above PACKAGECONFIG changes
however they do not match the correct override syntax for kirkstone. That
suggests to me that they haven't been tested.
They have not been tested on Kirkstone. These are the changes I needed for
Dunfell, I'd guess fixing the override syntax and trying the same on
Kirkstone will help your issue, but no guarantees.
Please also note that this is not specificly an issue with the cairo
configuration, attempting to build core-image-x11 & core-image-weston also fail.
For example, for core-image-x11 the errors are as follows, re-tested today with
the current HEAD of the kirkstone branch (2b11afa8aa19):
ERROR: Nothing PROVIDES 'virtual/libgl' (but
/workdir/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.4.bb,
/workdir/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.9.bb,
/workdir/poky/meta/recipes-graphics/cairo/cairo_1.16.0.bb DEPENDS on or
otherwise requires it)
mesa-gl PROVIDES virtual/libgl but was skipped:
PREFERRED_PROVIDER_virtual/libgl set to mesa, not mesa-gl
mesa PROVIDES virtual/libgl but was skipped:
PREFERRED_PROVIDER_virtual/libgles1 set to ti-sgx-ddk-um, not mesa
NOTE: Runtime target 'xserver-xorg' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['xserver-xorg', 'virtual/libgl']
NOTE: Runtime target 'packagegroup-core-x11-xserver' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['packagegroup-core-x11-xserver',
'xserver-xorg', 'virtual/libgl']
NOTE: Runtime target 'packagegroup-core-x11-base' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['packagegroup-core-x11-base',
'packagegroup-core-x11-xserver', 'xserver-xorg', 'virtual/libgl']
ERROR: Required build target 'core-image-x11' has no buildable providers.
Missing or unbuildable dependency chain was: ['core-image-x11',
'packagegroup-core-x11-base', 'packagegroup-core-x11-xserver', 'xserver-xorg',
'virtual/libgl']
Is the kirkstone branch currently tested or expected to work? If there are known
limitations or additional configuration changes neccessary in local.conf, could
they be documented in the readme?
Kirkstone is still WIP, the base builds and boots, but there are some
spots still being readied yet (especially around graphics).
I appreciate this is still WIP. However, Kirkstone was released several months
ago now and some of the projects we're involved in (e.g. Automotive Grade Linux)
have already upgraded to this release. As we use TI SoCs, our BSP depends on
meta-ti and the lack of Kirkstone support is holding back our participation in
these projects and preventing us from offering an up-to-date BSP release to our
customers.
Xorg by default assumes desktop OpenGL support, being an embedded device
we only support OpenGLES. Xorg does work just fine with OpenGLES but
you have to tell it what to use with distro level PACKAGECONFIG selecting
(same for cairo).
In the future I'd like to split the "opengl" DISTRO_FEATURE into two
(one for OpenGL and one for GLES2) and move them into MACHINE_FEATURE
where they belong. Then we can set these down in the BSP layer.
Until then you'll have to do the manual selecting.
I have tried building with `DISTRO_FEATURES:remove = "opengl"` and this allows
non-graphical images like core-image-base to build successfully. However, x11
and wayland images still fail:
You won't want to completely remove opengl, we do support it (ES version) and
that is needed in several spots. I'm attaching a patch for meta-ti that should
get both core-image-x11 and core-image-weston building for Kirkstone.
Let me know if you have any issues.
Andrew
core-image-x11:
gtk+3_3.24.34.bb:do_compile fails. The full log.do_compile is 327kB so I
won't include it all here, but there are several errors of the following
form:
In file included from
../../../gtk+-3.24.34/gdk/wayland/gdkscreen-wayland.c:28:
../../../gtk+-3.24.34/gdk/wayland/gdkdisplay-wayland.h:48:10: fatal error:
epoxy/egl.h: No such file or directory
48 | #include <epoxy/egl.h>
| ^~~~~~~~~~~~~
compilation terminated.
core-image-weston:
ERROR: Nothing RPROVIDES 'weston-xwayland' (but
/workdir/poky/meta/recipes-graphics/images/core-image-weston.bb RDEPENDS on or
otherwise requires it)
weston RPROVIDES weston-xwayland but was skipped: missing required distro
feature 'opengl' (not in DISTRO_FEATURES)
NOTE: Runtime target 'weston-xwayland' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['weston-xwayland']
ERROR: Required build target 'core-image-weston' has no buildable
providers.
Missing or unbuildable dependency chain was: ['core-image-weston',
'weston-xwayland']
Thanks,
From c81fbae2cf7787ed01ee00b378e95be9d653d7df Mon Sep 17 00:00:00 2001
From: Andrew Davis <[email protected]>
Date: Thu, 13 Oct 2022 09:59:46 -0500
Subject: [PATCH] Add core-image-weston and core-image-x11 support
This is more changes than I would normally like in a single commit
but these all do seem so logically connected. The goal being to
enable the two oe-core graphical images.
These changes are needed due to our MACHINES all only having GLES2
and not the desktop OpenGL versions. That would mean these belong
in the layer that adds the machines and not in a distro layer.
At some point we should add a new MACHINE_FEATURE that lets a BSP
layer specify the API supported by the hardware. Until then
we append these key recipes to switch them over to GLES2.
Signed-off-by: Andrew Davis <[email protected]>
---
.../recipes-graphics/cairo/cairo_%.bbappend | 3 ++
...abling-patch-to-not-exclude-libepoxy.patch | 46 +++++++++++++++++++
.../recipes-graphics/gtk+/gtk+3_%.bbappend | 9 ++++
.../libepoxy/libepoxy_%.bbappend | 3 ++
.../xorg-xserver/xserver-xorg_%.bbappend | 2 +
.../xwayland/xwayland_%.bbappend | 3 ++
6 files changed, 66 insertions(+)
create mode 100644 meta-ti-bsp/recipes-graphics/cairo/cairo_%.bbappend
create mode 100644 meta-ti-bsp/recipes-graphics/gtk+/gtk+3/0001-Fix-OpenGL-disabling-patch-to-not-exclude-libepoxy.patch
create mode 100644 meta-ti-bsp/recipes-graphics/gtk+/gtk+3_%.bbappend
create mode 100644 meta-ti-bsp/recipes-graphics/libepoxy/libepoxy_%.bbappend
create mode 100644 meta-ti-bsp/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend
create mode 100644 meta-ti-bsp/recipes-graphics/xwayland/xwayland_%.bbappend
diff --git a/meta-ti-bsp/recipes-graphics/cairo/cairo_%.bbappend b/meta-ti-bsp/recipes-graphics/cairo/cairo_%.bbappend
new file mode 100644
index 00000000..726f3911
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/cairo/cairo_%.bbappend
@@ -0,0 +1,3 @@
+PR:append:ti-soc = ".ti1"
+PACKAGECONFIG:append:ti-soc = " ${@bb.utils.contains('MACHINE_FEATURES', 'gpu', 'egl glesv2', '', d)}"
+PACKAGECONFIG:remove:ti-soc = "opengl"
diff --git a/meta-ti-bsp/recipes-graphics/gtk+/gtk+3/0001-Fix-OpenGL-disabling-patch-to-not-exclude-libepoxy.patch b/meta-ti-bsp/recipes-graphics/gtk+/gtk+3/0001-Fix-OpenGL-disabling-patch-to-not-exclude-libepoxy.patch
new file mode 100644
index 00000000..c873fb8d
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/gtk+/gtk+3/0001-Fix-OpenGL-disabling-patch-to-not-exclude-libepoxy.patch
@@ -0,0 +1,46 @@
+From eb16e80bf1f7c51024f3ed950ae85541e5ba2233 Mon Sep 17 00:00:00 2001
+From: Andrew Davis <[email protected]>
+Date: Wed, 12 Oct 2022 13:05:45 -0500
+Subject: [PATCH] Fix OpenGL disabling patch to not exclude libepoxy
+
+Upstream-Status: Inappropriate
+Signed-off-by: Andrew Davis <[email protected]>
+---
+ configure.ac | 9 ++++-----
+ 1 file changed, 4 insertions(+), 5 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 3cb24e9..aa365be 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -348,10 +348,9 @@ AC_ARG_ENABLE(cloudproviders,
+ [cloudproviders_set=yes])
+ AC_ARG_ENABLE(opengl,
+ [AS_HELP_STRING([--enable-opengl],
+- [When enabled, Gtk+ will use libepoxy and exposes GtkGLArea widget ])])
++ [When enabled, Gtk+ exposes GtkGLArea widget ])])
+ AS_IF([test "x$enable_opengl" != "xno"], [
+- AC_DEFINE([HAVE_OPENGL], [1], [libepoxy and opengl APIs are available at buildtime])
+- EPOXY_PACKAGES="epoxy >= epoxy_required_version"
++ AC_DEFINE([HAVE_OPENGL], [1], [OpenGL APIs are available at buildtime])
+ ])
+ AM_CONDITIONAL([HAVE_OPENGL],[test "x$enable_opengl" != "xno"])
+
+@@ -1365,7 +1364,7 @@ CFLAGS="$saved_cflags"
+ LDFLAGS="$saved_ldflags"
+
+ GDK_PACKAGES="$PANGO_PACKAGES gdk-pixbuf-2.0 >= gdk_pixbuf_required_version cairo >= cairo_required_version cairo-gobject >= cairo_required_version"
+-GDK_PRIVATE_PACKAGES="$GDK_GIO_PACKAGE $X_PACKAGES $WAYLAND_PACKAGES $cairo_backends $EPOXY_PACKAGES $CLOUDPROVIDER_PACKAGES $PROFILER_PACKAGES fribidi >= fribidi_required_version"
++GDK_PRIVATE_PACKAGES="$GDK_GIO_PACKAGE $X_PACKAGES $WAYLAND_PACKAGES $cairo_backends epoxy >= epoxy_required_version $CLOUDPROVIDER_PACKAGES $PROFILER_PACKAGES fribidi >= fribidi_required_version"
+
+ PKG_CHECK_MODULES(GDK_DEP, $GDK_PACKAGES $GDK_PRIVATE_PACKAGES)
+ GDK_DEP_LIBS="$GDK_EXTRA_LIBS $GDK_DEP_LIBS $MATH_LIB"
+@@ -1399,7 +1398,7 @@ fi
+ PKG_CHECK_MODULES(ATK, $ATK_PACKAGES)
+
+ GTK_PACKAGES="atk >= atk_required_version cairo >= cairo_required_version cairo-gobject >= cairo_required_version gdk-pixbuf-2.0 >= gdk_pixbuf_required_version gio-2.0 >= glib_required_version"
+-GTK_PRIVATE_PACKAGES="$ATK_PACKAGES $WAYLAND_PACKAGES $EPOXY_PACKAGES fribidi >= fribidi_required_version"
++GTK_PRIVATE_PACKAGES="$ATK_PACKAGES $WAYLAND_PACKAGES epoxy >= epoxy_required_version fribidi >= fribidi_required_version"
+ if test "x$enable_x11_backend" = xyes -o "x$enable_wayland_backend" = xyes; then
+ GTK_PRIVATE_PACKAGES="$GTK_PRIVATE_PACKAGES pangoft2"
+ fi
diff --git a/meta-ti-bsp/recipes-graphics/gtk+/gtk+3_%.bbappend b/meta-ti-bsp/recipes-graphics/gtk+/gtk+3_%.bbappend
new file mode 100644
index 00000000..b6e82d14
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/gtk+/gtk+3_%.bbappend
@@ -0,0 +1,9 @@
+FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
+
+SRC_URI:append:ti-soc = " \
+ file://0001-Fix-OpenGL-disabling-patch-to-not-exclude-libepoxy.patch \
+"
+
+PR:append:ti-soc = ".ti1"
+PACKAGECONFIG:remove:ti-soc = "opengl"
+DEPENDS:append:ti-soc = " libepoxy"
diff --git a/meta-ti-bsp/recipes-graphics/libepoxy/libepoxy_%.bbappend b/meta-ti-bsp/recipes-graphics/libepoxy/libepoxy_%.bbappend
new file mode 100644
index 00000000..aadf5bab
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/libepoxy/libepoxy_%.bbappend
@@ -0,0 +1,3 @@
+PR:append:ti-soc = ".ti1"
+PACKAGECONFIG:append:ti-soc = " ${@bb.utils.contains('MACHINE_FEATURES', 'gpu', 'egl', '', d)}"
+PACKAGECONFIG:remove:ti-soc = "x11"
diff --git a/meta-ti-bsp/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend b/meta-ti-bsp/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend
new file mode 100644
index 00000000..86c1e714
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend
@@ -0,0 +1,2 @@
+PR:append:ti-soc = ".ti1"
+OPENGL_PKGCONFIGS:ti-soc = ""
diff --git a/meta-ti-bsp/recipes-graphics/xwayland/xwayland_%.bbappend b/meta-ti-bsp/recipes-graphics/xwayland/xwayland_%.bbappend
new file mode 100644
index 00000000..e7163207
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/xwayland/xwayland_%.bbappend
@@ -0,0 +1,3 @@
+PR:append:ti-soc = ".ti1"
+PACKAGECONFIG:remove:ti-soc = "glx"
+DEPENDS:append:ti-soc = " libxshmfence"
--
2.37.3
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#15179):
https://lists.yoctoproject.org/g/meta-ti/message/15179
Mute This Topic: https://lists.yoctoproject.org/mt/93954566/21656
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-ti/unsub
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-