* [Buildroot] [PATCH 1/1] package/glslsandbox: kms needs gbm
@ 2021-08-27 22:19 Fabrice Fontaine
2021-08-28 10:04 ` Julien Olivain
0 siblings, 1 reply; 3+ messages in thread
From: Fabrice Fontaine @ 2021-08-27 22:19 UTC (permalink / raw)
To: buildroot; +Cc: Julien Olivain, Fabrice Fontaine
Obviously, KMS/DRM/GBM needs gbm (and so mesa3d which is the only gbm
provider since commit 814bfc5ec1ab49188d1c8cb7f0d8d857b92d6a03):
checking for gbm... no
configure: error: Package requirements (gbm) were not met:
Package 'gbm', required by 'virtual:world', not found
Fixes:
- http://autobuild.buildroot.org/results/31b3fff9748300e293b4efb5615176ccce48dd15
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
package/glslsandbox-player/Config.in | 4 ++++
package/glslsandbox-player/glslsandbox-player.mk | 4 +---
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/package/glslsandbox-player/Config.in b/package/glslsandbox-player/Config.in
index dc0d2c07f1..b85dff6a2f 100644
--- a/package/glslsandbox-player/Config.in
+++ b/package/glslsandbox-player/Config.in
@@ -67,8 +67,12 @@ choice
config BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS
bool "KMS/DRM/GBM"
depends on BR2_TOOLCHAIN_HAS_THREADS # libdrm
+ depends on BR2_PACKAGE_MESA3D_GBM
select BR2_PACKAGE_LIBDRM
+comment "KMS/DRM/GBM backend needs mesa3d w/ GBM"
+ depends on !BR2_PACKAGE_MESA3D_GBM
+
config BR2_PACKAGE_GLSLSANDBOX_PLAYER_MALI
bool "Allwinner ARM/Mali Frame Buffer"
depends on BR2_PACKAGE_SUNXI_MALI_MAINLINE
diff --git a/package/glslsandbox-player/glslsandbox-player.mk b/package/glslsandbox-player/glslsandbox-player.mk
index 5ace69d7dd..4f058772df 100644
--- a/package/glslsandbox-player/glslsandbox-player.mk
+++ b/package/glslsandbox-player/glslsandbox-player.mk
@@ -37,9 +37,7 @@ GLSLSANDBOX_PLAYER_CONF_OPTS += --disable-install-scripts
endif
ifeq ($(BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS),y)
-# gbm dependency is not needed, as it is normally packaged with
-# libegl/libgles drivers.
-GLSLSANDBOX_PLAYER_DEPENDENCIES += libdrm
+GLSLSANDBOX_PLAYER_DEPENDENCIES += libdrm mesa3d
GLSLSANDBOX_PLAYER_CONF_OPTS += --with-native-gfx=kms
else ifeq ($(BR2_PACKAGE_GLSLSANDBOX_PLAYER_MALI),y)
GLSLSANDBOX_PLAYER_DEPENDENCIES += sunxi-mali-mainline
--
2.32.0
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/glslsandbox: kms needs gbm
2021-08-27 22:19 [Buildroot] [PATCH 1/1] package/glslsandbox: kms needs gbm Fabrice Fontaine
@ 2021-08-28 10:04 ` Julien Olivain
2021-08-28 10:38 ` Fabrice Fontaine
0 siblings, 1 reply; 3+ messages in thread
From: Julien Olivain @ 2021-08-28 10:04 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: buildroot
Hi Fabrice,
On 28/08/2021 00:19, Fabrice Fontaine wrote:
> Obviously, KMS/DRM/GBM needs gbm (and so mesa3d which is the only gbm
> provider since commit 814bfc5ec1ab49188d1c8cb7f0d8d857b92d6a03):
To my knowledge, imx-gpu-viv also provides a working gbm.
> checking for gbm... no
> configure: error: Package requirements (gbm) were not met:
>
> Package 'gbm', required by 'virtual:world', not found
>
> Fixes:
> -
> http://autobuild.buildroot.org/results/31b3fff9748300e293b4efb5615176ccce48dd15
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
> package/glslsandbox-player/Config.in | 4 ++++
> package/glslsandbox-player/glslsandbox-player.mk | 4 +---
> 2 files changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/package/glslsandbox-player/Config.in
> b/package/glslsandbox-player/Config.in
> index dc0d2c07f1..b85dff6a2f 100644
> --- a/package/glslsandbox-player/Config.in
> +++ b/package/glslsandbox-player/Config.in
> @@ -67,8 +67,12 @@ choice
> config BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS
> bool "KMS/DRM/GBM"
> depends on BR2_TOOLCHAIN_HAS_THREADS # libdrm
> + depends on BR2_PACKAGE_MESA3D_GBM
There was already few discussions to have a gbm virtual package, which
was not
accepted. See [1]. I believe this is the kind of thing that would help
in
that case. It is a valid case (but maybe not really common) to do
OpenGL ES
accelerated graphics, on top of KMS/GBM, without being a Wayland
compositor.
The next best candidate I see would be a dependency on
BR2_PACKAGE_HAS_LIBEGL_WAYLAND, introduced in commit
1e3dfef19d8ae3804671a03b30003fa2d8115fc6.
Since gbm is usually in those dependencies, that should fix this build
failure,
even if the dependency is not accurate (we depend on what a wayland
compositor
would need, and this package is not a compositor).
See also commit fed835768aac18f2457544ff40f3b59b387117ed
Finally, we could eventually introduce here a
BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS_SUPPORTS
which lists the dependencies known to work in that case:
I see at least: BR2_PACKAGE_MESA3D_GBM and
BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_WL
> select BR2_PACKAGE_LIBDRM
>
> +comment "KMS/DRM/GBM backend needs mesa3d w/ GBM"
> + depends on !BR2_PACKAGE_MESA3D_GBM
> +
> config BR2_PACKAGE_GLSLSANDBOX_PLAYER_MALI
> bool "Allwinner ARM/Mali Frame Buffer"
> depends on BR2_PACKAGE_SUNXI_MALI_MAINLINE
> diff --git a/package/glslsandbox-player/glslsandbox-player.mk
> b/package/glslsandbox-player/glslsandbox-player.mk
> index 5ace69d7dd..4f058772df 100644
> --- a/package/glslsandbox-player/glslsandbox-player.mk
> +++ b/package/glslsandbox-player/glslsandbox-player.mk
> @@ -37,9 +37,7 @@ GLSLSANDBOX_PLAYER_CONF_OPTS +=
> --disable-install-scripts
> endif
>
> ifeq ($(BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS),y)
> -# gbm dependency is not needed, as it is normally packaged with
> -# libegl/libgles drivers.
> -GLSLSANDBOX_PLAYER_DEPENDENCIES += libdrm
> +GLSLSANDBOX_PLAYER_DEPENDENCIES += libdrm mesa3d
Same comment: mesa3d is not the only gbm provider.
> GLSLSANDBOX_PLAYER_CONF_OPTS += --with-native-gfx=kms
> else ifeq ($(BR2_PACKAGE_GLSLSANDBOX_PLAYER_MALI),y)
> GLSLSANDBOX_PLAYER_DEPENDENCIES += sunxi-mali-mainline
What do you think?
Best regards,
Julien.
[1].
https://patchwork.ozlabs.org/project/buildroot/patch/20180913194410.24077-1-bernd.kuhls@t-online.de/
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/glslsandbox: kms needs gbm
2021-08-28 10:04 ` Julien Olivain
@ 2021-08-28 10:38 ` Fabrice Fontaine
0 siblings, 0 replies; 3+ messages in thread
From: Fabrice Fontaine @ 2021-08-28 10:38 UTC (permalink / raw)
To: Julien Olivain; +Cc: Buildroot Mailing List
Hi Julien,
Le sam. 28 août 2021 à 12:04, Julien Olivain <ju.o@free.fr> a écrit :
>
> Hi Fabrice,
>
> On 28/08/2021 00:19, Fabrice Fontaine wrote:
> > Obviously, KMS/DRM/GBM needs gbm (and so mesa3d which is the only gbm
> > provider since commit 814bfc5ec1ab49188d1c8cb7f0d8d857b92d6a03):
>
> To my knowledge, imx-gpu-viv also provides a working gbm.
>
> > checking for gbm... no
> > configure: error: Package requirements (gbm) were not met:
> >
> > Package 'gbm', required by 'virtual:world', not found
> >
> > Fixes:
> > -
> > http://autobuild.buildroot.org/results/31b3fff9748300e293b4efb5615176ccce48dd15
> >
> > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> > ---
> > package/glslsandbox-player/Config.in | 4 ++++
> > package/glslsandbox-player/glslsandbox-player.mk | 4 +---
> > 2 files changed, 5 insertions(+), 3 deletions(-)
> >
> > diff --git a/package/glslsandbox-player/Config.in
> > b/package/glslsandbox-player/Config.in
> > index dc0d2c07f1..b85dff6a2f 100644
> > --- a/package/glslsandbox-player/Config.in
> > +++ b/package/glslsandbox-player/Config.in
> > @@ -67,8 +67,12 @@ choice
> > config BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS
> > bool "KMS/DRM/GBM"
> > depends on BR2_TOOLCHAIN_HAS_THREADS # libdrm
> > + depends on BR2_PACKAGE_MESA3D_GBM
>
> There was already few discussions to have a gbm virtual package, which
> was not
> accepted. See [1]. I believe this is the kind of thing that would help
> in
> that case. It is a valid case (but maybe not really common) to do
> OpenGL ES
> accelerated graphics, on top of KMS/GBM, without being a Wayland
> compositor.
>
> The next best candidate I see would be a dependency on
> BR2_PACKAGE_HAS_LIBEGL_WAYLAND, introduced in commit
> 1e3dfef19d8ae3804671a03b30003fa2d8115fc6.
>
> Since gbm is usually in those dependencies, that should fix this build
> failure,
> even if the dependency is not accurate (we depend on what a wayland
> compositor
> would need, and this package is not a compositor).
>
> See also commit fed835768aac18f2457544ff40f3b59b387117ed
>
> Finally, we could eventually introduce here a
> BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS_SUPPORTS
> which lists the dependencies known to work in that case:
> I see at least: BR2_PACKAGE_MESA3D_GBM and
> BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_WL
>
> > select BR2_PACKAGE_LIBDRM
> >
> > +comment "KMS/DRM/GBM backend needs mesa3d w/ GBM"
> > + depends on !BR2_PACKAGE_MESA3D_GBM
> > +
> > config BR2_PACKAGE_GLSLSANDBOX_PLAYER_MALI
> > bool "Allwinner ARM/Mali Frame Buffer"
> > depends on BR2_PACKAGE_SUNXI_MALI_MAINLINE
> > diff --git a/package/glslsandbox-player/glslsandbox-player.mk
> > b/package/glslsandbox-player/glslsandbox-player.mk
> > index 5ace69d7dd..4f058772df 100644
> > --- a/package/glslsandbox-player/glslsandbox-player.mk
> > +++ b/package/glslsandbox-player/glslsandbox-player.mk
> > @@ -37,9 +37,7 @@ GLSLSANDBOX_PLAYER_CONF_OPTS +=
> > --disable-install-scripts
> > endif
> >
> > ifeq ($(BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS),y)
> > -# gbm dependency is not needed, as it is normally packaged with
> > -# libegl/libgles drivers.
> > -GLSLSANDBOX_PLAYER_DEPENDENCIES += libdrm
> > +GLSLSANDBOX_PLAYER_DEPENDENCIES += libdrm mesa3d
>
> Same comment: mesa3d is not the only gbm provider.
>
> > GLSLSANDBOX_PLAYER_CONF_OPTS += --with-native-gfx=kms
> > else ifeq ($(BR2_PACKAGE_GLSLSANDBOX_PLAYER_MALI),y)
> > GLSLSANDBOX_PLAYER_DEPENDENCIES += sunxi-mali-mainline
>
> What do you think?
I'm not an expert in gbm and Thomas told me that Bootlin have a patch
series to improve the Buildroot handling of gbm:
https://patchwork.ozlabs.org/project/buildroot/patch/20210819160317.1045482-1-fontaine.fabrice@gmail.com/
So I'll let Thomas and gbm experts handle this long term solution.
As a short term solution (i.e. for the buildroot August release), I
think that adding a
"depends on BR2_PACKAGE_MESA3D_OPENGL_EGL || BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_WL"
as it is already done in weston is probably enough (without
BR2_PACKAGE_GLSLSANDBOX_PLAYER_KMS_SUPPORTS which seems a bit
overkilled).
I'll also drop the mesa3d dependency.
>
> Best regards,
>
> Julien.
>
> [1].
> https://patchwork.ozlabs.org/project/buildroot/patch/20180913194410.24077-1-bernd.kuhls@t-online.de/
Best Regards,
Fabrice
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-08-28 10:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-27 22:19 [Buildroot] [PATCH 1/1] package/glslsandbox: kms needs gbm Fabrice Fontaine
2021-08-28 10:04 ` Julien Olivain
2021-08-28 10:38 ` Fabrice Fontaine
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.