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: Wed, 07 Aug 2019 17:03:50
Message-Id: 1565197418.6a97acbbcdd98d8e449acc2c0359b389c57d39e2.mattst88@gentoo
1 commit: 6a97acbbcdd98d8e449acc2c0359b389c57d39e2
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Wed Aug 7 17:01:41 2019 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Wed Aug 7 17:03:38 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6a97acbb
7
8 media-libs/mesa: Version bump to 19.1.4
9
10 Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
11
12 media-libs/mesa/Manifest | 1 +
13 media-libs/mesa/mesa-19.1.4.ebuild | 540 +++++++++++++++++++++++++++++++++++++
14 2 files changed, 541 insertions(+)
15
16 diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest
17 index ef0c1c24e2f..3bbd7ac2972 100644
18 --- a/media-libs/mesa/Manifest
19 +++ b/media-libs/mesa/Manifest
20 @@ -1,2 +1,3 @@
21 DIST mesa-19.0.8.tar.xz 11967592 BLAKE2B 91a46b67bdb8cb3ab4c7337be7c2b0dc6ab5ec8cc126afc2d8af8d056bff0392a5b443c26304bf4c68472eb6ba16d29ca248c1fc0c0f2dd6af03d3e10d3ec1b3 SHA512 fbddc3a74f223564343027380af776b3fa5d63fe1af4e34121273235d1c6eced96439f601eb19bf658eb927aff3965b520f0329fcbd4650f3112167303e1746d
22 DIST mesa-19.1.3.tar.xz 10935604 BLAKE2B 4dfda4b3ef7a2d53b20a7a0c81b08901d6b88431b6b56679b8d97d6f2f57ce18f6dcdbae9b79c5d02b9175f47db629833da6012658295fe456829ef07a5ff087 SHA512 787310c43089142209ff7db298489b0815b630577680d5ce1bc3f796eed3772ba41f03e5e773b77ae084c191ed4e365eac1753166ce60f12b8f5974d55762eeb
23 +DIST mesa-19.1.4.tar.xz 10938008 BLAKE2B 4745fc7e844397378fe1adf61bcd5b54aad11ec0b375ced85fd80ced01227432b491ad8b7ba7d9013190cfbb451bc11cdb7c8af0e1f298dd5d793d3ce43aa92b SHA512 234032d917c9b378c3f6ceb921677b64e549344c3957331810b50fd73e0dccd2f4f62e2bd39e619590f389bc58fdab10fab4b88f7c117557cbeb1dda049b9fc5
24
25 diff --git a/media-libs/mesa/mesa-19.1.4.ebuild b/media-libs/mesa/mesa-19.1.4.ebuild
26 new file mode 100644
27 index 00000000000..0fd4ae716a5
28 --- /dev/null
29 +++ b/media-libs/mesa/mesa-19.1.4.ebuild
30 @@ -0,0 +1,540 @@
31 +# Copyright 1999-2019 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +PYTHON_COMPAT=( python3_5 python3_6 python3_7 )
37 +
38 +inherit llvm meson multilib-minimal pax-utils python-any-r1
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 + EXPERIMENTAL="true"
50 + inherit git-r3
51 +else
52 + SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz"
53 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
54 +fi
55 +
56 +LICENSE="MIT"
57 +SLOT="0"
58 +RESTRICT="
59 + !test? ( test )
60 +"
61 +
62 +RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
63 +VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 intel iris nouveau vc4 virgl vivante vmware"
64 +for card in ${VIDEO_CARDS}; do
65 + IUSE_VIDEO_CARDS+=" video_cards_${card}"
66 +done
67 +
68 +IUSE="${IUSE_VIDEO_CARDS}
69 + +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 +gles2 +libglvnd +llvm
70 + lm_sensors opencl osmesa pax_kernel pic selinux test unwind vaapi valgrind
71 + vdpau vulkan vulkan-overlay wayland xa xvmc"
72 +
73 +REQUIRED_USE="
74 + d3d9? ( dri3 || ( video_cards_iris video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) )
75 + gles1? ( egl )
76 + gles2? ( egl )
77 + vulkan? ( dri3
78 + || ( video_cards_i965 video_cards_iris video_cards_radeonsi )
79 + video_cards_radeonsi? ( llvm ) )
80 + vulkan-overlay? ( vulkan )
81 + wayland? ( egl gbm )
82 + video_cards_freedreno? ( gallium )
83 + video_cards_intel? ( classic )
84 + video_cards_i915? ( || ( classic gallium ) )
85 + video_cards_i965? ( classic )
86 + video_cards_iris? ( gallium )
87 + video_cards_nouveau? ( || ( classic gallium ) )
88 + video_cards_radeon? ( || ( classic gallium )
89 + gallium? ( x86? ( llvm ) amd64? ( llvm ) ) )
90 + video_cards_r100? ( classic )
91 + video_cards_r200? ( classic )
92 + video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) )
93 + video_cards_r600? ( gallium )
94 + video_cards_radeonsi? ( gallium llvm )
95 + video_cards_vc4? ( gallium )
96 + video_cards_virgl? ( gallium )
97 + video_cards_vivante? ( gallium gbm )
98 + video_cards_vmware? ( gallium )
99 +"
100 +
101 +LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.97"
102 +RDEPEND="
103 + !app-eselect/eselect-mesa
104 + >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
105 + >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}]
106 + >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
107 + >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
108 + >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
109 + >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
110 + >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
111 + >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}]
112 + x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
113 + libglvnd? (
114 + media-libs/libglvnd[${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 + dev-libs/ocl-icd[khronos-headers,${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 + video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 )
142 + )
143 + vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
144 + xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
145 + )
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 +
152 + video_cards_intel? (
153 + !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
154 + )
155 + video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
156 + vulkan-overlay? ( dev-util/glslang:0=[${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="9"
176 +LLVM_DEPSTR="
177 + || (
178 + sys-devel/llvm:9[${MULTILIB_USEDEP}]
179 + sys-devel/llvm:8[${MULTILIB_USEDEP}]
180 + sys-devel/llvm:7[${MULTILIB_USEDEP}]
181 + )
182 + sys-devel/llvm:=[${MULTILIB_USEDEP}]
183 +"
184 +LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
185 +CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang}
186 +CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
187 +RDEPEND="${RDEPEND}
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 +unset {LLVM,CLANG}_DEPSTR{,_AMDGPU}
240 +
241 +DEPEND="${RDEPEND}
242 + valgrind? ( dev-util/valgrind )
243 + x11-libs/libXrandr[${MULTILIB_USEDEP}]
244 + x11-base/xorg-proto
245 +"
246 +BDEPEND="
247 + ${PYTHON_DEPS}
248 + opencl? (
249 + >=sys-devel/gcc-4.6
250 + )
251 + sys-devel/bison
252 + sys-devel/flex
253 + sys-devel/gettext
254 + virtual/pkgconfig
255 + $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]")
256 +"
257 +
258 +S="${WORKDIR}/${MY_P}"
259 +EGIT_CHECKOUT_DIR=${S}
260 +
261 +QA_WX_LOAD="
262 +x86? (
263 + !pic? (
264 + usr/lib*/libglapi.so.0.0.0
265 + usr/lib*/libGLESv1_CM.so.1.0.0
266 + usr/lib*/libGLESv2.so.2.0.0
267 + usr/lib*/libGL.so.1.2.0
268 + usr/lib*/libOSMesa.so.8.0.0
269 + )
270 +)"
271 +
272 +llvm_check_deps() {
273 + local flags=${MULTILIB_USEDEP}
274 + if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi
275 + then
276 + flags+=",llvm_targets_AMDGPU(-)"
277 + fi
278 +
279 + if use opencl; then
280 + has_version "sys-devel/clang:${LLVM_SLOT}[${flags}]" || return 1
281 + fi
282 + has_version "sys-devel/llvm:${LLVM_SLOT}[${flags}]"
283 +}
284 +
285 +pkg_pretend() {
286 + if use opencl; then
287 + if ! use video_cards_r600 &&
288 + ! use video_cards_radeonsi; then
289 + ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi"
290 + fi
291 + fi
292 +
293 + if use vaapi; then
294 + if ! use video_cards_r600 &&
295 + ! use video_cards_radeonsi &&
296 + ! use video_cards_nouveau; then
297 + ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau"
298 + fi
299 + fi
300 +
301 + if use vdpau; then
302 + if ! use video_cards_r300 &&
303 + ! use video_cards_r600 &&
304 + ! use video_cards_radeonsi &&
305 + ! use video_cards_nouveau; then
306 + ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau"
307 + fi
308 + fi
309 +
310 + if use xa; then
311 + if ! use video_cards_freedreno &&
312 + ! use video_cards_nouveau &&
313 + ! use video_cards_vmware; then
314 + ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware"
315 + fi
316 + fi
317 +
318 + if use xvmc; then
319 + if ! use video_cards_r600 &&
320 + ! use video_cards_nouveau; then
321 + ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau"
322 + fi
323 + fi
324 +
325 + if ! use gallium; then
326 + use lm_sensors && ewarn "Ignoring USE=lm_sensors since USE does not contain gallium"
327 + use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium"
328 + use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium"
329 + use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium"
330 + use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium"
331 + use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium"
332 + use xa && ewarn "Ignoring USE=xa since USE does not contain gallium"
333 + use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium"
334 + fi
335 +
336 + if ! use llvm; then
337 + use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm"
338 + fi
339 +}
340 +
341 +python_check_deps() {
342 + has_version -b ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]"
343 +}
344 +
345 +pkg_setup() {
346 + # warning message for bug 459306
347 + if use llvm && has_version sys-devel/llvm[!debug=]; then
348 + ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
349 + ewarn "detected! This can cause problems. For details, see bug 459306."
350 + fi
351 +
352 + if use llvm; then
353 + llvm_pkg_setup
354 + fi
355 + python-any-r1_pkg_setup
356 +}
357 +
358 +multilib_src_configure() {
359 + local emesonargs=()
360 +
361 + if use classic; then
362 + # Intel code
363 + dri_driver_enable video_cards_i915 i915
364 + dri_driver_enable video_cards_i965 i965
365 + if ! use video_cards_i915 && \
366 + ! use video_cards_i965; then
367 + dri_driver_enable video_cards_intel i915 i965
368 + fi
369 +
370 + # Nouveau code
371 + dri_driver_enable video_cards_nouveau nouveau
372 +
373 + # ATI code
374 + dri_driver_enable video_cards_r100 r100
375 + dri_driver_enable video_cards_r200 r200
376 + if ! use video_cards_r100 && \
377 + ! use video_cards_r200; then
378 + dri_driver_enable video_cards_radeon r100 r200
379 + fi
380 + fi
381 +
382 + emesonargs+=( -Dplatforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm") )
383 +
384 + if use gallium; then
385 + emesonargs+=(
386 + $(meson_use llvm)
387 + $(meson_use lm_sensors lmsensors)
388 + $(meson_use unwind libunwind)
389 + )
390 +
391 + if use video_cards_iris ||
392 + use video_cards_r300 ||
393 + use video_cards_r600 ||
394 + use video_cards_radeonsi ||
395 + use video_cards_nouveau ||
396 + use video_cards_vmware; then
397 + emesonargs+=($(meson_use d3d9 gallium-nine))
398 + else
399 + emesonargs+=(-Dgallium-nine=false)
400 + fi
401 +
402 + if use video_cards_r600 ||
403 + use video_cards_radeonsi ||
404 + use video_cards_nouveau; then
405 + emesonargs+=($(meson_use vaapi gallium-va))
406 + use vaapi && emesonargs+=( -Dva-libs-path="${EPREFIX}"/usr/$(get_libdir)/va/drivers )
407 + else
408 + emesonargs+=(-Dgallium-va=false)
409 + fi
410 +
411 + if use video_cards_r300 ||
412 + use video_cards_r600 ||
413 + use video_cards_radeonsi ||
414 + use video_cards_nouveau; then
415 + emesonargs+=($(meson_use vdpau gallium-vdpau))
416 + else
417 + emesonargs+=(-Dgallium-vdpau=false)
418 + fi
419 +
420 + if use video_cards_freedreno ||
421 + use video_cards_nouveau ||
422 + use video_cards_vmware; then
423 + emesonargs+=($(meson_use xa gallium-xa))
424 + else
425 + emesonargs+=(-Dgallium-xa=false)
426 + fi
427 +
428 + if use video_cards_r600 ||
429 + use video_cards_nouveau; then
430 + emesonargs+=($(meson_use xvmc gallium-xvmc))
431 + else
432 + emesonargs+=(-Dgallium-xvmc=false)
433 + fi
434 +
435 + if use video_cards_freedreno ||
436 + use video_cards_vc4 ||
437 + use video_cards_vivante; then
438 + gallium_enable -- kmsro
439 + fi
440 +
441 + gallium_enable video_cards_vc4 vc4
442 + gallium_enable video_cards_vivante etnaviv
443 + gallium_enable video_cards_vmware svga
444 + gallium_enable video_cards_nouveau nouveau
445 +
446 + # Only one i915 driver (classic vs gallium). Default to classic.
447 + if ! use classic; then
448 + gallium_enable video_cards_i915 i915
449 + if ! use video_cards_i915 && \
450 + ! use video_cards_i965; then
451 + gallium_enable video_cards_intel i915
452 + fi
453 + fi
454 +
455 + gallium_enable video_cards_iris iris
456 +
457 + gallium_enable video_cards_r300 r300
458 + gallium_enable video_cards_r600 r600
459 + gallium_enable video_cards_radeonsi radeonsi
460 + if ! use video_cards_r300 && \
461 + ! use video_cards_r600; then
462 + gallium_enable video_cards_radeon r300 r600
463 + fi
464 +
465 + gallium_enable video_cards_freedreno freedreno
466 + gallium_enable video_cards_virgl virgl
467 +
468 + # opencl stuff
469 + emesonargs+=(
470 + -Dgallium-opencl="$(usex opencl icd disabled)"
471 + )
472 + fi
473 +
474 + if use vulkan; then
475 + vulkan_enable video_cards_i965 intel
476 + vulkan_enable video_cards_iris intel
477 + vulkan_enable video_cards_radeonsi amd
478 + fi
479 +
480 + # x86 hardened pax_kernel needs glx-rts, bug 240956
481 + if [[ ${ABI} == x86 ]]; then
482 + emesonargs+=( $(meson_use pax_kernel glx-read-only-text) )
483 + fi
484 +
485 + # on abi_x86_32 hardened we need to have asm disable
486 + if [[ ${ABI} == x86* ]] && use pic; then
487 + emesonargs+=( -Dasm=false )
488 + fi
489 +
490 + if use gallium; then
491 + gallium_enable -- swrast
492 + emesonargs+=( -Dosmesa=$(usex osmesa gallium none) )
493 + else
494 + dri_driver_enable -- swrast
495 + emesonargs+=( -Dosmesa=$(usex osmesa classic none) )
496 + fi
497 +
498 + driver_list() {
499 + local drivers="$(sort -u <<< "${1// /$'\n'}")"
500 + echo "${drivers//$'\n'/,}"
501 + }
502 +
503 + emesonargs+=(
504 + $(meson_use test build-tests)
505 + -Dglx=dri
506 + -Dshared-glapi=true
507 + $(meson_use dri3)
508 + $(meson_use egl)
509 + $(meson_use gbm)
510 + $(meson_use gles1)
511 + $(meson_use gles2)
512 + $(meson_use libglvnd glvnd)
513 + $(meson_use selinux)
514 + -Dvalgrind=$(usex valgrind auto false)
515 + -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}")
516 + -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}")
517 + -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}")
518 + $(meson_use vulkan-overlay vulkan-overlay-layer)
519 + --buildtype $(usex debug debug plain)
520 + -Db_ndebug=$(usex debug false true)
521 + )
522 + meson_src_configure
523 +}
524 +
525 +multilib_src_compile() {
526 + meson_src_compile
527 +}
528 +
529 +multilib_src_install() {
530 + meson_src_install
531 +
532 + use libglvnd && rm -f "${D}"/usr/$(get_libdir)/libGLESv{1_CM,2}.so*
533 +}
534 +
535 +multilib_src_install_all() {
536 + einstalldocs
537 +}
538 +
539 +multilib_src_test() {
540 + meson test -v -C "${BUILD_DIR}" -t 100
541 +}
542 +
543 +pkg_postinst() {
544 + # Switch to the xorg implementation.
545 + echo
546 + eselect opengl set --use-old ${OPENGL_DIR}
547 +}
548 +
549 +# $1 - VIDEO_CARDS flag (check skipped for "--")
550 +# other args - names of DRI drivers to enable
551 +dri_driver_enable() {
552 + if [[ $1 == -- ]] || use $1; then
553 + shift
554 + DRI_DRIVERS+=("$@")
555 + fi
556 +}
557 +
558 +gallium_enable() {
559 + if [[ $1 == -- ]] || use $1; then
560 + shift
561 + GALLIUM_DRIVERS+=("$@")
562 + fi
563 +}
564 +
565 +vulkan_enable() {
566 + if [[ $1 == -- ]] || use $1; then
567 + shift
568 + VULKAN_DRIVERS+=("$@")
569 + fi
570 +}