Mercurial > vanilla
diff graphics/mesa/mesa.sh @ 1309:66d3e04b22e6
graphics/mesa: upgrade to 21.2.5
author | David Demelier <markand@malikania.fr> |
---|---|
date | Fri, 19 Nov 2021 21:45:27 +0100 |
parents | 9867e578b1a9 |
children |
line wrap: on
line diff
--- a/graphics/mesa/mesa.sh Thu Nov 18 19:56:17 2021 +0100 +++ b/graphics/mesa/mesa.sh Fri Nov 19 21:45:27 2021 +0100 @@ -16,44 +16,41 @@ # PKGNAME=mesa -PKGVERSION=18.3.5 +PKGVERSION=21.2.5 PKGREVISION=1 -PKGLICENSE="CUSTOM" +PKGLICENSE="Custom" PKGSUMMARY="opensource OpenGL implementation" +PKGWWW="https://www.mesa3d.org" PKGDOWNLOAD="https://mesa.freedesktop.org/archive/$PKGNAME-$PKGVERSION.tar.xz" PKGDEPENDS="meson:build" -PKGOPTIONS="DRI DRM EGL GALLIUM GLVND LLVM PLATFORMS SELINUX VULKAN WAYLAND X" +PKGOPTIONS="DRI EGL GALLIUM GLVND LLVM PLATFORMS SELINUX VULKAN WAYLAND X" : ${CC:=clang} : ${CFLAGS:=-O2} : ${CXX:=clang++} : ${CXXFLAGS:=-O2} : ${LDFLAGS:=} -: ${DRI:=i965 r100 r200 nouveau} # driver list or "no" -: ${DRM:=yes} +: ${DRI:=yes} # Select: list|yes, no : ${EGL:=yes} -: ${GALLIUM:=i915 radeonsi r300 r600 virgl swrast} # driver list or "no" +: ${GALLIUM:=yes} # Select: list|yes, no : ${GLVND:=no} : ${LLVM:=yes} : ${SELINUX:=no} -: ${VULKAN:=intel amd} # driver list or "no" +: ${VULKAN:=yes} # Select: list|yes, no : ${WAYLAND:=yes} : ${X:=yes} # Convert user options separated by spaces to comma. with_platforms="" -with_dri_drivers="" -with_gallium_drivers="" -with_vulkan_drivers="" -if [ "$DRM" = "yes" ]; then - PKGDEPENDS="libdrm $PKGDEPENDS" - with_platforms="drm" -fi - -if [ "$DRI" != "no" ]; then - with_dri_drivers=$(echo $DRI | sed -e "s/ /,/g") -fi +case "$DRI" in +"yes") + with_dri_drivers="auto" ;; +"no") + with_dri_drivers="" ;; +*) + with_dri_drivers="$(echo $DRI | sed -e "s/ /,/g")" ;; +esac if [ "$EGL" = "yes" ]; then with_egl="-D egl=true" @@ -61,9 +58,14 @@ with_egl="-D egl=false" fi -if [ "$GALLIUM" != "no" ]; then - with_gallium_drivers=$(echo $GALLIUM | sed -e "s/ /,/g") -fi +case "$GALLIUM" in +"yes") + with_gallium_drivers="auto" ;; +"no") + with_gallium_drivers="" ;; +*) + with_gallium_drivers="$(echo $GALLIUM | sed -e "s/ /,/g")" +esac if [ "$GLVND" = "yes" ]; then with_glvnd="-D glvnd=true" @@ -78,13 +80,18 @@ with_llvm="-D llvm=false" fi -if [ "$VULKAN" != "no" ]; then - with_vulkan_drivers=$(echo $VULKAN | sed -e "s/ /,/g") -fi +case "$VULKAN" in +"yes") + with_vulkan_drivers="auto" ;; +"no") + with_vulkan_drivers="$(echo $VULKAN | sed -e "s/ /,/g")" ;; +*) + with_vulkan_drivers="" ;; +esac if [ "$WAYLAND" = "yes" ]; then PKGDEPENDS="wayland wayland-protocols $PKGDEPENDS" - with_platforms="wayland,$with_platforms" + with_platforms="wayland $with_platforms" fi if [ "$X" = "yes" ]; then @@ -95,7 +102,7 @@ libxshmfence libxxf86vm $PKGDEPENDS" - with_platforms="x11,$with_platforms" + with_platforms="x11 $with_platforms" with_dri="-D dri3=true" with_glx="-D glx=dri" else @@ -106,12 +113,9 @@ build() { rm -rf $PKGNAME-$PKGVERSION - tar xvf $PKGNAME-$PKGVERSION.tar.xz + tar -xvf $PKGNAME-$PKGVERSION.tar.xz cd $PKGNAME-$PKGVERSION - patch -p0 < ../disable-tls.patch - # https://git.alpinelinux.org/aports/plain/main/mesa/musl-fix-includes.patch - patch -p1 < ../musl.patch CC="$CC" \ CFLAGS="$CFLAGS" \ CXX="$CXX" \ @@ -122,8 +126,7 @@ --buildtype release \ --default-library shared \ -D libdir=lib \ - -D bpm=true \ - -D platforms="$with_platforms" \ + -D platforms="$(echo ${with_platforms% *} | tr " " ",")" \ -D dri-drivers="$with_dri_drivers" \ -D gallium-drivers="$with_gallium_drivers" \ -D vulkan-drivers="$with_vulkan_drivers" \