1 |
chithanh 14/05/21 14:15:43 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: mesa-10.1.4.ebuild |
5 |
Log: |
6 |
version bump. |
7 |
|
8 |
(Portage version: 2.2.8-r1/cvs/Linux x86_64, unsigned Manifest commit) |
9 |
|
10 |
Revision Changes Path |
11 |
1.559 media-libs/mesa/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/mesa/ChangeLog?rev=1.559&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/mesa/ChangeLog?rev=1.559&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/mesa/ChangeLog?r1=1.558&r2=1.559 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/media-libs/mesa/ChangeLog,v |
20 |
retrieving revision 1.558 |
21 |
retrieving revision 1.559 |
22 |
diff -u -r1.558 -r1.559 |
23 |
--- ChangeLog 15 May 2014 07:39:40 -0000 1.558 |
24 |
+++ ChangeLog 21 May 2014 14:15:43 -0000 1.559 |
25 |
@@ -1,6 +1,12 @@ |
26 |
# ChangeLog for media-libs/mesa |
27 |
# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/ChangeLog,v 1.558 2014/05/15 07:39:40 chithanh Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/ChangeLog,v 1.559 2014/05/21 14:15:43 chithanh Exp $ |
30 |
+ |
31 |
+*mesa-10.1.4 (21 May 2014) |
32 |
+ |
33 |
+ 21 May 2014; Chí-Thanh Christopher Nguyễn <chithanh@g.o> |
34 |
+ +mesa-10.1.4.ebuild: |
35 |
+ version bump. |
36 |
|
37 |
15 May 2014; Chí-Thanh Christopher Nguyễn <chithanh@g.o> |
38 |
mesa-10.1.3.ebuild: |
39 |
|
40 |
|
41 |
|
42 |
1.1 media-libs/mesa/mesa-10.1.4.ebuild |
43 |
|
44 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/mesa/mesa-10.1.4.ebuild?rev=1.1&view=markup |
45 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/mesa/mesa-10.1.4.ebuild?rev=1.1&content-type=text/plain |
46 |
|
47 |
Index: mesa-10.1.4.ebuild |
48 |
=================================================================== |
49 |
# Copyright 1999-2014 Gentoo Foundation |
50 |
# Distributed under the terms of the GNU General Public License v2 |
51 |
# $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/mesa-10.1.4.ebuild,v 1.1 2014/05/21 14:15:43 chithanh Exp $ |
52 |
|
53 |
EAPI=5 |
54 |
|
55 |
EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa" |
56 |
|
57 |
if [[ ${PV} = 9999* ]]; then |
58 |
GIT_ECLASS="git-r3" |
59 |
EXPERIMENTAL="true" |
60 |
fi |
61 |
|
62 |
PYTHON_COMPAT=( python{2_6,2_7} ) |
63 |
|
64 |
inherit base autotools multilib multilib-minimal flag-o-matic \ |
65 |
python-any-r1 toolchain-funcs pax-utils ${GIT_ECLASS} |
66 |
|
67 |
OPENGL_DIR="xorg-x11" |
68 |
|
69 |
MY_PN="${PN/m/M}" |
70 |
MY_P="${MY_PN}-${PV/_/-}" |
71 |
MY_SRC_P="${MY_PN}Lib-${PV/_/-}" |
72 |
|
73 |
FOLDER="${PV/.0/}" |
74 |
|
75 |
DESCRIPTION="OpenGL-like graphic library for Linux" |
76 |
HOMEPAGE="http://mesa3d.sourceforge.net/" |
77 |
|
78 |
#SRC_PATCHES="mirror://gentoo/${P}-gentoo-patches-01.tar.bz2" |
79 |
if [[ $PV = 9999* ]]; then |
80 |
SRC_URI="${SRC_PATCHES}" |
81 |
else |
82 |
SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_SRC_P}.tar.bz2 |
83 |
${SRC_PATCHES}" |
84 |
fi |
85 |
|
86 |
# The code is MIT/X11. |
87 |
# GLES[2]/gl[2]{,ext,platform}.h are SGI-B-2.0 |
88 |
LICENSE="MIT SGI-B-2.0" |
89 |
SLOT="0" |
90 |
KEYWORDS="~alpha ~amd64 ~arm ~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" |
91 |
|
92 |
INTEL_CARDS="i915 i965 ilo intel" |
93 |
RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
94 |
VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno nouveau vmware" |
95 |
for card in ${VIDEO_CARDS}; do |
96 |
IUSE_VIDEO_CARDS+=" video_cards_${card}" |
97 |
done |
98 |
|
99 |
IUSE="${IUSE_VIDEO_CARDS} |
100 |
bindist +classic debug +dri3 +egl +gallium gbm gles1 gles2 +llvm +nptl |
101 |
opencl openvg osmesa pax_kernel pic r600-llvm-compiler selinux |
102 |
vdpau wayland xvmc xa kernel_FreeBSD" |
103 |
|
104 |
REQUIRED_USE=" |
105 |
llvm? ( gallium ) |
106 |
openvg? ( egl gallium ) |
107 |
opencl? ( |
108 |
gallium |
109 |
video_cards_r600? ( r600-llvm-compiler ) |
110 |
video_cards_radeon? ( r600-llvm-compiler ) |
111 |
video_cards_radeonsi? ( r600-llvm-compiler ) |
112 |
) |
113 |
gles1? ( egl ) |
114 |
gles2? ( egl ) |
115 |
r600-llvm-compiler? ( gallium llvm || ( video_cards_r600 video_cards_radeonsi video_cards_radeon ) ) |
116 |
wayland? ( egl gbm ) |
117 |
xa? ( gallium ) |
118 |
video_cards_freedreno? ( gallium ) |
119 |
video_cards_intel? ( || ( classic gallium ) ) |
120 |
video_cards_i915? ( || ( classic gallium ) ) |
121 |
video_cards_i965? ( classic ) |
122 |
video_cards_ilo? ( gallium ) |
123 |
video_cards_nouveau? ( || ( classic gallium ) ) |
124 |
video_cards_radeon? ( || ( classic gallium ) ) |
125 |
video_cards_r100? ( classic ) |
126 |
video_cards_r200? ( classic ) |
127 |
video_cards_r300? ( gallium ) |
128 |
video_cards_r600? ( gallium ) |
129 |
video_cards_radeonsi? ( gallium llvm ) |
130 |
video_cards_vmware? ( gallium ) |
131 |
${PYTHON_REQUIRED_USE} |
132 |
" |
133 |
|
134 |
LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.52" |
135 |
# keep correct libdrm and dri2proto dep |
136 |
# keep blocks in rdepend for binpkg |
137 |
RDEPEND=" |
138 |
!<x11-base/xorg-server-1.7 |
139 |
!<=x11-proto/xf86driproto-2.0.3 |
140 |
abi_x86_32? ( !app-emulation/emul-linux-x86-opengl[-abi_x86_32(-)] ) |
141 |
classic? ( app-admin/eselect-mesa ) |
142 |
gallium? ( app-admin/eselect-mesa ) |
143 |
>=app-admin/eselect-opengl-1.2.7 |
144 |
dev-libs/expat[${MULTILIB_USEDEP}] |
145 |
gbm? ( virtual/udev[${MULTILIB_USEDEP}] ) |
146 |
dri3? ( virtual/udev[${MULTILIB_USEDEP}] ) |
147 |
>=x11-libs/libX11-1.3.99.901[${MULTILIB_USEDEP}] |
148 |
>=x11-libs/libxshmfence-1.1[${MULTILIB_USEDEP}] |
149 |
x11-libs/libXdamage[${MULTILIB_USEDEP}] |
150 |
x11-libs/libXext[${MULTILIB_USEDEP}] |
151 |
x11-libs/libXxf86vm[${MULTILIB_USEDEP}] |
152 |
>=x11-libs/libxcb-1.9.2[${MULTILIB_USEDEP}] |
153 |
llvm? ( |
154 |
video_cards_radeonsi? ( || ( |
155 |
dev-libs/elfutils[${MULTILIB_USEDEP}] |
156 |
dev-libs/libelf[${MULTILIB_USEDEP}] |
157 |
) ) |
158 |
video_cards_r600? ( || ( |
159 |
dev-libs/elfutils[${MULTILIB_USEDEP}] |
160 |
dev-libs/libelf[${MULTILIB_USEDEP}] |
161 |
) ) |
162 |
!video_cards_r600? ( |
163 |
video_cards_radeon? ( || ( |
164 |
dev-libs/elfutils[${MULTILIB_USEDEP}] |
165 |
dev-libs/libelf[${MULTILIB_USEDEP}] |
166 |
) ) |
167 |
) |
168 |
>=sys-devel/llvm-3.3-r3[${MULTILIB_USEDEP}] |
169 |
) |
170 |
opencl? ( |
171 |
app-admin/eselect-opencl |
172 |
dev-libs/libclc |
173 |
) |
174 |
vdpau? ( >=x11-libs/libvdpau-0.4.1[${MULTILIB_USEDEP}] ) |
175 |
wayland? ( >=dev-libs/wayland-1.2.0[${MULTILIB_USEDEP}] ) |
176 |
xvmc? ( >=x11-libs/libXvMC-1.0.6[${MULTILIB_USEDEP}] ) |
177 |
${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vmware?,${MULTILIB_USEDEP}] |
178 |
" |
179 |
for card in ${INTEL_CARDS}; do |
180 |
RDEPEND="${RDEPEND} |
181 |
video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
182 |
" |
183 |
done |
184 |
|
185 |
for card in ${RADEON_CARDS}; do |
186 |
RDEPEND="${RDEPEND} |
187 |
video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
188 |
" |
189 |
done |
190 |
|
191 |
DEPEND="${RDEPEND} |
192 |
llvm? ( |
193 |
r600-llvm-compiler? ( sys-devel/llvm[video_cards_radeon] ) |
194 |
video_cards_radeonsi? ( sys-devel/llvm[video_cards_radeon] ) |
195 |
) |
196 |
opencl? ( |
197 |
>=sys-devel/llvm-3.3-r3[video_cards_radeon,${MULTILIB_USEDEP}] |
198 |
>=sys-devel/clang-3.3[${MULTILIB_USEDEP}] |
199 |
>=sys-devel/gcc-4.6 |
200 |
) |
201 |
sys-devel/bison |
202 |
sys-devel/flex |
203 |
sys-devel/gettext |
204 |
virtual/pkgconfig |
205 |
>=x11-proto/dri2proto-2.6[${MULTILIB_USEDEP}] |
206 |
dri3? ( |
207 |
>=x11-proto/dri3proto-1.0[${MULTILIB_USEDEP}] |
208 |
>=x11-proto/presentproto-1.0[${MULTILIB_USEDEP}] |
209 |
) |
210 |
>=x11-proto/glproto-1.4.15-r1[${MULTILIB_USEDEP}] |
211 |
>=x11-proto/xextproto-7.0.99.1[${MULTILIB_USEDEP}] |
212 |
x11-proto/xf86driproto[${MULTILIB_USEDEP}] |
213 |
x11-proto/xf86vidmodeproto[${MULTILIB_USEDEP}] |
214 |
$(python_gen_any_dep 'dev-libs/libxml2[python,${PYTHON_USEDEP}]') |
215 |
" |
216 |
|
217 |
python_check_deps() { |
218 |
has_version --host-root "dev-libs/libxml2[python,${PYTHON_USEDEP}]" |
219 |
} |
220 |
|
221 |
S="${WORKDIR}/${MY_P}" |
222 |
EGIT_CHECKOUT_DIR=${S} |
223 |
|
224 |
# It is slow without texrels, if someone wants slow |
225 |
# mesa without texrels +pic use is worth the shot |
226 |
QA_EXECSTACK="usr/lib*/opengl/xorg-x11/lib/libGL.so*" |
227 |
QA_WX_LOAD="usr/lib*/opengl/xorg-x11/lib/libGL.so*" |
228 |
|
229 |
# Think about: ggi, fbcon, no-X configs |
230 |
|
231 |
pkg_setup() { |
232 |
# workaround toc-issue wrt #386545 |
233 |
use ppc64 && append-flags -mminimal-toc |
234 |
|
235 |
# warning message for bug 459306 |
236 |
if use llvm && has_version sys-devel/llvm[!debug=]; then |
237 |
ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
238 |
ewarn "detected! This can cause problems. For details, see bug 459306." |
239 |
fi |
240 |
|
241 |
python-any-r1_pkg_setup |
242 |
} |
243 |
|
244 |
src_unpack() { |
245 |
default |
246 |
[[ $PV = 9999* ]] && git-r3_src_unpack |
247 |
} |
248 |
|
249 |
src_prepare() { |
250 |
# apply patches |
251 |
if [[ ${PV} != 9999* && -n ${SRC_PATCHES} ]]; then |
252 |
EPATCH_FORCE="yes" \ |
253 |
EPATCH_SOURCE="${WORKDIR}/patches" \ |
254 |
EPATCH_SUFFIX="patch" \ |
255 |
epatch |
256 |
fi |
257 |
|
258 |
# relax the requirement that r300 must have llvm, bug 380303 |
259 |
epatch "${FILESDIR}"/${PN}-9.2-dont-require-llvm-for-r300.patch |
260 |
|
261 |
# fix for hardened pax_kernel, bug 240956 |
262 |
[[ ${PV} != 9999* ]] && epatch "${FILESDIR}"/glx_ro_text_segm.patch |
263 |
|
264 |
# Solaris needs some recent POSIX stuff in our case |
265 |
if [[ ${CHOST} == *-solaris* ]] ; then |
266 |
sed -i -e "s/-DSVR4/-D_POSIX_C_SOURCE=200112L/" configure.ac || die |
267 |
fi |
268 |
|
269 |
base_src_prepare |
270 |
|
271 |
eautoreconf |
272 |
multilib_copy_sources |
273 |
} |
274 |
|
275 |
multilib_src_configure() { |
276 |
local myconf |
277 |
|
278 |
if use classic; then |
279 |
# Configurable DRI drivers |
280 |
driver_enable swrast |
281 |
|
282 |
# Intel code |
283 |
driver_enable video_cards_i915 i915 |
284 |
driver_enable video_cards_i965 i965 |
285 |
if ! use video_cards_i915 && \ |
286 |
! use video_cards_i965; then |
287 |
driver_enable video_cards_intel i915 i965 |
288 |
fi |
289 |
|
290 |
# Nouveau code |
291 |
driver_enable video_cards_nouveau nouveau |
292 |
|
293 |
# ATI code |
294 |
driver_enable video_cards_r100 radeon |
295 |
driver_enable video_cards_r200 r200 |
296 |
if ! use video_cards_r100 && \ |
297 |
! use video_cards_r200; then |
298 |
driver_enable video_cards_radeon radeon r200 |
299 |
fi |
300 |
fi |
301 |
|
302 |
if use egl; then |
303 |
myconf+="--with-egl-platforms=x11$(use wayland && echo ",wayland")$(use gbm && echo ",drm") " |
304 |
fi |
305 |
|
306 |
if use gallium; then |
307 |
myconf+=" |
308 |
$(use_enable llvm gallium-llvm) |
309 |
$(use_enable openvg) |
310 |
$(use_enable openvg gallium-egl) |
311 |
$(use_enable r600-llvm-compiler) |
312 |
$(use_enable vdpau) |
313 |
$(use_enable xa) |
314 |
$(use_enable xvmc) |
315 |
" |
316 |
gallium_enable swrast |
317 |
gallium_enable video_cards_vmware svga |
318 |
gallium_enable video_cards_nouveau nouveau |
319 |
gallium_enable video_cards_i915 i915 |
320 |
gallium_enable video_cards_ilo ilo |
321 |
if ! use video_cards_i915 && \ |
322 |
! use video_cards_i965; then |
323 |
gallium_enable video_cards_intel i915 |
324 |
fi |
325 |
|
326 |
gallium_enable video_cards_r300 r300 |
327 |
gallium_enable video_cards_r600 r600 |
328 |
gallium_enable video_cards_radeonsi radeonsi |
329 |
if ! use video_cards_r300 && \ |
330 |
! use video_cards_r600; then |
331 |
gallium_enable video_cards_radeon r300 r600 |
332 |
fi |
333 |
|
334 |
gallium_enable video_cards_freedreno freedreno |
335 |
# opencl stuff |
336 |
if use opencl; then |
337 |
myconf+=" |
338 |
$(use_enable opencl) |
339 |
--with-opencl-libdir="${EPREFIX}/usr/$(get_libdir)/OpenCL/vendors/mesa" |
340 |
--with-clang-libdir="${EPREFIX}/usr/lib" |
341 |
" |
342 |
fi |
343 |
fi |
344 |
|
345 |
# x86 hardened pax_kernel needs glx-rts, bug 240956 |
346 |
if use pax_kernel; then |
347 |
myconf+=" |
348 |
$(use_enable x86 glx-rts) |
349 |
" |
350 |
fi |
351 |
|
352 |
# build fails with BSD indent, bug #428112 |
353 |
use userland_GNU || export INDENT=cat |
354 |
|
355 |
econf \ |
356 |
--enable-dri \ |
357 |
--enable-glx \ |
358 |
--enable-shared-glapi \ |
359 |
$(use_enable !bindist texture-float) \ |
360 |
$(use_enable debug) \ |
361 |
$(use_enable dri3) \ |
362 |
$(use_enable egl) \ |
363 |
$(use_enable gbm) \ |
364 |
$(use_enable gles1) \ |
365 |
$(use_enable gles2) \ |
366 |
$(use_enable nptl glx-tls) \ |
367 |
$(use_enable osmesa) \ |
368 |
$(use_enable !pic asm) \ |
369 |
--with-dri-drivers=${DRI_DRIVERS} \ |
370 |
--with-gallium-drivers=${GALLIUM_DRIVERS} \ |
371 |
PYTHON2="${PYTHON}" \ |
372 |
${myconf} |
373 |
} |
374 |
|
375 |
multilib_src_install() { |
376 |
emake install DESTDIR="${D}" |
377 |
|
378 |
# Move libGL and others from /usr/lib to /usr/lib/opengl/blah/lib |
379 |
# because user can eselect desired GL provider. |
380 |
ebegin "Moving libGL and friends for dynamic switching" |
381 |
local x |
382 |
local gl_dir="/usr/$(get_libdir)/opengl/${OPENGL_DIR}/" |
383 |
dodir ${gl_dir}/{lib,extensions,include/GL} |
384 |
for x in "${ED}"/usr/$(get_libdir)/lib{EGL,GL*,OpenVG}.{la,a,so*}; do |
385 |
if [ -f ${x} -o -L ${x} ]; then |
386 |
mv -f "${x}" "${ED}${gl_dir}"/lib \ |
387 |
|| die "Failed to move ${x}" |
388 |
fi |
389 |
done |
390 |
for x in "${ED}"/usr/include/GL/{gl.h,glx.h,glext.h,glxext.h}; do |
391 |
if [ -f ${x} -o -L ${x} ]; then |
392 |
mv -f "${x}" "${ED}${gl_dir}"/include/GL \ |
393 |
|| die "Failed to move ${x}" |
394 |
fi |
395 |
done |
396 |
for x in "${ED}"/usr/include/{EGL,GLES*,VG,KHR}; do |
397 |
if [ -d ${x} ]; then |
398 |
mv -f "${x}" "${ED}${gl_dir}"/include \ |
399 |
|| die "Failed to move ${x}" |
400 |
fi |
401 |
done |
402 |
eend $? |
403 |
|
404 |
if use classic || use gallium; then |
405 |
ebegin "Moving DRI/Gallium drivers for dynamic switching" |
406 |
local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so ) |
407 |
keepdir /usr/$(get_libdir)/dri |
408 |
dodir /usr/$(get_libdir)/mesa |
409 |
for x in ${gallium_drivers[@]}; do |
410 |
if [ -f "$(get_libdir)/gallium/${x}" ]; then |
411 |
mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \ |
412 |
|| die "Failed to move ${x}" |
413 |
fi |
414 |
done |
415 |
if use classic; then |
416 |
emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install |
417 |
fi |
418 |
for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do |
419 |
if [ -f ${x} -o -L ${x} ]; then |
420 |
mv -f "${x}" "${x/dri/mesa}" \ |
421 |
|| die "Failed to move ${x}" |
422 |
fi |
423 |
done |
424 |
pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed" |
425 |
ln -s ../mesa/*.so . || die "Creating symlink failed" |
426 |
# remove symlinks to drivers known to eselect |
427 |
for x in ${gallium_drivers[@]}; do |
428 |
if [ -f ${x} -o -L ${x} ]; then |
429 |
rm "${x}" || die "Failed to remove ${x}" |
430 |
fi |
431 |
done |
432 |
popd |
433 |
eend $? |
434 |
fi |
435 |
if use opencl; then |
436 |
ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching" |
437 |
local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa" |
438 |
dodir ${cl_dir}/{lib,include} |
439 |
if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then |
440 |
mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \ |
441 |
"${ED}"${cl_dir} |
442 |
fi |
443 |
if [ -f "${ED}/usr/include/CL/opencl.h" ]; then |
444 |
mv -f "${ED}"/usr/include/CL \ |
445 |
"${ED}"${cl_dir}/include |
446 |
fi |
447 |
eend $? |
448 |
fi |
449 |
} |
450 |
|
451 |
multilib_src_install_all() { |
452 |
prune_libtool_files --all |
453 |
einstalldocs |
454 |
|
455 |
if use !bindist; then |
456 |
dodoc docs/patents.txt |
457 |
fi |
458 |
|
459 |
# Install config file for eselect mesa |
460 |
insinto /usr/share/mesa |
461 |
newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf |
462 |
} |
463 |
|
464 |
multilib_src_test() { |
465 |
if use llvm; then |
466 |
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' |
467 |
pushd src/gallium/drivers/llvmpipe >/dev/null || die |
468 |
emake ${llvm_tests} |
469 |
pax-mark m ${llvm_tests} |
470 |
popd >/dev/null || die |
471 |
fi |
472 |
emake check |
473 |
} |
474 |
|
475 |
pkg_postinst() { |
476 |
# Switch to the xorg implementation. |
477 |
echo |
478 |
eselect opengl set --use-old ${OPENGL_DIR} |
479 |
|
480 |
# switch to xorg-x11 and back if necessary, bug #374647 comment 11 |
481 |
OLD_IMPLEM="$(eselect opengl show)" |
482 |
if [[ ${OPENGL_DIR}x != ${OLD_IMPLEM}x ]]; then |
483 |
eselect opengl set ${OPENGL_DIR} |
484 |
eselect opengl set ${OLD_IMPLEM} |
485 |
fi |
486 |
|
487 |
# Select classic/gallium drivers |
488 |
if use classic || use gallium; then |
489 |
eselect mesa set --auto |
490 |
fi |
491 |
|
492 |
# Switch to mesa opencl |
493 |
if use opencl; then |
494 |
eselect opencl set --use-old ${PN} |
495 |
fi |
496 |
|
497 |
# warn about patent encumbered texture-float |
498 |
if use !bindist; then |
499 |
elog "USE=\"bindist\" was not set. Potentially patent encumbered code was" |
500 |
elog "enabled. Please see patents.txt for an explanation." |
501 |
fi |
502 |
|
503 |
local using_radeon r_flag |
504 |
for r_flag in ${RADEON_CARDS}; do |
505 |
if use video_cards_${r_flag}; then |
506 |
using_radeon=1 |
507 |
break |
508 |
fi |
509 |
done |
510 |
|
511 |
if [[ ${using_radeon} = 1 ]] && ! has_version media-libs/libtxc_dxtn; then |
512 |
elog "Note that in order to have full S3TC support, it is necessary to install" |
513 |
elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice" |
514 |
elog "textures in some apps, and some others even require this to run." |
515 |
fi |
516 |
} |
517 |
|
518 |
# $1 - VIDEO_CARDS flag |
519 |
# other args - names of DRI drivers to enable |
520 |
# TODO: avoid code duplication for a more elegant implementation |
521 |
driver_enable() { |
522 |
case $# in |
523 |
# for enabling unconditionally |
524 |
1) |
525 |
DRI_DRIVERS+=",$1" |
526 |
;; |
527 |
*) |
528 |
if use $1; then |
529 |
shift |
530 |
for i in $@; do |
531 |
DRI_DRIVERS+=",${i}" |
532 |
done |
533 |
fi |
534 |
;; |
535 |
esac |
536 |
} |
537 |
|
538 |
gallium_enable() { |
539 |
case $# in |
540 |
# for enabling unconditionally |
541 |
1) |
542 |
GALLIUM_DRIVERS+=",$1" |
543 |
;; |
544 |
*) |
545 |
if use $1; then |
546 |
shift |
547 |
for i in $@; do |
548 |
GALLIUM_DRIVERS+=",${i}" |
549 |
done |
550 |
fi |
551 |
;; |
552 |
esac |
553 |
} |