Gentoo Archives: gentoo-commits

From: "Manuel Rüger" <mrueg@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/mesa/
Date: Sun, 20 Sep 2015 13:38:52
Message-Id: 1442756229.bdaac4ab8885120494d4fb8d66b2591393bdc549.mrueg@gentoo
1 commit: bdaac4ab8885120494d4fb8d66b2591393bdc549
2 Author: Manuel Rüger <mrueg <AT> gentoo <DOT> org>
3 AuthorDate: Sun Sep 20 13:37:09 2015 +0000
4 Commit: Manuel Rüger <mrueg <AT> gentoo <DOT> org>
5 CommitDate: Sun Sep 20 13:37:09 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bdaac4ab
7
8 media-libs/mesa: Version bump
9
10 Package-Manager: portage-2.2.20.1
11
12 media-libs/mesa/Manifest | 1 +
13 media-libs/mesa/mesa-10.6.8.ebuild | 463 +++++++++++++++++++++++++++++++++++++
14 2 files changed, 464 insertions(+)
15
16 diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest
17 index 62cd236..011e964 100644
18 --- a/media-libs/mesa/Manifest
19 +++ b/media-libs/mesa/Manifest
20 @@ -5,6 +5,7 @@ DIST MesaLib-7.10.3.tar.bz2 6056837 SHA256 1e701fc839b872677ddca9ed8784d754c9da1
21 DIST mesa-10.5.8.tar.xz 6993084 SHA256 2866b855c5299a4aed066338c77ff6467c389b2c30ada7647be8758663da2b54 SHA512 d7fc441b4cdad8a2905f03091af26ca7b01573bf4d0d928e950270981e4c6e7d20dba6aa97a60500b9a335a3c5cabc7f388a5338d43d391eed3f09dea60b77b2 WHIRLPOOL 68cc3d8490da9759b9d790053c70429be4c529c63b114f65f411112f76cd4daccc3490120a85a84d01cdcb989c0a0e58016b4d80f2238f2320b1caff797f3390
22 DIST mesa-10.6.5.tar.xz 7037400 SHA256 fb6fac3c85bcfa9d06b8dd439169f23f0c0924a88e44362e738b99b1feff762f SHA512 46be6bd683d286bdf9ab8b4c1b1b32f89c95701b8c48cee49b060f5beaacea4540a69b99b4fde0f80acdd8e725552bef17dbd4251b9e977caeb5fd9d0ba56595 WHIRLPOOL dee48a0c680aae01cc39dc9157ea7c4c353b7ffdf543ab1cde8e76612a462ff3e3cb33433abff6d88f6800b71a02cd8cfcc23be98218d3cc4f85f424f3d12474
23 DIST mesa-10.6.6.tar.xz 7040744 SHA256 570f2154b7340ff5db61ff103bc6e85165b8958798b78a50fa2df488e98e5778 SHA512 a251dc258ccf2fbeccbff3447a23c0f417722244322c8887fe4a50b0013d3da3705ffbfe412b61717d2c3370cb6a88bec51b91e1b77a5b987d6fbf0fdbfe4a5e WHIRLPOOL 6f441a5b19b496d14b659b1ba3b70d2ead685ab1eb7d77b77c24d69127bd69ce6453feed1e042840bdb6cf47f68caa61c73c07ec2259a697acc3393e42111be6
24 +DIST mesa-10.6.8.tar.xz 7042260 SHA256 e36ee5ceeadb3966fb5ce5b4cf18322dbb76a4f075558ae49c3bba94f57d58fd SHA512 ebb2daff1afcc5f6808c5c9948814014c0570b18fb91481c9d09b2c28776ce6e4fd8bba650e559ac5d87d30fe06b38032c78828c13b95d5f9a0338d44b75f61e WHIRLPOOL e94395c0954875c9b1eaa6692385593a24242c3915012dcf8fcfa7b0d16cff33fc80421234dccdfafa4ecb9b82a176f177cf7ec622f6b80eac6de4cfcb5c7552
25 DIST mesa-11.0.0-rc3.tar.xz 7256736 SHA256 6188679020894140d923eff3c62485a1ee942a8c1c3a2fe617addfca607f916f SHA512 ae0563369d7f0508f4701cabe505701f81dcdbd4797dbc99aa24014bd29f7b7c6d84e7460ffe8d8a7d424b7e59fedae49aacc28e51a01939f0d07af105d57599 WHIRLPOOL 870e4361d15ebb19525f3b4a1e60be172b73ba0b9aa2b469e015f2c79b63c8a0afec2808de13d4fe699edad33f91e49ee896fc5efeeb90ce9ca1be999984c8e2
26 DIST mesa-11.0.0.tar.xz 7257112 SHA256 e095a3eb2eca9dfde7efca8946527c8ae20a0cc938a8c78debc7f158ad44af32 SHA512 9938010f3d5e72bb8dea371e3502622e2ff6eae14e0265011df8fc81ec915d632abda9be7e772828adb8f0c7c12c830d89dce42e196ca18489fb1386a766220f WHIRLPOOL 454466396fac029450b619c842fa1e34906e5c529a67a575e9096f9e9b1584ad5b00f9ada2656e0469d5cf6d94e966709d4e0253484eb03d32f93e3e7d521f78
27 DIST mesa-7.10.1-gentoo-patches-01.tar.bz2 5488 SHA256 31cd4f6d1a0a70249c40452919074856d120cd473a01a8457e3dc147a1b622d8 SHA512 c62b45b32e396e67f629003fc5242b7b4df054b8e20b5237489212bc4f0171534915a02fc9efa68965068121d10660b5cd92a419efabe33fd4596a97a39249c2 WHIRLPOOL 5f171959e3a31f5c38438b4806ce371bb8fdf1c7a87501865e4ed5d5ab284cda9568b7773005997d7a1cff151f95e64c027b36c0be48a4dd288a7ab8b5f69b97
28
29 diff --git a/media-libs/mesa/mesa-10.6.8.ebuild b/media-libs/mesa/mesa-10.6.8.ebuild
30 new file mode 100644
31 index 0000000..4386f87
32 --- /dev/null
33 +++ b/media-libs/mesa/mesa-10.6.8.ebuild
34 @@ -0,0 +1,463 @@
35 +# Copyright 1999-2015 Gentoo Foundation
36 +# Distributed under the terms of the GNU General Public License v2
37 +# $Id$
38 +
39 +EAPI=5
40 +
41 +EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa"
42 +
43 +if [[ ${PV} = 9999* ]]; then
44 + GIT_ECLASS="git-r3"
45 + EXPERIMENTAL="true"
46 +fi
47 +
48 +PYTHON_COMPAT=( python2_7 )
49 +
50 +inherit autotools multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS}
51 +
52 +OPENGL_DIR="xorg-x11"
53 +
54 +MY_P="${P/_/-}"
55 +FOLDER="${PV/_rc*/}"
56 +
57 +DESCRIPTION="OpenGL-like graphic library for Linux"
58 +HOMEPAGE="http://mesa3d.sourceforge.net/"
59 +
60 +if [[ $PV == 9999* ]]; then
61 + SRC_URI=""
62 +else
63 + SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_P}.tar.xz"
64 +fi
65 +
66 +LICENSE="MIT"
67 +SLOT="0"
68 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~arm-linux ~ia64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
69 +RESTRICT="!bindist? ( bindist )"
70 +
71 +INTEL_CARDS="i915 i965 ilo intel"
72 +RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
73 +VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno nouveau vmware"
74 +for card in ${VIDEO_CARDS}; do
75 + IUSE_VIDEO_CARDS+=" video_cards_${card}"
76 +done
77 +
78 +IUSE="${IUSE_VIDEO_CARDS}
79 + bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm
80 + +nptl opencl osmesa pax_kernel openmax pic selinux +udev vaapi vdpau
81 + wayland xvmc xa kernel_FreeBSD"
82 +
83 +REQUIRED_USE="
84 + d3d9? ( dri3 gallium )
85 + llvm? ( gallium )
86 + opencl? ( gallium llvm )
87 + openmax? ( gallium )
88 + gles1? ( egl )
89 + gles2? ( egl )
90 + vaapi? ( gallium )
91 + vdpau? ( gallium )
92 + wayland? ( egl gbm )
93 + xa? ( gallium )
94 + video_cards_freedreno? ( gallium )
95 + video_cards_intel? ( classic )
96 + video_cards_i915? ( || ( classic gallium ) )
97 + video_cards_i965? ( classic )
98 + video_cards_ilo? ( gallium )
99 + video_cards_nouveau? ( || ( classic gallium ) )
100 + video_cards_radeon? ( || ( classic gallium ) )
101 + video_cards_r100? ( classic )
102 + video_cards_r200? ( classic )
103 + video_cards_r300? ( gallium llvm )
104 + video_cards_r600? ( gallium )
105 + video_cards_radeonsi? ( gallium llvm )
106 + video_cards_vmware? ( gallium )
107 + ${PYTHON_REQUIRED_USE}
108 +"
109 +
110 +LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.60"
111 +# keep correct libdrm and dri2proto dep
112 +# keep blocks in rdepend for binpkg
113 +RDEPEND="
114 + !<x11-base/xorg-server-1.7
115 + !<=x11-proto/xf86driproto-2.0.3
116 + abi_x86_32? ( !app-emulation/emul-linux-x86-opengl[-abi_x86_32(-)] )
117 + classic? ( app-eselect/eselect-mesa )
118 + gallium? ( app-eselect/eselect-mesa )
119 + >=app-eselect/eselect-opengl-1.3.0
120 + udev? ( kernel_linux? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] ) )
121 + >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
122 + gbm? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
123 + dri3? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
124 + >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
125 + >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
126 + >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
127 + >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
128 + >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
129 + >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}]
130 + x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
131 + llvm? (
132 + video_cards_radeonsi? ( || (
133 + >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
134 + >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
135 + ) )
136 + !video_cards_r600? (
137 + video_cards_radeon? ( || (
138 + >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
139 + >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
140 + ) )
141 + )
142 + >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
143 + )
144 + opencl? (
145 + app-eselect/eselect-opencl
146 + dev-libs/libclc
147 + || (
148 + >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
149 + >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
150 + )
151 + )
152 + openmax? ( >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] )
153 + vaapi? ( >=x11-libs/libva-0.35.0:=[${MULTILIB_USEDEP}] )
154 + vdpau? ( >=x11-libs/libvdpau-0.7:=[${MULTILIB_USEDEP}] )
155 + wayland? ( >=dev-libs/wayland-1.2.0:=[${MULTILIB_USEDEP}] )
156 + xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
157 + ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vmware?,${MULTILIB_USEDEP}]
158 +"
159 +for card in ${INTEL_CARDS}; do
160 + RDEPEND="${RDEPEND}
161 + video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
162 + "
163 +done
164 +
165 +for card in ${RADEON_CARDS}; do
166 + RDEPEND="${RDEPEND}
167 + video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
168 + "
169 +done
170 +
171 +DEPEND="${RDEPEND}
172 + llvm? (
173 + video_cards_radeonsi? ( sys-devel/llvm[video_cards_radeon] )
174 + )
175 + opencl? (
176 + >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
177 + >=sys-devel/clang-3.4.2:=[${MULTILIB_USEDEP}]
178 + >=sys-devel/gcc-4.6
179 + )
180 + sys-devel/gettext
181 + virtual/pkgconfig
182 + >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}]
183 + dri3? (
184 + >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}]
185 + >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}]
186 + )
187 + >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}]
188 + >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}]
189 + >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}]
190 + >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}]
191 +"
192 +[[ ${PV} == "9999" ]] && DEPEND+="
193 + sys-devel/bison
194 + sys-devel/flex
195 + ${PYTHON_DEPS}
196 + $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
197 +"
198 +
199 +S="${WORKDIR}/${MY_P}"
200 +EGIT_CHECKOUT_DIR=${S}
201 +
202 +QA_WX_LOAD="
203 +x86? (
204 + !pic? (
205 + usr/lib*/libglapi.so.0.0.0
206 + usr/lib*/libGLESv1_CM.so.1.1.0
207 + usr/lib*/libGLESv2.so.2.0.0
208 + usr/lib*/libGL.so.1.2.0
209 + usr/lib*/libOSMesa.so.8.0.0
210 + )
211 +)"
212 +
213 +pkg_setup() {
214 + # warning message for bug 459306
215 + if use llvm && has_version sys-devel/llvm[!debug=]; then
216 + ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
217 + ewarn "detected! This can cause problems. For details, see bug 459306."
218 + fi
219 +
220 + python-any-r1_pkg_setup
221 +}
222 +
223 +src_prepare() {
224 + # fix for hardened pax_kernel, bug 240956
225 + [[ ${PV} != 9999* ]] && epatch "${FILESDIR}"/glx_ro_text_segm.patch
226 +
227 + eautoreconf
228 +}
229 +
230 +multilib_src_configure() {
231 + local myconf
232 +
233 + if use classic; then
234 + # Configurable DRI drivers
235 + driver_enable swrast
236 +
237 + # Intel code
238 + driver_enable video_cards_i915 i915
239 + driver_enable video_cards_i965 i965
240 + if ! use video_cards_i915 && \
241 + ! use video_cards_i965; then
242 + driver_enable video_cards_intel i915 i965
243 + fi
244 +
245 + # Nouveau code
246 + driver_enable video_cards_nouveau nouveau
247 +
248 + # ATI code
249 + driver_enable video_cards_r100 radeon
250 + driver_enable video_cards_r200 r200
251 + if ! use video_cards_r100 && \
252 + ! use video_cards_r200; then
253 + driver_enable video_cards_radeon radeon r200
254 + fi
255 + fi
256 +
257 + if use egl; then
258 + myconf+="--with-egl-platforms=x11$(use wayland && echo ",wayland")$(use gbm && echo ",drm") "
259 + fi
260 +
261 + if use gallium; then
262 + myconf+="
263 + $(use_enable d3d9 nine)
264 + $(use_enable llvm gallium-llvm)
265 + $(use_enable openmax omx)
266 + $(use_enable vaapi va)
267 + $(use_enable vdpau)
268 + $(use_enable xa)
269 + $(use_enable xvmc)
270 + "
271 + use vaapi && myconf+="--with-va-libdir=/usr/$(get_libdir)/va/drivers"
272 +
273 + gallium_enable swrast
274 + gallium_enable video_cards_vmware svga
275 + gallium_enable video_cards_nouveau nouveau
276 + gallium_enable video_cards_i915 i915
277 + gallium_enable video_cards_ilo ilo
278 + if ! use video_cards_i915 && \
279 + ! use video_cards_i965; then
280 + gallium_enable video_cards_intel i915
281 + fi
282 +
283 + gallium_enable video_cards_r300 r300
284 + gallium_enable video_cards_r600 r600
285 + gallium_enable video_cards_radeonsi radeonsi
286 + if ! use video_cards_r300 && \
287 + ! use video_cards_r600; then
288 + gallium_enable video_cards_radeon r300 r600
289 + fi
290 +
291 + gallium_enable video_cards_freedreno freedreno
292 + # opencl stuff
293 + if use opencl; then
294 + myconf+="
295 + $(use_enable opencl)
296 + --with-clang-libdir="${EPREFIX}/usr/lib"
297 + "
298 + fi
299 + fi
300 +
301 + # x86 hardened pax_kernel needs glx-rts, bug 240956
302 + if use pax_kernel; then
303 + myconf+="
304 + $(use_enable x86 glx-rts)
305 + "
306 + fi
307 +
308 + # on abi_x86_32 hardened we need to have asm disable
309 + if [[ ${ABI} == x86* ]] && use pic; then
310 + myconf+=" --disable-asm"
311 + fi
312 +
313 + # build fails with BSD indent, bug #428112
314 + use userland_GNU || export INDENT=cat
315 +
316 + ECONF_SOURCE="${S}" \
317 + econf \
318 + --enable-dri \
319 + --enable-glx \
320 + --enable-shared-glapi \
321 + $(use_enable !bindist texture-float) \
322 + $(use_enable d3d9 nine) \
323 + $(use_enable debug) \
324 + $(use_enable dri3) \
325 + $(use_enable egl) \
326 + $(use_enable gbm) \
327 + $(use_enable gles1) \
328 + $(use_enable gles2) \
329 + $(use_enable nptl glx-tls) \
330 + $(use_enable osmesa) \
331 + $(use_enable !udev sysfs) \
332 + --enable-llvm-shared-libs \
333 + --with-dri-drivers=${DRI_DRIVERS} \
334 + --with-gallium-drivers=${GALLIUM_DRIVERS} \
335 + PYTHON2="${PYTHON}" \
336 + ${myconf}
337 +}
338 +
339 +multilib_src_install() {
340 + emake install DESTDIR="${D}"
341 +
342 + if use classic || use gallium; then
343 + ebegin "Moving DRI/Gallium drivers for dynamic switching"
344 + local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so )
345 + keepdir /usr/$(get_libdir)/dri
346 + dodir /usr/$(get_libdir)/mesa
347 + for x in ${gallium_drivers[@]}; do
348 + if [ -f "$(get_libdir)/gallium/${x}" ]; then
349 + mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \
350 + || die "Failed to move ${x}"
351 + fi
352 + done
353 + if use classic; then
354 + emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install
355 + fi
356 + for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do
357 + if [ -f ${x} -o -L ${x} ]; then
358 + mv -f "${x}" "${x/dri/mesa}" \
359 + || die "Failed to move ${x}"
360 + fi
361 + done
362 + pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed"
363 + ln -s ../mesa/*.so . || die "Creating symlink failed"
364 + # remove symlinks to drivers known to eselect
365 + for x in ${gallium_drivers[@]}; do
366 + if [ -f ${x} -o -L ${x} ]; then
367 + rm "${x}" || die "Failed to remove ${x}"
368 + fi
369 + done
370 + popd
371 + eend $?
372 + fi
373 + if use opencl; then
374 + ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching"
375 + local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa"
376 + dodir ${cl_dir}/{lib,include}
377 + if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then
378 + mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \
379 + "${ED}"${cl_dir}
380 + fi
381 + if [ -f "${ED}/usr/include/CL/opencl.h" ]; then
382 + mv -f "${ED}"/usr/include/CL \
383 + "${ED}"${cl_dir}/include
384 + fi
385 + eend $?
386 + fi
387 +
388 + if use openmax; then
389 + echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx"
390 + doenvd "${T}"/99mesaxdgomx
391 + keepdir /usr/share/mesa/xdg
392 + fi
393 +}
394 +
395 +multilib_src_install_all() {
396 + prune_libtool_files --all
397 + einstalldocs
398 +
399 + if use !bindist; then
400 + dodoc docs/patents.txt
401 + fi
402 +
403 + # Install config file for eselect mesa
404 + insinto /usr/share/mesa
405 + newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf
406 +}
407 +
408 +multilib_src_test() {
409 + if use llvm; then
410 + 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'
411 + pushd src/gallium/drivers/llvmpipe >/dev/null || die
412 + emake ${llvm_tests}
413 + pax-mark m ${llvm_tests}
414 + popd >/dev/null || die
415 + fi
416 + emake check
417 +}
418 +
419 +pkg_postinst() {
420 + # Switch to the xorg implementation.
421 + echo
422 + eselect opengl set --use-old ${OPENGL_DIR}
423 +
424 + # Select classic/gallium drivers
425 + if use classic || use gallium; then
426 + eselect mesa set --auto
427 + fi
428 +
429 + # Switch to mesa opencl
430 + if use opencl; then
431 + eselect opencl set --use-old ${PN}
432 + fi
433 +
434 + # run omxregister-bellagio to make the OpenMAX drivers known system-wide
435 + if use openmax; then
436 + ebegin "Registering OpenMAX drivers"
437 + BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \
438 + OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \
439 + omxregister-bellagio
440 + eend $?
441 + fi
442 +
443 + # warn about patent encumbered texture-float
444 + if use !bindist; then
445 + elog "USE=\"bindist\" was not set. Potentially patent encumbered code was"
446 + elog "enabled. Please see patents.txt for an explanation."
447 + fi
448 +
449 + if ! has_version media-libs/libtxc_dxtn; then
450 + elog "Note that in order to have full S3TC support, it is necessary to install"
451 + elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice"
452 + elog "textures in some apps, and some others even require this to run."
453 + fi
454 +}
455 +
456 +pkg_prerm() {
457 + if use openmax; then
458 + rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister
459 + fi
460 +}
461 +
462 +# $1 - VIDEO_CARDS flag
463 +# other args - names of DRI drivers to enable
464 +# TODO: avoid code duplication for a more elegant implementation
465 +driver_enable() {
466 + case $# in
467 + # for enabling unconditionally
468 + 1)
469 + DRI_DRIVERS+=",$1"
470 + ;;
471 + *)
472 + if use $1; then
473 + shift
474 + for i in $@; do
475 + DRI_DRIVERS+=",${i}"
476 + done
477 + fi
478 + ;;
479 + esac
480 +}
481 +
482 +gallium_enable() {
483 + case $# in
484 + # for enabling unconditionally
485 + 1)
486 + GALLIUM_DRIVERS+=",$1"
487 + ;;
488 + *)
489 + if use $1; then
490 + shift
491 + for i in $@; do
492 + GALLIUM_DRIVERS+=",${i}"
493 + done
494 + fi
495 + ;;
496 + esac
497 +}