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, 08 Apr 2021 02:55:31
Message-Id: 1617850516.e6ffb274488abd65fa6bb4b544f00b57a3d64ccf.mattst88@gentoo
1 commit: e6ffb274488abd65fa6bb4b544f00b57a3d64ccf
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Thu Apr 8 02:53:33 2021 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Thu Apr 8 02:55:16 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e6ffb274
7
8 media-libs/mesa: Version bump to 21.0.2
9
10 Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
11
12 media-libs/mesa/Manifest | 1 +
13 media-libs/mesa/mesa-21.0.2.ebuild | 564 +++++++++++++++++++++++++++++++++++++
14 2 files changed, 565 insertions(+)
15
16 diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest
17 index 9371f32bcdb..12fd22ba98e 100644
18 --- a/media-libs/mesa/Manifest
19 +++ b/media-libs/mesa/Manifest
20 @@ -1,2 +1,3 @@
21 DIST mesa-20.3.5.tar.xz 14367412 BLAKE2B 7bad876ce702158e727a752eda6722e7165b497fd3a485dae4e989f22b13288a93f51bcd5e6a69b979f0bbe41599fa237c08f3bbb81cb9c6dc4c06827f8ad5f4 SHA512 481e710ed80d8f215a8d541cfe51b960862c2403c2b9e7e6932c8236b8decb5d478871d6c73559d6d795ada143803764f3a93b2329588c80f62e2e5ec98c78a9
22 DIST mesa-21.0.1.tar.xz 14648932 BLAKE2B 70e1277336320d7b4351c72f42a72cbcb91dcbc46cc1bf30996b8895bbc30552265404508130c828b67a7d045c9f6eece5ac3d07c2443cea581774c585ba0b69 SHA512 b31b78778b6092dfaf0712f90de3074217574389c4236f8379c127739874f6bd1b47883140a26445d25e58df87e6207278efd048453096ee710d334b1dcfe419
23 +DIST mesa-21.0.2.tar.xz 14671512 BLAKE2B 5733e65e7e8ffe3e6bed17f499c4d40d2dfbd3dafef967f6b1dbbd14089734640aed02d39568a32d362cc27b4125f425874c25625fd58731500910427dc6c594 SHA512 c3d7969b56e1c31ee642e3b7143d565c4233173dab7cc5576b686c873c27134dc8292a9f2caa0a0dd3c54d0c89d27d6030f36a2c84f85dcedee7ae80b19e5c3b
24
25 diff --git a/media-libs/mesa/mesa-21.0.2.ebuild b/media-libs/mesa/mesa-21.0.2.ebuild
26 new file mode 100644
27 index 00000000000..ebeac9698ee
28 --- /dev/null
29 +++ b/media-libs/mesa/mesa-21.0.2.ebuild
30 @@ -0,0 +1,564 @@
31 +# Copyright 1999-2021 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +PYTHON_COMPAT=( python3_{7,8,9} )
37 +
38 +inherit llvm meson multilib-minimal python-any-r1 linux-info
39 +
40 +OPENGL_DIR="xorg-x11"
41 +
42 +MY_P="${P/_/-}"
43 +
44 +DESCRIPTION="OpenGL-like graphic library for Linux"
45 +HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/"
46 +
47 +if [[ ${PV} == 9999 ]]; then
48 + EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git"
49 + inherit git-r3
50 +else
51 + SRC_URI="https://archive.mesa3d.org/${MY_P}.tar.xz"
52 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
53 +fi
54 +
55 +LICENSE="MIT"
56 +SLOT="0"
57 +RESTRICT="
58 + !test? ( test )
59 +"
60 +
61 +RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
62 +VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 intel iris lima nouveau panfrost v3d vc4 virgl vivante vmware"
63 +for card in ${VIDEO_CARDS}; do
64 + IUSE_VIDEO_CARDS+=" video_cards_${card}"
65 +done
66 +
67 +IUSE="${IUSE_VIDEO_CARDS}
68 + +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 +gles2 +llvm
69 + lm-sensors opencl osmesa selinux test unwind vaapi valgrind vdpau vulkan
70 + vulkan-overlay wayland +X xa xvmc zink +zstd"
71 +
72 +REQUIRED_USE="
73 + d3d9? ( dri3 || ( video_cards_iris video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) )
74 + gles1? ( egl )
75 + gles2? ( egl )
76 + osmesa? ( gallium )
77 + vulkan? ( dri3
78 + video_cards_radeonsi? ( llvm ) )
79 + vulkan-overlay? ( vulkan )
80 + wayland? ( egl gbm )
81 + video_cards_freedreno? ( gallium )
82 + video_cards_intel? ( classic )
83 + video_cards_i915? ( || ( classic gallium ) )
84 + video_cards_i965? ( classic )
85 + video_cards_iris? ( gallium )
86 + video_cards_lima? ( gallium )
87 + video_cards_nouveau? ( || ( classic gallium ) )
88 + video_cards_panfrost? ( gallium )
89 + video_cards_radeon? ( || ( classic gallium )
90 + gallium? ( x86? ( llvm ) amd64? ( llvm ) ) )
91 + video_cards_r100? ( classic )
92 + video_cards_r200? ( classic )
93 + video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) )
94 + video_cards_r600? ( gallium )
95 + video_cards_radeonsi? ( gallium llvm )
96 + video_cards_v3d? ( gallium )
97 + video_cards_vc4? ( gallium )
98 + video_cards_virgl? ( gallium )
99 + video_cards_vivante? ( gallium gbm )
100 + video_cards_vmware? ( gallium )
101 + xa? ( X )
102 + xvmc? ( X )
103 + zink? ( gallium vulkan )
104 +"
105 +
106 +LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.100"
107 +RDEPEND="
108 + >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
109 + >=media-libs/libglvnd-1.3.2[X?,${MULTILIB_USEDEP}]
110 + >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}]
111 + gallium? (
112 + unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] )
113 + llvm? (
114 + video_cards_radeonsi? (
115 + virtual/libelf:0=[${MULTILIB_USEDEP}]
116 + )
117 + video_cards_r600? (
118 + virtual/libelf:0=[${MULTILIB_USEDEP}]
119 + )
120 + video_cards_radeon? (
121 + virtual/libelf:0=[${MULTILIB_USEDEP}]
122 + )
123 + )
124 + lm-sensors? ( sys-apps/lm-sensors:=[${MULTILIB_USEDEP}] )
125 + opencl? (
126 + >=virtual/opencl-3[${MULTILIB_USEDEP}]
127 + dev-libs/libclc
128 + virtual/libelf:0=[${MULTILIB_USEDEP}]
129 + )
130 + vaapi? (
131 + >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}]
132 + )
133 + vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
134 + xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
135 + )
136 + selinux? ( sys-libs/libselinux[${MULTILIB_USEDEP}] )
137 + wayland? (
138 + >=dev-libs/wayland-1.18.0:=[${MULTILIB_USEDEP}]
139 + >=dev-libs/wayland-protocols-1.8
140 + )
141 + ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}]
142 + video_cards_intel? (
143 + !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
144 + )
145 + video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
146 + vulkan-overlay? ( dev-util/glslang:0=[${MULTILIB_USEDEP}] )
147 + X? (
148 + >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
149 + >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
150 + >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
151 + >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
152 + >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}]
153 + x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
154 + )
155 + zink? ( media-libs/vulkan-loader:=[${MULTILIB_USEDEP}] )
156 + zstd? ( app-arch/zstd:=[${MULTILIB_USEDEP}] )
157 +"
158 +for card in ${RADEON_CARDS}; do
159 + RDEPEND="${RDEPEND}
160 + video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
161 + "
162 +done
163 +RDEPEND="${RDEPEND}
164 + video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
165 +"
166 +
167 +# Please keep the LLVM dependency block separate. Since LLVM is slotted,
168 +# we need to *really* make sure we're not pulling one than more slot
169 +# simultaneously.
170 +#
171 +# How to use it:
172 +# 1. List all the working slots (with min versions) in ||, newest first.
173 +# 2. Update the := to specify *max* version, e.g. < 10.
174 +# 3. Specify LLVM_MAX_SLOT, e.g. 9.
175 +LLVM_MAX_SLOT="11"
176 +LLVM_DEPSTR="
177 + || (
178 + sys-devel/llvm:11[${MULTILIB_USEDEP}]
179 + sys-devel/llvm:10[${MULTILIB_USEDEP}]
180 + )
181 + <sys-devel/llvm-$((LLVM_MAX_SLOT + 1)):=[${MULTILIB_USEDEP}]
182 +"
183 +LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
184 +CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang}
185 +CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
186 +RDEPEND="${RDEPEND}
187 + gallium? (
188 + llvm? (
189 + opencl? (
190 + video_cards_r600? (
191 + ${CLANG_DEPSTR_AMDGPU}
192 + )
193 + !video_cards_r600? (
194 + video_cards_radeonsi? (
195 + ${CLANG_DEPSTR_AMDGPU}
196 + )
197 + )
198 + !video_cards_r600? (
199 + !video_cards_radeonsi? (
200 + video_cards_radeon? (
201 + ${CLANG_DEPSTR_AMDGPU}
202 + )
203 + )
204 + )
205 + !video_cards_r600? (
206 + !video_cards_radeon? (
207 + !video_cards_radeonsi? (
208 + ${CLANG_DEPSTR}
209 + )
210 + )
211 + )
212 + )
213 + !opencl? (
214 + video_cards_r600? (
215 + ${LLVM_DEPSTR_AMDGPU}
216 + )
217 + !video_cards_r600? (
218 + video_cards_radeonsi? (
219 + ${LLVM_DEPSTR_AMDGPU}
220 + )
221 + )
222 + !video_cards_r600? (
223 + !video_cards_radeonsi? (
224 + video_cards_radeon? (
225 + ${LLVM_DEPSTR_AMDGPU}
226 + )
227 + )
228 + )
229 + !video_cards_r600? (
230 + !video_cards_radeon? (
231 + !video_cards_radeonsi? (
232 + ${LLVM_DEPSTR}
233 + )
234 + )
235 + )
236 + )
237 + )
238 + )
239 +"
240 +unset {LLVM,CLANG}_DEPSTR{,_AMDGPU}
241 +
242 +DEPEND="${RDEPEND}
243 + valgrind? ( dev-util/valgrind )
244 + X? (
245 + x11-libs/libXrandr[${MULTILIB_USEDEP}]
246 + x11-base/xorg-proto
247 + )
248 +"
249 +BDEPEND="
250 + ${PYTHON_DEPS}
251 + opencl? (
252 + >=sys-devel/gcc-4.6
253 + )
254 + sys-devel/bison
255 + sys-devel/flex
256 + virtual/pkgconfig
257 + $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]")
258 + wayland? ( dev-util/wayland-scanner[${MULTILIB_USEDEP}] )
259 +"
260 +
261 +S="${WORKDIR}/${MY_P}"
262 +EGIT_CHECKOUT_DIR=${S}
263 +
264 +QA_WX_LOAD="
265 +x86? (
266 + usr/lib*/libglapi.so.0.0.0
267 + usr/lib*/libGLESv1_CM.so.1.1.0
268 + usr/lib*/libGLESv2.so.2.0.0
269 + usr/lib*/libGL.so.1.2.0
270 + usr/lib*/libOSMesa.so.8.0.0
271 + usr/lib/libGLX_mesa.so.0.0.0
272 +)"
273 +
274 +llvm_check_deps() {
275 + local flags=${MULTILIB_USEDEP}
276 + if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi
277 + then
278 + flags+=",llvm_targets_AMDGPU(-)"
279 + fi
280 +
281 + if use opencl; then
282 + has_version "sys-devel/clang:${LLVM_SLOT}[${flags}]" || return 1
283 + fi
284 + has_version "sys-devel/llvm:${LLVM_SLOT}[${flags}]"
285 +}
286 +
287 +pkg_pretend() {
288 + if use vulkan; then
289 + if ! use video_cards_i965 &&
290 + ! use video_cards_iris &&
291 + ! use video_cards_radeonsi &&
292 + ! use video_cards_v3d; then
293 + ewarn "Ignoring USE=vulkan since VIDEO_CARDS does not contain i965, iris, radeonsi, or v3d"
294 + fi
295 + fi
296 +
297 + if use opencl; then
298 + if ! use video_cards_r600 &&
299 + ! use video_cards_radeonsi; then
300 + ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi"
301 + fi
302 + fi
303 +
304 + if use vaapi; then
305 + if ! use video_cards_r600 &&
306 + ! use video_cards_radeonsi &&
307 + ! use video_cards_nouveau; then
308 + ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau"
309 + fi
310 + fi
311 +
312 + if use vdpau; then
313 + if ! use video_cards_r300 &&
314 + ! use video_cards_r600 &&
315 + ! use video_cards_radeonsi &&
316 + ! use video_cards_nouveau; then
317 + ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau"
318 + fi
319 + fi
320 +
321 + if use xa; then
322 + if ! use video_cards_freedreno &&
323 + ! use video_cards_nouveau &&
324 + ! use video_cards_vmware; then
325 + ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware"
326 + fi
327 + fi
328 +
329 + if use xvmc; then
330 + if ! use video_cards_r600 &&
331 + ! use video_cards_nouveau; then
332 + ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau"
333 + fi
334 + fi
335 +
336 + if ! use gallium; then
337 + use lm-sensors && ewarn "Ignoring USE=lm-sensors since USE does not contain gallium"
338 + use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium"
339 + use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium"
340 + use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium"
341 + use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium"
342 + use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium"
343 + use xa && ewarn "Ignoring USE=xa since USE does not contain gallium"
344 + use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium"
345 + fi
346 +
347 + if ! use llvm; then
348 + use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm"
349 + fi
350 +
351 + if use osmesa && ! use llvm; then
352 + ewarn "OSMesa will be slow without enabling USE=llvm"
353 + fi
354 +}
355 +
356 +python_check_deps() {
357 + has_version -b ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]"
358 +}
359 +
360 +pkg_setup() {
361 + # warning message for bug 459306
362 + if use llvm && has_version sys-devel/llvm[!debug=]; then
363 + ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
364 + ewarn "detected! This can cause problems. For details, see bug 459306."
365 + fi
366 +
367 + if use video_cards_i965 ||
368 + use video_cards_iris ||
369 + use video_cards_radeonsi; then
370 + if kernel_is -ge 5 11 3; then
371 + CONFIG_CHECK="~KCMP"
372 + elif kernel_is -ge 5 11; then
373 + CONFIG_CHECK="~CHECKPOINT_RESTORE"
374 + elif kernel_is -ge 5 10 20; then
375 + CONFIG_CHECK="~KCMP"
376 + else
377 + CONFIG_CHECK="~CHECKPOINT_RESTORE"
378 + fi
379 + linux-info_pkg_setup
380 + fi
381 +
382 + if use gallium && use llvm; then
383 + llvm_pkg_setup
384 + fi
385 + python-any-r1_pkg_setup
386 +}
387 +
388 +multilib_src_configure() {
389 + local emesonargs=()
390 +
391 + if use classic; then
392 + # Intel code
393 + dri_driver_enable video_cards_i915 i915
394 + dri_driver_enable video_cards_i965 i965
395 + if ! use video_cards_i915 && \
396 + ! use video_cards_i965; then
397 + dri_driver_enable video_cards_intel i915 i965
398 + fi
399 +
400 + # Nouveau code
401 + dri_driver_enable video_cards_nouveau nouveau
402 +
403 + # ATI code
404 + dri_driver_enable video_cards_r100 r100
405 + dri_driver_enable video_cards_r200 r200
406 + if ! use video_cards_r100 && \
407 + ! use video_cards_r200; then
408 + dri_driver_enable video_cards_radeon r100 r200
409 + fi
410 + fi
411 +
412 + local platforms
413 + use X && platforms+="x11"
414 + use wayland && platforms+=",wayland"
415 + emesonargs+=(-Dplatforms=${platforms#,})
416 +
417 + if use X || use egl; then
418 + emesonargs+=(-Dglvnd=true)
419 + else
420 + emesonargs+=(-Dglvnd=false)
421 + fi
422 +
423 + if use gallium; then
424 + emesonargs+=(
425 + $(meson_feature llvm)
426 + $(meson_feature lm-sensors lmsensors)
427 + $(meson_feature unwind libunwind)
428 + )
429 +
430 + if use video_cards_iris ||
431 + use video_cards_r300 ||
432 + use video_cards_r600 ||
433 + use video_cards_radeonsi ||
434 + use video_cards_nouveau ||
435 + use video_cards_vmware; then
436 + emesonargs+=($(meson_use d3d9 gallium-nine))
437 + else
438 + emesonargs+=(-Dgallium-nine=false)
439 + fi
440 +
441 + if use video_cards_r600 ||
442 + use video_cards_radeonsi ||
443 + use video_cards_nouveau; then
444 + emesonargs+=($(meson_feature vaapi gallium-va))
445 + use vaapi && emesonargs+=( -Dva-libs-path="${EPREFIX}"/usr/$(get_libdir)/va/drivers )
446 + else
447 + emesonargs+=(-Dgallium-va=disabled)
448 + fi
449 +
450 + if use video_cards_r300 ||
451 + use video_cards_r600 ||
452 + use video_cards_radeonsi ||
453 + use video_cards_nouveau; then
454 + emesonargs+=($(meson_feature vdpau gallium-vdpau))
455 + else
456 + emesonargs+=(-Dgallium-vdpau=disabled)
457 + fi
458 +
459 + if use video_cards_freedreno ||
460 + use video_cards_nouveau ||
461 + use video_cards_vmware; then
462 + emesonargs+=($(meson_feature xa gallium-xa))
463 + else
464 + emesonargs+=(-Dgallium-xa=disabled)
465 + fi
466 +
467 + if use video_cards_r600 ||
468 + use video_cards_nouveau; then
469 + emesonargs+=($(meson_feature xvmc gallium-xvmc))
470 + else
471 + emesonargs+=(-Dgallium-xvmc=disabled)
472 + fi
473 +
474 + if use video_cards_freedreno ||
475 + use video_cards_lima ||
476 + use video_cards_panfrost ||
477 + use video_cards_v3d ||
478 + use video_cards_vc4 ||
479 + use video_cards_vivante; then
480 + gallium_enable -- kmsro
481 + fi
482 +
483 + gallium_enable -- swrast
484 + gallium_enable video_cards_lima lima
485 + gallium_enable video_cards_panfrost panfrost
486 + gallium_enable video_cards_v3d v3d
487 + gallium_enable video_cards_vc4 vc4
488 + gallium_enable video_cards_vivante etnaviv
489 + gallium_enable video_cards_vmware svga
490 + gallium_enable video_cards_nouveau nouveau
491 + gallium_enable zink zink
492 +
493 + # Only one i915 driver (classic vs gallium). Default to classic.
494 + if ! use classic; then
495 + gallium_enable video_cards_i915 i915
496 + if ! use video_cards_i915 && \
497 + ! use video_cards_i965; then
498 + gallium_enable video_cards_intel i915
499 + fi
500 + fi
501 +
502 + gallium_enable video_cards_iris iris
503 +
504 + gallium_enable video_cards_r300 r300
505 + gallium_enable video_cards_r600 r600
506 + gallium_enable video_cards_radeonsi radeonsi
507 + if ! use video_cards_r300 && \
508 + ! use video_cards_r600; then
509 + gallium_enable video_cards_radeon r300 r600
510 + fi
511 +
512 + gallium_enable video_cards_freedreno freedreno
513 + gallium_enable video_cards_virgl virgl
514 +
515 + # opencl stuff
516 + emesonargs+=(
517 + -Dgallium-opencl="$(usex opencl icd disabled)"
518 + )
519 + fi
520 +
521 + if use vulkan; then
522 + vulkan_enable video_cards_i965 intel
523 + vulkan_enable video_cards_iris intel
524 + vulkan_enable video_cards_radeonsi amd
525 + vulkan_enable video_cards_v3d broadcom
526 + fi
527 +
528 + driver_list() {
529 + local drivers="$(sort -u <<< "${1// /$'\n'}")"
530 + echo "${drivers//$'\n'/,}"
531 + }
532 +
533 + emesonargs+=(
534 + $(meson_use test build-tests)
535 + -Dglx=$(usex X dri disabled)
536 + -Dshared-glapi=enabled
537 + $(meson_feature dri3)
538 + $(meson_feature egl)
539 + $(meson_feature gbm)
540 + $(meson_feature gles1)
541 + $(meson_feature gles2)
542 + $(meson_use osmesa)
543 + $(meson_use selinux)
544 + $(meson_feature zstd)
545 + -Dvalgrind=$(usex valgrind auto false)
546 + -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}")
547 + -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}")
548 + -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}")
549 + $(meson_use vulkan vulkan-device-select-layer)
550 + $(meson_use vulkan-overlay vulkan-overlay-layer)
551 + --buildtype $(usex debug debug plain)
552 + -Db_ndebug=$(usex debug false true)
553 + )
554 + meson_src_configure
555 +}
556 +
557 +multilib_src_compile() {
558 + meson_src_compile
559 +}
560 +
561 +multilib_src_install() {
562 + meson_src_install
563 +}
564 +
565 +multilib_src_install_all() {
566 + einstalldocs
567 +}
568 +
569 +multilib_src_test() {
570 + meson_src_test -t 100
571 +}
572 +
573 +# $1 - VIDEO_CARDS flag (check skipped for "--")
574 +# other args - names of DRI drivers to enable
575 +dri_driver_enable() {
576 + if [[ $1 == -- ]] || use $1; then
577 + shift
578 + DRI_DRIVERS+=("$@")
579 + fi
580 +}
581 +
582 +gallium_enable() {
583 + if [[ $1 == -- ]] || use $1; then
584 + shift
585 + GALLIUM_DRIVERS+=("$@")
586 + fi
587 +}
588 +
589 +vulkan_enable() {
590 + if [[ $1 == -- ]] || use $1; then
591 + shift
592 + VULKAN_DRIVERS+=("$@")
593 + fi
594 +}