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, 11 Oct 2015 12:41:18
Message-Id: 1444567252.9a065a4407d26e1bb14ee1a274beb7f7f5eaf047.mrueg@gentoo
1 commit: 9a065a4407d26e1bb14ee1a274beb7f7f5eaf047
2 Author: Manuel Rüger <mrueg <AT> gentoo <DOT> org>
3 AuthorDate: Sun Oct 11 12:35:01 2015 +0000
4 Commit: Manuel Rüger <mrueg <AT> gentoo <DOT> org>
5 CommitDate: Sun Oct 11 12:40:52 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9a065a44
7
8 media-libs/mesa: Remove old
9
10 Package-Manager: portage-2.2.23
11
12 media-libs/mesa/Manifest | 4 -
13 media-libs/mesa/mesa-10.6.6.ebuild | 463 ------------------------------------
14 media-libs/mesa/mesa-10.6.8.ebuild | 463 ------------------------------------
15 media-libs/mesa/mesa-11.0.0.ebuild | 466 -------------------------------------
16 media-libs/mesa/mesa-11.0.2.ebuild | 462 ------------------------------------
17 5 files changed, 1858 deletions(-)
18
19 diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest
20 index 06194af..0bc5c95 100644
21 --- a/media-libs/mesa/Manifest
22 +++ b/media-libs/mesa/Manifest
23 @@ -3,10 +3,6 @@ DIST MesaLib-10.3.7.tar.bz2 7287153 SHA256 43c6ced15e237cbb21b3082d7c0b42777c50c
24 DIST MesaLib-10.4.6.tar.bz2 7520024 SHA256 d8baedd20e79ccd98a5a7b05e23d59a30892e68de1fcc057ca6873dafca02735 SHA512 1a379de8471f9154aa1348c15d24a56788e42b666094d63aa5dc8bffd1ed87c1ab50fb95adac010a92d832be4ec1be60b712179ad1ec99869ee653ccb576f50e WHIRLPOOL 45ff4f46a9c165c2cd3f49696f9d972216fdbc27051287d4eea4210f25631fb1faca517a714cc50229c463be1628dfbf71ba689d02ed3b3d52bfc71683fe667e
25 DIST MesaLib-7.10.3.tar.bz2 6056837 SHA256 1e701fc839b872677ddca9ed8784d754c9da1fbeda98173980e06aa7df0e85c0 SHA512 aa1f5f068b305fae5519e11cad2db9c6dc647d3122252bbcb210f13ac6ef1b667ae750344898bca7c5bfae94934db05eff915cb7417a59590e6d3ba230817aa8 WHIRLPOOL 5c2adda647936ed4163a4e4d5afad8344eb576712f9432f697aa0fc22ca17d7aaf0aeb6ad2d4e7e0825dc27cae570660332450778f8091e9b27aad2865c9b5fc
26 DIST mesa-10.5.8.tar.xz 6993084 SHA256 2866b855c5299a4aed066338c77ff6467c389b2c30ada7647be8758663da2b54 SHA512 d7fc441b4cdad8a2905f03091af26ca7b01573bf4d0d928e950270981e4c6e7d20dba6aa97a60500b9a335a3c5cabc7f388a5338d43d391eed3f09dea60b77b2 WHIRLPOOL 68cc3d8490da9759b9d790053c70429be4c529c63b114f65f411112f76cd4daccc3490120a85a84d01cdcb989c0a0e58016b4d80f2238f2320b1caff797f3390
27 -DIST mesa-10.6.6.tar.xz 7040744 SHA256 570f2154b7340ff5db61ff103bc6e85165b8958798b78a50fa2df488e98e5778 SHA512 a251dc258ccf2fbeccbff3447a23c0f417722244322c8887fe4a50b0013d3da3705ffbfe412b61717d2c3370cb6a88bec51b91e1b77a5b987d6fbf0fdbfe4a5e WHIRLPOOL 6f441a5b19b496d14b659b1ba3b70d2ead685ab1eb7d77b77c24d69127bd69ce6453feed1e042840bdb6cf47f68caa61c73c07ec2259a697acc3393e42111be6
28 -DIST mesa-10.6.8.tar.xz 7042260 SHA256 e36ee5ceeadb3966fb5ce5b4cf18322dbb76a4f075558ae49c3bba94f57d58fd SHA512 ebb2daff1afcc5f6808c5c9948814014c0570b18fb91481c9d09b2c28776ce6e4fd8bba650e559ac5d87d30fe06b38032c78828c13b95d5f9a0338d44b75f61e WHIRLPOOL e94395c0954875c9b1eaa6692385593a24242c3915012dcf8fcfa7b0d16cff33fc80421234dccdfafa4ecb9b82a176f177cf7ec622f6b80eac6de4cfcb5c7552
29 DIST mesa-10.6.9.tar.xz 7041588 SHA256 b04c4de6280b863babc2929573da17218d92e9e4ba6272d548d135415723e8c3 SHA512 32abcf167312dea06482e46da6f15b1c6902696a7dff759561f099eb12a6748673a5d6bb084c12ef57e6f13d3ec1b456541611a710519da87b11fd622f453344 WHIRLPOOL d3bf4627bdf7a576343bd2701948d5872e5d05a43b2980ce4e4915e8d95bd85eadb563cb3588918c55307769132a0cc8592361b4c9fbdf4831c181604d79028b
30 -DIST mesa-11.0.0.tar.xz 7257112 SHA256 e095a3eb2eca9dfde7efca8946527c8ae20a0cc938a8c78debc7f158ad44af32 SHA512 9938010f3d5e72bb8dea371e3502622e2ff6eae14e0265011df8fc81ec915d632abda9be7e772828adb8f0c7c12c830d89dce42e196ca18489fb1386a766220f WHIRLPOOL 454466396fac029450b619c842fa1e34906e5c529a67a575e9096f9e9b1584ad5b00f9ada2656e0469d5cf6d94e966709d4e0253484eb03d32f93e3e7d521f78
31 -DIST mesa-11.0.2.tar.xz 7263112 SHA256 fce11fb27eb87adf1e620a76455d635c6136dfa49ae58c53b34ef8d0c7b7eae4 SHA512 5b388c7464a97259b43f0c95114ddb6ea8d748a53a495202a01aa757baf5784c66c57e1f462a909bb9b3bf1239aa4fcbefbfc9fad2376a8288493304a2988ec4 WHIRLPOOL b4dd696c6135dd5f9711727ab57d042941a8b949010192544138f184086d90f1e9da1408ea937c95e831788c0797317d938e40948ae25226928ea14f77503859
32 DIST mesa-11.0.3.tar.xz 7264824 SHA256 ab2992eece21adc23c398720ef8c6933cb69ea42e1b2611dc09d031e17e033d6 SHA512 7cec13749a600e589794c4b7c082bcbe47d708d3e4a670160a09b07a0c5afc301b984ac4e26519ed3acda6171f936f700eb62c0977cc392343822603ff6c7c15 WHIRLPOOL edcef9df038384cace1b650efbd0245dc6b7ecdd6e22d35a57590d919b1bceb73ff5b531b441b06da806ff1efe357872d1f16d3d0364fbd85000a2d7b406391f
33 DIST mesa-7.10.1-gentoo-patches-01.tar.bz2 5488 SHA256 31cd4f6d1a0a70249c40452919074856d120cd473a01a8457e3dc147a1b622d8 SHA512 c62b45b32e396e67f629003fc5242b7b4df054b8e20b5237489212bc4f0171534915a02fc9efa68965068121d10660b5cd92a419efabe33fd4596a97a39249c2 WHIRLPOOL 5f171959e3a31f5c38438b4806ce371bb8fdf1c7a87501865e4ed5d5ab284cda9568b7773005997d7a1cff151f95e64c027b36c0be48a4dd288a7ab8b5f69b97
34
35 diff --git a/media-libs/mesa/mesa-10.6.6.ebuild b/media-libs/mesa/mesa-10.6.6.ebuild
36 deleted file mode 100644
37 index 4386f87..0000000
38 --- a/media-libs/mesa/mesa-10.6.6.ebuild
39 +++ /dev/null
40 @@ -1,463 +0,0 @@
41 -# Copyright 1999-2015 Gentoo Foundation
42 -# Distributed under the terms of the GNU General Public License v2
43 -# $Id$
44 -
45 -EAPI=5
46 -
47 -EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa"
48 -
49 -if [[ ${PV} = 9999* ]]; then
50 - GIT_ECLASS="git-r3"
51 - EXPERIMENTAL="true"
52 -fi
53 -
54 -PYTHON_COMPAT=( python2_7 )
55 -
56 -inherit autotools multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS}
57 -
58 -OPENGL_DIR="xorg-x11"
59 -
60 -MY_P="${P/_/-}"
61 -FOLDER="${PV/_rc*/}"
62 -
63 -DESCRIPTION="OpenGL-like graphic library for Linux"
64 -HOMEPAGE="http://mesa3d.sourceforge.net/"
65 -
66 -if [[ $PV == 9999* ]]; then
67 - SRC_URI=""
68 -else
69 - SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_P}.tar.xz"
70 -fi
71 -
72 -LICENSE="MIT"
73 -SLOT="0"
74 -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"
75 -RESTRICT="!bindist? ( bindist )"
76 -
77 -INTEL_CARDS="i915 i965 ilo intel"
78 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
79 -VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno nouveau vmware"
80 -for card in ${VIDEO_CARDS}; do
81 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
82 -done
83 -
84 -IUSE="${IUSE_VIDEO_CARDS}
85 - bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm
86 - +nptl opencl osmesa pax_kernel openmax pic selinux +udev vaapi vdpau
87 - wayland xvmc xa kernel_FreeBSD"
88 -
89 -REQUIRED_USE="
90 - d3d9? ( dri3 gallium )
91 - llvm? ( gallium )
92 - opencl? ( gallium llvm )
93 - openmax? ( gallium )
94 - gles1? ( egl )
95 - gles2? ( egl )
96 - vaapi? ( gallium )
97 - vdpau? ( gallium )
98 - wayland? ( egl gbm )
99 - xa? ( gallium )
100 - video_cards_freedreno? ( gallium )
101 - video_cards_intel? ( classic )
102 - video_cards_i915? ( || ( classic gallium ) )
103 - video_cards_i965? ( classic )
104 - video_cards_ilo? ( gallium )
105 - video_cards_nouveau? ( || ( classic gallium ) )
106 - video_cards_radeon? ( || ( classic gallium ) )
107 - video_cards_r100? ( classic )
108 - video_cards_r200? ( classic )
109 - video_cards_r300? ( gallium llvm )
110 - video_cards_r600? ( gallium )
111 - video_cards_radeonsi? ( gallium llvm )
112 - video_cards_vmware? ( gallium )
113 - ${PYTHON_REQUIRED_USE}
114 -"
115 -
116 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.60"
117 -# keep correct libdrm and dri2proto dep
118 -# keep blocks in rdepend for binpkg
119 -RDEPEND="
120 - !<x11-base/xorg-server-1.7
121 - !<=x11-proto/xf86driproto-2.0.3
122 - abi_x86_32? ( !app-emulation/emul-linux-x86-opengl[-abi_x86_32(-)] )
123 - classic? ( app-eselect/eselect-mesa )
124 - gallium? ( app-eselect/eselect-mesa )
125 - >=app-eselect/eselect-opengl-1.3.0
126 - udev? ( kernel_linux? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] ) )
127 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
128 - gbm? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
129 - dri3? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
130 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
131 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
132 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
133 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
134 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
135 - >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}]
136 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
137 - llvm? (
138 - video_cards_radeonsi? ( || (
139 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
140 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
141 - ) )
142 - !video_cards_r600? (
143 - video_cards_radeon? ( || (
144 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
145 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
146 - ) )
147 - )
148 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
149 - )
150 - opencl? (
151 - app-eselect/eselect-opencl
152 - dev-libs/libclc
153 - || (
154 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
155 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
156 - )
157 - )
158 - openmax? ( >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] )
159 - vaapi? ( >=x11-libs/libva-0.35.0:=[${MULTILIB_USEDEP}] )
160 - vdpau? ( >=x11-libs/libvdpau-0.7:=[${MULTILIB_USEDEP}] )
161 - wayland? ( >=dev-libs/wayland-1.2.0:=[${MULTILIB_USEDEP}] )
162 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
163 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vmware?,${MULTILIB_USEDEP}]
164 -"
165 -for card in ${INTEL_CARDS}; do
166 - RDEPEND="${RDEPEND}
167 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
168 - "
169 -done
170 -
171 -for card in ${RADEON_CARDS}; do
172 - RDEPEND="${RDEPEND}
173 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
174 - "
175 -done
176 -
177 -DEPEND="${RDEPEND}
178 - llvm? (
179 - video_cards_radeonsi? ( sys-devel/llvm[video_cards_radeon] )
180 - )
181 - opencl? (
182 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
183 - >=sys-devel/clang-3.4.2:=[${MULTILIB_USEDEP}]
184 - >=sys-devel/gcc-4.6
185 - )
186 - sys-devel/gettext
187 - virtual/pkgconfig
188 - >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}]
189 - dri3? (
190 - >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}]
191 - >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}]
192 - )
193 - >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}]
194 - >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}]
195 - >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}]
196 - >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}]
197 -"
198 -[[ ${PV} == "9999" ]] && DEPEND+="
199 - sys-devel/bison
200 - sys-devel/flex
201 - ${PYTHON_DEPS}
202 - $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
203 -"
204 -
205 -S="${WORKDIR}/${MY_P}"
206 -EGIT_CHECKOUT_DIR=${S}
207 -
208 -QA_WX_LOAD="
209 -x86? (
210 - !pic? (
211 - usr/lib*/libglapi.so.0.0.0
212 - usr/lib*/libGLESv1_CM.so.1.1.0
213 - usr/lib*/libGLESv2.so.2.0.0
214 - usr/lib*/libGL.so.1.2.0
215 - usr/lib*/libOSMesa.so.8.0.0
216 - )
217 -)"
218 -
219 -pkg_setup() {
220 - # warning message for bug 459306
221 - if use llvm && has_version sys-devel/llvm[!debug=]; then
222 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
223 - ewarn "detected! This can cause problems. For details, see bug 459306."
224 - fi
225 -
226 - python-any-r1_pkg_setup
227 -}
228 -
229 -src_prepare() {
230 - # fix for hardened pax_kernel, bug 240956
231 - [[ ${PV} != 9999* ]] && epatch "${FILESDIR}"/glx_ro_text_segm.patch
232 -
233 - eautoreconf
234 -}
235 -
236 -multilib_src_configure() {
237 - local myconf
238 -
239 - if use classic; then
240 - # Configurable DRI drivers
241 - driver_enable swrast
242 -
243 - # Intel code
244 - driver_enable video_cards_i915 i915
245 - driver_enable video_cards_i965 i965
246 - if ! use video_cards_i915 && \
247 - ! use video_cards_i965; then
248 - driver_enable video_cards_intel i915 i965
249 - fi
250 -
251 - # Nouveau code
252 - driver_enable video_cards_nouveau nouveau
253 -
254 - # ATI code
255 - driver_enable video_cards_r100 radeon
256 - driver_enable video_cards_r200 r200
257 - if ! use video_cards_r100 && \
258 - ! use video_cards_r200; then
259 - driver_enable video_cards_radeon radeon r200
260 - fi
261 - fi
262 -
263 - if use egl; then
264 - myconf+="--with-egl-platforms=x11$(use wayland && echo ",wayland")$(use gbm && echo ",drm") "
265 - fi
266 -
267 - if use gallium; then
268 - myconf+="
269 - $(use_enable d3d9 nine)
270 - $(use_enable llvm gallium-llvm)
271 - $(use_enable openmax omx)
272 - $(use_enable vaapi va)
273 - $(use_enable vdpau)
274 - $(use_enable xa)
275 - $(use_enable xvmc)
276 - "
277 - use vaapi && myconf+="--with-va-libdir=/usr/$(get_libdir)/va/drivers"
278 -
279 - gallium_enable swrast
280 - gallium_enable video_cards_vmware svga
281 - gallium_enable video_cards_nouveau nouveau
282 - gallium_enable video_cards_i915 i915
283 - gallium_enable video_cards_ilo ilo
284 - if ! use video_cards_i915 && \
285 - ! use video_cards_i965; then
286 - gallium_enable video_cards_intel i915
287 - fi
288 -
289 - gallium_enable video_cards_r300 r300
290 - gallium_enable video_cards_r600 r600
291 - gallium_enable video_cards_radeonsi radeonsi
292 - if ! use video_cards_r300 && \
293 - ! use video_cards_r600; then
294 - gallium_enable video_cards_radeon r300 r600
295 - fi
296 -
297 - gallium_enable video_cards_freedreno freedreno
298 - # opencl stuff
299 - if use opencl; then
300 - myconf+="
301 - $(use_enable opencl)
302 - --with-clang-libdir="${EPREFIX}/usr/lib"
303 - "
304 - fi
305 - fi
306 -
307 - # x86 hardened pax_kernel needs glx-rts, bug 240956
308 - if use pax_kernel; then
309 - myconf+="
310 - $(use_enable x86 glx-rts)
311 - "
312 - fi
313 -
314 - # on abi_x86_32 hardened we need to have asm disable
315 - if [[ ${ABI} == x86* ]] && use pic; then
316 - myconf+=" --disable-asm"
317 - fi
318 -
319 - # build fails with BSD indent, bug #428112
320 - use userland_GNU || export INDENT=cat
321 -
322 - ECONF_SOURCE="${S}" \
323 - econf \
324 - --enable-dri \
325 - --enable-glx \
326 - --enable-shared-glapi \
327 - $(use_enable !bindist texture-float) \
328 - $(use_enable d3d9 nine) \
329 - $(use_enable debug) \
330 - $(use_enable dri3) \
331 - $(use_enable egl) \
332 - $(use_enable gbm) \
333 - $(use_enable gles1) \
334 - $(use_enable gles2) \
335 - $(use_enable nptl glx-tls) \
336 - $(use_enable osmesa) \
337 - $(use_enable !udev sysfs) \
338 - --enable-llvm-shared-libs \
339 - --with-dri-drivers=${DRI_DRIVERS} \
340 - --with-gallium-drivers=${GALLIUM_DRIVERS} \
341 - PYTHON2="${PYTHON}" \
342 - ${myconf}
343 -}
344 -
345 -multilib_src_install() {
346 - emake install DESTDIR="${D}"
347 -
348 - if use classic || use gallium; then
349 - ebegin "Moving DRI/Gallium drivers for dynamic switching"
350 - local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so )
351 - keepdir /usr/$(get_libdir)/dri
352 - dodir /usr/$(get_libdir)/mesa
353 - for x in ${gallium_drivers[@]}; do
354 - if [ -f "$(get_libdir)/gallium/${x}" ]; then
355 - mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \
356 - || die "Failed to move ${x}"
357 - fi
358 - done
359 - if use classic; then
360 - emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install
361 - fi
362 - for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do
363 - if [ -f ${x} -o -L ${x} ]; then
364 - mv -f "${x}" "${x/dri/mesa}" \
365 - || die "Failed to move ${x}"
366 - fi
367 - done
368 - pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed"
369 - ln -s ../mesa/*.so . || die "Creating symlink failed"
370 - # remove symlinks to drivers known to eselect
371 - for x in ${gallium_drivers[@]}; do
372 - if [ -f ${x} -o -L ${x} ]; then
373 - rm "${x}" || die "Failed to remove ${x}"
374 - fi
375 - done
376 - popd
377 - eend $?
378 - fi
379 - if use opencl; then
380 - ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching"
381 - local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa"
382 - dodir ${cl_dir}/{lib,include}
383 - if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then
384 - mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \
385 - "${ED}"${cl_dir}
386 - fi
387 - if [ -f "${ED}/usr/include/CL/opencl.h" ]; then
388 - mv -f "${ED}"/usr/include/CL \
389 - "${ED}"${cl_dir}/include
390 - fi
391 - eend $?
392 - fi
393 -
394 - if use openmax; then
395 - echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx"
396 - doenvd "${T}"/99mesaxdgomx
397 - keepdir /usr/share/mesa/xdg
398 - fi
399 -}
400 -
401 -multilib_src_install_all() {
402 - prune_libtool_files --all
403 - einstalldocs
404 -
405 - if use !bindist; then
406 - dodoc docs/patents.txt
407 - fi
408 -
409 - # Install config file for eselect mesa
410 - insinto /usr/share/mesa
411 - newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf
412 -}
413 -
414 -multilib_src_test() {
415 - if use llvm; then
416 - 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'
417 - pushd src/gallium/drivers/llvmpipe >/dev/null || die
418 - emake ${llvm_tests}
419 - pax-mark m ${llvm_tests}
420 - popd >/dev/null || die
421 - fi
422 - emake check
423 -}
424 -
425 -pkg_postinst() {
426 - # Switch to the xorg implementation.
427 - echo
428 - eselect opengl set --use-old ${OPENGL_DIR}
429 -
430 - # Select classic/gallium drivers
431 - if use classic || use gallium; then
432 - eselect mesa set --auto
433 - fi
434 -
435 - # Switch to mesa opencl
436 - if use opencl; then
437 - eselect opencl set --use-old ${PN}
438 - fi
439 -
440 - # run omxregister-bellagio to make the OpenMAX drivers known system-wide
441 - if use openmax; then
442 - ebegin "Registering OpenMAX drivers"
443 - BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \
444 - OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \
445 - omxregister-bellagio
446 - eend $?
447 - fi
448 -
449 - # warn about patent encumbered texture-float
450 - if use !bindist; then
451 - elog "USE=\"bindist\" was not set. Potentially patent encumbered code was"
452 - elog "enabled. Please see patents.txt for an explanation."
453 - fi
454 -
455 - if ! has_version media-libs/libtxc_dxtn; then
456 - elog "Note that in order to have full S3TC support, it is necessary to install"
457 - elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice"
458 - elog "textures in some apps, and some others even require this to run."
459 - fi
460 -}
461 -
462 -pkg_prerm() {
463 - if use openmax; then
464 - rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister
465 - fi
466 -}
467 -
468 -# $1 - VIDEO_CARDS flag
469 -# other args - names of DRI drivers to enable
470 -# TODO: avoid code duplication for a more elegant implementation
471 -driver_enable() {
472 - case $# in
473 - # for enabling unconditionally
474 - 1)
475 - DRI_DRIVERS+=",$1"
476 - ;;
477 - *)
478 - if use $1; then
479 - shift
480 - for i in $@; do
481 - DRI_DRIVERS+=",${i}"
482 - done
483 - fi
484 - ;;
485 - esac
486 -}
487 -
488 -gallium_enable() {
489 - case $# in
490 - # for enabling unconditionally
491 - 1)
492 - GALLIUM_DRIVERS+=",$1"
493 - ;;
494 - *)
495 - if use $1; then
496 - shift
497 - for i in $@; do
498 - GALLIUM_DRIVERS+=",${i}"
499 - done
500 - fi
501 - ;;
502 - esac
503 -}
504
505 diff --git a/media-libs/mesa/mesa-10.6.8.ebuild b/media-libs/mesa/mesa-10.6.8.ebuild
506 deleted file mode 100644
507 index 4386f87..0000000
508 --- a/media-libs/mesa/mesa-10.6.8.ebuild
509 +++ /dev/null
510 @@ -1,463 +0,0 @@
511 -# Copyright 1999-2015 Gentoo Foundation
512 -# Distributed under the terms of the GNU General Public License v2
513 -# $Id$
514 -
515 -EAPI=5
516 -
517 -EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa"
518 -
519 -if [[ ${PV} = 9999* ]]; then
520 - GIT_ECLASS="git-r3"
521 - EXPERIMENTAL="true"
522 -fi
523 -
524 -PYTHON_COMPAT=( python2_7 )
525 -
526 -inherit autotools multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS}
527 -
528 -OPENGL_DIR="xorg-x11"
529 -
530 -MY_P="${P/_/-}"
531 -FOLDER="${PV/_rc*/}"
532 -
533 -DESCRIPTION="OpenGL-like graphic library for Linux"
534 -HOMEPAGE="http://mesa3d.sourceforge.net/"
535 -
536 -if [[ $PV == 9999* ]]; then
537 - SRC_URI=""
538 -else
539 - SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_P}.tar.xz"
540 -fi
541 -
542 -LICENSE="MIT"
543 -SLOT="0"
544 -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"
545 -RESTRICT="!bindist? ( bindist )"
546 -
547 -INTEL_CARDS="i915 i965 ilo intel"
548 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
549 -VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno nouveau vmware"
550 -for card in ${VIDEO_CARDS}; do
551 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
552 -done
553 -
554 -IUSE="${IUSE_VIDEO_CARDS}
555 - bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm
556 - +nptl opencl osmesa pax_kernel openmax pic selinux +udev vaapi vdpau
557 - wayland xvmc xa kernel_FreeBSD"
558 -
559 -REQUIRED_USE="
560 - d3d9? ( dri3 gallium )
561 - llvm? ( gallium )
562 - opencl? ( gallium llvm )
563 - openmax? ( gallium )
564 - gles1? ( egl )
565 - gles2? ( egl )
566 - vaapi? ( gallium )
567 - vdpau? ( gallium )
568 - wayland? ( egl gbm )
569 - xa? ( gallium )
570 - video_cards_freedreno? ( gallium )
571 - video_cards_intel? ( classic )
572 - video_cards_i915? ( || ( classic gallium ) )
573 - video_cards_i965? ( classic )
574 - video_cards_ilo? ( gallium )
575 - video_cards_nouveau? ( || ( classic gallium ) )
576 - video_cards_radeon? ( || ( classic gallium ) )
577 - video_cards_r100? ( classic )
578 - video_cards_r200? ( classic )
579 - video_cards_r300? ( gallium llvm )
580 - video_cards_r600? ( gallium )
581 - video_cards_radeonsi? ( gallium llvm )
582 - video_cards_vmware? ( gallium )
583 - ${PYTHON_REQUIRED_USE}
584 -"
585 -
586 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.60"
587 -# keep correct libdrm and dri2proto dep
588 -# keep blocks in rdepend for binpkg
589 -RDEPEND="
590 - !<x11-base/xorg-server-1.7
591 - !<=x11-proto/xf86driproto-2.0.3
592 - abi_x86_32? ( !app-emulation/emul-linux-x86-opengl[-abi_x86_32(-)] )
593 - classic? ( app-eselect/eselect-mesa )
594 - gallium? ( app-eselect/eselect-mesa )
595 - >=app-eselect/eselect-opengl-1.3.0
596 - udev? ( kernel_linux? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] ) )
597 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
598 - gbm? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
599 - dri3? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
600 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
601 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
602 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
603 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
604 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
605 - >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}]
606 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
607 - llvm? (
608 - video_cards_radeonsi? ( || (
609 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
610 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
611 - ) )
612 - !video_cards_r600? (
613 - video_cards_radeon? ( || (
614 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
615 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
616 - ) )
617 - )
618 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
619 - )
620 - opencl? (
621 - app-eselect/eselect-opencl
622 - dev-libs/libclc
623 - || (
624 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
625 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
626 - )
627 - )
628 - openmax? ( >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] )
629 - vaapi? ( >=x11-libs/libva-0.35.0:=[${MULTILIB_USEDEP}] )
630 - vdpau? ( >=x11-libs/libvdpau-0.7:=[${MULTILIB_USEDEP}] )
631 - wayland? ( >=dev-libs/wayland-1.2.0:=[${MULTILIB_USEDEP}] )
632 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
633 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vmware?,${MULTILIB_USEDEP}]
634 -"
635 -for card in ${INTEL_CARDS}; do
636 - RDEPEND="${RDEPEND}
637 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
638 - "
639 -done
640 -
641 -for card in ${RADEON_CARDS}; do
642 - RDEPEND="${RDEPEND}
643 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
644 - "
645 -done
646 -
647 -DEPEND="${RDEPEND}
648 - llvm? (
649 - video_cards_radeonsi? ( sys-devel/llvm[video_cards_radeon] )
650 - )
651 - opencl? (
652 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
653 - >=sys-devel/clang-3.4.2:=[${MULTILIB_USEDEP}]
654 - >=sys-devel/gcc-4.6
655 - )
656 - sys-devel/gettext
657 - virtual/pkgconfig
658 - >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}]
659 - dri3? (
660 - >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}]
661 - >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}]
662 - )
663 - >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}]
664 - >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}]
665 - >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}]
666 - >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}]
667 -"
668 -[[ ${PV} == "9999" ]] && DEPEND+="
669 - sys-devel/bison
670 - sys-devel/flex
671 - ${PYTHON_DEPS}
672 - $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
673 -"
674 -
675 -S="${WORKDIR}/${MY_P}"
676 -EGIT_CHECKOUT_DIR=${S}
677 -
678 -QA_WX_LOAD="
679 -x86? (
680 - !pic? (
681 - usr/lib*/libglapi.so.0.0.0
682 - usr/lib*/libGLESv1_CM.so.1.1.0
683 - usr/lib*/libGLESv2.so.2.0.0
684 - usr/lib*/libGL.so.1.2.0
685 - usr/lib*/libOSMesa.so.8.0.0
686 - )
687 -)"
688 -
689 -pkg_setup() {
690 - # warning message for bug 459306
691 - if use llvm && has_version sys-devel/llvm[!debug=]; then
692 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
693 - ewarn "detected! This can cause problems. For details, see bug 459306."
694 - fi
695 -
696 - python-any-r1_pkg_setup
697 -}
698 -
699 -src_prepare() {
700 - # fix for hardened pax_kernel, bug 240956
701 - [[ ${PV} != 9999* ]] && epatch "${FILESDIR}"/glx_ro_text_segm.patch
702 -
703 - eautoreconf
704 -}
705 -
706 -multilib_src_configure() {
707 - local myconf
708 -
709 - if use classic; then
710 - # Configurable DRI drivers
711 - driver_enable swrast
712 -
713 - # Intel code
714 - driver_enable video_cards_i915 i915
715 - driver_enable video_cards_i965 i965
716 - if ! use video_cards_i915 && \
717 - ! use video_cards_i965; then
718 - driver_enable video_cards_intel i915 i965
719 - fi
720 -
721 - # Nouveau code
722 - driver_enable video_cards_nouveau nouveau
723 -
724 - # ATI code
725 - driver_enable video_cards_r100 radeon
726 - driver_enable video_cards_r200 r200
727 - if ! use video_cards_r100 && \
728 - ! use video_cards_r200; then
729 - driver_enable video_cards_radeon radeon r200
730 - fi
731 - fi
732 -
733 - if use egl; then
734 - myconf+="--with-egl-platforms=x11$(use wayland && echo ",wayland")$(use gbm && echo ",drm") "
735 - fi
736 -
737 - if use gallium; then
738 - myconf+="
739 - $(use_enable d3d9 nine)
740 - $(use_enable llvm gallium-llvm)
741 - $(use_enable openmax omx)
742 - $(use_enable vaapi va)
743 - $(use_enable vdpau)
744 - $(use_enable xa)
745 - $(use_enable xvmc)
746 - "
747 - use vaapi && myconf+="--with-va-libdir=/usr/$(get_libdir)/va/drivers"
748 -
749 - gallium_enable swrast
750 - gallium_enable video_cards_vmware svga
751 - gallium_enable video_cards_nouveau nouveau
752 - gallium_enable video_cards_i915 i915
753 - gallium_enable video_cards_ilo ilo
754 - if ! use video_cards_i915 && \
755 - ! use video_cards_i965; then
756 - gallium_enable video_cards_intel i915
757 - fi
758 -
759 - gallium_enable video_cards_r300 r300
760 - gallium_enable video_cards_r600 r600
761 - gallium_enable video_cards_radeonsi radeonsi
762 - if ! use video_cards_r300 && \
763 - ! use video_cards_r600; then
764 - gallium_enable video_cards_radeon r300 r600
765 - fi
766 -
767 - gallium_enable video_cards_freedreno freedreno
768 - # opencl stuff
769 - if use opencl; then
770 - myconf+="
771 - $(use_enable opencl)
772 - --with-clang-libdir="${EPREFIX}/usr/lib"
773 - "
774 - fi
775 - fi
776 -
777 - # x86 hardened pax_kernel needs glx-rts, bug 240956
778 - if use pax_kernel; then
779 - myconf+="
780 - $(use_enable x86 glx-rts)
781 - "
782 - fi
783 -
784 - # on abi_x86_32 hardened we need to have asm disable
785 - if [[ ${ABI} == x86* ]] && use pic; then
786 - myconf+=" --disable-asm"
787 - fi
788 -
789 - # build fails with BSD indent, bug #428112
790 - use userland_GNU || export INDENT=cat
791 -
792 - ECONF_SOURCE="${S}" \
793 - econf \
794 - --enable-dri \
795 - --enable-glx \
796 - --enable-shared-glapi \
797 - $(use_enable !bindist texture-float) \
798 - $(use_enable d3d9 nine) \
799 - $(use_enable debug) \
800 - $(use_enable dri3) \
801 - $(use_enable egl) \
802 - $(use_enable gbm) \
803 - $(use_enable gles1) \
804 - $(use_enable gles2) \
805 - $(use_enable nptl glx-tls) \
806 - $(use_enable osmesa) \
807 - $(use_enable !udev sysfs) \
808 - --enable-llvm-shared-libs \
809 - --with-dri-drivers=${DRI_DRIVERS} \
810 - --with-gallium-drivers=${GALLIUM_DRIVERS} \
811 - PYTHON2="${PYTHON}" \
812 - ${myconf}
813 -}
814 -
815 -multilib_src_install() {
816 - emake install DESTDIR="${D}"
817 -
818 - if use classic || use gallium; then
819 - ebegin "Moving DRI/Gallium drivers for dynamic switching"
820 - local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so )
821 - keepdir /usr/$(get_libdir)/dri
822 - dodir /usr/$(get_libdir)/mesa
823 - for x in ${gallium_drivers[@]}; do
824 - if [ -f "$(get_libdir)/gallium/${x}" ]; then
825 - mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \
826 - || die "Failed to move ${x}"
827 - fi
828 - done
829 - if use classic; then
830 - emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install
831 - fi
832 - for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do
833 - if [ -f ${x} -o -L ${x} ]; then
834 - mv -f "${x}" "${x/dri/mesa}" \
835 - || die "Failed to move ${x}"
836 - fi
837 - done
838 - pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed"
839 - ln -s ../mesa/*.so . || die "Creating symlink failed"
840 - # remove symlinks to drivers known to eselect
841 - for x in ${gallium_drivers[@]}; do
842 - if [ -f ${x} -o -L ${x} ]; then
843 - rm "${x}" || die "Failed to remove ${x}"
844 - fi
845 - done
846 - popd
847 - eend $?
848 - fi
849 - if use opencl; then
850 - ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching"
851 - local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa"
852 - dodir ${cl_dir}/{lib,include}
853 - if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then
854 - mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \
855 - "${ED}"${cl_dir}
856 - fi
857 - if [ -f "${ED}/usr/include/CL/opencl.h" ]; then
858 - mv -f "${ED}"/usr/include/CL \
859 - "${ED}"${cl_dir}/include
860 - fi
861 - eend $?
862 - fi
863 -
864 - if use openmax; then
865 - echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx"
866 - doenvd "${T}"/99mesaxdgomx
867 - keepdir /usr/share/mesa/xdg
868 - fi
869 -}
870 -
871 -multilib_src_install_all() {
872 - prune_libtool_files --all
873 - einstalldocs
874 -
875 - if use !bindist; then
876 - dodoc docs/patents.txt
877 - fi
878 -
879 - # Install config file for eselect mesa
880 - insinto /usr/share/mesa
881 - newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf
882 -}
883 -
884 -multilib_src_test() {
885 - if use llvm; then
886 - 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'
887 - pushd src/gallium/drivers/llvmpipe >/dev/null || die
888 - emake ${llvm_tests}
889 - pax-mark m ${llvm_tests}
890 - popd >/dev/null || die
891 - fi
892 - emake check
893 -}
894 -
895 -pkg_postinst() {
896 - # Switch to the xorg implementation.
897 - echo
898 - eselect opengl set --use-old ${OPENGL_DIR}
899 -
900 - # Select classic/gallium drivers
901 - if use classic || use gallium; then
902 - eselect mesa set --auto
903 - fi
904 -
905 - # Switch to mesa opencl
906 - if use opencl; then
907 - eselect opencl set --use-old ${PN}
908 - fi
909 -
910 - # run omxregister-bellagio to make the OpenMAX drivers known system-wide
911 - if use openmax; then
912 - ebegin "Registering OpenMAX drivers"
913 - BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \
914 - OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \
915 - omxregister-bellagio
916 - eend $?
917 - fi
918 -
919 - # warn about patent encumbered texture-float
920 - if use !bindist; then
921 - elog "USE=\"bindist\" was not set. Potentially patent encumbered code was"
922 - elog "enabled. Please see patents.txt for an explanation."
923 - fi
924 -
925 - if ! has_version media-libs/libtxc_dxtn; then
926 - elog "Note that in order to have full S3TC support, it is necessary to install"
927 - elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice"
928 - elog "textures in some apps, and some others even require this to run."
929 - fi
930 -}
931 -
932 -pkg_prerm() {
933 - if use openmax; then
934 - rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister
935 - fi
936 -}
937 -
938 -# $1 - VIDEO_CARDS flag
939 -# other args - names of DRI drivers to enable
940 -# TODO: avoid code duplication for a more elegant implementation
941 -driver_enable() {
942 - case $# in
943 - # for enabling unconditionally
944 - 1)
945 - DRI_DRIVERS+=",$1"
946 - ;;
947 - *)
948 - if use $1; then
949 - shift
950 - for i in $@; do
951 - DRI_DRIVERS+=",${i}"
952 - done
953 - fi
954 - ;;
955 - esac
956 -}
957 -
958 -gallium_enable() {
959 - case $# in
960 - # for enabling unconditionally
961 - 1)
962 - GALLIUM_DRIVERS+=",$1"
963 - ;;
964 - *)
965 - if use $1; then
966 - shift
967 - for i in $@; do
968 - GALLIUM_DRIVERS+=",${i}"
969 - done
970 - fi
971 - ;;
972 - esac
973 -}
974
975 diff --git a/media-libs/mesa/mesa-11.0.0.ebuild b/media-libs/mesa/mesa-11.0.0.ebuild
976 deleted file mode 100644
977 index 309e882..0000000
978 --- a/media-libs/mesa/mesa-11.0.0.ebuild
979 +++ /dev/null
980 @@ -1,466 +0,0 @@
981 -# Copyright 1999-2015 Gentoo Foundation
982 -# Distributed under the terms of the GNU General Public License v2
983 -# $Id$
984 -
985 -EAPI=5
986 -
987 -EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa"
988 -
989 -if [[ ${PV} = 9999* ]]; then
990 - GIT_ECLASS="git-r3"
991 - EXPERIMENTAL="true"
992 -fi
993 -
994 -PYTHON_COMPAT=( python2_7 )
995 -
996 -inherit autotools multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS}
997 -
998 -OPENGL_DIR="xorg-x11"
999 -
1000 -MY_P="${P/_/-}"
1001 -FOLDER="${PV/_rc*/}"
1002 -
1003 -DESCRIPTION="OpenGL-like graphic library for Linux"
1004 -HOMEPAGE="http://mesa3d.sourceforge.net/"
1005 -
1006 -if [[ $PV == 9999* ]]; then
1007 - SRC_URI=""
1008 -else
1009 - SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_P}.tar.xz"
1010 -fi
1011 -
1012 -LICENSE="MIT"
1013 -SLOT="0"
1014 -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"
1015 -RESTRICT="!bindist? ( bindist )"
1016 -
1017 -INTEL_CARDS="i915 i965 ilo intel"
1018 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
1019 -VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno nouveau vmware"
1020 -for card in ${VIDEO_CARDS}; do
1021 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
1022 -done
1023 -
1024 -IUSE="${IUSE_VIDEO_CARDS}
1025 - bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm
1026 - +nptl opencl osmesa pax_kernel openmax pic selinux +udev vaapi vdpau
1027 - wayland xvmc xa kernel_FreeBSD"
1028 -
1029 -REQUIRED_USE="
1030 - d3d9? ( dri3 gallium )
1031 - llvm? ( gallium )
1032 - opencl? ( gallium llvm )
1033 - openmax? ( gallium )
1034 - gles1? ( egl )
1035 - gles2? ( egl )
1036 - vaapi? ( gallium )
1037 - vdpau? ( gallium )
1038 - wayland? ( egl gbm )
1039 - xa? ( gallium )
1040 - video_cards_freedreno? ( gallium )
1041 - video_cards_intel? ( classic )
1042 - video_cards_i915? ( || ( classic gallium ) )
1043 - video_cards_i965? ( classic )
1044 - video_cards_ilo? ( gallium )
1045 - video_cards_nouveau? ( || ( classic gallium ) )
1046 - video_cards_radeon? ( || ( classic gallium ) )
1047 - video_cards_r100? ( classic )
1048 - video_cards_r200? ( classic )
1049 - video_cards_r300? ( gallium llvm )
1050 - video_cards_r600? ( gallium )
1051 - video_cards_radeonsi? ( gallium llvm )
1052 - video_cards_vmware? ( gallium )
1053 - ${PYTHON_REQUIRED_USE}
1054 -"
1055 -
1056 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.64"
1057 -# keep correct libdrm and dri2proto dep
1058 -# keep blocks in rdepend for binpkg
1059 -RDEPEND="
1060 - !<x11-base/xorg-server-1.7
1061 - !<=x11-proto/xf86driproto-2.0.3
1062 - abi_x86_32? ( !app-emulation/emul-linux-x86-opengl[-abi_x86_32(-)] )
1063 - classic? ( app-eselect/eselect-mesa )
1064 - gallium? ( app-eselect/eselect-mesa )
1065 - >=app-eselect/eselect-opengl-1.3.0
1066 - udev? ( kernel_linux? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] ) )
1067 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
1068 - gbm? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
1069 - dri3? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
1070 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
1071 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
1072 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
1073 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
1074 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
1075 - >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}]
1076 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
1077 - llvm? (
1078 - video_cards_radeonsi? ( || (
1079 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
1080 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
1081 - ) )
1082 - !video_cards_r600? (
1083 - video_cards_radeon? ( || (
1084 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
1085 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
1086 - ) )
1087 - )
1088 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
1089 - )
1090 - opencl? (
1091 - app-eselect/eselect-opencl
1092 - dev-libs/libclc
1093 - || (
1094 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
1095 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
1096 - )
1097 - )
1098 - openmax? ( >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] )
1099 - vaapi? ( >=x11-libs/libva-0.35.0:=[${MULTILIB_USEDEP}] )
1100 - vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
1101 - wayland? ( >=dev-libs/wayland-1.2.0:=[${MULTILIB_USEDEP}] )
1102 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
1103 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vmware?,${MULTILIB_USEDEP}]
1104 -"
1105 -for card in ${INTEL_CARDS}; do
1106 - RDEPEND="${RDEPEND}
1107 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
1108 - "
1109 -done
1110 -
1111 -for card in ${RADEON_CARDS}; do
1112 - RDEPEND="${RDEPEND}
1113 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
1114 - "
1115 -done
1116 -RDEPEND="${RDEPEND}
1117 - video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
1118 -"
1119 -
1120 -DEPEND="${RDEPEND}
1121 - llvm? (
1122 - video_cards_radeonsi? ( sys-devel/llvm[video_cards_radeon] )
1123 - )
1124 - opencl? (
1125 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
1126 - >=sys-devel/clang-3.4.2:=[${MULTILIB_USEDEP}]
1127 - >=sys-devel/gcc-4.6
1128 - )
1129 - sys-devel/gettext
1130 - virtual/pkgconfig
1131 - >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}]
1132 - dri3? (
1133 - >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}]
1134 - >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}]
1135 - )
1136 - >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}]
1137 - >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}]
1138 - >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}]
1139 - >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}]
1140 -"
1141 -[[ ${PV} == "9999" ]] && DEPEND+="
1142 - sys-devel/bison
1143 - sys-devel/flex
1144 - ${PYTHON_DEPS}
1145 - $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
1146 -"
1147 -
1148 -S="${WORKDIR}/${MY_P}"
1149 -EGIT_CHECKOUT_DIR=${S}
1150 -
1151 -QA_WX_LOAD="
1152 -x86? (
1153 - !pic? (
1154 - usr/lib*/libglapi.so.0.0.0
1155 - usr/lib*/libGLESv1_CM.so.1.1.0
1156 - usr/lib*/libGLESv2.so.2.0.0
1157 - usr/lib*/libGL.so.1.2.0
1158 - usr/lib*/libOSMesa.so.8.0.0
1159 - )
1160 -)"
1161 -
1162 -pkg_setup() {
1163 - # warning message for bug 459306
1164 - if use llvm && has_version sys-devel/llvm[!debug=]; then
1165 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
1166 - ewarn "detected! This can cause problems. For details, see bug 459306."
1167 - fi
1168 -
1169 - python-any-r1_pkg_setup
1170 -}
1171 -
1172 -src_prepare() {
1173 - # fix for hardened pax_kernel, bug 240956
1174 - [[ ${PV} != 9999* ]] && epatch "${FILESDIR}"/glx_ro_text_segm.patch
1175 -
1176 - eautoreconf
1177 -}
1178 -
1179 -multilib_src_configure() {
1180 - local myconf
1181 -
1182 - if use classic; then
1183 - # Configurable DRI drivers
1184 - driver_enable swrast
1185 -
1186 - # Intel code
1187 - driver_enable video_cards_i915 i915
1188 - driver_enable video_cards_i965 i965
1189 - if ! use video_cards_i915 && \
1190 - ! use video_cards_i965; then
1191 - driver_enable video_cards_intel i915 i965
1192 - fi
1193 -
1194 - # Nouveau code
1195 - driver_enable video_cards_nouveau nouveau
1196 -
1197 - # ATI code
1198 - driver_enable video_cards_r100 radeon
1199 - driver_enable video_cards_r200 r200
1200 - if ! use video_cards_r100 && \
1201 - ! use video_cards_r200; then
1202 - driver_enable video_cards_radeon radeon r200
1203 - fi
1204 - fi
1205 -
1206 - if use egl; then
1207 - myconf+="--with-egl-platforms=x11$(use wayland && echo ",wayland")$(use gbm && echo ",drm") "
1208 - fi
1209 -
1210 - if use gallium; then
1211 - myconf+="
1212 - $(use_enable d3d9 nine)
1213 - $(use_enable llvm gallium-llvm)
1214 - $(use_enable openmax omx)
1215 - $(use_enable vaapi va)
1216 - $(use_enable vdpau)
1217 - $(use_enable xa)
1218 - $(use_enable xvmc)
1219 - "
1220 - use vaapi && myconf+="--with-va-libdir=/usr/$(get_libdir)/va/drivers"
1221 -
1222 - gallium_enable swrast
1223 - gallium_enable video_cards_vmware svga
1224 - gallium_enable video_cards_nouveau nouveau
1225 - gallium_enable video_cards_i915 i915
1226 - gallium_enable video_cards_ilo ilo
1227 - if ! use video_cards_i915 && \
1228 - ! use video_cards_i965; then
1229 - gallium_enable video_cards_intel i915
1230 - fi
1231 -
1232 - gallium_enable video_cards_r300 r300
1233 - gallium_enable video_cards_r600 r600
1234 - gallium_enable video_cards_radeonsi radeonsi
1235 - if ! use video_cards_r300 && \
1236 - ! use video_cards_r600; then
1237 - gallium_enable video_cards_radeon r300 r600
1238 - fi
1239 -
1240 - gallium_enable video_cards_freedreno freedreno
1241 - # opencl stuff
1242 - if use opencl; then
1243 - myconf+="
1244 - $(use_enable opencl)
1245 - --with-clang-libdir="${EPREFIX}/usr/lib"
1246 - "
1247 - fi
1248 - fi
1249 -
1250 - # x86 hardened pax_kernel needs glx-rts, bug 240956
1251 - if use pax_kernel; then
1252 - myconf+="
1253 - $(use_enable x86 glx-rts)
1254 - "
1255 - fi
1256 -
1257 - # on abi_x86_32 hardened we need to have asm disable
1258 - if [[ ${ABI} == x86* ]] && use pic; then
1259 - myconf+=" --disable-asm"
1260 - fi
1261 -
1262 - # build fails with BSD indent, bug #428112
1263 - use userland_GNU || export INDENT=cat
1264 -
1265 - ECONF_SOURCE="${S}" \
1266 - econf \
1267 - --enable-dri \
1268 - --enable-glx \
1269 - --enable-shared-glapi \
1270 - $(use_enable !bindist texture-float) \
1271 - $(use_enable d3d9 nine) \
1272 - $(use_enable debug) \
1273 - $(use_enable dri3) \
1274 - $(use_enable egl) \
1275 - $(use_enable gbm) \
1276 - $(use_enable gles1) \
1277 - $(use_enable gles2) \
1278 - $(use_enable nptl glx-tls) \
1279 - $(use_enable osmesa) \
1280 - $(use_enable !udev sysfs) \
1281 - --enable-llvm-shared-libs \
1282 - --with-dri-drivers=${DRI_DRIVERS} \
1283 - --with-gallium-drivers=${GALLIUM_DRIVERS} \
1284 - PYTHON2="${PYTHON}" \
1285 - ${myconf}
1286 -}
1287 -
1288 -multilib_src_install() {
1289 - emake install DESTDIR="${D}"
1290 -
1291 - if use classic || use gallium; then
1292 - ebegin "Moving DRI/Gallium drivers for dynamic switching"
1293 - local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so )
1294 - keepdir /usr/$(get_libdir)/dri
1295 - dodir /usr/$(get_libdir)/mesa
1296 - for x in ${gallium_drivers[@]}; do
1297 - if [ -f "$(get_libdir)/gallium/${x}" ]; then
1298 - mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \
1299 - || die "Failed to move ${x}"
1300 - fi
1301 - done
1302 - if use classic; then
1303 - emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install
1304 - fi
1305 - for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do
1306 - if [ -f ${x} -o -L ${x} ]; then
1307 - mv -f "${x}" "${x/dri/mesa}" \
1308 - || die "Failed to move ${x}"
1309 - fi
1310 - done
1311 - pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed"
1312 - ln -s ../mesa/*.so . || die "Creating symlink failed"
1313 - # remove symlinks to drivers known to eselect
1314 - for x in ${gallium_drivers[@]}; do
1315 - if [ -f ${x} -o -L ${x} ]; then
1316 - rm "${x}" || die "Failed to remove ${x}"
1317 - fi
1318 - done
1319 - popd
1320 - eend $?
1321 - fi
1322 - if use opencl; then
1323 - ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching"
1324 - local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa"
1325 - dodir ${cl_dir}/{lib,include}
1326 - if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then
1327 - mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \
1328 - "${ED}"${cl_dir}
1329 - fi
1330 - if [ -f "${ED}/usr/include/CL/opencl.h" ]; then
1331 - mv -f "${ED}"/usr/include/CL \
1332 - "${ED}"${cl_dir}/include
1333 - fi
1334 - eend $?
1335 - fi
1336 -
1337 - if use openmax; then
1338 - echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx"
1339 - doenvd "${T}"/99mesaxdgomx
1340 - keepdir /usr/share/mesa/xdg
1341 - fi
1342 -}
1343 -
1344 -multilib_src_install_all() {
1345 - prune_libtool_files --all
1346 - einstalldocs
1347 -
1348 - if use !bindist; then
1349 - dodoc docs/patents.txt
1350 - fi
1351 -
1352 - # Install config file for eselect mesa
1353 - insinto /usr/share/mesa
1354 - newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf
1355 -}
1356 -
1357 -multilib_src_test() {
1358 - if use llvm; then
1359 - 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'
1360 - pushd src/gallium/drivers/llvmpipe >/dev/null || die
1361 - emake ${llvm_tests}
1362 - pax-mark m ${llvm_tests}
1363 - popd >/dev/null || die
1364 - fi
1365 - emake check
1366 -}
1367 -
1368 -pkg_postinst() {
1369 - # Switch to the xorg implementation.
1370 - echo
1371 - eselect opengl set --use-old ${OPENGL_DIR}
1372 -
1373 - # Select classic/gallium drivers
1374 - if use classic || use gallium; then
1375 - eselect mesa set --auto
1376 - fi
1377 -
1378 - # Switch to mesa opencl
1379 - if use opencl; then
1380 - eselect opencl set --use-old ${PN}
1381 - fi
1382 -
1383 - # run omxregister-bellagio to make the OpenMAX drivers known system-wide
1384 - if use openmax; then
1385 - ebegin "Registering OpenMAX drivers"
1386 - BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \
1387 - OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \
1388 - omxregister-bellagio
1389 - eend $?
1390 - fi
1391 -
1392 - # warn about patent encumbered texture-float
1393 - if use !bindist; then
1394 - elog "USE=\"bindist\" was not set. Potentially patent encumbered code was"
1395 - elog "enabled. Please see patents.txt for an explanation."
1396 - fi
1397 -
1398 - if ! has_version media-libs/libtxc_dxtn; then
1399 - elog "Note that in order to have full S3TC support, it is necessary to install"
1400 - elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice"
1401 - elog "textures in some apps, and some others even require this to run."
1402 - fi
1403 -}
1404 -
1405 -pkg_prerm() {
1406 - if use openmax; then
1407 - rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister
1408 - fi
1409 -}
1410 -
1411 -# $1 - VIDEO_CARDS flag
1412 -# other args - names of DRI drivers to enable
1413 -# TODO: avoid code duplication for a more elegant implementation
1414 -driver_enable() {
1415 - case $# in
1416 - # for enabling unconditionally
1417 - 1)
1418 - DRI_DRIVERS+=",$1"
1419 - ;;
1420 - *)
1421 - if use $1; then
1422 - shift
1423 - for i in $@; do
1424 - DRI_DRIVERS+=",${i}"
1425 - done
1426 - fi
1427 - ;;
1428 - esac
1429 -}
1430 -
1431 -gallium_enable() {
1432 - case $# in
1433 - # for enabling unconditionally
1434 - 1)
1435 - GALLIUM_DRIVERS+=",$1"
1436 - ;;
1437 - *)
1438 - if use $1; then
1439 - shift
1440 - for i in $@; do
1441 - GALLIUM_DRIVERS+=",${i}"
1442 - done
1443 - fi
1444 - ;;
1445 - esac
1446 -}
1447
1448 diff --git a/media-libs/mesa/mesa-11.0.2.ebuild b/media-libs/mesa/mesa-11.0.2.ebuild
1449 deleted file mode 100644
1450 index 38d52d0..0000000
1451 --- a/media-libs/mesa/mesa-11.0.2.ebuild
1452 +++ /dev/null
1453 @@ -1,462 +0,0 @@
1454 -# Copyright 1999-2015 Gentoo Foundation
1455 -# Distributed under the terms of the GNU General Public License v2
1456 -# $Id$
1457 -
1458 -EAPI=5
1459 -
1460 -EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa"
1461 -
1462 -if [[ ${PV} = 9999 ]]; then
1463 - GIT_ECLASS="git-r3"
1464 - EXPERIMENTAL="true"
1465 -fi
1466 -
1467 -PYTHON_COMPAT=( python2_7 )
1468 -
1469 -inherit autotools multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS}
1470 -
1471 -OPENGL_DIR="xorg-x11"
1472 -
1473 -MY_P="${P/_/-}"
1474 -FOLDER="${PV/_rc*/}"
1475 -
1476 -DESCRIPTION="OpenGL-like graphic library for Linux"
1477 -HOMEPAGE="http://mesa3d.sourceforge.net/"
1478 -
1479 -if [[ $PV == 9999 ]]; then
1480 - SRC_URI=""
1481 - KEYWORDS=""
1482 -else
1483 - SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_P}.tar.xz"
1484 - 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"
1485 -fi
1486 -
1487 -LICENSE="MIT"
1488 -SLOT="0"
1489 -RESTRICT="!bindist? ( bindist )"
1490 -
1491 -INTEL_CARDS="i915 i965 ilo intel"
1492 -RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi"
1493 -VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno nouveau vmware"
1494 -for card in ${VIDEO_CARDS}; do
1495 - IUSE_VIDEO_CARDS+=" video_cards_${card}"
1496 -done
1497 -
1498 -IUSE="${IUSE_VIDEO_CARDS}
1499 - bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm
1500 - +nptl opencl osmesa pax_kernel openmax pic selinux +udev vaapi vdpau
1501 - wayland xvmc xa kernel_FreeBSD"
1502 -
1503 -REQUIRED_USE="
1504 - d3d9? ( dri3 gallium )
1505 - llvm? ( gallium )
1506 - opencl? ( gallium llvm )
1507 - openmax? ( gallium )
1508 - gles1? ( egl )
1509 - gles2? ( egl )
1510 - vaapi? ( gallium )
1511 - vdpau? ( gallium )
1512 - wayland? ( egl gbm )
1513 - xa? ( gallium )
1514 - video_cards_freedreno? ( gallium )
1515 - video_cards_intel? ( classic )
1516 - video_cards_i915? ( || ( classic gallium ) )
1517 - video_cards_i965? ( classic )
1518 - video_cards_ilo? ( gallium )
1519 - video_cards_nouveau? ( || ( classic gallium ) )
1520 - video_cards_radeon? ( || ( classic gallium ) )
1521 - video_cards_r100? ( classic )
1522 - video_cards_r200? ( classic )
1523 - video_cards_r300? ( gallium llvm )
1524 - video_cards_r600? ( gallium )
1525 - video_cards_radeonsi? ( gallium llvm )
1526 - video_cards_vmware? ( gallium )
1527 - ${PYTHON_REQUIRED_USE}
1528 -"
1529 -
1530 -LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.64"
1531 -# keep correct libdrm and dri2proto dep
1532 -# keep blocks in rdepend for binpkg
1533 -RDEPEND="
1534 - !<x11-base/xorg-server-1.7
1535 - !<=x11-proto/xf86driproto-2.0.3
1536 - abi_x86_32? ( !app-emulation/emul-linux-x86-opengl[-abi_x86_32(-)] )
1537 - classic? ( app-eselect/eselect-mesa )
1538 - gallium? ( app-eselect/eselect-mesa )
1539 - >=app-eselect/eselect-opengl-1.3.0
1540 - udev? ( kernel_linux? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] ) )
1541 - >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}]
1542 - gbm? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
1543 - dri3? ( >=virtual/libudev-215:=[${MULTILIB_USEDEP}] )
1544 - >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}]
1545 - >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}]
1546 - >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}]
1547 - >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}]
1548 - >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}]
1549 - >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}]
1550 - x11-libs/libXfixes:=[${MULTILIB_USEDEP}]
1551 - llvm? ( !kernel_FreeBSD? (
1552 - video_cards_radeonsi? ( || (
1553 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
1554 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
1555 - ) )
1556 - !video_cards_r600? (
1557 - video_cards_radeon? ( || (
1558 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
1559 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
1560 - ) )
1561 - ) )
1562 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
1563 - )
1564 - opencl? (
1565 - app-eselect/eselect-opencl
1566 - dev-libs/libclc
1567 - !kernel_FreeBSD? ( || (
1568 - >=dev-libs/elfutils-0.155-r1:=[${MULTILIB_USEDEP}]
1569 - >=dev-libs/libelf-0.8.13-r2:=[${MULTILIB_USEDEP}]
1570 - ) )
1571 - )
1572 - openmax? ( >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] )
1573 - vaapi? ( >=x11-libs/libva-0.35.0:=[${MULTILIB_USEDEP}] )
1574 - vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] )
1575 - wayland? ( >=dev-libs/wayland-1.2.0:=[${MULTILIB_USEDEP}] )
1576 - xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] )
1577 - ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vmware?,${MULTILIB_USEDEP}]
1578 -"
1579 -for card in ${INTEL_CARDS}; do
1580 - RDEPEND="${RDEPEND}
1581 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
1582 - "
1583 -done
1584 -
1585 -for card in ${RADEON_CARDS}; do
1586 - RDEPEND="${RDEPEND}
1587 - video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
1588 - "
1589 -done
1590 -RDEPEND="${RDEPEND}
1591 - video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] )
1592 -"
1593 -
1594 -DEPEND="${RDEPEND}
1595 - llvm? (
1596 - video_cards_radeonsi? ( sys-devel/llvm[video_cards_radeon] )
1597 - )
1598 - opencl? (
1599 - >=sys-devel/llvm-3.4.2:=[${MULTILIB_USEDEP}]
1600 - >=sys-devel/clang-3.4.2:=[${MULTILIB_USEDEP}]
1601 - >=sys-devel/gcc-4.6
1602 - )
1603 - sys-devel/gettext
1604 - virtual/pkgconfig
1605 - >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}]
1606 - dri3? (
1607 - >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}]
1608 - >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}]
1609 - )
1610 - >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}]
1611 - >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}]
1612 - >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}]
1613 - >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}]
1614 -"
1615 -[[ ${PV} == 9999 ]] && DEPEND+="
1616 - sys-devel/bison
1617 - sys-devel/flex
1618 - ${PYTHON_DEPS}
1619 - $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]")
1620 -"
1621 -
1622 -S="${WORKDIR}/${MY_P}"
1623 -EGIT_CHECKOUT_DIR=${S}
1624 -
1625 -QA_WX_LOAD="
1626 -x86? (
1627 - !pic? (
1628 - usr/lib*/libglapi.so.0.0.0
1629 - usr/lib*/libGLESv1_CM.so.1.1.0
1630 - usr/lib*/libGLESv2.so.2.0.0
1631 - usr/lib*/libGL.so.1.2.0
1632 - usr/lib*/libOSMesa.so.8.0.0
1633 - )
1634 -)"
1635 -
1636 -pkg_setup() {
1637 - # warning message for bug 459306
1638 - if use llvm && has_version sys-devel/llvm[!debug=]; then
1639 - ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm"
1640 - ewarn "detected! This can cause problems. For details, see bug 459306."
1641 - fi
1642 -
1643 - python-any-r1_pkg_setup
1644 -}
1645 -
1646 -src_prepare() {
1647 - [[ ${PV} == 9999 ]] && eautoreconf
1648 -}
1649 -
1650 -multilib_src_configure() {
1651 - local myconf
1652 -
1653 - if use classic; then
1654 - # Configurable DRI drivers
1655 - driver_enable swrast
1656 -
1657 - # Intel code
1658 - driver_enable video_cards_i915 i915
1659 - driver_enable video_cards_i965 i965
1660 - if ! use video_cards_i915 && \
1661 - ! use video_cards_i965; then
1662 - driver_enable video_cards_intel i915 i965
1663 - fi
1664 -
1665 - # Nouveau code
1666 - driver_enable video_cards_nouveau nouveau
1667 -
1668 - # ATI code
1669 - driver_enable video_cards_r100 radeon
1670 - driver_enable video_cards_r200 r200
1671 - if ! use video_cards_r100 && \
1672 - ! use video_cards_r200; then
1673 - driver_enable video_cards_radeon radeon r200
1674 - fi
1675 - fi
1676 -
1677 - if use egl; then
1678 - myconf+="--with-egl-platforms=x11$(use wayland && echo ",wayland")$(use gbm && echo ",drm") "
1679 - fi
1680 -
1681 - if use gallium; then
1682 - myconf+="
1683 - $(use_enable d3d9 nine)
1684 - $(use_enable llvm gallium-llvm)
1685 - $(use_enable openmax omx)
1686 - $(use_enable vaapi va)
1687 - $(use_enable vdpau)
1688 - $(use_enable xa)
1689 - $(use_enable xvmc)
1690 - "
1691 - use vaapi && myconf+="--with-va-libdir=/usr/$(get_libdir)/va/drivers"
1692 -
1693 - gallium_enable swrast
1694 - gallium_enable video_cards_vmware svga
1695 - gallium_enable video_cards_nouveau nouveau
1696 - gallium_enable video_cards_i915 i915
1697 - gallium_enable video_cards_ilo ilo
1698 - if ! use video_cards_i915 && \
1699 - ! use video_cards_i965; then
1700 - gallium_enable video_cards_intel i915
1701 - fi
1702 -
1703 - gallium_enable video_cards_r300 r300
1704 - gallium_enable video_cards_r600 r600
1705 - gallium_enable video_cards_radeonsi radeonsi
1706 - if ! use video_cards_r300 && \
1707 - ! use video_cards_r600; then
1708 - gallium_enable video_cards_radeon r300 r600
1709 - fi
1710 -
1711 - gallium_enable video_cards_freedreno freedreno
1712 - # opencl stuff
1713 - if use opencl; then
1714 - myconf+="
1715 - $(use_enable opencl)
1716 - --with-clang-libdir="${EPREFIX}/usr/lib"
1717 - "
1718 - fi
1719 - fi
1720 -
1721 - # x86 hardened pax_kernel needs glx-read-only-text, bug 240956
1722 - if [[ ${ABI} == x86 ]]; then
1723 - myconf+="$(use_enable pax_kernel glx-read-only-text)"
1724 - fi
1725 -
1726 - # on abi_x86_32 hardened we need to have asm disable
1727 - if [[ ${ABI} == x86* ]] && use pic; then
1728 - myconf+=" --disable-asm"
1729 - fi
1730 -
1731 - # build fails with BSD indent, bug #428112
1732 - use userland_GNU || export INDENT=cat
1733 -
1734 - ECONF_SOURCE="${S}" \
1735 - econf \
1736 - --enable-dri \
1737 - --enable-glx \
1738 - --enable-shared-glapi \
1739 - $(use_enable !bindist texture-float) \
1740 - $(use_enable d3d9 nine) \
1741 - $(use_enable debug) \
1742 - $(use_enable dri3) \
1743 - $(use_enable egl) \
1744 - $(use_enable gbm) \
1745 - $(use_enable gles1) \
1746 - $(use_enable gles2) \
1747 - $(use_enable nptl glx-tls) \
1748 - $(use_enable osmesa) \
1749 - $(use_enable !udev sysfs) \
1750 - --enable-llvm-shared-libs \
1751 - --with-dri-drivers=${DRI_DRIVERS} \
1752 - --with-gallium-drivers=${GALLIUM_DRIVERS} \
1753 - PYTHON2="${PYTHON}" \
1754 - ${myconf}
1755 -}
1756 -
1757 -multilib_src_install() {
1758 - emake install DESTDIR="${D}"
1759 -
1760 - if use classic || use gallium; then
1761 - ebegin "Moving DRI/Gallium drivers for dynamic switching"
1762 - local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so )
1763 - keepdir /usr/$(get_libdir)/dri
1764 - dodir /usr/$(get_libdir)/mesa
1765 - for x in ${gallium_drivers[@]}; do
1766 - if [ -f "$(get_libdir)/gallium/${x}" ]; then
1767 - mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \
1768 - || die "Failed to move ${x}"
1769 - fi
1770 - done
1771 - if use classic; then
1772 - emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install
1773 - fi
1774 - for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do
1775 - if [ -f ${x} -o -L ${x} ]; then
1776 - mv -f "${x}" "${x/dri/mesa}" \
1777 - || die "Failed to move ${x}"
1778 - fi
1779 - done
1780 - pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed"
1781 - ln -s ../mesa/*.so . || die "Creating symlink failed"
1782 - # remove symlinks to drivers known to eselect
1783 - for x in ${gallium_drivers[@]}; do
1784 - if [ -f ${x} -o -L ${x} ]; then
1785 - rm "${x}" || die "Failed to remove ${x}"
1786 - fi
1787 - done
1788 - popd
1789 - eend $?
1790 - fi
1791 - if use opencl; then
1792 - ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching"
1793 - local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa"
1794 - dodir ${cl_dir}/{lib,include}
1795 - if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then
1796 - mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \
1797 - "${ED}"${cl_dir}
1798 - fi
1799 - if [ -f "${ED}/usr/include/CL/opencl.h" ]; then
1800 - mv -f "${ED}"/usr/include/CL \
1801 - "${ED}"${cl_dir}/include
1802 - fi
1803 - eend $?
1804 - fi
1805 -
1806 - if use openmax; then
1807 - echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx"
1808 - doenvd "${T}"/99mesaxdgomx
1809 - keepdir /usr/share/mesa/xdg
1810 - fi
1811 -}
1812 -
1813 -multilib_src_install_all() {
1814 - prune_libtool_files --all
1815 - einstalldocs
1816 -
1817 - if use !bindist; then
1818 - dodoc docs/patents.txt
1819 - fi
1820 -
1821 - # Install config file for eselect mesa
1822 - insinto /usr/share/mesa
1823 - newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf
1824 -}
1825 -
1826 -multilib_src_test() {
1827 - if use llvm; then
1828 - 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'
1829 - pushd src/gallium/drivers/llvmpipe >/dev/null || die
1830 - emake ${llvm_tests}
1831 - pax-mark m ${llvm_tests}
1832 - popd >/dev/null || die
1833 - fi
1834 - emake check
1835 -}
1836 -
1837 -pkg_postinst() {
1838 - # Switch to the xorg implementation.
1839 - echo
1840 - eselect opengl set --use-old ${OPENGL_DIR}
1841 -
1842 - # Select classic/gallium drivers
1843 - if use classic || use gallium; then
1844 - eselect mesa set --auto
1845 - fi
1846 -
1847 - # Switch to mesa opencl
1848 - if use opencl; then
1849 - eselect opencl set --use-old ${PN}
1850 - fi
1851 -
1852 - # run omxregister-bellagio to make the OpenMAX drivers known system-wide
1853 - if use openmax; then
1854 - ebegin "Registering OpenMAX drivers"
1855 - BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \
1856 - OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \
1857 - omxregister-bellagio
1858 - eend $?
1859 - fi
1860 -
1861 - # warn about patent encumbered texture-float
1862 - if use !bindist; then
1863 - elog "USE=\"bindist\" was not set. Potentially patent encumbered code was"
1864 - elog "enabled. Please see patents.txt for an explanation."
1865 - fi
1866 -
1867 - if ! has_version media-libs/libtxc_dxtn; then
1868 - elog "Note that in order to have full S3TC support, it is necessary to install"
1869 - elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice"
1870 - elog "textures in some apps, and some others even require this to run."
1871 - fi
1872 -}
1873 -
1874 -pkg_prerm() {
1875 - if use openmax; then
1876 - rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister
1877 - fi
1878 -}
1879 -
1880 -# $1 - VIDEO_CARDS flag
1881 -# other args - names of DRI drivers to enable
1882 -# TODO: avoid code duplication for a more elegant implementation
1883 -driver_enable() {
1884 - case $# in
1885 - # for enabling unconditionally
1886 - 1)
1887 - DRI_DRIVERS+=",$1"
1888 - ;;
1889 - *)
1890 - if use $1; then
1891 - shift
1892 - for i in $@; do
1893 - DRI_DRIVERS+=",${i}"
1894 - done
1895 - fi
1896 - ;;
1897 - esac
1898 -}
1899 -
1900 -gallium_enable() {
1901 - case $# in
1902 - # for enabling unconditionally
1903 - 1)
1904 - GALLIUM_DRIVERS+=",$1"
1905 - ;;
1906 - *)
1907 - if use $1; then
1908 - shift
1909 - for i in $@; do
1910 - GALLIUM_DRIVERS+=",${i}"
1911 - done
1912 - fi
1913 - ;;
1914 - esac
1915 -}