aboutsummaryrefslogtreecommitdiff
path: root/package/mesa3d
diff options
context:
space:
mode:
Diffstat (limited to 'package/mesa3d')
-rw-r--r--package/mesa3d/0002-meson-Set-proper-value-for-LIBCLC_INCLUDEDIR.patch28
-rw-r--r--package/mesa3d/0003-vc4-add-meson-option-to-disable-optional-neon-suppor.patch8
-rw-r--r--package/mesa3d/0004-src-util-rand_xor-Include-stddef.h-to-fix-build-erro.patch40
-rw-r--r--package/mesa3d/Config.in10
-rw-r--r--package/mesa3d/mesa3d.hash8
-rw-r--r--package/mesa3d/mesa3d.mk88
6 files changed, 105 insertions, 77 deletions
diff --git a/package/mesa3d/0002-meson-Set-proper-value-for-LIBCLC_INCLUDEDIR.patch b/package/mesa3d/0002-meson-Set-proper-value-for-LIBCLC_INCLUDEDIR.patch
index 6293b8fba4..e3c70c3f24 100644
--- a/package/mesa3d/0002-meson-Set-proper-value-for-LIBCLC_INCLUDEDIR.patch
+++ b/package/mesa3d/0002-meson-Set-proper-value-for-LIBCLC_INCLUDEDIR.patch
@@ -17,23 +17,25 @@ that they are not removed by Buildroot target-finalize logic.
Based on the patch for autotools provided by Valentin Korenblit.
Signed-off-by: Romain Naour <romain.naour@smile.fr>
+Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
+[rebased for 20.2.0 & 20.3.0]
---
- src/gallium/state_trackers/clover/meson.build | 2 +-
+ src/gallium/frontends/clover/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/src/gallium/state_trackers/clover/meson.build b/src/gallium/state_trackers/clover/meson.build
+diff --git a/src/gallium/frontends/clover/meson.build b/src/gallium/frontends/clover/meson.build
index 62ac5f5278d..ecdeb39669c 100644
---- a/src/gallium/state_trackers/clover/meson.build
-+++ b/src/gallium/state_trackers/clover/meson.build
-@@ -64,7 +64,7 @@
- clover_opencl_cpp_args,
- clover_spirv_cpp_args,
- cpp_vis_args,
-- '-DLIBCLC_INCLUDEDIR="@0@/"'.format(dep_clc.get_pkgconfig_variable('includedir')),
-+ '-DLIBCLC_INCLUDEDIR="/usr/share"',
- '-DLIBCLC_LIBEXECDIR="@0@/"'.format(dep_clc.get_pkgconfig_variable('libexecdir')),
- '-DCLANG_RESOURCE_DIR="@0@"'.format(join_paths(
- dep_llvm.get_configtool_variable('libdir'), 'clang',
+--- a/src/gallium/frontends/clover/meson.build
++++ b/src/gallium/frontends/clover/meson.build
+@@ -27,7 +27,7 @@
+ '-DCL_USE_DEPRECATED_OPENCL_2_0_APIS',
+ '-DCL_USE_DEPRECATED_OPENCL_2_1_APIS',
+ '-DCL_USE_DEPRECATED_OPENCL_2_2_APIS',
+- '-DLIBCLC_INCLUDEDIR="@0@/"'.format(dep_clc.get_variable(pkgconfig : 'includedir')),
++ '-DLIBCLC_INCLUDEDIR="/usr/share"',
+ '-DLIBCLC_LIBEXECDIR="@0@/"'.format(dep_clc.get_variable(pkgconfig : 'libexecdir'))
+ ]
+ clover_spirv_cpp_args = []
--
2.20.1
diff --git a/package/mesa3d/0003-vc4-add-meson-option-to-disable-optional-neon-suppor.patch b/package/mesa3d/0003-vc4-add-meson-option-to-disable-optional-neon-suppor.patch
index 138f145af5..39e402361f 100644
--- a/package/mesa3d/0003-vc4-add-meson-option-to-disable-optional-neon-suppor.patch
+++ b/package/mesa3d/0003-vc4-add-meson-option-to-disable-optional-neon-suppor.patch
@@ -9,6 +9,8 @@ to force disabling it at compile time.
[Upstream: https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4114]
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
+Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
+[rebased for 20.2.0 & 20.3.0]
---
meson_options.txt | 7 +++++++
src/gallium/drivers/vc4/meson.build | 4 ++--
@@ -19,9 +21,9 @@ diff --git a/meson_options.txt b/meson_options.txt
index a39596a6f19..0f6b6c62b55 100644
--- a/meson_options.txt
+++ b/meson_options.txt
-@@ -117,6 +117,13 @@ option(
- choices : ['auto', 'true', 'false'],
- description : 'enable gallium va state tracker.',
+@@ -123,6 +123,13 @@ option(
+ choices : ['auto', 'true', 'false', 'enabled', 'disabled'],
+ description : 'enable gallium va frontend.',
)
+option(
+ 'gallium-vc4-neon',
diff --git a/package/mesa3d/0004-src-util-rand_xor-Include-stddef.h-to-fix-build-erro.patch b/package/mesa3d/0004-src-util-rand_xor-Include-stddef.h-to-fix-build-erro.patch
new file mode 100644
index 0000000000..538aa74e0c
--- /dev/null
+++ b/package/mesa3d/0004-src-util-rand_xor-Include-stddef.h-to-fix-build-erro.patch
@@ -0,0 +1,40 @@
+From fdc8b5a205e2116408aeb9fd305e57f656e2e89d Mon Sep 17 00:00:00 2001
+From: Bernd Kuhls <bernd.kuhls@t-online.de>
+Date: Sun, 9 Aug 2020 17:06:26 +0200
+Subject: [PATCH] src/util/rand_xor: Include stddef.h to fix build error
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Fixes
+
+In file included from ../src/util/rand_xor.c:29:
+output/host/x86_64-buildroot-linux-uclibc/sysroot/usr/include/sys/random.h:27:35:
+ error: unknown type name ‘size_t’
+ extern int getrandom(void *__buf, size_t count, unsigned int flags)
+
+seen with gcc version 8.3.0 (Buildroot 2020.02) and uClibc.
+
+Patch sent upstream:
+https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6248
+
+Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
+---
+ src/util/rand_xor.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/util/rand_xor.c b/src/util/rand_xor.c
+index 81b64f1ea71..fcb481487fa 100644
+--- a/src/util/rand_xor.c
++++ b/src/util/rand_xor.c
+@@ -25,6 +25,7 @@
+ #include "detect_os.h"
+
+ #if !DETECT_OS_WINDOWS
++#include <stddef.h>
+ #if defined(HAVE_GETRANDOM)
+ #include <sys/random.h>
+ #endif
+--
+2.27.0
+
diff --git a/package/mesa3d/Config.in b/package/mesa3d/Config.in
index a12ed641a6..a96fd46bbe 100644
--- a/package/mesa3d/Config.in
+++ b/package/mesa3d/Config.in
@@ -4,8 +4,8 @@ menuconfig BR2_PACKAGE_MESA3D
depends on !BR2_STATIC_LIBS
depends on BR2_TOOLCHAIN_HAS_SYNC_1
depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
- select BR2_PACKAGE_LIBDRM
select BR2_PACKAGE_EXPAT
+ select BR2_PACKAGE_LIBDRM
select BR2_PACKAGE_WAYLAND_PROTOCOLS if BR2_PACKAGE_WAYLAND
select BR2_PACKAGE_ZLIB
help
@@ -370,7 +370,13 @@ config BR2_PACKAGE_MESA3D_DRI_DRIVER_NOUVEAU
Support for Nvidia-based GPUs.
config BR2_PACKAGE_MESA3D_DRI_DRIVER_RADEON
- bool "DRI radeon driver"
+ bool "DRI radeon r100 driver"
+ depends on BR2_i386 || BR2_x86_64
+ # libdrm's radeon option depends on LIBDRM_HAS_ATOMIC. Propagating
+ # that dependency here causes a circular dependency that Kconfig
+ # can't see is just spurious. However, that dependency is about
+ # the toolchain having sync4 primitives, which is always a given
+ # for i386 and x86_64.
select BR2_PACKAGE_MESA3D_DRI_DRIVER
select BR2_PACKAGE_LIBDRM_RADEON
help
diff --git a/package/mesa3d/mesa3d.hash b/package/mesa3d/mesa3d.hash
index d0fb2003ee..e7b375440d 100644
--- a/package/mesa3d/mesa3d.hash
+++ b/package/mesa3d/mesa3d.hash
@@ -1,6 +1,6 @@
-# From https://lists.freedesktop.org/archives/mesa-announce/2020-September/000597.html
-sha256 4de9dd0cb2ca367606cada421db62fbf6d276dfd533e522bfab6001ff9aba288 mesa-20.1.7.tar.xz
-sha512 5ff614c3f7568db7673cd2398615e5398c7f50093abdabd0730e07fe9c358310793fea3f130058110c9a2aa284c6efd207e1bdca3d1a1ba46fb18d76e34f361a mesa-20.1.7.tar.xz
+# From https://lists.freedesktop.org/archives/mesa-announce/2021-January/000618.html
+sha256 dc21a987ec1ff45b278fe4b1419b1719f1968debbb80221480e44180849b4084 mesa-20.3.4.tar.xz
+sha512 81c4d032213b4aef842f1594e0e89bc0045f7ca7ce5f267b62a0f8236eb12ab09c1f780d8b3776b3072f37cd0bd8829f8a1330a749ccf462471b262ef8097477 mesa-20.3.4.tar.xz
# License
-sha256 1ddae7da415352a5b5360ff3a9d7ecf23ba81408f62eeecce0011f32e3ef9da6 docs/license.html
+sha256 1361129baa4519b6ed27a1bf4aeee33a58b060bf7bb9b6ea415ecede04e35e46 docs/license.rst
diff --git a/package/mesa3d/mesa3d.mk b/package/mesa3d/mesa3d.mk
index a5dac045d4..5105727e8b 100644
--- a/package/mesa3d/mesa3d.mk
+++ b/package/mesa3d/mesa3d.mk
@@ -5,11 +5,11 @@
################################################################################
# When updating the version, please also update mesa3d-headers
-MESA3D_VERSION = 20.1.7
+MESA3D_VERSION = 20.3.4
MESA3D_SOURCE = mesa-$(MESA3D_VERSION).tar.xz
MESA3D_SITE = https://mesa.freedesktop.org/archive
MESA3D_LICENSE = MIT, SGI, Khronos
-MESA3D_LICENSE_FILES = docs/license.html
+MESA3D_LICENSE_FILES = docs/license.rst
MESA3D_INSTALL_STAGING = YES
@@ -25,7 +25,7 @@ MESA3D_DEPENDENCIES = \
MESA3D_CONF_OPTS = \
-Dgallium-omx=disabled \
- -Dpower8=false
+ -Dpower8=disabled
# Codesourcery ARM 2014.05 fail to link libmesa_dri_drivers.so with --as-needed linker
# flag due to a linker bug between binutils 2.24 and 2.25 (2.24.51.20140217).
@@ -36,10 +36,10 @@ endif
ifeq ($(BR2_PACKAGE_MESA3D_LLVM),y)
MESA3D_DEPENDENCIES += host-llvm llvm
MESA3D_MESON_EXTRA_BINARIES += llvm-config='$(STAGING_DIR)/usr/bin/llvm-config'
-MESA3D_CONF_OPTS += -Dllvm=true
+MESA3D_CONF_OPTS += -Dllvm=enabled
else
# Avoid automatic search of llvm-config
-MESA3D_CONF_OPTS += -Dllvm=false
+MESA3D_CONF_OPTS += -Dllvm=disabled
endif
# Disable opencl-icd: OpenCL lib will be named libOpenCL instead of
@@ -64,14 +64,14 @@ ifeq ($(BR2_PACKAGE_MESA3D_OPENGL_GLX),y)
# gallium-xlib : Gallium-xlib based GLX requires at least one gallium driver || Gallium-xlib based GLX requires softpipe or llvmpipe || gallium-xlib conflicts with any dri driver.
MESA3D_CONF_OPTS += -Dglx=dri
ifeq ($(BR2_PACKAGE_MESA3D_NEEDS_XA),y)
-MESA3D_CONF_OPTS += -Dgallium-xa=true
+MESA3D_CONF_OPTS += -Dgallium-xa=enabled
else
-MESA3D_CONF_OPTS += -Dgallium-xa=false
+MESA3D_CONF_OPTS += -Dgallium-xa=disabled
endif
else
MESA3D_CONF_OPTS += \
-Dglx=disabled \
- -Dgallium-xa=false
+ -Dgallium-xa=disabled
endif
ifeq ($(BR2_ARM_CPU_HAS_NEON),y)
@@ -115,23 +115,23 @@ MESA3D_CONF_OPTS += \
-Dgallium-extra-hud=false
else
MESA3D_CONF_OPTS += \
- -Dshared-glapi=true \
+ -Dshared-glapi=enabled \
-Dgallium-drivers=$(subst $(space),$(comma),$(MESA3D_GALLIUM_DRIVERS-y)) \
-Dgallium-extra-hud=true
endif
ifeq ($(BR2_PACKAGE_MESA3D_DRI_DRIVER),)
MESA3D_CONF_OPTS += \
- -Ddri-drivers= -Ddri3=false
+ -Ddri-drivers= -Ddri3=disabled
else
ifeq ($(BR2_PACKAGE_XLIB_LIBXSHMFENCE),y)
MESA3D_DEPENDENCIES += xlib_libxshmfence
-MESA3D_CONF_OPTS += -Ddri3=true
+MESA3D_CONF_OPTS += -Ddri3=enabled
else
-MESA3D_CONF_OPTS += -Ddri3=false
+MESA3D_CONF_OPTS += -Ddri3=disabled
endif
MESA3D_CONF_OPTS += \
- -Dshared-glapi=true \
+ -Dshared-glapi=enabled \
-Dglx-direct=true \
-Ddri-drivers=$(subst $(space),$(comma),$(MESA3D_DRI_DRIVERS-y))
endif
@@ -142,7 +142,7 @@ MESA3D_CONF_OPTS += \
else
MESA3D_DEPENDENCIES += xlib_libxshmfence
MESA3D_CONF_OPTS += \
- -Ddri3=true \
+ -Ddri3=enabled \
-Dvulkan-drivers=$(subst $(space),$(comma),$(MESA3D_VULKAN_DRIVERS-y))
endif
@@ -160,7 +160,7 @@ MESA3D_CONF_OPTS += -Dopengl=true
# libva and mesa3d have a circular dependency
# we do not need libva support in mesa3d, therefore disable this option
-MESA3D_CONF_OPTS += -Dgallium-va=false
+MESA3D_CONF_OPTS += -Dgallium-va=disabled
# libGL is only provided for a full xorg stack
ifeq ($(BR2_PACKAGE_MESA3D_OPENGL_GLX),y)
@@ -189,96 +189,74 @@ ifeq ($(BR2_PACKAGE_WAYLAND),y)
MESA3D_DEPENDENCIES += wayland wayland-protocols
MESA3D_PLATFORMS += wayland
endif
-ifeq ($(BR2_PACKAGE_MESA3D_DRI_DRIVER),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_V3D),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_VC4),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_ETNAVIV),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_FREEDRENO),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_IRIS),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_LIMA),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_PANFROST),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_VIRGL),y)
-MESA3D_PLATFORMS += drm
-else ifeq ($(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_RADEONSI),y)
-MESA3D_PLATFORMS += drm
-endif
-MESA3D_PLATFORMS += surfaceless
MESA3D_CONF_OPTS += \
-Dplatforms=$(subst $(space),$(comma),$(MESA3D_PLATFORMS))
ifeq ($(BR2_PACKAGE_MESA3D_GBM),y)
MESA3D_CONF_OPTS += \
- -Dgbm=true
+ -Dgbm=enabled
else
MESA3D_CONF_OPTS += \
- -Dgbm=false
+ -Dgbm=disabled
endif
ifeq ($(BR2_PACKAGE_MESA3D_OPENGL_EGL),y)
MESA3D_PROVIDES += libegl
MESA3D_CONF_OPTS += \
- -Degl=true
+ -Degl=enabled
else
MESA3D_CONF_OPTS += \
- -Degl=false
+ -Degl=disabled
endif
ifeq ($(BR2_PACKAGE_MESA3D_OPENGL_ES),y)
MESA3D_PROVIDES += libgles
-MESA3D_CONF_OPTS += -Dgles1=true -Dgles2=true
+MESA3D_CONF_OPTS += -Dgles1=enabled -Dgles2=enabled
else
-MESA3D_CONF_OPTS += -Dgles1=false -Dgles2=false
+MESA3D_CONF_OPTS += -Dgles1=disabled -Dgles2=disabled
endif
ifeq ($(BR2_PACKAGE_MESA3D_XVMC),y)
MESA3D_DEPENDENCIES += xlib_libXv xlib_libXvMC
-MESA3D_CONF_OPTS += -Dgallium-xvmc=true
+MESA3D_CONF_OPTS += -Dgallium-xvmc=enabled
else
-MESA3D_CONF_OPTS += -Dgallium-xvmc=false
+MESA3D_CONF_OPTS += -Dgallium-xvmc=disabled
endif
ifeq ($(BR2_PACKAGE_VALGRIND),y)
-MESA3D_CONF_OPTS += -Dvalgrind=true
+MESA3D_CONF_OPTS += -Dvalgrind=enabled
MESA3D_DEPENDENCIES += valgrind
else
-MESA3D_CONF_OPTS += -Dvalgrind=false
+MESA3D_CONF_OPTS += -Dvalgrind=disabled
endif
ifeq ($(BR2_PACKAGE_LIBUNWIND),y)
-MESA3D_CONF_OPTS += -Dlibunwind=true
+MESA3D_CONF_OPTS += -Dlibunwind=enabled
MESA3D_DEPENDENCIES += libunwind
else
-MESA3D_CONF_OPTS += -Dlibunwind=false
+MESA3D_CONF_OPTS += -Dlibunwind=disabled
endif
ifeq ($(BR2_PACKAGE_MESA3D_VDPAU),y)
MESA3D_DEPENDENCIES += libvdpau
-MESA3D_CONF_OPTS += -Dgallium-vdpau=true
+MESA3D_CONF_OPTS += -Dgallium-vdpau=enabled
else
-MESA3D_CONF_OPTS += -Dgallium-vdpau=false
+MESA3D_CONF_OPTS += -Dgallium-vdpau=disabled
endif
ifeq ($(BR2_PACKAGE_LM_SENSORS),y)
-MESA3D_CONF_OPTS += -Dlmsensors=true
+MESA3D_CONF_OPTS += -Dlmsensors=enabled
MESA3D_DEPENDENCIES += lm-sensors
else
-MESA3D_CONF_OPTS += -Dlmsensors=false
+MESA3D_CONF_OPTS += -Dlmsensors=disabled
endif
ifeq ($(BR2_PACKAGE_ZSTD),y)
-MESA3D_CONF_OPTS += -Dzstd=true
+MESA3D_CONF_OPTS += -Dzstd=enabled
MESA3D_DEPENDENCIES += zstd
else
-MESA3D_CONF_OPTS += -Dzstd=false
+MESA3D_CONF_OPTS += -Dzstd=disabled
endif
$(eval $(meson-package))