Gentoo Archives: gentoo-commits

From: Matt Turner <mattst88@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/mesa/
Date: Thu, 20 Aug 2020 00:00:46
Message-Id: 1597881567.8cdb11d128801dcbbc3e0a0d15e83b5cdff3a34d.mattst88@gentoo
1 commit: 8cdb11d128801dcbbc3e0a0d15e83b5cdff3a34d
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Wed Aug 19 23:59:11 2020 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Wed Aug 19 23:59:27 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8cdb11d1
7
8 media-libs/mesa: Drop old versions
9
10 Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
11
12 media-libs/mesa/Manifest | 3 -
13 media-libs/mesa/mesa-20.1.4.ebuild | 558 --------------------------------
14 media-libs/mesa/mesa-20.1.5.ebuild | 557 --------------------------------
15 media-libs/mesa/mesa-20.2.0_rc1.ebuild | 565 ---------------------------------
16 4 files changed, 1683 deletions(-)
17
18 diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest
19 index a96a4157ff5..3432a3707ad 100644
20 --- a/media-libs/mesa/Manifest
21 +++ b/media-libs/mesa/Manifest
22 @@ -1,6 +1,3 @@
23 DIST mesa-20.0.8.tar.xz 12360736 BLAKE2B 19e3f8a40b34b5f17ed76077c5d92f728a134b2479c43d86674ed1818ab99639a9b732041f67488251df808564f6abe5b587d756ef9c7c13dcada87cd0fc05de SHA512 d906330c412899907dd05a84034a929107fccaf3044814c4b1f30ba5690cbcf1587b5f17534c6345111f3cb7cf292afd5984a60486643ff6f534b57cec615374
24 -DIST mesa-20.1.4.tar.xz 12758452 BLAKE2B 2f4e4563382a455f7fd6ac0bb32c91901c4ca4fa297da7769b40722713316ba9a6b8acc7bd5ae9df46b9ffea6bee13cdf2a8dd4fe747ac61dc052391aeae18d9 SHA512 f4d79694cda8531e7560147caf5d18bce5c685cd6c61264dced5adaa9043be9c83d3a2bd623ebffedc8d4258b9b1f97d84d9aeea307aa77cf99d0bc47c987155
25 -DIST mesa-20.1.5.tar.xz 12783368 BLAKE2B f452832b3ed3468d01b7129cd782f3b58752a6de511679c9bd7eca7a5728630202a185e61f435c172f84d4ef6ffd05bbf7873e5f8c4cc64572d3b5a38e5ebf28 SHA512 47796bf2cccfd054ff25f571747754e0ab9b42fe87644ea320b3d9497d63b3013e9b7e59ea0516bbd1a38b5594e0d185bf5a36230ea5c5974e7ff889cee2601e
26 DIST mesa-20.1.6.tar.xz 12805724 BLAKE2B d652b59e4987436d2e05de9138f2e2fb4a8bf435c24d9c7ad08bcb82a3bf7c9c64bc71b15b4b6d334f8b574341719f372aa1b893283abc21191a4d71d9d30fee SHA512 5ef28334ecb7effaaf597ea3efe0406af62419e6fa629e835d843161ab8d83515626ec0f0495c4cc66af9e5669398ac96c16ca626e4965a9831e1704c995fb09
27 -DIST mesa-20.2.0-rc1.tar.xz 13521940 BLAKE2B 6e9fdc8fa9d2b0f9bd72b033d710b0cbc10d4434adc5d702576cc08559ad32f83983cb3ba44f96a1f740c626429cc386a4e14ee4fa5549c2f3dbb942243b1641 SHA512 d86e52a985d94e3d5b5ef7799acf4fced72df6cd68b29e1fef2c7755144d9633d74f648d8434699497d38b50f0d1a12d12a135a45ea5bc4cf22f2033a3651aac
28 DIST mesa-20.2.0-rc2.tar.xz 13528208 BLAKE2B 6505446829ec2c01c0de7a7d9c1187db874111402da5ffe2f9f5872df7b6a5e53a3b628c190172bb9a806851b3b85aa0e3b53a4fcfb40f99adfc48cc3876c9f5 SHA512 36d9a74db50335bd31a8d5c47f7c657f05eeda044530fe123c06c472ed27c9b5dff19716d11d95256449223e82dde38895547cf6ae60b7460d3b1e9ed440704a
29
30 diff --git a/media-libs/mesa/mesa-20.1.4.ebuild b/media-libs/mesa/mesa-20.1.4.ebuild
31 deleted file mode 100644
32 index 058a206a5ff..00000000000
33 --- a/media-libs/mesa/mesa-20.1.4.ebuild
34 +++ /dev/null
35 @@ -1,558 +0,0 @@
36 -# Copyright 1999-2020 Gentoo Authors
37 -# Distributed under the terms of the GNU General Public License v2
38 -
39 -EAPI=7
40 -
41 -PYTHON_COMPAT=( python3_{6,7,8} )
42 -
43 -inherit llvm meson multilib-minimal python-any-r1 linux-info
44 -
45 -OPENGL_DIR="xorg-x11"
46 -
47 -MY_P="${P/_/-}"
48 -
49 -DESCRIPTION="OpenGL-like graphic library for Linux"
50 -HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/"
51 -
52 -if [[ ${PV} == 9999 ]]; then
53 - EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git"
54 - inherit git-r3
55 -else
56 - SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz"
57 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
58 -fi
59 -
60 -LICENSE="MIT"
61 -SLOT="0"
62 -RESTRICT="
63 - !test? ( test )
64 -"
65 -
66 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
67 -VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 intel iris lima nouveau panfrost vc4 virgl vivante vmware"
68 -for card in ${VIDEO_CARDS}; do
69 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
70 -done
71 -
72 -IUSE="${IUSE_VIDEO_CARDS}
73 - +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 +gles2 +libglvnd +llvm
74 - lm-sensors opencl osmesa selinux test unwind vaapi valgrind vdpau vulkan
75 - vulkan-overlay wayland +X xa xvmc +zstd"
76 -
77 -REQUIRED_USE="
78 - d3d9? ( dri3 || ( video_cards_iris video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) )
79 - gles1? ( egl )
80 - gles2? ( egl )
81 - vulkan? ( dri3
82 - video_cards_radeonsi? ( llvm ) )
83 - vulkan-overlay? ( vulkan )
84 - wayland? ( egl gbm )
85 - video_cards_freedreno? ( gallium )
86 - video_cards_intel? ( classic )
87 - video_cards_i915? ( || ( classic gallium ) )
88 - video_cards_i965? ( classic )
89 - video_cards_iris? ( gallium )
90 - video_cards_lima? ( gallium )
91 - video_cards_nouveau? ( || ( classic gallium ) )
92 - video_cards_panfrost? ( gallium )
93 - video_cards_radeon? ( || ( classic gallium )
94 - gallium? ( x86? ( llvm ) amd64? ( llvm ) ) )
95 - video_cards_r100? ( classic )
96 - video_cards_r200? ( classic )
97 - video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) )
98 - video_cards_r600? ( gallium )
99 - video_cards_radeonsi? ( gallium llvm )
100 - video_cards_vc4? ( gallium )
101 - video_cards_virgl? ( gallium )
102 - video_cards_vivante? ( gallium gbm )
103 - video_cards_vmware? ( gallium )
104 - xa? ( X )
105 - xvmc? ( X )
106 -"
107 -
108 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.100"
109 -RDEPEND="
110 - !app-eselect/eselect-mesa
111 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
112 - >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}]
113 - libglvnd? (
114 - >=media-libs/libglvnd-1.2.0-r1[X?,${MULTILIB_USEDEP}]
115 - !app-eselect/eselect-opengl
116 - )
117 - !libglvnd? (
118 - >=app-eselect/eselect-opengl-1.3.0
119 - )
120 - gallium? (
121 - unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] )
122 - llvm? (
123 - video_cards_radeonsi? (
124 - virtual/libelf:0=[${MULTILIB_USEDEP}]
125 - )
126 - video_cards_r600? (
127 - virtual/libelf:0=[${MULTILIB_USEDEP}]
128 - )
129 - video_cards_radeon? (
130 - virtual/libelf:0=[${MULTILIB_USEDEP}]
131 - )
132 - )
133 - lm-sensors? ( sys-apps/lm-sensors:=[${MULTILIB_USEDEP}] )
134 - opencl? (
135 - >=virtual/opencl-3[${MULTILIB_USEDEP}]
136 - dev-libs/libclc
137 - virtual/libelf:0=[${MULTILIB_USEDEP}]
138 - )
139 - vaapi? (
140 - >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}]
141 - )
142 - vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
143 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
144 - )
145 - selinux? ( sys-libs/libselinux[${MULTILIB_USEDEP}] )
146 - wayland? (
147 - >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}]
148 - >=dev-libs/wayland-protocols-1.8
149 - )
150 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}]
151 - video_cards_intel? (
152 - !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
153 - )
154 - video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
155 - vulkan-overlay? ( dev-util/glslang:0=[${MULTILIB_USEDEP}] )
156 - X? (
157 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
158 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
159 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
160 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
161 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
162 - >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}]
163 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
164 - )
165 - zstd? ( app-arch/zstd:=[${MULTILIB_USEDEP}] )
166 -"
167 -for card in ${RADEON_CARDS}; do
168 - RDEPEND="${RDEPEND}
169 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
170 - "
171 -done
172 -RDEPEND="${RDEPEND}
173 - video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
174 -"
175 -
176 -# Please keep the LLVM dependency block separate. Since LLVM is slotted,
177 -# we need to *really* make sure we're not pulling one than more slot
178 -# simultaneously.
179 -#
180 -# How to use it:
181 -# 1. List all the working slots (with min versions) in ||, newest first.
182 -# 2. Update the := to specify *max* version, e.g. < 10.
183 -# 3. Specify LLVM_MAX_SLOT, e.g. 9.
184 -LLVM_MAX_SLOT="10"
185 -LLVM_DEPSTR="
186 - || (
187 - sys-devel/llvm:10[${MULTILIB_USEDEP}]
188 - sys-devel/llvm:9[${MULTILIB_USEDEP}]
189 - sys-devel/llvm:8[${MULTILIB_USEDEP}]
190 - )
191 - <sys-devel/llvm-$((LLVM_MAX_SLOT + 1)):=[${MULTILIB_USEDEP}]
192 -"
193 -LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
194 -CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang}
195 -CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
196 -RDEPEND="${RDEPEND}
197 - gallium? (
198 - llvm? (
199 - opencl? (
200 - video_cards_r600? (
201 - ${CLANG_DEPSTR_AMDGPU}
202 - )
203 - !video_cards_r600? (
204 - video_cards_radeonsi? (
205 - ${CLANG_DEPSTR_AMDGPU}
206 - )
207 - )
208 - !video_cards_r600? (
209 - !video_cards_radeonsi? (
210 - video_cards_radeon? (
211 - ${CLANG_DEPSTR_AMDGPU}
212 - )
213 - )
214 - )
215 - !video_cards_r600? (
216 - !video_cards_radeon? (
217 - !video_cards_radeonsi? (
218 - ${CLANG_DEPSTR}
219 - )
220 - )
221 - )
222 - )
223 - !opencl? (
224 - video_cards_r600? (
225 - ${LLVM_DEPSTR_AMDGPU}
226 - )
227 - !video_cards_r600? (
228 - video_cards_radeonsi? (
229 - ${LLVM_DEPSTR_AMDGPU}
230 - )
231 - )
232 - !video_cards_r600? (
233 - !video_cards_radeonsi? (
234 - video_cards_radeon? (
235 - ${LLVM_DEPSTR_AMDGPU}
236 - )
237 - )
238 - )
239 - !video_cards_r600? (
240 - !video_cards_radeon? (
241 - !video_cards_radeonsi? (
242 - ${LLVM_DEPSTR}
243 - )
244 - )
245 - )
246 - )
247 - )
248 - )
249 -"
250 -unset {LLVM,CLANG}_DEPSTR{,_AMDGPU}
251 -
252 -DEPEND="${RDEPEND}
253 - valgrind? ( dev-util/valgrind )
254 - X? (
255 - x11-libs/libXrandr[${MULTILIB_USEDEP}]
256 - x11-base/xorg-proto
257 - )
258 -"
259 -BDEPEND="
260 - ${PYTHON_DEPS}
261 - opencl? (
262 - >=sys-devel/gcc-4.6
263 - )
264 - sys-devel/bison
265 - sys-devel/flex
266 - sys-devel/gettext
267 - virtual/pkgconfig
268 - $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]")
269 -"
270 -
271 -S="${WORKDIR}/${MY_P}"
272 -EGIT_CHECKOUT_DIR=${S}
273 -
274 -QA_WX_LOAD="
275 -x86? (
276 - usr/lib*/libglapi.so.0.0.0
277 - usr/lib*/libGLESv1_CM.so.1.1.0
278 - usr/lib*/libGLESv2.so.2.0.0
279 - usr/lib*/libGL.so.1.2.0
280 - usr/lib*/libOSMesa.so.8.0.0
281 - libglvnd? ( usr/lib/libGLX_mesa.so.0.0.0 )
282 -)"
283 -
284 -llvm_check_deps() {
285 - local flags=${MULTILIB_USEDEP}
286 - if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi
287 - then
288 - flags+=",llvm_targets_AMDGPU(-)"
289 - fi
290 -
291 - if use opencl; then
292 - has_version "sys-devel/clang:${LLVM_SLOT}[${flags}]" || return 1
293 - fi
294 - has_version "sys-devel/llvm:${LLVM_SLOT}[${flags}]"
295 -}
296 -
297 -pkg_pretend() {
298 - if use vulkan; then
299 - if ! use video_cards_i965 &&
300 - ! use video_cards_iris &&
301 - ! use video_cards_radeonsi; then
302 - ewarn "Ignoring USE=vulkan since VIDEO_CARDS does not contain i965, iris, or radeonsi"
303 - fi
304 - fi
305 -
306 - if use opencl; then
307 - if ! use video_cards_r600 &&
308 - ! use video_cards_radeonsi; then
309 - ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi"
310 - fi
311 - fi
312 -
313 - if use vaapi; then
314 - if ! use video_cards_r600 &&
315 - ! use video_cards_radeonsi &&
316 - ! use video_cards_nouveau; then
317 - ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau"
318 - fi
319 - fi
320 -
321 - if use vdpau; then
322 - if ! use video_cards_r300 &&
323 - ! use video_cards_r600 &&
324 - ! use video_cards_radeonsi &&
325 - ! use video_cards_nouveau; then
326 - ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau"
327 - fi
328 - fi
329 -
330 - if use xa; then
331 - if ! use video_cards_freedreno &&
332 - ! use video_cards_nouveau &&
333 - ! use video_cards_vmware; then
334 - ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware"
335 - fi
336 - fi
337 -
338 - if use xvmc; then
339 - if ! use video_cards_r600 &&
340 - ! use video_cards_nouveau; then
341 - ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau"
342 - fi
343 - fi
344 -
345 - if ! use gallium; then
346 - use lm-sensors && ewarn "Ignoring USE=lm-sensors since USE does not contain gallium"
347 - use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium"
348 - use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium"
349 - use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium"
350 - use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium"
351 - use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium"
352 - use xa && ewarn "Ignoring USE=xa since USE does not contain gallium"
353 - use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium"
354 - fi
355 -
356 - if ! use llvm; then
357 - use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm"
358 - fi
359 -}
360 -
361 -python_check_deps() {
362 - has_version -b ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]"
363 -}
364 -
365 -pkg_setup() {
366 - # warning message for bug 459306
367 - if use llvm && has_version sys-devel/llvm[!debug=]; then
368 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
369 - ewarn "detected! This can cause problems. For details, see bug 459306."
370 - fi
371 -
372 - if use video_cards_i965 ||
373 - use video_cards_iris ||
374 - use video_cards_radeonsi; then
375 - CONFIG_CHECK="~CHECKPOINT_RESTORE"
376 - linux-info_pkg_setup
377 - fi
378 -
379 - if use gallium && use llvm; then
380 - llvm_pkg_setup
381 - fi
382 - python-any-r1_pkg_setup
383 -}
384 -
385 -multilib_src_configure() {
386 - local emesonargs=()
387 -
388 - if use classic; then
389 - # Intel code
390 - dri_driver_enable video_cards_i915 i915
391 - dri_driver_enable video_cards_i965 i965
392 - if ! use video_cards_i915 && \
393 - ! use video_cards_i965; then
394 - dri_driver_enable video_cards_intel i915 i965
395 - fi
396 -
397 - # Nouveau code
398 - dri_driver_enable video_cards_nouveau nouveau
399 -
400 - # ATI code
401 - dri_driver_enable video_cards_r100 r100
402 - dri_driver_enable video_cards_r200 r200
403 - if ! use video_cards_r100 && \
404 - ! use video_cards_r200; then
405 - dri_driver_enable video_cards_radeon r100 r200
406 - fi
407 - fi
408 -
409 - emesonargs+=( -Dplatforms=$(use X && echo "x11,")$(use wayland && echo "wayland,")$(use gbm && echo "drm,")surfaceless )
410 -
411 - if use gallium; then
412 - emesonargs+=(
413 - $(meson_use llvm)
414 - $(meson_use lm-sensors lmsensors)
415 - $(meson_use unwind libunwind)
416 - )
417 -
418 - if use video_cards_iris ||
419 - use video_cards_r300 ||
420 - use video_cards_r600 ||
421 - use video_cards_radeonsi ||
422 - use video_cards_nouveau ||
423 - use video_cards_vmware; then
424 - emesonargs+=($(meson_use d3d9 gallium-nine))
425 - else
426 - emesonargs+=(-Dgallium-nine=false)
427 - fi
428 -
429 - if use video_cards_r600 ||
430 - use video_cards_radeonsi ||
431 - use video_cards_nouveau; then
432 - emesonargs+=($(meson_use vaapi gallium-va))
433 - use vaapi && emesonargs+=( -Dva-libs-path="${EPREFIX}"/usr/$(get_libdir)/va/drivers )
434 - else
435 - emesonargs+=(-Dgallium-va=false)
436 - fi
437 -
438 - if use video_cards_r300 ||
439 - use video_cards_r600 ||
440 - use video_cards_radeonsi ||
441 - use video_cards_nouveau; then
442 - emesonargs+=($(meson_use vdpau gallium-vdpau))
443 - else
444 - emesonargs+=(-Dgallium-vdpau=false)
445 - fi
446 -
447 - if use video_cards_freedreno ||
448 - use video_cards_nouveau ||
449 - use video_cards_vmware; then
450 - emesonargs+=($(meson_use xa gallium-xa))
451 - else
452 - emesonargs+=(-Dgallium-xa=false)
453 - fi
454 -
455 - if use video_cards_r600 ||
456 - use video_cards_nouveau; then
457 - emesonargs+=($(meson_use xvmc gallium-xvmc))
458 - else
459 - emesonargs+=(-Dgallium-xvmc=false)
460 - fi
461 -
462 - if use video_cards_freedreno ||
463 - use video_cards_lima ||
464 - use video_cards_panfrost ||
465 - use video_cards_vc4 ||
466 - use video_cards_vivante; then
467 - gallium_enable -- kmsro
468 - fi
469 -
470 - gallium_enable video_cards_lima lima
471 - gallium_enable video_cards_panfrost panfrost
472 - gallium_enable video_cards_vc4 vc4
473 - gallium_enable video_cards_vivante etnaviv
474 - gallium_enable video_cards_vmware svga
475 - gallium_enable video_cards_nouveau nouveau
476 -
477 - # Only one i915 driver (classic vs gallium). Default to classic.
478 - if ! use classic; then
479 - gallium_enable video_cards_i915 i915
480 - if ! use video_cards_i915 && \
481 - ! use video_cards_i965; then
482 - gallium_enable video_cards_intel i915
483 - fi
484 - fi
485 -
486 - gallium_enable video_cards_iris iris
487 -
488 - gallium_enable video_cards_r300 r300
489 - gallium_enable video_cards_r600 r600
490 - gallium_enable video_cards_radeonsi radeonsi
491 - if ! use video_cards_r300 && \
492 - ! use video_cards_r600; then
493 - gallium_enable video_cards_radeon r300 r600
494 - fi
495 -
496 - gallium_enable video_cards_freedreno freedreno
497 - gallium_enable video_cards_virgl virgl
498 -
499 - # opencl stuff
500 - emesonargs+=(
501 - -Dgallium-opencl="$(usex opencl icd disabled)"
502 - )
503 - fi
504 -
505 - if use vulkan; then
506 - vulkan_enable video_cards_i965 intel
507 - vulkan_enable video_cards_iris intel
508 - vulkan_enable video_cards_radeonsi amd
509 - fi
510 -
511 - if use gallium; then
512 - gallium_enable -- swrast
513 - emesonargs+=( -Dosmesa=$(usex osmesa gallium none) )
514 - else
515 - dri_driver_enable -- swrast
516 - emesonargs+=( -Dosmesa=$(usex osmesa classic none) )
517 - fi
518 -
519 - driver_list() {
520 - local drivers="$(sort -u <<< "${1// /$'\n'}")"
521 - echo "${drivers//$'\n'/,}"
522 - }
523 -
524 - emesonargs+=(
525 - $(meson_use test build-tests)
526 - -Dglx=$(usex X dri disabled)
527 - -Dshared-glapi=true
528 - $(meson_use dri3)
529 - $(meson_use egl)
530 - $(meson_use gbm)
531 - $(meson_use gles1)
532 - $(meson_use gles2)
533 - $(meson_use libglvnd glvnd)
534 - $(meson_use selinux)
535 - $(meson_use zstd)
536 - -Dvalgrind=$(usex valgrind auto false)
537 - -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}")
538 - -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}")
539 - -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}")
540 - $(meson_use vulkan vulkan-device-select-layer)
541 - $(meson_use vulkan-overlay vulkan-overlay-layer)
542 - --buildtype $(usex debug debug plain)
543 - -Db_ndebug=$(usex debug false true)
544 - )
545 - meson_src_configure
546 -}
547 -
548 -multilib_src_compile() {
549 - meson_src_compile
550 -}
551 -
552 -multilib_src_install() {
553 - meson_src_install
554 -}
555 -
556 -multilib_src_install_all() {
557 - einstalldocs
558 -}
559 -
560 -multilib_src_test() {
561 - meson test -v -C "${BUILD_DIR}" -t 100
562 -}
563 -
564 -pkg_postinst() {
565 - if ! use libglvnd; then
566 - # Switch to the xorg implementation.
567 - echo
568 - eselect opengl set --use-old ${OPENGL_DIR}
569 - fi
570 -}
571 -
572 -# $1 - VIDEO_CARDS flag (check skipped for "--")
573 -# other args - names of DRI drivers to enable
574 -dri_driver_enable() {
575 - if [[ $1 == -- ]] || use $1; then
576 - shift
577 - DRI_DRIVERS+=("$@")
578 - fi
579 -}
580 -
581 -gallium_enable() {
582 - if [[ $1 == -- ]] || use $1; then
583 - shift
584 - GALLIUM_DRIVERS+=("$@")
585 - fi
586 -}
587 -
588 -vulkan_enable() {
589 - if [[ $1 == -- ]] || use $1; then
590 - shift
591 - VULKAN_DRIVERS+=("$@")
592 - fi
593 -}
594
595 diff --git a/media-libs/mesa/mesa-20.1.5.ebuild b/media-libs/mesa/mesa-20.1.5.ebuild
596 deleted file mode 100644
597 index f50ead67947..00000000000
598 --- a/media-libs/mesa/mesa-20.1.5.ebuild
599 +++ /dev/null
600 @@ -1,557 +0,0 @@
601 -# Copyright 1999-2020 Gentoo Authors
602 -# Distributed under the terms of the GNU General Public License v2
603 -
604 -EAPI=7
605 -
606 -PYTHON_COMPAT=( python3_{6,7,8} )
607 -
608 -inherit llvm meson multilib-minimal python-any-r1 linux-info
609 -
610 -OPENGL_DIR="xorg-x11"
611 -
612 -MY_P="${P/_/-}"
613 -
614 -DESCRIPTION="OpenGL-like graphic library for Linux"
615 -HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/"
616 -
617 -if [[ ${PV} == 9999 ]]; then
618 - EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git"
619 - inherit git-r3
620 -else
621 - SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz"
622 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
623 -fi
624 -
625 -LICENSE="MIT"
626 -SLOT="0"
627 -RESTRICT="
628 - !test? ( test )
629 -"
630 -
631 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
632 -VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 intel iris lima nouveau panfrost vc4 virgl vivante vmware"
633 -for card in ${VIDEO_CARDS}; do
634 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
635 -done
636 -
637 -IUSE="${IUSE_VIDEO_CARDS}
638 - +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 +gles2 +libglvnd +llvm
639 - lm-sensors opencl osmesa selinux test unwind vaapi valgrind vdpau vulkan
640 - vulkan-overlay wayland +X xa xvmc +zstd"
641 -
642 -REQUIRED_USE="
643 - d3d9? ( dri3 || ( video_cards_iris video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) )
644 - gles1? ( egl )
645 - gles2? ( egl )
646 - vulkan? ( dri3
647 - video_cards_radeonsi? ( llvm ) )
648 - vulkan-overlay? ( vulkan )
649 - wayland? ( egl gbm )
650 - video_cards_freedreno? ( gallium )
651 - video_cards_intel? ( classic )
652 - video_cards_i915? ( || ( classic gallium ) )
653 - video_cards_i965? ( classic )
654 - video_cards_iris? ( gallium )
655 - video_cards_lima? ( gallium )
656 - video_cards_nouveau? ( || ( classic gallium ) )
657 - video_cards_panfrost? ( gallium )
658 - video_cards_radeon? ( || ( classic gallium )
659 - gallium? ( x86? ( llvm ) amd64? ( llvm ) ) )
660 - video_cards_r100? ( classic )
661 - video_cards_r200? ( classic )
662 - video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) )
663 - video_cards_r600? ( gallium )
664 - video_cards_radeonsi? ( gallium llvm )
665 - video_cards_vc4? ( gallium )
666 - video_cards_virgl? ( gallium )
667 - video_cards_vivante? ( gallium gbm )
668 - video_cards_vmware? ( gallium )
669 - xa? ( X )
670 - xvmc? ( X )
671 -"
672 -
673 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.100"
674 -RDEPEND="
675 - !app-eselect/eselect-mesa
676 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
677 - >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}]
678 - libglvnd? (
679 - >=media-libs/libglvnd-1.2.0-r1[X?,${MULTILIB_USEDEP}]
680 - !app-eselect/eselect-opengl
681 - )
682 - !libglvnd? (
683 - >=app-eselect/eselect-opengl-1.3.0
684 - )
685 - gallium? (
686 - unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] )
687 - llvm? (
688 - video_cards_radeonsi? (
689 - virtual/libelf:0=[${MULTILIB_USEDEP}]
690 - )
691 - video_cards_r600? (
692 - virtual/libelf:0=[${MULTILIB_USEDEP}]
693 - )
694 - video_cards_radeon? (
695 - virtual/libelf:0=[${MULTILIB_USEDEP}]
696 - )
697 - )
698 - lm-sensors? ( sys-apps/lm-sensors:=[${MULTILIB_USEDEP}] )
699 - opencl? (
700 - >=virtual/opencl-3[${MULTILIB_USEDEP}]
701 - dev-libs/libclc
702 - virtual/libelf:0=[${MULTILIB_USEDEP}]
703 - )
704 - vaapi? (
705 - >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}]
706 - )
707 - vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
708 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
709 - )
710 - selinux? ( sys-libs/libselinux[${MULTILIB_USEDEP}] )
711 - wayland? (
712 - >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}]
713 - >=dev-libs/wayland-protocols-1.8
714 - )
715 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}]
716 - video_cards_intel? (
717 - !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
718 - )
719 - video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
720 - vulkan-overlay? ( dev-util/glslang:0=[${MULTILIB_USEDEP}] )
721 - X? (
722 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
723 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
724 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
725 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
726 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
727 - >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}]
728 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
729 - )
730 - zstd? ( app-arch/zstd:=[${MULTILIB_USEDEP}] )
731 -"
732 -for card in ${RADEON_CARDS}; do
733 - RDEPEND="${RDEPEND}
734 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
735 - "
736 -done
737 -RDEPEND="${RDEPEND}
738 - video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
739 -"
740 -
741 -# Please keep the LLVM dependency block separate. Since LLVM is slotted,
742 -# we need to *really* make sure we're not pulling one than more slot
743 -# simultaneously.
744 -#
745 -# How to use it:
746 -# 1. List all the working slots (with min versions) in ||, newest first.
747 -# 2. Update the := to specify *max* version, e.g. < 10.
748 -# 3. Specify LLVM_MAX_SLOT, e.g. 9.
749 -LLVM_MAX_SLOT="10"
750 -LLVM_DEPSTR="
751 - || (
752 - sys-devel/llvm:10[${MULTILIB_USEDEP}]
753 - sys-devel/llvm:9[${MULTILIB_USEDEP}]
754 - )
755 - <sys-devel/llvm-$((LLVM_MAX_SLOT + 1)):=[${MULTILIB_USEDEP}]
756 -"
757 -LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
758 -CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang}
759 -CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
760 -RDEPEND="${RDEPEND}
761 - gallium? (
762 - llvm? (
763 - opencl? (
764 - video_cards_r600? (
765 - ${CLANG_DEPSTR_AMDGPU}
766 - )
767 - !video_cards_r600? (
768 - video_cards_radeonsi? (
769 - ${CLANG_DEPSTR_AMDGPU}
770 - )
771 - )
772 - !video_cards_r600? (
773 - !video_cards_radeonsi? (
774 - video_cards_radeon? (
775 - ${CLANG_DEPSTR_AMDGPU}
776 - )
777 - )
778 - )
779 - !video_cards_r600? (
780 - !video_cards_radeon? (
781 - !video_cards_radeonsi? (
782 - ${CLANG_DEPSTR}
783 - )
784 - )
785 - )
786 - )
787 - !opencl? (
788 - video_cards_r600? (
789 - ${LLVM_DEPSTR_AMDGPU}
790 - )
791 - !video_cards_r600? (
792 - video_cards_radeonsi? (
793 - ${LLVM_DEPSTR_AMDGPU}
794 - )
795 - )
796 - !video_cards_r600? (
797 - !video_cards_radeonsi? (
798 - video_cards_radeon? (
799 - ${LLVM_DEPSTR_AMDGPU}
800 - )
801 - )
802 - )
803 - !video_cards_r600? (
804 - !video_cards_radeon? (
805 - !video_cards_radeonsi? (
806 - ${LLVM_DEPSTR}
807 - )
808 - )
809 - )
810 - )
811 - )
812 - )
813 -"
814 -unset {LLVM,CLANG}_DEPSTR{,_AMDGPU}
815 -
816 -DEPEND="${RDEPEND}
817 - valgrind? ( dev-util/valgrind )
818 - X? (
819 - x11-libs/libXrandr[${MULTILIB_USEDEP}]
820 - x11-base/xorg-proto
821 - )
822 -"
823 -BDEPEND="
824 - ${PYTHON_DEPS}
825 - opencl? (
826 - >=sys-devel/gcc-4.6
827 - )
828 - sys-devel/bison
829 - sys-devel/flex
830 - sys-devel/gettext
831 - virtual/pkgconfig
832 - $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]")
833 -"
834 -
835 -S="${WORKDIR}/${MY_P}"
836 -EGIT_CHECKOUT_DIR=${S}
837 -
838 -QA_WX_LOAD="
839 -x86? (
840 - usr/lib*/libglapi.so.0.0.0
841 - usr/lib*/libGLESv1_CM.so.1.1.0
842 - usr/lib*/libGLESv2.so.2.0.0
843 - usr/lib*/libGL.so.1.2.0
844 - usr/lib*/libOSMesa.so.8.0.0
845 - libglvnd? ( usr/lib/libGLX_mesa.so.0.0.0 )
846 -)"
847 -
848 -llvm_check_deps() {
849 - local flags=${MULTILIB_USEDEP}
850 - if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi
851 - then
852 - flags+=",llvm_targets_AMDGPU(-)"
853 - fi
854 -
855 - if use opencl; then
856 - has_version "sys-devel/clang:${LLVM_SLOT}[${flags}]" || return 1
857 - fi
858 - has_version "sys-devel/llvm:${LLVM_SLOT}[${flags}]"
859 -}
860 -
861 -pkg_pretend() {
862 - if use vulkan; then
863 - if ! use video_cards_i965 &&
864 - ! use video_cards_iris &&
865 - ! use video_cards_radeonsi; then
866 - ewarn "Ignoring USE=vulkan since VIDEO_CARDS does not contain i965, iris, or radeonsi"
867 - fi
868 - fi
869 -
870 - if use opencl; then
871 - if ! use video_cards_r600 &&
872 - ! use video_cards_radeonsi; then
873 - ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi"
874 - fi
875 - fi
876 -
877 - if use vaapi; then
878 - if ! use video_cards_r600 &&
879 - ! use video_cards_radeonsi &&
880 - ! use video_cards_nouveau; then
881 - ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau"
882 - fi
883 - fi
884 -
885 - if use vdpau; then
886 - if ! use video_cards_r300 &&
887 - ! use video_cards_r600 &&
888 - ! use video_cards_radeonsi &&
889 - ! use video_cards_nouveau; then
890 - ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau"
891 - fi
892 - fi
893 -
894 - if use xa; then
895 - if ! use video_cards_freedreno &&
896 - ! use video_cards_nouveau &&
897 - ! use video_cards_vmware; then
898 - ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware"
899 - fi
900 - fi
901 -
902 - if use xvmc; then
903 - if ! use video_cards_r600 &&
904 - ! use video_cards_nouveau; then
905 - ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau"
906 - fi
907 - fi
908 -
909 - if ! use gallium; then
910 - use lm-sensors && ewarn "Ignoring USE=lm-sensors since USE does not contain gallium"
911 - use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium"
912 - use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium"
913 - use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium"
914 - use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium"
915 - use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium"
916 - use xa && ewarn "Ignoring USE=xa since USE does not contain gallium"
917 - use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium"
918 - fi
919 -
920 - if ! use llvm; then
921 - use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm"
922 - fi
923 -}
924 -
925 -python_check_deps() {
926 - has_version -b ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]"
927 -}
928 -
929 -pkg_setup() {
930 - # warning message for bug 459306
931 - if use llvm && has_version sys-devel/llvm[!debug=]; then
932 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
933 - ewarn "detected! This can cause problems. For details, see bug 459306."
934 - fi
935 -
936 - if use video_cards_i965 ||
937 - use video_cards_iris ||
938 - use video_cards_radeonsi; then
939 - CONFIG_CHECK="~CHECKPOINT_RESTORE"
940 - linux-info_pkg_setup
941 - fi
942 -
943 - if use gallium && use llvm; then
944 - llvm_pkg_setup
945 - fi
946 - python-any-r1_pkg_setup
947 -}
948 -
949 -multilib_src_configure() {
950 - local emesonargs=()
951 -
952 - if use classic; then
953 - # Intel code
954 - dri_driver_enable video_cards_i915 i915
955 - dri_driver_enable video_cards_i965 i965
956 - if ! use video_cards_i915 && \
957 - ! use video_cards_i965; then
958 - dri_driver_enable video_cards_intel i915 i965
959 - fi
960 -
961 - # Nouveau code
962 - dri_driver_enable video_cards_nouveau nouveau
963 -
964 - # ATI code
965 - dri_driver_enable video_cards_r100 r100
966 - dri_driver_enable video_cards_r200 r200
967 - if ! use video_cards_r100 && \
968 - ! use video_cards_r200; then
969 - dri_driver_enable video_cards_radeon r100 r200
970 - fi
971 - fi
972 -
973 - emesonargs+=( -Dplatforms=$(use X && echo "x11,")$(use wayland && echo "wayland,")$(use gbm && echo "drm,")surfaceless )
974 -
975 - if use gallium; then
976 - emesonargs+=(
977 - $(meson_use llvm)
978 - $(meson_use lm-sensors lmsensors)
979 - $(meson_use unwind libunwind)
980 - )
981 -
982 - if use video_cards_iris ||
983 - use video_cards_r300 ||
984 - use video_cards_r600 ||
985 - use video_cards_radeonsi ||
986 - use video_cards_nouveau ||
987 - use video_cards_vmware; then
988 - emesonargs+=($(meson_use d3d9 gallium-nine))
989 - else
990 - emesonargs+=(-Dgallium-nine=false)
991 - fi
992 -
993 - if use video_cards_r600 ||
994 - use video_cards_radeonsi ||
995 - use video_cards_nouveau; then
996 - emesonargs+=($(meson_use vaapi gallium-va))
997 - use vaapi && emesonargs+=( -Dva-libs-path="${EPREFIX}"/usr/$(get_libdir)/va/drivers )
998 - else
999 - emesonargs+=(-Dgallium-va=false)
1000 - fi
1001 -
1002 - if use video_cards_r300 ||
1003 - use video_cards_r600 ||
1004 - use video_cards_radeonsi ||
1005 - use video_cards_nouveau; then
1006 - emesonargs+=($(meson_use vdpau gallium-vdpau))
1007 - else
1008 - emesonargs+=(-Dgallium-vdpau=false)
1009 - fi
1010 -
1011 - if use video_cards_freedreno ||
1012 - use video_cards_nouveau ||
1013 - use video_cards_vmware; then
1014 - emesonargs+=($(meson_use xa gallium-xa))
1015 - else
1016 - emesonargs+=(-Dgallium-xa=false)
1017 - fi
1018 -
1019 - if use video_cards_r600 ||
1020 - use video_cards_nouveau; then
1021 - emesonargs+=($(meson_use xvmc gallium-xvmc))
1022 - else
1023 - emesonargs+=(-Dgallium-xvmc=false)
1024 - fi
1025 -
1026 - if use video_cards_freedreno ||
1027 - use video_cards_lima ||
1028 - use video_cards_panfrost ||
1029 - use video_cards_vc4 ||
1030 - use video_cards_vivante; then
1031 - gallium_enable -- kmsro
1032 - fi
1033 -
1034 - gallium_enable video_cards_lima lima
1035 - gallium_enable video_cards_panfrost panfrost
1036 - gallium_enable video_cards_vc4 vc4
1037 - gallium_enable video_cards_vivante etnaviv
1038 - gallium_enable video_cards_vmware svga
1039 - gallium_enable video_cards_nouveau nouveau
1040 -
1041 - # Only one i915 driver (classic vs gallium). Default to classic.
1042 - if ! use classic; then
1043 - gallium_enable video_cards_i915 i915
1044 - if ! use video_cards_i915 && \
1045 - ! use video_cards_i965; then
1046 - gallium_enable video_cards_intel i915
1047 - fi
1048 - fi
1049 -
1050 - gallium_enable video_cards_iris iris
1051 -
1052 - gallium_enable video_cards_r300 r300
1053 - gallium_enable video_cards_r600 r600
1054 - gallium_enable video_cards_radeonsi radeonsi
1055 - if ! use video_cards_r300 && \
1056 - ! use video_cards_r600; then
1057 - gallium_enable video_cards_radeon r300 r600
1058 - fi
1059 -
1060 - gallium_enable video_cards_freedreno freedreno
1061 - gallium_enable video_cards_virgl virgl
1062 -
1063 - # opencl stuff
1064 - emesonargs+=(
1065 - -Dgallium-opencl="$(usex opencl icd disabled)"
1066 - )
1067 - fi
1068 -
1069 - if use vulkan; then
1070 - vulkan_enable video_cards_i965 intel
1071 - vulkan_enable video_cards_iris intel
1072 - vulkan_enable video_cards_radeonsi amd
1073 - fi
1074 -
1075 - if use gallium; then
1076 - gallium_enable -- swrast
1077 - emesonargs+=( -Dosmesa=$(usex osmesa gallium none) )
1078 - else
1079 - dri_driver_enable -- swrast
1080 - emesonargs+=( -Dosmesa=$(usex osmesa classic none) )
1081 - fi
1082 -
1083 - driver_list() {
1084 - local drivers="$(sort -u <<< "${1// /$'\n'}")"
1085 - echo "${drivers//$'\n'/,}"
1086 - }
1087 -
1088 - emesonargs+=(
1089 - $(meson_use test build-tests)
1090 - -Dglx=$(usex X dri disabled)
1091 - -Dshared-glapi=true
1092 - $(meson_use dri3)
1093 - $(meson_use egl)
1094 - $(meson_use gbm)
1095 - $(meson_use gles1)
1096 - $(meson_use gles2)
1097 - $(meson_use libglvnd glvnd)
1098 - $(meson_use selinux)
1099 - $(meson_use zstd)
1100 - -Dvalgrind=$(usex valgrind auto false)
1101 - -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}")
1102 - -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}")
1103 - -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}")
1104 - $(meson_use vulkan vulkan-device-select-layer)
1105 - $(meson_use vulkan-overlay vulkan-overlay-layer)
1106 - --buildtype $(usex debug debug plain)
1107 - -Db_ndebug=$(usex debug false true)
1108 - )
1109 - meson_src_configure
1110 -}
1111 -
1112 -multilib_src_compile() {
1113 - meson_src_compile
1114 -}
1115 -
1116 -multilib_src_install() {
1117 - meson_src_install
1118 -}
1119 -
1120 -multilib_src_install_all() {
1121 - einstalldocs
1122 -}
1123 -
1124 -multilib_src_test() {
1125 - meson test -v -C "${BUILD_DIR}" -t 100
1126 -}
1127 -
1128 -pkg_postinst() {
1129 - if ! use libglvnd; then
1130 - # Switch to the xorg implementation.
1131 - echo
1132 - eselect opengl set --use-old ${OPENGL_DIR}
1133 - fi
1134 -}
1135 -
1136 -# $1 - VIDEO_CARDS flag (check skipped for "--")
1137 -# other args - names of DRI drivers to enable
1138 -dri_driver_enable() {
1139 - if [[ $1 == -- ]] || use $1; then
1140 - shift
1141 - DRI_DRIVERS+=("$@")
1142 - fi
1143 -}
1144 -
1145 -gallium_enable() {
1146 - if [[ $1 == -- ]] || use $1; then
1147 - shift
1148 - GALLIUM_DRIVERS+=("$@")
1149 - fi
1150 -}
1151 -
1152 -vulkan_enable() {
1153 - if [[ $1 == -- ]] || use $1; then
1154 - shift
1155 - VULKAN_DRIVERS+=("$@")
1156 - fi
1157 -}
1158
1159 diff --git a/media-libs/mesa/mesa-20.2.0_rc1.ebuild b/media-libs/mesa/mesa-20.2.0_rc1.ebuild
1160 deleted file mode 100644
1161 index ebb32fce460..00000000000
1162 --- a/media-libs/mesa/mesa-20.2.0_rc1.ebuild
1163 +++ /dev/null
1164 @@ -1,565 +0,0 @@
1165 -# Copyright 1999-2020 Gentoo Authors
1166 -# Distributed under the terms of the GNU General Public License v2
1167 -
1168 -EAPI=7
1169 -
1170 -PYTHON_COMPAT=( python3_{6,7,8} )
1171 -
1172 -inherit llvm meson multilib-minimal python-any-r1 linux-info
1173 -
1174 -OPENGL_DIR="xorg-x11"
1175 -
1176 -MY_P="${P/_/-}"
1177 -
1178 -DESCRIPTION="OpenGL-like graphic library for Linux"
1179 -HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/"
1180 -
1181 -if [[ ${PV} == 9999 ]]; then
1182 - EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git"
1183 - inherit git-r3
1184 -else
1185 - SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz"
1186 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
1187 -fi
1188 -
1189 -LICENSE="MIT"
1190 -SLOT="0"
1191 -RESTRICT="
1192 - !test? ( test )
1193 -"
1194 -
1195 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
1196 -VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 intel iris lima nouveau panfrost v3d vc4 virgl vivante vmware"
1197 -for card in ${VIDEO_CARDS}; do
1198 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
1199 -done
1200 -
1201 -IUSE="${IUSE_VIDEO_CARDS}
1202 - +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 +gles2 +libglvnd +llvm
1203 - lm-sensors opencl osmesa selinux test unwind vaapi valgrind vdpau vulkan
1204 - vulkan-overlay wayland +X xa xvmc zink +zstd"
1205 -
1206 -REQUIRED_USE="
1207 - d3d9? ( dri3 || ( video_cards_iris video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) )
1208 - gles1? ( egl )
1209 - gles2? ( egl )
1210 - vulkan? ( dri3
1211 - video_cards_radeonsi? ( llvm ) )
1212 - vulkan-overlay? ( vulkan )
1213 - wayland? ( egl gbm )
1214 - video_cards_freedreno? ( gallium )
1215 - video_cards_intel? ( classic )
1216 - video_cards_i915? ( || ( classic gallium ) )
1217 - video_cards_i965? ( classic )
1218 - video_cards_iris? ( gallium )
1219 - video_cards_lima? ( gallium )
1220 - video_cards_nouveau? ( || ( classic gallium ) )
1221 - video_cards_panfrost? ( gallium )
1222 - video_cards_radeon? ( || ( classic gallium )
1223 - gallium? ( x86? ( llvm ) amd64? ( llvm ) ) )
1224 - video_cards_r100? ( classic )
1225 - video_cards_r200? ( classic )
1226 - video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) )
1227 - video_cards_r600? ( gallium )
1228 - video_cards_radeonsi? ( gallium llvm )
1229 - video_cards_v3d? ( gallium )
1230 - video_cards_vc4? ( gallium )
1231 - video_cards_virgl? ( gallium )
1232 - video_cards_vivante? ( gallium gbm )
1233 - video_cards_vmware? ( gallium )
1234 - xa? ( X )
1235 - xvmc? ( X )
1236 - zink? ( gallium vulkan )
1237 -"
1238 -
1239 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.100"
1240 -RDEPEND="
1241 - !app-eselect/eselect-mesa
1242 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
1243 - >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}]
1244 - libglvnd? (
1245 - >=media-libs/libglvnd-1.2.0-r1[X?,${MULTILIB_USEDEP}]
1246 - !app-eselect/eselect-opengl
1247 - )
1248 - !libglvnd? (
1249 - >=app-eselect/eselect-opengl-1.3.0
1250 - )
1251 - gallium? (
1252 - unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] )
1253 - llvm? (
1254 - video_cards_radeonsi? (
1255 - virtual/libelf:0=[${MULTILIB_USEDEP}]
1256 - )
1257 - video_cards_r600? (
1258 - virtual/libelf:0=[${MULTILIB_USEDEP}]
1259 - )
1260 - video_cards_radeon? (
1261 - virtual/libelf:0=[${MULTILIB_USEDEP}]
1262 - )
1263 - )
1264 - lm-sensors? ( sys-apps/lm-sensors:=[${MULTILIB_USEDEP}] )
1265 - opencl? (
1266 - >=virtual/opencl-3[${MULTILIB_USEDEP}]
1267 - dev-libs/libclc
1268 - virtual/libelf:0=[${MULTILIB_USEDEP}]
1269 - )
1270 - vaapi? (
1271 - >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}]
1272 - )
1273 - vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
1274 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
1275 - )
1276 - selinux? ( sys-libs/libselinux[${MULTILIB_USEDEP}] )
1277 - wayland? (
1278 - >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}]
1279 - >=dev-libs/wayland-protocols-1.8
1280 - )
1281 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}]
1282 - video_cards_intel? (
1283 - !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
1284 - )
1285 - video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
1286 - vulkan-overlay? ( dev-util/glslang:0=[${MULTILIB_USEDEP}] )
1287 - X? (
1288 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
1289 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
1290 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
1291 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
1292 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
1293 - >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}]
1294 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
1295 - )
1296 - zink? ( media-libs/vulkan-loader:=[${MULTILIB_USEDEP}] )
1297 - zstd? ( app-arch/zstd:=[${MULTILIB_USEDEP}] )
1298 -"
1299 -for card in ${RADEON_CARDS}; do
1300 - RDEPEND="${RDEPEND}
1301 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
1302 - "
1303 -done
1304 -RDEPEND="${RDEPEND}
1305 - video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
1306 -"
1307 -
1308 -# Please keep the LLVM dependency block separate. Since LLVM is slotted,
1309 -# we need to *really* make sure we're not pulling one than more slot
1310 -# simultaneously.
1311 -#
1312 -# How to use it:
1313 -# 1. List all the working slots (with min versions) in ||, newest first.
1314 -# 2. Update the := to specify *max* version, e.g. < 10.
1315 -# 3. Specify LLVM_MAX_SLOT, e.g. 9.
1316 -LLVM_MAX_SLOT="10"
1317 -LLVM_DEPSTR="
1318 - || (
1319 - sys-devel/llvm:10[${MULTILIB_USEDEP}]
1320 - sys-devel/llvm:9[${MULTILIB_USEDEP}]
1321 - )
1322 - <sys-devel/llvm-$((LLVM_MAX_SLOT + 1)):=[${MULTILIB_USEDEP}]
1323 -"
1324 -LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
1325 -CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang}
1326 -CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
1327 -RDEPEND="${RDEPEND}
1328 - gallium? (
1329 - llvm? (
1330 - opencl? (
1331 - video_cards_r600? (
1332 - ${CLANG_DEPSTR_AMDGPU}
1333 - )
1334 - !video_cards_r600? (
1335 - video_cards_radeonsi? (
1336 - ${CLANG_DEPSTR_AMDGPU}
1337 - )
1338 - )
1339 - !video_cards_r600? (
1340 - !video_cards_radeonsi? (
1341 - video_cards_radeon? (
1342 - ${CLANG_DEPSTR_AMDGPU}
1343 - )
1344 - )
1345 - )
1346 - !video_cards_r600? (
1347 - !video_cards_radeon? (
1348 - !video_cards_radeonsi? (
1349 - ${CLANG_DEPSTR}
1350 - )
1351 - )
1352 - )
1353 - )
1354 - !opencl? (
1355 - video_cards_r600? (
1356 - ${LLVM_DEPSTR_AMDGPU}
1357 - )
1358 - !video_cards_r600? (
1359 - video_cards_radeonsi? (
1360 - ${LLVM_DEPSTR_AMDGPU}
1361 - )
1362 - )
1363 - !video_cards_r600? (
1364 - !video_cards_radeonsi? (
1365 - video_cards_radeon? (
1366 - ${LLVM_DEPSTR_AMDGPU}
1367 - )
1368 - )
1369 - )
1370 - !video_cards_r600? (
1371 - !video_cards_radeon? (
1372 - !video_cards_radeonsi? (
1373 - ${LLVM_DEPSTR}
1374 - )
1375 - )
1376 - )
1377 - )
1378 - )
1379 - )
1380 -"
1381 -unset {LLVM,CLANG}_DEPSTR{,_AMDGPU}
1382 -
1383 -DEPEND="${RDEPEND}
1384 - valgrind? ( dev-util/valgrind )
1385 - X? (
1386 - x11-libs/libXrandr[${MULTILIB_USEDEP}]
1387 - x11-base/xorg-proto
1388 - )
1389 -"
1390 -BDEPEND="
1391 - ${PYTHON_DEPS}
1392 - opencl? (
1393 - >=sys-devel/gcc-4.6
1394 - )
1395 - sys-devel/bison
1396 - sys-devel/flex
1397 - virtual/pkgconfig
1398 - $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]")
1399 -"
1400 -
1401 -S="${WORKDIR}/${MY_P}"
1402 -EGIT_CHECKOUT_DIR=${S}
1403 -
1404 -QA_WX_LOAD="
1405 -x86? (
1406 - usr/lib*/libglapi.so.0.0.0
1407 - usr/lib*/libGLESv1_CM.so.1.1.0
1408 - usr/lib*/libGLESv2.so.2.0.0
1409 - usr/lib*/libGL.so.1.2.0
1410 - usr/lib*/libOSMesa.so.8.0.0
1411 - libglvnd? ( usr/lib/libGLX_mesa.so.0.0.0 )
1412 -)"
1413 -
1414 -llvm_check_deps() {
1415 - local flags=${MULTILIB_USEDEP}
1416 - if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi
1417 - then
1418 - flags+=",llvm_targets_AMDGPU(-)"
1419 - fi
1420 -
1421 - if use opencl; then
1422 - has_version "sys-devel/clang:${LLVM_SLOT}[${flags}]" || return 1
1423 - fi
1424 - has_version "sys-devel/llvm:${LLVM_SLOT}[${flags}]"
1425 -}
1426 -
1427 -pkg_pretend() {
1428 - if use vulkan; then
1429 - if ! use video_cards_i965 &&
1430 - ! use video_cards_iris &&
1431 - ! use video_cards_radeonsi; then
1432 - ewarn "Ignoring USE=vulkan since VIDEO_CARDS does not contain i965, iris, or radeonsi"
1433 - fi
1434 - fi
1435 -
1436 - if use opencl; then
1437 - if ! use video_cards_r600 &&
1438 - ! use video_cards_radeonsi; then
1439 - ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi"
1440 - fi
1441 - fi
1442 -
1443 - if use vaapi; then
1444 - if ! use video_cards_r600 &&
1445 - ! use video_cards_radeonsi &&
1446 - ! use video_cards_nouveau; then
1447 - ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau"
1448 - fi
1449 - fi
1450 -
1451 - if use vdpau; then
1452 - if ! use video_cards_r300 &&
1453 - ! use video_cards_r600 &&
1454 - ! use video_cards_radeonsi &&
1455 - ! use video_cards_nouveau; then
1456 - ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau"
1457 - fi
1458 - fi
1459 -
1460 - if use xa; then
1461 - if ! use video_cards_freedreno &&
1462 - ! use video_cards_nouveau &&
1463 - ! use video_cards_vmware; then
1464 - ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware"
1465 - fi
1466 - fi
1467 -
1468 - if use xvmc; then
1469 - if ! use video_cards_r600 &&
1470 - ! use video_cards_nouveau; then
1471 - ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau"
1472 - fi
1473 - fi
1474 -
1475 - if ! use gallium; then
1476 - use lm-sensors && ewarn "Ignoring USE=lm-sensors since USE does not contain gallium"
1477 - use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium"
1478 - use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium"
1479 - use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium"
1480 - use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium"
1481 - use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium"
1482 - use xa && ewarn "Ignoring USE=xa since USE does not contain gallium"
1483 - use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium"
1484 - fi
1485 -
1486 - if ! use llvm; then
1487 - use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm"
1488 - fi
1489 -}
1490 -
1491 -python_check_deps() {
1492 - has_version -b ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]"
1493 -}
1494 -
1495 -pkg_setup() {
1496 - # warning message for bug 459306
1497 - if use llvm && has_version sys-devel/llvm[!debug=]; then
1498 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
1499 - ewarn "detected! This can cause problems. For details, see bug 459306."
1500 - fi
1501 -
1502 - if use video_cards_i965 ||
1503 - use video_cards_iris ||
1504 - use video_cards_radeonsi; then
1505 - CONFIG_CHECK="~CHECKPOINT_RESTORE"
1506 - linux-info_pkg_setup
1507 - fi
1508 -
1509 - if use gallium && use llvm; then
1510 - llvm_pkg_setup
1511 - fi
1512 - python-any-r1_pkg_setup
1513 -}
1514 -
1515 -multilib_src_configure() {
1516 - local emesonargs=()
1517 -
1518 - if use classic; then
1519 - # Intel code
1520 - dri_driver_enable video_cards_i915 i915
1521 - dri_driver_enable video_cards_i965 i965
1522 - if ! use video_cards_i915 && \
1523 - ! use video_cards_i965; then
1524 - dri_driver_enable video_cards_intel i915 i965
1525 - fi
1526 -
1527 - # Nouveau code
1528 - dri_driver_enable video_cards_nouveau nouveau
1529 -
1530 - # ATI code
1531 - dri_driver_enable video_cards_r100 r100
1532 - dri_driver_enable video_cards_r200 r200
1533 - if ! use video_cards_r100 && \
1534 - ! use video_cards_r200; then
1535 - dri_driver_enable video_cards_radeon r100 r200
1536 - fi
1537 - fi
1538 -
1539 - local platforms
1540 - use X && platforms+="x11"
1541 - use wayland && platforms+=",wayland"
1542 - [[ -n $platforms ]] && emesonargs+=(-Dplatforms=${platforms#,})
1543 -
1544 - if use gallium; then
1545 - emesonargs+=(
1546 - $(meson_feature llvm)
1547 - $(meson_feature lm-sensors lmsensors)
1548 - $(meson_feature unwind libunwind)
1549 - )
1550 -
1551 - if use video_cards_iris ||
1552 - use video_cards_r300 ||
1553 - use video_cards_r600 ||
1554 - use video_cards_radeonsi ||
1555 - use video_cards_nouveau ||
1556 - use video_cards_vmware; then
1557 - emesonargs+=($(meson_use d3d9 gallium-nine))
1558 - else
1559 - emesonargs+=(-Dgallium-nine=false)
1560 - fi
1561 -
1562 - if use video_cards_r600 ||
1563 - use video_cards_radeonsi ||
1564 - use video_cards_nouveau; then
1565 - emesonargs+=($(meson_feature vaapi gallium-va))
1566 - use vaapi && emesonargs+=( -Dva-libs-path="${EPREFIX}"/usr/$(get_libdir)/va/drivers )
1567 - else
1568 - emesonargs+=(-Dgallium-va=disabled)
1569 - fi
1570 -
1571 - if use video_cards_r300 ||
1572 - use video_cards_r600 ||
1573 - use video_cards_radeonsi ||
1574 - use video_cards_nouveau; then
1575 - emesonargs+=($(meson_feature vdpau gallium-vdpau))
1576 - else
1577 - emesonargs+=(-Dgallium-vdpau=disabled)
1578 - fi
1579 -
1580 - if use video_cards_freedreno ||
1581 - use video_cards_nouveau ||
1582 - use video_cards_vmware; then
1583 - emesonargs+=($(meson_feature xa gallium-xa))
1584 - else
1585 - emesonargs+=(-Dgallium-xa=disabled)
1586 - fi
1587 -
1588 - if use video_cards_r600 ||
1589 - use video_cards_nouveau; then
1590 - emesonargs+=($(meson_feature xvmc gallium-xvmc))
1591 - else
1592 - emesonargs+=(-Dgallium-xvmc=disabled)
1593 - fi
1594 -
1595 - if use video_cards_freedreno ||
1596 - use video_cards_lima ||
1597 - use video_cards_panfrost ||
1598 - use video_cards_v3d ||
1599 - use video_cards_vc4 ||
1600 - use video_cards_vivante; then
1601 - gallium_enable -- kmsro
1602 - fi
1603 -
1604 - gallium_enable video_cards_lima lima
1605 - gallium_enable video_cards_panfrost panfrost
1606 - gallium_enable video_cards_v3d v3d
1607 - gallium_enable video_cards_vc4 vc4
1608 - gallium_enable video_cards_vivante etnaviv
1609 - gallium_enable video_cards_vmware svga
1610 - gallium_enable video_cards_nouveau nouveau
1611 - gallium_enable zink zink
1612 -
1613 - # Only one i915 driver (classic vs gallium). Default to classic.
1614 - if ! use classic; then
1615 - gallium_enable video_cards_i915 i915
1616 - if ! use video_cards_i915 && \
1617 - ! use video_cards_i965; then
1618 - gallium_enable video_cards_intel i915
1619 - fi
1620 - fi
1621 -
1622 - gallium_enable video_cards_iris iris
1623 -
1624 - gallium_enable video_cards_r300 r300
1625 - gallium_enable video_cards_r600 r600
1626 - gallium_enable video_cards_radeonsi radeonsi
1627 - if ! use video_cards_r300 && \
1628 - ! use video_cards_r600; then
1629 - gallium_enable video_cards_radeon r300 r600
1630 - fi
1631 -
1632 - gallium_enable video_cards_freedreno freedreno
1633 - gallium_enable video_cards_virgl virgl
1634 -
1635 - # opencl stuff
1636 - emesonargs+=(
1637 - -Dgallium-opencl="$(usex opencl icd disabled)"
1638 - )
1639 - fi
1640 -
1641 - if use vulkan; then
1642 - vulkan_enable video_cards_i965 intel
1643 - vulkan_enable video_cards_iris intel
1644 - vulkan_enable video_cards_radeonsi amd
1645 - fi
1646 -
1647 - if use gallium; then
1648 - gallium_enable -- swrast
1649 - emesonargs+=( -Dosmesa=$(usex osmesa gallium none) )
1650 - else
1651 - dri_driver_enable -- swrast
1652 - emesonargs+=( -Dosmesa=$(usex osmesa classic none) )
1653 - fi
1654 -
1655 - driver_list() {
1656 - local drivers="$(sort -u <<< "${1// /$'\n'}")"
1657 - echo "${drivers//$'\n'/,}"
1658 - }
1659 -
1660 - emesonargs+=(
1661 - $(meson_use test build-tests)
1662 - -Dglx=$(usex X dri disabled)
1663 - -Dshared-glapi=enabled
1664 - $(meson_feature dri3)
1665 - $(meson_feature egl)
1666 - $(meson_feature gbm)
1667 - $(meson_feature gles1)
1668 - $(meson_feature gles2)
1669 - $(meson_use libglvnd glvnd)
1670 - $(meson_use selinux)
1671 - $(meson_feature zstd)
1672 - -Dvalgrind=$(usex valgrind auto false)
1673 - -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}")
1674 - -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}")
1675 - -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}")
1676 - $(meson_use vulkan vulkan-device-select-layer)
1677 - $(meson_use vulkan-overlay vulkan-overlay-layer)
1678 - --buildtype $(usex debug debug plain)
1679 - -Db_ndebug=$(usex debug false true)
1680 - )
1681 - meson_src_configure
1682 -}
1683 -
1684 -multilib_src_compile() {
1685 - meson_src_compile
1686 -}
1687 -
1688 -multilib_src_install() {
1689 - meson_src_install
1690 -}
1691 -
1692 -multilib_src_install_all() {
1693 - einstalldocs
1694 -}
1695 -
1696 -multilib_src_test() {
1697 - meson test -v -C "${BUILD_DIR}" -t 100
1698 -}
1699 -
1700 -pkg_postinst() {
1701 - if ! use libglvnd; then
1702 - # Switch to the xorg implementation.
1703 - echo
1704 - eselect opengl set --use-old ${OPENGL_DIR}
1705 - fi
1706 -}
1707 -
1708 -# $1 - VIDEO_CARDS flag (check skipped for "--")
1709 -# other args - names of DRI drivers to enable
1710 -dri_driver_enable() {
1711 - if [[ $1 == -- ]] || use $1; then
1712 - shift
1713 - DRI_DRIVERS+=("$@")
1714 - fi
1715 -}
1716 -
1717 -gallium_enable() {
1718 - if [[ $1 == -- ]] || use $1; then
1719 - shift
1720 - GALLIUM_DRIVERS+=("$@")
1721 - fi
1722 -}
1723 -
1724 -vulkan_enable() {
1725 - if [[ $1 == -- ]] || use $1; then
1726 - shift
1727 - VULKAN_DRIVERS+=("$@")
1728 - fi
1729 -}