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: Mon, 24 Sep 2018 16:41:24
Message-Id: 1537807266.1bc419a0b3a33e67eca8fb9c4646388222c8d43a.mattst88@gentoo
1 commit: 1bc419a0b3a33e67eca8fb9c4646388222c8d43a
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Mon Sep 24 16:26:49 2018 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Mon Sep 24 16:41:06 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1bc419a0
7
8 media-libs/mesa: Version bump to 18.1.9
9
10 media-libs/mesa/Manifest | 1 +
11 media-libs/mesa/mesa-18.1.9.ebuild | 540 +++++++++++++++++++++++++++++++++++++
12 2 files changed, 541 insertions(+)
13
14 diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest
15 index 067fcc6fc50..3a1703b6c6c 100644
16 --- a/media-libs/mesa/Manifest
17 +++ b/media-libs/mesa/Manifest
18 @@ -1,5 +1,6 @@
19 DIST mesa-17.3.9.tar.xz 10660456 BLAKE2B 54f4a75f9040e50e9eea8f5c52a276578379d25d2a01ac4767ab12bee85fe5dae1492d5bb1df06b6e8c6b0fe960bbd5ea38691c75d08a6b4302c64377ce58e54 SHA512 83deffbc6b9823b8e93cccf57d7952106f3d55fea881e3924f9f9586f0e9347a6e3a1a36cc19c24af819f2fde3af9496652a6ff56132511a5618d5774404f63f
20 DIST mesa-18.1.6.tar.xz 11142884 BLAKE2B fdd156fe7debf5223285dfa238070a2bd7d8ec684dec168afab78b9d2d38d53c10d939aaa64f34c2910e542dce3869adfca6383fca6a854c6dd03287a044b0e3 SHA512 2966210800215f5ced2720691063a8519b51ebeab9fb1e99bde4b1bd7ccc719d6395a1c29f25c88efe62d1592cf14ceafc163aca349490b1f8cee81070d46fcc
21 DIST mesa-18.1.8.tar.xz 11139864 BLAKE2B bdbd6c186f79b708656a44177b352e9188b8b846c816f8457c99ff76607019f856e19f5eba1c2473d998cd020aa03e732f25f9253f1acdd7f3d9b1470f42ec9e SHA512 ab89c6d27b765d3efdf61b24dc56d863ae590d83003d2eae4bfe25ecfbeda5bee0227f21d057523bb4eceeaf3d9955df48087ffb472c41b123c100e593056cb9
22 +DIST mesa-18.1.9.tar.xz 11146188 BLAKE2B 753f0fa3780502d56927f9b0e6124b4728cb5aa3600de78585487fb8e178c6987a72b79fb56e6c310757d157f9f85f12b73a6889bd361b51b62fb1dc1c20eecd SHA512 22db2950d25a3d9393e7c622c783bd177c21695569c8a95683bf77e92318e1db85672a134d4bea30c1f49a24e52bc3a2c1a0ac15deafb3a8fcbfb6de6a18adc2
23 DIST mesa-18.2.0.tar.xz 11331164 BLAKE2B e4e7c65a0c3c0716451157f7d026df8836399b5a25ca7ce77746b34f82e0c14d0bfcb965732f67c979190c2c2db68f272ffafa51b49613a510f186e9e8a01c93 SHA512 e6e997e166845009f6b97da204384758c797c870b56332652c0a2636734638f9180b7e4dbad144495645308ae4d77981a2493a22d57973723338b658e0655557
24 DIST mesa-18.2.1.tar.xz 11374476 BLAKE2B f0f3b766d68550f8c395a1b1d1ffc7a9e532c22ee6b91d698db33a270c152e03ab656d4219301bc2e0e95ba6f0583017c4361add928ad8ab26378a1ec6958f36 SHA512 d249bdf79aad36db9a8d291b3a1a100d283893ac741f58f85ae7e5c90ca25c37f80a5fa6fc57945ffeb0b67b788e7ea146543ec790b22f144578fc4c1525b84d
25
26 diff --git a/media-libs/mesa/mesa-18.1.9.ebuild b/media-libs/mesa/mesa-18.1.9.ebuild
27 new file mode 100644
28 index 00000000000..749c5c07c8a
29 --- /dev/null
30 +++ b/media-libs/mesa/mesa-18.1.9.ebuild
31 @@ -0,0 +1,540 @@
32 +# Copyright 1999-2018 Gentoo Foundation
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=6
36 +
37 +EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git"
38 +
39 +if [[ ${PV} = 9999 ]]; then
40 + GIT_ECLASS="git-r3"
41 + EXPERIMENTAL="true"
42 +fi
43 +
44 +PYTHON_COMPAT=( python2_7 )
45 +
46 +inherit autotools llvm multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS}
47 +
48 +OPENGL_DIR="xorg-x11"
49 +
50 +MY_P="${P/_/-}"
51 +
52 +DESCRIPTION="OpenGL-like graphic library for Linux"
53 +HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/"
54 +
55 +if [[ $PV == 9999 ]]; then
56 + SRC_URI=""
57 +else
58 + SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz"
59 + 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"
60 +fi
61 +
62 +LICENSE="MIT"
63 +SLOT="0"
64 +RESTRICT="!bindist? ( bindist )"
65 +
66 +RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
67 +VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau 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 + bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 unwind
74 + +llvm +nptl opencl osmesa pax_kernel openmax pic selinux vaapi valgrind
75 + vdpau vulkan wayland xvmc xa"
76 +
77 +REQUIRED_USE="
78 + d3d9? ( dri3 gallium )
79 + llvm? ( gallium )
80 + opencl? ( gallium llvm || ( video_cards_r600 video_cards_radeonsi ) )
81 + openmax? ( gallium )
82 + gles1? ( egl )
83 + gles2? ( egl )
84 + vaapi? ( gallium )
85 + vdpau? ( gallium )
86 + vulkan? ( || ( video_cards_i965 video_cards_radeonsi )
87 + video_cards_radeonsi? ( llvm ) )
88 + wayland? ( egl gbm )
89 + xa? ( gallium )
90 + video_cards_freedreno? ( gallium )
91 + video_cards_intel? ( classic )
92 + video_cards_i915? ( || ( classic gallium ) )
93 + video_cards_i965? ( classic )
94 + video_cards_imx? ( gallium video_cards_vivante )
95 + video_cards_nouveau? ( || ( classic gallium ) )
96 + video_cards_radeon? ( || ( classic gallium )
97 + gallium? ( x86? ( llvm ) amd64? ( llvm ) ) )
98 + video_cards_r100? ( classic )
99 + video_cards_r200? ( classic )
100 + video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) )
101 + video_cards_r600? ( gallium )
102 + video_cards_radeonsi? ( gallium llvm )
103 + video_cards_vc4? ( gallium )
104 + video_cards_virgl? ( gallium )
105 + video_cards_vivante? ( gallium gbm )
106 + video_cards_vmware? ( gallium )
107 +"
108 +
109 +LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.91"
110 +RDEPEND="
111 + !app-eselect/eselect-mesa
112 + >=app-eselect/eselect-opengl-1.3.0
113 + >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
114 + >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}]
115 + >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
116 + >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
117 + >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
118 + >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
119 + >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
120 + >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}]
121 + x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
122 + unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] )
123 + llvm? (
124 + video_cards_radeonsi? (
125 + virtual/libelf:0=[${MULTILIB_USEDEP}]
126 + )
127 + video_cards_r600? (
128 + virtual/libelf:0=[${MULTILIB_USEDEP}]
129 + )
130 + video_cards_radeon? (
131 + virtual/libelf:0=[${MULTILIB_USEDEP}]
132 + )
133 + )
134 + opencl? (
135 + app-eselect/eselect-opencl
136 + dev-libs/libclc
137 + virtual/libelf:0=[${MULTILIB_USEDEP}]
138 + )
139 + openmax? (
140 + >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}]
141 + x11-misc/xdg-utils
142 + )
143 + vaapi? (
144 + >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}]
145 + video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 )
146 + )
147 + vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
148 + wayland? (
149 + >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}]
150 + >=dev-libs/wayland-protocols-1.8
151 + )
152 + xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
153 + ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}]
154 +
155 + video_cards_intel? (
156 + !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
157 + )
158 + video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
159 +"
160 +for card in ${RADEON_CARDS}; do
161 + RDEPEND="${RDEPEND}
162 + video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
163 + "
164 +done
165 +RDEPEND="${RDEPEND}
166 + video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
167 +"
168 +
169 +# Please keep the LLVM dependency block separate. Since LLVM is slotted,
170 +# we need to *really* make sure we're not pulling one than more slot
171 +# simultaneously.
172 +#
173 +# How to use it:
174 +# 1. List all the working slots (with min versions) in ||, newest first.
175 +# 2. Update the := to specify *max* version, e.g. < 7.
176 +# 3. Specify LLVM_MAX_SLOT, e.g. 6.
177 +LLVM_MAX_SLOT="6"
178 +LLVM_DEPSTR="
179 + || (
180 + sys-devel/llvm:7[${MULTILIB_USEDEP}]
181 + sys-devel/llvm:6[${MULTILIB_USEDEP}]
182 + sys-devel/llvm:5[${MULTILIB_USEDEP}]
183 + sys-devel/llvm:4[${MULTILIB_USEDEP}]
184 + >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}]
185 + )
186 + sys-devel/llvm:=[${MULTILIB_USEDEP}]
187 +"
188 +LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
189 +CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang}
190 +CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]}
191 +RDEPEND="${RDEPEND}
192 + llvm? (
193 + opencl? (
194 + video_cards_r600? (
195 + ${CLANG_DEPSTR_AMDGPU}
196 + )
197 + !video_cards_r600? (
198 + video_cards_radeonsi? (
199 + ${CLANG_DEPSTR_AMDGPU}
200 + )
201 + )
202 + !video_cards_r600? (
203 + !video_cards_radeonsi? (
204 + video_cards_radeon? (
205 + ${CLANG_DEPSTR_AMDGPU}
206 + )
207 + )
208 + )
209 + !video_cards_r600? (
210 + !video_cards_radeon? (
211 + !video_cards_radeonsi? (
212 + ${CLANG_DEPSTR}
213 + )
214 + )
215 + )
216 + )
217 + !opencl? (
218 + video_cards_r600? (
219 + ${LLVM_DEPSTR_AMDGPU}
220 + )
221 + !video_cards_r600? (
222 + video_cards_radeonsi? (
223 + ${LLVM_DEPSTR_AMDGPU}
224 + )
225 + )
226 + !video_cards_r600? (
227 + !video_cards_radeonsi? (
228 + video_cards_radeon? (
229 + ${LLVM_DEPSTR_AMDGPU}
230 + )
231 + )
232 + )
233 + !video_cards_r600? (
234 + !video_cards_radeon? (
235 + !video_cards_radeonsi? (
236 + ${LLVM_DEPSTR}
237 + )
238 + )
239 + )
240 + )
241 + )
242 +"
243 +unset {LLVM,CLANG}_DEPSTR{,_AMDGPU}
244 +
245 +DEPEND="${RDEPEND}
246 + ${PYTHON_DEPS}
247 + opencl? (
248 + >=sys-devel/gcc-4.6
249 + )
250 + sys-devel/gettext
251 + virtual/pkgconfig
252 + valgrind? ( dev-util/valgrind )
253 + x11-base/xorg-proto
254 + vulkan? (
255 + $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
256 + )
257 +"
258 +[[ ${PV} == 9999 ]] && DEPEND+="
259 + sys-devel/bison
260 + sys-devel/flex
261 + $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
262 +"
263 +
264 +S="${WORKDIR}/${MY_P}"
265 +EGIT_CHECKOUT_DIR=${S}
266 +
267 +QA_WX_LOAD="
268 +x86? (
269 + !pic? (
270 + usr/lib*/libglapi.so.0.0.0
271 + usr/lib*/libGLESv1_CM.so.1.1.0
272 + usr/lib*/libGLESv2.so.2.0.0
273 + usr/lib*/libGL.so.1.2.0
274 + usr/lib*/libOSMesa.so.8.0.0
275 + )
276 +)"
277 +
278 +llvm_check_deps() {
279 + local flags=${MULTILIB_USEDEP}
280 + if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi
281 + then
282 + flags+=",llvm_targets_AMDGPU(-)"
283 + fi
284 +
285 + if use opencl; then
286 + has_version "sys-devel/clang[${flags}]" || return 1
287 + fi
288 + has_version "sys-devel/llvm[${flags}]"
289 +}
290 +
291 +pkg_setup() {
292 + # warning message for bug 459306
293 + if use llvm && has_version sys-devel/llvm[!debug=]; then
294 + ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
295 + ewarn "detected! This can cause problems. For details, see bug 459306."
296 + fi
297 +
298 + if use llvm; then
299 + llvm_pkg_setup
300 + fi
301 + python-any-r1_pkg_setup
302 +}
303 +
304 +src_prepare() {
305 + eapply_user
306 + [[ ${PV} == 9999 ]] && eautoreconf
307 +}
308 +
309 +multilib_src_configure() {
310 + local myconf
311 +
312 + if use classic; then
313 + # Configurable DRI drivers
314 + driver_enable swrast
315 +
316 + # Intel code
317 + driver_enable video_cards_i915 i915
318 + driver_enable video_cards_i965 i965
319 + if ! use video_cards_i915 && \
320 + ! use video_cards_i965; then
321 + driver_enable video_cards_intel i915 i965
322 + fi
323 +
324 + # Nouveau code
325 + driver_enable video_cards_nouveau nouveau
326 +
327 + # ATI code
328 + driver_enable video_cards_r100 radeon
329 + driver_enable video_cards_r200 r200
330 + if ! use video_cards_r100 && \
331 + ! use video_cards_r200; then
332 + driver_enable video_cards_radeon radeon r200
333 + fi
334 + fi
335 +
336 + if use egl; then
337 + myconf+=" --with-platforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm")"
338 + fi
339 +
340 + if use gallium; then
341 + myconf+="
342 + $(use_enable d3d9 nine)
343 + $(use_enable llvm)
344 + $(use_enable openmax omx-bellagio)
345 + $(use_enable vaapi va)
346 + $(use_enable vdpau)
347 + $(use_enable xa)
348 + $(use_enable xvmc)
349 + "
350 + use vaapi && myconf+=" --with-va-libdir=/usr/$(get_libdir)/va/drivers"
351 +
352 + gallium_enable swrast
353 + gallium_enable video_cards_vc4 vc4
354 + gallium_enable video_cards_vivante etnaviv
355 + gallium_enable video_cards_vmware svga
356 + gallium_enable video_cards_nouveau nouveau
357 + gallium_enable video_cards_i915 i915
358 + gallium_enable video_cards_imx imx
359 + if ! use video_cards_i915 && \
360 + ! use video_cards_i965; then
361 + gallium_enable video_cards_intel i915
362 + fi
363 +
364 + gallium_enable video_cards_r300 r300
365 + gallium_enable video_cards_r600 r600
366 + gallium_enable video_cards_radeonsi radeonsi
367 + if ! use video_cards_r300 && \
368 + ! use video_cards_r600; then
369 + gallium_enable video_cards_radeon r300 r600
370 + fi
371 +
372 + gallium_enable video_cards_freedreno freedreno
373 + # opencl stuff
374 + if use opencl; then
375 + myconf+="
376 + $(use_enable opencl)
377 + --with-clang-libdir="${EPREFIX}/usr/lib"
378 + "
379 + fi
380 +
381 + gallium_enable video_cards_virgl virgl
382 + fi
383 +
384 + if use vulkan; then
385 + vulkan_enable video_cards_i965 intel
386 + vulkan_enable video_cards_radeonsi radeon
387 + fi
388 +
389 + # x86 hardened pax_kernel needs glx-rts, bug 240956
390 + if [[ ${ABI} == x86 ]]; then
391 + myconf+=" $(use_enable pax_kernel glx-read-only-text)"
392 + fi
393 +
394 + # on abi_x86_32 hardened we need to have asm disable
395 + if [[ ${ABI} == x86* ]] && use pic; then
396 + myconf+=" --disable-asm"
397 + fi
398 +
399 + if use gallium; then
400 + myconf+=" $(use_enable osmesa gallium-osmesa)"
401 + else
402 + myconf+=" $(use_enable osmesa)"
403 + fi
404 +
405 + # build fails with BSD indent, bug #428112
406 + use userland_GNU || export INDENT=cat
407 +
408 + ECONF_SOURCE="${S}" \
409 + econf \
410 + --enable-dri \
411 + --enable-glx \
412 + --enable-shared-glapi \
413 + $(use_enable !bindist texture-float) \
414 + $(use_enable d3d9 nine) \
415 + $(use_enable debug) \
416 + $(use_enable dri3) \
417 + $(use_enable egl) \
418 + $(use_enable gbm) \
419 + $(use_enable gles1) \
420 + $(use_enable gles2) \
421 + $(use_enable nptl glx-tls) \
422 + $(use_enable unwind libunwind) \
423 + --enable-valgrind=$(usex valgrind auto no) \
424 + --enable-llvm-shared-libs \
425 + --disable-opencl-icd \
426 + --with-dri-drivers=${DRI_DRIVERS} \
427 + --with-gallium-drivers=${GALLIUM_DRIVERS} \
428 + --with-vulkan-drivers=${VULKAN_DRIVERS} \
429 + PYTHON2="${PYTHON}" \
430 + ${myconf}
431 +}
432 +
433 +multilib_src_install() {
434 + emake install DESTDIR="${D}"
435 +
436 + if use wayland; then
437 + # These files are now provided by >=dev-libs/wayland-1.15.0
438 + rm "${ED}/usr/$(get_libdir)/libwayland-egl.so" || die
439 + rm "${ED}/usr/$(get_libdir)/libwayland-egl.so.1" || die
440 + rm "${ED}/usr/$(get_libdir)/libwayland-egl.so.1.0.0" || die
441 + rm "${ED}/usr/$(get_libdir)/pkgconfig/wayland-egl.pc" || die
442 + fi
443 +
444 + if use opencl; then
445 + ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching"
446 + local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa"
447 + dodir ${cl_dir}/{lib,include}
448 + if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then
449 + mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \
450 + "${ED}"${cl_dir}
451 + fi
452 + if [ -f "${ED}/usr/include/CL/opencl.h" ]; then
453 + mv -f "${ED}"/usr/include/CL \
454 + "${ED}"${cl_dir}/include
455 + fi
456 + eend $?
457 + fi
458 +
459 + if use openmax; then
460 + echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx"
461 + doenvd "${T}"/99mesaxdgomx
462 + keepdir /usr/share/mesa/xdg
463 + fi
464 +}
465 +
466 +multilib_src_install_all() {
467 + find "${ED}" -name '*.la' -delete
468 + einstalldocs
469 +
470 + if use !bindist; then
471 + dodoc docs/patents.txt
472 + fi
473 +}
474 +
475 +multilib_src_test() {
476 + if use llvm; then
477 + local llvm_tests='lp_test_arit lp_test_arit lp_test_blend lp_test_blend lp_test_conv lp_test_conv lp_test_format lp_test_format lp_test_printf lp_test_printf'
478 + pushd src/gallium/drivers/llvmpipe >/dev/null || die
479 + emake ${llvm_tests}
480 + pax-mark m ${llvm_tests}
481 + popd >/dev/null || die
482 + fi
483 + emake check
484 +}
485 +
486 +pkg_postinst() {
487 + # Switch to the xorg implementation.
488 + echo
489 + eselect opengl set --use-old ${OPENGL_DIR}
490 +
491 + # Switch to mesa opencl
492 + if use opencl; then
493 + eselect opencl set --use-old ${PN}
494 + fi
495 +
496 + # run omxregister-bellagio to make the OpenMAX drivers known system-wide
497 + if use openmax; then
498 + ebegin "Registering OpenMAX drivers"
499 + BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \
500 + OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \
501 + omxregister-bellagio
502 + eend $?
503 + fi
504 +
505 + # warn about patent encumbered texture-float
506 + if use !bindist; then
507 + elog "USE=\"bindist\" was not set. Potentially patent encumbered code was"
508 + elog "enabled. Please see /usr/share/doc/${P}/patents.txt.bz2 for an"
509 + elog "explanation."
510 + fi
511 +}
512 +
513 +pkg_prerm() {
514 + if use openmax; then
515 + rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister
516 + fi
517 +}
518 +
519 +# $1 - VIDEO_CARDS flag
520 +# other args - names of DRI drivers to enable
521 +# TODO: avoid code duplication for a more elegant implementation
522 +driver_enable() {
523 + case $# in
524 + # for enabling unconditionally
525 + 1)
526 + DRI_DRIVERS+=",$1"
527 + ;;
528 + *)
529 + if use $1; then
530 + shift
531 + for i in $@; do
532 + DRI_DRIVERS+=",${i}"
533 + done
534 + fi
535 + ;;
536 + esac
537 +}
538 +
539 +gallium_enable() {
540 + case $# in
541 + # for enabling unconditionally
542 + 1)
543 + GALLIUM_DRIVERS+=",$1"
544 + ;;
545 + *)
546 + if use $1; then
547 + shift
548 + for i in $@; do
549 + GALLIUM_DRIVERS+=",${i}"
550 + done
551 + fi
552 + ;;
553 + esac
554 +}
555 +
556 +vulkan_enable() {
557 + case $# in
558 + # for enabling unconditionally
559 + 1)
560 + VULKAN_DRIVERS+=",$1"
561 + ;;
562 + *)
563 + if use $1; then
564 + shift
565 + for i in $@; do
566 + VULKAN_DRIVERS+=",${i}"
567 + done
568 + fi
569 + ;;
570 + esac
571 +}