package/libva: remove optional mesa3d support
PATCH 1/2 package/libva: remove optional mesa3d support
Kodi 18.0-Leia will support vaapi on r600 and radeonsi.
We need libva support in mesa3d for this. To avoid the circular dependency we switch from using mesa3d in libva to use libva in mesa3d.
This patch is the first step: disable mesa3d support in libva.
--- package/libva/libva.mk | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
package/libva/libva.mk +2 -5
@@ -15,17 +15,14 @@ LIBVA_DEPENDENCIES = host-pkgconf libdrm # libdrm is a hard-dependency LIBVA_CONF_OPTS = \ --enable-drm \ + --disable-glx \ --with-drivers-path="/usr/lib/va" ifeq ($(BR2_PACKAGE_XORG7),y) LIBVA_DEPENDENCIES += xlib_libX11 xlib_libXext xlib_libXfixes LIBVA_CONF_OPTS += --enable-x11 -ifeq ($(BR2_PACKAGE_MESA3D_DRI_DRIVER),y) -LIBVA_DEPENDENCIES += mesa3d -LIBVA_CONF_OPTS += --enable-glx -endif else -LIBVA_CONF_OPTS += --disable-glx --disable-x11 +LIBVA_CONF_OPTS += --disable-x11 endif ifeq ($(BR2_PACKAGE_WAYLAND),y)
Signature · 1 line
2.20.1
PATCH 2/2 package/mesa3d: add optional support for libva
Kodi 18.0-Leia will support vaapi on r600 and radeonsi.
We need libva support in mesa3d for this. To avoid the circular dependency we switch from using mesa3d in libva to use libva in mesa3d.
This patch is the second step: enable libva support in mesa3d.
To fix a new configure error caused by this patch
configure: error: VA requires at least one of the x11 drm or wayland platforms
with this defconfig
BR2_PACKAGE_MESA3D=y
BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_R600=y
BR2_PACKAGE_MESA3D_OPENGL_EGL=y
BR2_PACKAGE_LIBVA=y
we add drm to mesa platforms for r600.
Added upstream patch, for details see LibreELEC PR 2403 and Kodi PR 13333.
--- package/mesa3d/mesa3d.mk | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-)
package/mesa3d/mesa3d.mk +8 -4
@@ -124,6 +124,12 @@ MESA3D_CONF_OPTS += \ --enable-shared-glapi \ --with-gallium-drivers=$(subst $(space),$(comma),$(MESA3D_GALLIUM_DRIVERS-y)) \ --enable-gallium-extra-hud +ifeq ($(BR2_PACKAGE_LIBVA),y) +MESA3D_CONF_OPTS += --enable-va +MESA3D_DEPENDENCIES += libva +else +MESA3D_CONF_OPTS += --disable-va +endif endif ifeq ($(BR2_PACKAGE_MESA3D_DRI_DRIVER),)
@@ -165,10 +171,6 @@ endif # - it is needed for GLES (mesa3d's ./configure is a bit weird) MESA3D_CONF_OPTS += --enable-opengl --enable-dri -# libva and mesa3d have a circular dependency -# we do not need libva support in mesa3d, therefore disable this option -MESA3D_CONF_OPTS += --disable-va - # libGL is only provided for a full xorg stack ifeq ($(BR2_PACKAGE_XORG7),y) MESA3D_PROVIDES += libgl
@@ -190,6 +192,8 @@ else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_VIRGL),y) MESA3D_PLATFORMS = drm else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_RADEONSI),y) MESA3D_PLATFORMS = drm +else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_R600),y) +MESA3D_PLATFORMS = drm endif ifeq ($(BR2_PACKAGE_WAYLAND),y) MESA3D_DEPENDENCIES += wayland wayland-protocols
Signature · 1 line
2.20.1
PATCH 1/2 package/libva: remove optional mesa3d support
In reply to Bernd KuhlsHello Bernd,
Quoted 10 lines · On Sun, 7 Apr 2019 19:13:17 +0200 Bernd Kuhls <[email protected]> wrote:
Kodi 18.0-Leia will support vaapi on r600 and radeonsi.
We need libva support in mesa3d for this. To avoid the circular dependency we switch from using mesa3d in libva to use libva in mesa3d.This patch is the first step: disable mesa3d support in libva.
Signed-off-by Bernd Kuhls <[email protected]>--- package/libva/libva.mk | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
I understand the circular dependency issue, but what makes it reasonable to drop mesa3d support in libva ? Until now, the choice was rather the opposite: have mesa3d support in libva, and no libva support in mesa3d. Is there a fundamental reason why one is more useful than the other ?
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH 1/2 package/libva: remove optional mesa3d support
Am Wed, 10 Apr 2019 19:13:07 +0200 schrieb Thomas Petazzoni:
Quoted 4 lines
I understand the circular dependency issue, but what makes it reasonable to drop mesa3d support in libva ? Until now, the choice was rather the
opposite: have mesa3d support in libva, and no libva support in mesa3d. Is there a fundamental reason why one is more useful than the other ?
Hi Thomas,
first I like to mention that I do not have any AMD hardware in use with buildroot, I am just following the development of Libreelec:
https://github.com/xbmc/xbmc/pull/13333
https://github.com/LibreELEC/LibreELEC.tv/pull/2403
The motivation for the Kodi patch was: "Hardware decoding with AMD GPUs is only supported with this new method"
Because I think this will improve user experience with AMD hardware I sent these patches.
Regards, Bernd