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