public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: media-libs/mesa/, profiles/base/
@ 2024-02-01 19:49 Matt Turner
  0 siblings, 0 replies; only message in thread
From: Matt Turner @ 2024-02-01 19:49 UTC (permalink / raw
  To: gentoo-commits

commit:     78da2493dd11ce279d74d8ed1f790ff03bfc2090
Author:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
AuthorDate: Thu Feb  1 19:36:53 2024 +0000
Commit:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
CommitDate: Thu Feb  1 19:49:41 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=78da2493

media-libs/mesa: Add USE=opengl

Closes: https://bugs.gentoo.org/920692
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>

 media-libs/mesa/mesa-9999.ebuild | 30 ++++++++++++++++++++++++------
 profiles/base/package.use.force  |  4 ++++
 2 files changed, 28 insertions(+), 6 deletions(-)

diff --git a/media-libs/mesa/mesa-9999.ebuild b/media-libs/mesa/mesa-9999.ebuild
index 69bb2e2a8abb..28a5b5573daa 100644
--- a/media-libs/mesa/mesa-9999.ebuild
+++ b/media-libs/mesa/mesa-9999.ebuild
@@ -32,7 +32,7 @@ done
 
 IUSE="${IUSE_VIDEO_CARDS}
 	cpu_flags_x86_sse2 d3d9 debug gles1 +gles2 +llvm
-	lm-sensors opencl osmesa +proprietary-codecs selinux
+	lm-sensors opencl +opengl osmesa +proprietary-codecs selinux
 	test unwind vaapi valgrind vdpau vulkan
 	vulkan-overlay wayland +X xa zink +zstd"
 
@@ -54,7 +54,8 @@ REQUIRED_USE="
 	video_cards_r300?   ( x86? ( llvm ) amd64? ( llvm ) )
 	vdpau? ( X )
 	xa? ( X )
-	zink? ( vulkan )
+	X? ( gles1? ( opengl ) gles2? ( opengl ) )
+	zink? ( vulkan || ( opengl gles1 gles2 ) )
 "
 
 LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.119"
@@ -396,15 +397,32 @@ multilib_src_configure() {
 		emesonargs+=(-Dintel-clc=disabled)
 	fi
 
+	if use opengl || use gles1 || use gles2; then
+		emesonargs+=(
+			-Degl=enabled
+			-Dgbm=enabled
+			-Dglvnd=true
+		)
+	else
+		emesonargs+=(
+			-Degl=disabled
+			-Dgbm=disabled
+			-Dglvnd=false
+		)
+	fi
+
+	if use opengl && use X; then
+		emesonargs+=(-Dglx=dri)
+	else
+		emesonargs+=(-Dglx=disabled)
+	fi
+
 	emesonargs+=(
 		$(meson_use test build-tests)
-		-Dglx=$(usex X dri disabled)
 		-Dshared-glapi=enabled
 		-Ddri3=enabled
-		-Degl=enabled
 		-Dexpat=enabled
-		-Dgbm=enabled
-		-Dglvnd=true
+		$(meson_use opengl)
 		$(meson_feature gles1)
 		$(meson_feature gles2)
 		$(meson_feature llvm)

diff --git a/profiles/base/package.use.force b/profiles/base/package.use.force
index 9a47d64fea28..e50d568231f8 100644
--- a/profiles/base/package.use.force
+++ b/profiles/base/package.use.force
@@ -1,6 +1,10 @@
 # Copyright 1999-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
+# Matt Turner <mattst88@gentoo.org> (2024-02-01)
+# Reverse dependencies are not ready for media-libs/mesa to not provide OpenGL.
+media-libs/mesa opengl
+
 # Michael Orlitzky <mjo@gentoo.org> (2023-11-22)
 # USE=-gui is broken in this and the subsequent version (bug
 # 916718). Package is a PITA: the maintainer is combative, and the


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2024-02-01 19:49 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-01 19:49 [gentoo-commits] repo/gentoo:master commit in: media-libs/mesa/, profiles/base/ Matt Turner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox