git: aa6c9614c0f6 - main - graphics/mesa: Simplify x11/wayland option
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 01 Jul 2024 08:18:31 UTC
The branch main has been updated by manu: URL: https://cgit.FreeBSD.org/ports/commit/?id=aa6c9614c0f637cf82b56467e5d918c1e0988369 commit aa6c9614c0f637cf82b56467e5d918c1e0988369 Author: Emmanuel Vadot <manu@FreeBSD.org> AuthorDate: 2024-06-26 13:18:23 +0000 Commit: Emmanuel Vadot <manu@FreeBSD.org> CommitDate: 2024-07-01 08:17:57 +0000 graphics/mesa: Simplify x11/wayland option Simply use X11 for x11 support as it's done for all other ports. Same for Wayland, just use WAYLAND. While here always use xcb and xrandr for X11 support in mesa-dri as we always build a vulkan driver (swrast). Differential Revision: https://reviews.freebsd.org/D45743 Reviewed by: bapt Sponsored by: Beckhoff Automation GmbH & Co. KG --- graphics/mesa-dri/Makefile | 30 ++++++++++++------------------ graphics/mesa-dri/Makefile.common | 2 +- graphics/mesa-libs/Makefile | 25 +++++++++++-------------- 3 files changed, 24 insertions(+), 33 deletions(-) diff --git a/graphics/mesa-dri/Makefile b/graphics/mesa-dri/Makefile index f9ba777266c4..b656f81d0a7d 100644 --- a/graphics/mesa-dri/Makefile +++ b/graphics/mesa-dri/Makefile @@ -1,5 +1,6 @@ PORTNAME= mesa-dri PORTVERSION= ${MESAVERSION} +PORTREVISION= 1 CATEGORIES= graphics COMMENT= OpenGL hardware acceleration drivers for DRI2+ @@ -10,20 +11,16 @@ LIB_DEPENDS+= libglapi.so:graphics/mesa-libs USES+= llvm:lib,noexport OPTIONS_GROUP= PLATFORM -OPTIONS_GROUP_PLATFORM= PLATFORM_X11 PLATFORM_WAYLAND -PLATFORM_X11_DESC= Enable X11 support for GBM/EGL -PLATFORM_WAYLAND_DESC= Enable Wayland support for GBM/EGL -PLATFORM_WAYLAND_IMPLIES= WAYLAND - -OPTIONS_DEFINE= WAYLAND ZSTD -OPTIONS_DEFAULT= WAYLAND PLATFORM_X11 PLATFORM_WAYLAND ZSTD +OPTIONS_GROUP_PLATFORM= X11 WAYLAND +X11_DESC= Enable X11 support for GBM/EGL +WAYLAND_DESC= Enable Wayland support for GBM/EGL and Vulkan +WAYLAND_BUILD_DEPENDS= wayland-protocols>=1.8:graphics/wayland-protocols +WAYLAND_LIB_DEPENDS= libwayland-client.so:graphics/wayland + +OPTIONS_DEFINE= ZSTD +OPTIONS_DEFAULT= WAYLAND X11 ZSTD OPTIONS_SUB= yes -WAYLAND_DESC= Enable support for the Wayland platform in Vulkan drivers -WAYLAND_BUILD_DEPENDS= wayland-protocols>=1.8:graphics/wayland-protocols -WAYLAND_LIB_DEPENDS= libwayland-client.so:graphics/wayland -WAYLAND_IMPLIES= PLATFORM_WAYLAND - ZSTD_DESC= Use ZSTD for shader cache ZSTD_LIB_DEPENDS= libzstd.so:archivers/zstd ZSTD_MESON_ENABLED= zstd @@ -56,15 +53,12 @@ VULKAN_DRIVERS+= INTEL LDFLAGS_i386= -Wl,-znotext -.if ${PORT_OPTIONS:MPLATFORM_X11} +.if ${PORT_OPTIONS:MX11} MESA_PLATFORMS+= x11 -USE_XORG+= xorgproto x11 xdamage xext xfixes xshmfence xv -.if defined(VULKAN_DRIVERS) -USE_XORG+= xcb xrandr -.endif +USE_XORG+= xcb xorgproto xrandr x11 xdamage xext xfixes xshmfence xv .endif -.if ${PORT_OPTIONS:MPLATFORM_WAYLAND} +.if ${PORT_OPTIONS:MWAYLAND} MESA_PLATFORMS+= wayland .endif diff --git a/graphics/mesa-dri/Makefile.common b/graphics/mesa-dri/Makefile.common index 6e9bb1fcf85f..66dde6177702 100644 --- a/graphics/mesa-dri/Makefile.common +++ b/graphics/mesa-dri/Makefile.common @@ -28,7 +28,7 @@ COMPONENT= ${PORTNAME:tl:C/^lib//:C/mesa-//} BUILD_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}mako>0:textproc/py-mako@${PY_FLAVOR} .if ${COMPONENT} != clover -.if ${PORT_OPTIONS:MPLATFORM_X11} +.if ${PORT_OPTIONS:MX11} USES+= xorg .endif .endif diff --git a/graphics/mesa-libs/Makefile b/graphics/mesa-libs/Makefile index f0bb8f7ec8e7..c1e04551a089 100644 --- a/graphics/mesa-libs/Makefile +++ b/graphics/mesa-libs/Makefile @@ -1,5 +1,6 @@ PORTNAME= mesa-libs PORTVERSION= ${MESAVERSION} +PORTREVISION= 1 CATEGORIES= graphics COMMENT= OpenGL libraries that support GLX and EGL clients @@ -12,20 +13,16 @@ USES= llvm:noexport BUILD_DEPENDS= libglvnd>=0:graphics/libglvnd -OPTIONS_GROUP= PLATFORM -OPTIONS_GROUP_PLATFORM= PLATFORM_X11 PLATFORM_WAYLAND -PLATFORM_X11_DESC= Enable X11 support for GBM/EGL -PLATFORM_WAYLAND_DESC= Enable Wayland support for GBM/EGL -PLATFORM_WAYLAND_IMPLIES= WAYLAND - -OPTIONS_DEFINE= WAYLAND ZSTD -OPTIONS_DEFAULT=WAYLAND PLATFORM_X11 PLATFORM_WAYLAND ZSTD -OPTIONS_SUB= yes - -WAYLAND_DESC= Enable support for the Wayland platform in EGL +OPTIONS_GROUP= PLATFORM +OPTIONS_GROUP_PLATFORM= X11 WAYLAND +X11_DESC= Enable X11 support for GBM/EGL +WAYLAND_DESC= Enable Wayland support for GBM/EGL WAYLAND_BUILD_DEPENDS= wayland-protocols>=1.8:graphics/wayland-protocols WAYLAND_LIB_DEPENDS= libwayland-server.so:graphics/wayland -WAYLAND_IMPLIES= PLATFORM_WAYLAND + +OPTIONS_DEFINE= ZSTD +OPTIONS_DEFAULT= WAYLAND X11 ZSTD +OPTIONS_SUB= yes ZSTD_DESC= Use ZSTD for shader cache ZSTD_LIB_DEPENDS= libzstd.so:archivers/zstd @@ -54,7 +51,7 @@ MESON_ARGS+= -Dandroid-libbacktrace=disabled \ # Building EGL and GBM requires a driver so add r300 MESON_ARGS+= -Dgallium-drivers="r300" -.if ${PORT_OPTIONS:MPLATFORM_X11} +.if ${PORT_OPTIONS:MX11} MESA_PLATFORMS+= x11 USE_XORG+= xorgproto x11 xcb xdamage xext \ xfixes xshmfence xxf86vm xrandr @@ -64,7 +61,7 @@ MESON_ARGS+= -Dglx=disabled PLIST_SUB+= GLX="@comment " .endif -.if ${PORT_OPTIONS:MPLATFORM_WAYLAND} && ${PORT_OPTIONS:MWAYLAND} +.if ${PORT_OPTIONS:MWAYLAND} MESA_PLATFORMS+= wayland .endif