1 |
commit: 84cb13e54f0eb737db417d599ce74ca58ffeb6b0 |
2 |
Author: Matt Turner <mattst88 <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Apr 30 18:53:30 2018 +0000 |
4 |
Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Apr 30 18:53:53 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=84cb13e5 |
7 |
|
8 |
media-libs/mesa: Drop old versions |
9 |
|
10 |
media-libs/mesa/Manifest | 6 - |
11 |
media-libs/mesa/mesa-17.1.10.ebuild | 505 ---------------------------- |
12 |
media-libs/mesa/mesa-17.2.8.ebuild | 584 --------------------------------- |
13 |
media-libs/mesa/mesa-17.3.8.ebuild | 582 -------------------------------- |
14 |
media-libs/mesa/mesa-18.0.0.ebuild | 583 -------------------------------- |
15 |
media-libs/mesa/mesa-18.0.1.ebuild | 583 -------------------------------- |
16 |
media-libs/mesa/mesa-18.1.0_rc1.ebuild | 584 --------------------------------- |
17 |
7 files changed, 3427 deletions(-) |
18 |
|
19 |
diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest |
20 |
index d8673e6d07b..d72581e4f46 100644 |
21 |
--- a/media-libs/mesa/Manifest |
22 |
+++ b/media-libs/mesa/Manifest |
23 |
@@ -1,9 +1,3 @@ |
24 |
-DIST mesa-17.1.10.tar.xz 9872168 BLAKE2B 205ece7b016fcc1de5bb72711775cd8f4b90f5d6c26db77d1576752fcd4a99a36cbcd902bb6ad1041d476d1c3b32479baceb4087c902ce598ede3d57851c6b9d SHA512 728dbd41f5d3a7a1c33fc18c08a8b8eb1f6d236c5f00781209f46b144dd66a27ecd723ab1635868b7ad77de3a18ad53f1a88c932f17c0be97605a2775e3b3a9b |
25 |
-DIST mesa-17.2.8.tar.xz 10393304 BLAKE2B 558321eefc6d599aaedfe468f03c2f1f99b5c96c253637db00b7da3265ec38e031d15f77623db1f4408f15912c93347e0f5769b01d92329be7f55e45f6f6bf75 SHA512 ce05ad2d3e1b55ffe9c8ef65023a840c04b29014c7876b23182a6a6dd0b768f248ec21bc5b738d21b846f59f4b73501a9fe834d6a87e7dba16c6f821008e0f01 |
26 |
-DIST mesa-17.3.8.tar.xz 10660896 BLAKE2B 432deefad4b0a42914efc24c558d5c766443f55ff8324317980a4f91a5e560207c3c142d9547868c6cd480ad751c2b11a76da06dea891a044016868b3dcdaaa2 SHA512 4a63b760d5c64425e2d4dddf6ab8167c1845020f173bd56ec1d2e483e3bf2afb9ca483fcf329d37cc0bce82ab5134ee43ea82a2e3a4ee9463de16a9f75bc6e16 |
27 |
DIST mesa-17.3.9.tar.xz 10660456 BLAKE2B 54f4a75f9040e50e9eea8f5c52a276578379d25d2a01ac4767ab12bee85fe5dae1492d5bb1df06b6e8c6b0fe960bbd5ea38691c75d08a6b4302c64377ce58e54 SHA512 83deffbc6b9823b8e93cccf57d7952106f3d55fea881e3924f9f9586f0e9347a6e3a1a36cc19c24af819f2fde3af9496652a6ff56132511a5618d5774404f63f |
28 |
-DIST mesa-18.0.0.tar.xz 11056544 BLAKE2B 467c100bcbc0a60e3868e718331192255fd16394c21b08c128a054e066740cd071e0b272aba011873fe239821f53442e9a07ae860d94b425275bd68c3db3b7fc SHA512 1494bb09357896a2505b3dcfec772268e28c765804f21e144948a314f1d79d99ff9f21062ef5860eb5a5a568b305a9c954585924a7ac8890fe1ebd8df3bcc396 |
29 |
-DIST mesa-18.0.1.tar.xz 10945308 BLAKE2B 03dad0961aafeb954a50f1db305288682e6b0dc58631b66de2f331dc95756b881bf7f73b5e2fa4ec04640054c27aab236acdf6b89bd7cd89ca1dbe9134a6a2d0 SHA512 b0d610904b6f179a27b42aee5f479339e341926915cdc6adb08ac999a4a12539abc3776577e86af83e10381d9703ef1bca70bab81b43daf2c000622c9c3612d2 |
30 |
DIST mesa-18.0.2.tar.xz 10949364 BLAKE2B 8b0557db70f61ac39df96e923383e41008f483ae2f89b3723e94e644cb2ced81a7996d61009acaebaf7813843742a24351a573c80f1173615e6c0302552cf621 SHA512 77d24d01c4c22596d28421aeb74932ff232730a4f556ae1a2e8777ece2876e4e352679575385c065505df4a2a83d2c1cf30db92dcf88038417e36a2768332d7e |
31 |
-DIST mesa-18.1.0-rc1.tar.xz 11118324 BLAKE2B e5a89c8469b6716463c9efb0e7059022bc986da83d55a020156a3466cb44c283828bacb340ef4dceda9e14a82f737b6809f742b49a8b38d7e871ff1864e8bb3e SHA512 5b179b4ece6fd0e04ef00744d975607b6678c4c333c47fdd7442768ac15b375c7faeb8472b0dba19c0b8755067effd6243803ce17739a50c17efc8e69e6ae401 |
32 |
DIST mesa-18.1.0-rc2.tar.xz 11117872 BLAKE2B a95096ed573031eed17b880f725d68af062e0f7d9513d391d83c51e996fa238add93e05ae98ad4ed77d731f7521736b73566687be798029293d88f8b4b75db1c SHA512 43ddb27c436ab6ad08c4f5f764855e0681c10995e5279146c01e03e6e8af98dd23d96a20d3ac50107a6ca89cc3dd094bc472ddd70d290d0357cef3059ae34cfc |
33 |
|
34 |
diff --git a/media-libs/mesa/mesa-17.1.10.ebuild b/media-libs/mesa/mesa-17.1.10.ebuild |
35 |
deleted file mode 100644 |
36 |
index ed0e205a3b4..00000000000 |
37 |
--- a/media-libs/mesa/mesa-17.1.10.ebuild |
38 |
+++ /dev/null |
39 |
@@ -1,505 +0,0 @@ |
40 |
-# Copyright 1999-2018 Gentoo Foundation |
41 |
-# Distributed under the terms of the GNU General Public License v2 |
42 |
- |
43 |
-EAPI=6 |
44 |
- |
45 |
-EGIT_REPO_URI="https://anongit.freedesktop.org/git/mesa/mesa.git" |
46 |
- |
47 |
-if [[ ${PV} = 9999 ]]; then |
48 |
- GIT_ECLASS="git-r3" |
49 |
- EXPERIMENTAL="true" |
50 |
-fi |
51 |
- |
52 |
-PYTHON_COMPAT=( python2_7 ) |
53 |
- |
54 |
-inherit autotools llvm multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS} |
55 |
- |
56 |
-OPENGL_DIR="xorg-x11" |
57 |
- |
58 |
-MY_P="${P/_/-}" |
59 |
- |
60 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
61 |
-HOMEPAGE="https://www.mesa3d.org/" |
62 |
- |
63 |
-if [[ $PV == 9999 ]]; then |
64 |
- SRC_URI="" |
65 |
-else |
66 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
67 |
- KEYWORDS="arm" |
68 |
-fi |
69 |
- |
70 |
-LICENSE="MIT" |
71 |
-SLOT="0" |
72 |
-RESTRICT="!bindist? ( bindist )" |
73 |
- |
74 |
-INTEL_CARDS="i915 i965 intel" |
75 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
76 |
-VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} freedreno imx nouveau vc4 vivante vmware" |
77 |
-for card in ${VIDEO_CARDS}; do |
78 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
79 |
-done |
80 |
- |
81 |
-IUSE="${IUSE_VIDEO_CARDS} |
82 |
- bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 unwind |
83 |
- +llvm +nptl opencl osmesa pax_kernel openmax pic selinux vaapi valgrind |
84 |
- vdpau vulkan wayland xvmc xa" |
85 |
- |
86 |
-REQUIRED_USE=" |
87 |
- d3d9? ( dri3 gallium ) |
88 |
- llvm? ( gallium ) |
89 |
- opencl? ( gallium llvm ) |
90 |
- openmax? ( gallium ) |
91 |
- gles1? ( egl ) |
92 |
- gles2? ( egl ) |
93 |
- vaapi? ( gallium ) |
94 |
- vdpau? ( gallium ) |
95 |
- vulkan? ( || ( video_cards_i965 video_cards_radeonsi ) |
96 |
- video_cards_radeonsi? ( llvm ) ) |
97 |
- wayland? ( egl gbm ) |
98 |
- xa? ( gallium ) |
99 |
- video_cards_freedreno? ( gallium ) |
100 |
- video_cards_intel? ( classic ) |
101 |
- video_cards_i915? ( || ( classic gallium ) ) |
102 |
- video_cards_i965? ( classic ) |
103 |
- video_cards_imx? ( gallium ) |
104 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
105 |
- video_cards_radeon? ( || ( classic gallium ) |
106 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
107 |
- video_cards_r100? ( classic ) |
108 |
- video_cards_r200? ( classic ) |
109 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
110 |
- video_cards_r600? ( gallium ) |
111 |
- video_cards_radeonsi? ( gallium llvm ) |
112 |
- video_cards_vc4? ( gallium ) |
113 |
- video_cards_vivante? ( gallium gbm ) |
114 |
- video_cards_vmware? ( gallium ) |
115 |
-" |
116 |
- |
117 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.77" |
118 |
-# keep correct libdrm and dri2proto dep |
119 |
-# keep blocks in rdepend for binpkg |
120 |
-RDEPEND=" |
121 |
- !<x11-base/xorg-server-1.7 |
122 |
- !<=x11-proto/xf86driproto-2.0.3 |
123 |
- classic? ( app-eselect/eselect-mesa ) |
124 |
- gallium? ( app-eselect/eselect-mesa ) |
125 |
- >=app-eselect/eselect-opengl-1.3.0 |
126 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
127 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
128 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
129 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
130 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
131 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
132 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
133 |
- >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}] |
134 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
135 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
136 |
- llvm? ( |
137 |
- video_cards_radeonsi? ( |
138 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
139 |
- vulkan? ( >=sys-devel/llvm-3.9.0:0=[${MULTILIB_USEDEP}] ) |
140 |
- ) |
141 |
- video_cards_r600? ( |
142 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
143 |
- ) |
144 |
- video_cards_radeon? ( |
145 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
146 |
- ) |
147 |
- >=sys-devel/llvm-3.6.0:0=[${MULTILIB_USEDEP}] |
148 |
- ) |
149 |
- opencl? ( |
150 |
- app-eselect/eselect-opencl |
151 |
- dev-libs/libclc |
152 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
153 |
- ) |
154 |
- openmax? ( |
155 |
- >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] |
156 |
- x11-misc/xdg-utils |
157 |
- ) |
158 |
- vaapi? ( |
159 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
160 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
161 |
- ) |
162 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
163 |
- wayland? ( >=dev-libs/wayland-1.11.0:=[${MULTILIB_USEDEP}] ) |
164 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
165 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
166 |
-" |
167 |
-for card in ${INTEL_CARDS}; do |
168 |
- RDEPEND="${RDEPEND} |
169 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
170 |
- " |
171 |
-done |
172 |
- |
173 |
-for card in ${RADEON_CARDS}; do |
174 |
- RDEPEND="${RDEPEND} |
175 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
176 |
- " |
177 |
-done |
178 |
-RDEPEND="${RDEPEND} |
179 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
180 |
-" |
181 |
- |
182 |
-# FIXME: kill the sys-devel/llvm[video_cards_radeon] compat once |
183 |
-# LLVM < 3.9 is out of the game |
184 |
-DEPEND="${RDEPEND} |
185 |
- ${PYTHON_DEPS} |
186 |
- llvm? ( |
187 |
- video_cards_radeonsi? ( || ( |
188 |
- sys-devel/llvm:0[llvm_targets_AMDGPU] |
189 |
- sys-devel/llvm:0[video_cards_radeon] |
190 |
- ) ) |
191 |
- ) |
192 |
- opencl? ( |
193 |
- >=sys-devel/llvm-3.6.0:0=[${MULTILIB_USEDEP}] |
194 |
- >=sys-devel/clang-3.6.0:0=[${MULTILIB_USEDEP}] |
195 |
- >=sys-devel/gcc-4.6 |
196 |
- ) |
197 |
- sys-devel/gettext |
198 |
- virtual/pkgconfig |
199 |
- valgrind? ( dev-util/valgrind ) |
200 |
- >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}] |
201 |
- dri3? ( |
202 |
- >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}] |
203 |
- >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}] |
204 |
- ) |
205 |
- >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}] |
206 |
- >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}] |
207 |
- >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}] |
208 |
- >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}] |
209 |
-" |
210 |
-[[ ${PV} == 9999 ]] && DEPEND+=" |
211 |
- sys-devel/bison |
212 |
- sys-devel/flex |
213 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
214 |
-" |
215 |
- |
216 |
-S="${WORKDIR}/${MY_P}" |
217 |
-EGIT_CHECKOUT_DIR=${S} |
218 |
- |
219 |
-QA_WX_LOAD=" |
220 |
-x86? ( |
221 |
- !pic? ( |
222 |
- usr/lib*/libglapi.so.0.0.0 |
223 |
- usr/lib*/libGLESv1_CM.so.1.1.0 |
224 |
- usr/lib*/libGLESv2.so.2.0.0 |
225 |
- usr/lib*/libGL.so.1.2.0 |
226 |
- usr/lib*/libOSMesa.so.8.0.0 |
227 |
- ) |
228 |
-)" |
229 |
- |
230 |
-pkg_setup() { |
231 |
- # warning message for bug 459306 |
232 |
- if use llvm && has_version "sys-devel/llvm:0[!debug=]"; then |
233 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
234 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
235 |
- fi |
236 |
- |
237 |
- if use llvm || use opencl; then |
238 |
- llvm_pkg_setup |
239 |
- fi |
240 |
- python-any-r1_pkg_setup |
241 |
-} |
242 |
- |
243 |
-src_prepare() { |
244 |
- [[ ${PV} == 9999 ]] && eautoreconf |
245 |
- eapply_user |
246 |
-} |
247 |
- |
248 |
-multilib_src_configure() { |
249 |
- local myconf |
250 |
- |
251 |
- if use classic; then |
252 |
- # Configurable DRI drivers |
253 |
- driver_enable swrast |
254 |
- |
255 |
- # Intel code |
256 |
- driver_enable video_cards_i915 i915 |
257 |
- driver_enable video_cards_i965 i965 |
258 |
- if ! use video_cards_i915 && \ |
259 |
- ! use video_cards_i965; then |
260 |
- driver_enable video_cards_intel i915 i965 |
261 |
- fi |
262 |
- |
263 |
- # Nouveau code |
264 |
- driver_enable video_cards_nouveau nouveau |
265 |
- |
266 |
- # ATI code |
267 |
- driver_enable video_cards_r100 radeon |
268 |
- driver_enable video_cards_r200 r200 |
269 |
- if ! use video_cards_r100 && \ |
270 |
- ! use video_cards_r200; then |
271 |
- driver_enable video_cards_radeon radeon r200 |
272 |
- fi |
273 |
- fi |
274 |
- |
275 |
- if use egl; then |
276 |
- myconf+=" --with-egl-platforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm")" |
277 |
- fi |
278 |
- |
279 |
- if use gallium; then |
280 |
- myconf+=" |
281 |
- $(use_enable d3d9 nine) |
282 |
- $(use_enable llvm) |
283 |
- $(use_enable openmax omx) |
284 |
- $(use_enable vaapi va) |
285 |
- $(use_enable vdpau) |
286 |
- $(use_enable xa) |
287 |
- $(use_enable xvmc) |
288 |
- " |
289 |
- use vaapi && myconf+=" --with-va-libdir=/usr/$(get_libdir)/va/drivers" |
290 |
- |
291 |
- gallium_enable swrast |
292 |
- gallium_enable video_cards_vc4 vc4 |
293 |
- gallium_enable video_cards_vivante etnaviv |
294 |
- gallium_enable video_cards_vmware svga |
295 |
- gallium_enable video_cards_nouveau nouveau |
296 |
- gallium_enable video_cards_i915 i915 |
297 |
- gallium_enable video_cards_imx imx |
298 |
- if ! use video_cards_i915 && \ |
299 |
- ! use video_cards_i965; then |
300 |
- gallium_enable video_cards_intel i915 |
301 |
- fi |
302 |
- |
303 |
- gallium_enable video_cards_r300 r300 |
304 |
- gallium_enable video_cards_r600 r600 |
305 |
- gallium_enable video_cards_radeonsi radeonsi |
306 |
- if ! use video_cards_r300 && \ |
307 |
- ! use video_cards_r600; then |
308 |
- gallium_enable video_cards_radeon r300 r600 |
309 |
- fi |
310 |
- |
311 |
- gallium_enable video_cards_freedreno freedreno |
312 |
- # opencl stuff |
313 |
- if use opencl; then |
314 |
- myconf+=" |
315 |
- $(use_enable opencl) |
316 |
- --with-clang-libdir="${EPREFIX}/usr/lib" |
317 |
- " |
318 |
- fi |
319 |
- fi |
320 |
- |
321 |
- if use vulkan; then |
322 |
- vulkan_enable video_cards_i965 intel |
323 |
- vulkan_enable video_cards_radeonsi radeon |
324 |
- fi |
325 |
- |
326 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
327 |
- if [[ ${ABI} == x86 ]]; then |
328 |
- myconf+=" $(use_enable pax_kernel glx-read-only-text)" |
329 |
- fi |
330 |
- |
331 |
- # on abi_x86_32 hardened we need to have asm disable |
332 |
- if [[ ${ABI} == x86* ]] && use pic; then |
333 |
- myconf+=" --disable-asm" |
334 |
- fi |
335 |
- |
336 |
- if use gallium; then |
337 |
- myconf+=" $(use_enable osmesa gallium-osmesa)" |
338 |
- else |
339 |
- myconf+=" $(use_enable osmesa)" |
340 |
- fi |
341 |
- |
342 |
- # build fails with BSD indent, bug #428112 |
343 |
- use userland_GNU || export INDENT=cat |
344 |
- |
345 |
- ECONF_SOURCE="${S}" \ |
346 |
- econf \ |
347 |
- --enable-dri \ |
348 |
- --enable-glx \ |
349 |
- --enable-shared-glapi \ |
350 |
- $(use_enable !bindist texture-float) \ |
351 |
- $(use_enable d3d9 nine) \ |
352 |
- $(use_enable debug) \ |
353 |
- $(use_enable dri3) \ |
354 |
- $(use_enable egl) \ |
355 |
- $(use_enable gbm) \ |
356 |
- $(use_enable gles1) \ |
357 |
- $(use_enable gles2) \ |
358 |
- $(use_enable nptl glx-tls) \ |
359 |
- $(use_enable unwind libunwind) \ |
360 |
- --enable-valgrind=$(usex valgrind auto no) \ |
361 |
- --enable-llvm-shared-libs \ |
362 |
- --with-dri-drivers=${DRI_DRIVERS} \ |
363 |
- --with-gallium-drivers=${GALLIUM_DRIVERS} \ |
364 |
- --with-vulkan-drivers=${VULKAN_DRIVERS} \ |
365 |
- PYTHON2="${PYTHON}" \ |
366 |
- ${myconf} |
367 |
-} |
368 |
- |
369 |
-multilib_src_install() { |
370 |
- emake install DESTDIR="${D}" |
371 |
- |
372 |
- if use classic || use gallium; then |
373 |
- ebegin "Moving DRI/Gallium drivers for dynamic switching" |
374 |
- local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so ) |
375 |
- keepdir /usr/$(get_libdir)/dri |
376 |
- dodir /usr/$(get_libdir)/mesa |
377 |
- for x in ${gallium_drivers[@]}; do |
378 |
- if [ -f "$(get_libdir)/gallium/${x}" ]; then |
379 |
- mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \ |
380 |
- || die "Failed to move ${x}" |
381 |
- fi |
382 |
- done |
383 |
- if use classic; then |
384 |
- emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install |
385 |
- fi |
386 |
- for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do |
387 |
- if [ -f ${x} -o -L ${x} ]; then |
388 |
- mv -f "${x}" "${x/dri/mesa}" \ |
389 |
- || die "Failed to move ${x}" |
390 |
- fi |
391 |
- done |
392 |
- pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed" |
393 |
- ln -s ../mesa/*.so . || die "Creating symlink failed" |
394 |
- # remove symlinks to drivers known to eselect |
395 |
- for x in ${gallium_drivers[@]}; do |
396 |
- if [ -f ${x} -o -L ${x} ]; then |
397 |
- rm "${x}" || die "Failed to remove ${x}" |
398 |
- fi |
399 |
- done |
400 |
- popd |
401 |
- eend $? |
402 |
- fi |
403 |
- if use opencl; then |
404 |
- ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching" |
405 |
- local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa" |
406 |
- dodir ${cl_dir}/{lib,include} |
407 |
- if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then |
408 |
- mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \ |
409 |
- "${ED}"${cl_dir} |
410 |
- fi |
411 |
- if [ -f "${ED}/usr/include/CL/opencl.h" ]; then |
412 |
- mv -f "${ED}"/usr/include/CL \ |
413 |
- "${ED}"${cl_dir}/include |
414 |
- fi |
415 |
- eend $? |
416 |
- fi |
417 |
- |
418 |
- if use openmax; then |
419 |
- echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx" |
420 |
- doenvd "${T}"/99mesaxdgomx |
421 |
- keepdir /usr/share/mesa/xdg |
422 |
- fi |
423 |
-} |
424 |
- |
425 |
-multilib_src_install_all() { |
426 |
- find "${ED}" -name '*.la' -delete |
427 |
- einstalldocs |
428 |
- |
429 |
- if use !bindist; then |
430 |
- dodoc docs/patents.txt |
431 |
- fi |
432 |
- |
433 |
- # Install config file for eselect mesa |
434 |
- insinto /usr/share/mesa |
435 |
- newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf |
436 |
-} |
437 |
- |
438 |
-multilib_src_test() { |
439 |
- if use llvm; then |
440 |
- 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' |
441 |
- pushd src/gallium/drivers/llvmpipe >/dev/null || die |
442 |
- emake ${llvm_tests} |
443 |
- pax-mark m ${llvm_tests} |
444 |
- popd >/dev/null || die |
445 |
- fi |
446 |
- emake check |
447 |
-} |
448 |
- |
449 |
-pkg_postinst() { |
450 |
- # Switch to the xorg implementation. |
451 |
- echo |
452 |
- eselect opengl set --use-old ${OPENGL_DIR} |
453 |
- |
454 |
- # Select classic/gallium drivers |
455 |
- if use classic || use gallium; then |
456 |
- eselect mesa set --auto |
457 |
- fi |
458 |
- |
459 |
- # Switch to mesa opencl |
460 |
- if use opencl; then |
461 |
- eselect opencl set --use-old ${PN} |
462 |
- fi |
463 |
- |
464 |
- # run omxregister-bellagio to make the OpenMAX drivers known system-wide |
465 |
- if use openmax; then |
466 |
- ebegin "Registering OpenMAX drivers" |
467 |
- BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \ |
468 |
- OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \ |
469 |
- omxregister-bellagio |
470 |
- eend $? |
471 |
- fi |
472 |
- |
473 |
- # warn about patent encumbered texture-float |
474 |
- if use !bindist; then |
475 |
- elog "USE=\"bindist\" was not set. Potentially patent encumbered code was" |
476 |
- elog "enabled. Please see patents.txt for an explanation." |
477 |
- fi |
478 |
- |
479 |
- if ! has_version media-libs/libtxc_dxtn; then |
480 |
- elog "Note that in order to have full S3TC support, it is necessary to install" |
481 |
- elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice" |
482 |
- elog "textures in some apps, and some others even require this to run." |
483 |
- fi |
484 |
-} |
485 |
- |
486 |
-pkg_prerm() { |
487 |
- if use openmax; then |
488 |
- rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister |
489 |
- fi |
490 |
-} |
491 |
- |
492 |
-# $1 - VIDEO_CARDS flag |
493 |
-# other args - names of DRI drivers to enable |
494 |
-# TODO: avoid code duplication for a more elegant implementation |
495 |
-driver_enable() { |
496 |
- case $# in |
497 |
- # for enabling unconditionally |
498 |
- 1) |
499 |
- DRI_DRIVERS+=",$1" |
500 |
- ;; |
501 |
- *) |
502 |
- if use $1; then |
503 |
- shift |
504 |
- for i in $@; do |
505 |
- DRI_DRIVERS+=",${i}" |
506 |
- done |
507 |
- fi |
508 |
- ;; |
509 |
- esac |
510 |
-} |
511 |
- |
512 |
-gallium_enable() { |
513 |
- case $# in |
514 |
- # for enabling unconditionally |
515 |
- 1) |
516 |
- GALLIUM_DRIVERS+=",$1" |
517 |
- ;; |
518 |
- *) |
519 |
- if use $1; then |
520 |
- shift |
521 |
- for i in $@; do |
522 |
- GALLIUM_DRIVERS+=",${i}" |
523 |
- done |
524 |
- fi |
525 |
- ;; |
526 |
- esac |
527 |
-} |
528 |
- |
529 |
-vulkan_enable() { |
530 |
- case $# in |
531 |
- # for enabling unconditionally |
532 |
- 1) |
533 |
- VULKAN_DRIVERS+=",$1" |
534 |
- ;; |
535 |
- *) |
536 |
- if use $1; then |
537 |
- shift |
538 |
- for i in $@; do |
539 |
- VULKAN_DRIVERS+=",${i}" |
540 |
- done |
541 |
- fi |
542 |
- ;; |
543 |
- esac |
544 |
-} |
545 |
|
546 |
diff --git a/media-libs/mesa/mesa-17.2.8.ebuild b/media-libs/mesa/mesa-17.2.8.ebuild |
547 |
deleted file mode 100644 |
548 |
index b009828a1ad..00000000000 |
549 |
--- a/media-libs/mesa/mesa-17.2.8.ebuild |
550 |
+++ /dev/null |
551 |
@@ -1,584 +0,0 @@ |
552 |
-# Copyright 1999-2018 Gentoo Foundation |
553 |
-# Distributed under the terms of the GNU General Public License v2 |
554 |
- |
555 |
-EAPI=6 |
556 |
- |
557 |
-EGIT_REPO_URI="https://anongit.freedesktop.org/git/mesa/mesa.git" |
558 |
- |
559 |
-if [[ ${PV} = 9999 ]]; then |
560 |
- GIT_ECLASS="git-r3" |
561 |
- EXPERIMENTAL="true" |
562 |
-fi |
563 |
- |
564 |
-PYTHON_COMPAT=( python2_7 ) |
565 |
- |
566 |
-inherit autotools llvm multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS} |
567 |
- |
568 |
-OPENGL_DIR="xorg-x11" |
569 |
- |
570 |
-MY_P="${P/_/-}" |
571 |
- |
572 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
573 |
-HOMEPAGE="https://www.mesa3d.org/" |
574 |
- |
575 |
-if [[ $PV == 9999 ]]; then |
576 |
- SRC_URI="" |
577 |
-else |
578 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
579 |
- KEYWORDS="alpha amd64 ~arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
580 |
-fi |
581 |
- |
582 |
-LICENSE="MIT" |
583 |
-SLOT="0" |
584 |
-RESTRICT="!bindist? ( bindist )" |
585 |
- |
586 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
587 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
588 |
-for card in ${VIDEO_CARDS}; do |
589 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
590 |
-done |
591 |
- |
592 |
-IUSE="${IUSE_VIDEO_CARDS} |
593 |
- bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 unwind |
594 |
- +llvm +nptl opencl osmesa pax_kernel openmax pic selinux vaapi valgrind |
595 |
- vdpau vulkan wayland xvmc xa" |
596 |
- |
597 |
-REQUIRED_USE=" |
598 |
- d3d9? ( dri3 gallium ) |
599 |
- llvm? ( gallium ) |
600 |
- opencl? ( gallium llvm ) |
601 |
- openmax? ( gallium ) |
602 |
- gles1? ( egl ) |
603 |
- gles2? ( egl ) |
604 |
- vaapi? ( gallium ) |
605 |
- vdpau? ( gallium ) |
606 |
- vulkan? ( || ( video_cards_i965 video_cards_radeonsi ) |
607 |
- video_cards_radeonsi? ( llvm ) ) |
608 |
- wayland? ( egl gbm ) |
609 |
- xa? ( gallium ) |
610 |
- video_cards_freedreno? ( gallium ) |
611 |
- video_cards_intel? ( classic ) |
612 |
- video_cards_i915? ( || ( classic gallium ) ) |
613 |
- video_cards_i965? ( classic ) |
614 |
- video_cards_imx? ( gallium ) |
615 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
616 |
- video_cards_radeon? ( || ( classic gallium ) |
617 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
618 |
- video_cards_r100? ( classic ) |
619 |
- video_cards_r200? ( classic ) |
620 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
621 |
- video_cards_r600? ( gallium ) |
622 |
- video_cards_radeonsi? ( gallium llvm ) |
623 |
- video_cards_vc4? ( gallium ) |
624 |
- video_cards_virgl? ( gallium ) |
625 |
- video_cards_vivante? ( gallium gbm ) |
626 |
- video_cards_vmware? ( gallium ) |
627 |
-" |
628 |
- |
629 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.82" |
630 |
-# keep correct libdrm and dri2proto dep |
631 |
-# keep blocks in rdepend for binpkg |
632 |
-RDEPEND=" |
633 |
- !<x11-base/xorg-server-1.7 |
634 |
- !<=x11-proto/xf86driproto-2.0.3 |
635 |
- classic? ( app-eselect/eselect-mesa ) |
636 |
- gallium? ( app-eselect/eselect-mesa ) |
637 |
- >=app-eselect/eselect-opengl-1.3.0 |
638 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
639 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
640 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
641 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
642 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
643 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
644 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
645 |
- >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}] |
646 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
647 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
648 |
- llvm? ( |
649 |
- video_cards_radeonsi? ( |
650 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
651 |
- ) |
652 |
- video_cards_r600? ( |
653 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
654 |
- ) |
655 |
- video_cards_radeon? ( |
656 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
657 |
- ) |
658 |
- ) |
659 |
- opencl? ( |
660 |
- app-eselect/eselect-opencl |
661 |
- dev-libs/libclc |
662 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
663 |
- ) |
664 |
- openmax? ( |
665 |
- >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] |
666 |
- x11-misc/xdg-utils |
667 |
- ) |
668 |
- vaapi? ( |
669 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
670 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
671 |
- ) |
672 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
673 |
- wayland? ( |
674 |
- >=dev-libs/wayland-1.11.0:=[${MULTILIB_USEDEP}] |
675 |
- >=dev-libs/wayland-protocols-1.8 |
676 |
- ) |
677 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
678 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
679 |
- |
680 |
- video_cards_intel? ( |
681 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
682 |
- ) |
683 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
684 |
-" |
685 |
-for card in ${RADEON_CARDS}; do |
686 |
- RDEPEND="${RDEPEND} |
687 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
688 |
- " |
689 |
-done |
690 |
-RDEPEND="${RDEPEND} |
691 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
692 |
-" |
693 |
- |
694 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
695 |
-# we need to *really* make sure we're not pulling one than more slot |
696 |
-# simultaneously. |
697 |
-# |
698 |
-# How to use it: |
699 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
700 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
701 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
702 |
-LLVM_MAX_SLOT="5" |
703 |
-LLVM_DEPSTR=" |
704 |
- || ( |
705 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
706 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
707 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
708 |
- ) |
709 |
- <sys-devel/llvm-6:=[${MULTILIB_USEDEP}] |
710 |
-" |
711 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
712 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
713 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
714 |
-RDEPEND="${RDEPEND} |
715 |
- llvm? ( |
716 |
- opencl? ( |
717 |
- video_cards_r600? ( |
718 |
- ${CLANG_DEPSTR_AMDGPU} |
719 |
- ) |
720 |
- !video_cards_r600? ( |
721 |
- video_cards_radeonsi? ( |
722 |
- ${CLANG_DEPSTR_AMDGPU} |
723 |
- ) |
724 |
- ) |
725 |
- !video_cards_r600? ( |
726 |
- !video_cards_radeonsi? ( |
727 |
- video_cards_radeon? ( |
728 |
- ${CLANG_DEPSTR_AMDGPU} |
729 |
- ) |
730 |
- ) |
731 |
- ) |
732 |
- !video_cards_r600? ( |
733 |
- !video_cards_radeon? ( |
734 |
- !video_cards_radeonsi? ( |
735 |
- ${CLANG_DEPSTR} |
736 |
- ) |
737 |
- ) |
738 |
- ) |
739 |
- ) |
740 |
- !opencl? ( |
741 |
- video_cards_r600? ( |
742 |
- ${LLVM_DEPSTR_AMDGPU} |
743 |
- ) |
744 |
- !video_cards_r600? ( |
745 |
- video_cards_radeonsi? ( |
746 |
- ${LLVM_DEPSTR_AMDGPU} |
747 |
- ) |
748 |
- ) |
749 |
- !video_cards_r600? ( |
750 |
- !video_cards_radeonsi? ( |
751 |
- video_cards_radeon? ( |
752 |
- ${LLVM_DEPSTR_AMDGPU} |
753 |
- ) |
754 |
- ) |
755 |
- ) |
756 |
- !video_cards_r600? ( |
757 |
- !video_cards_radeon? ( |
758 |
- !video_cards_radeonsi? ( |
759 |
- ${LLVM_DEPSTR} |
760 |
- ) |
761 |
- ) |
762 |
- ) |
763 |
- ) |
764 |
- ) |
765 |
-" |
766 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
767 |
- |
768 |
-DEPEND="${RDEPEND} |
769 |
- ${PYTHON_DEPS} |
770 |
- opencl? ( |
771 |
- >=sys-devel/gcc-4.6 |
772 |
- ) |
773 |
- sys-devel/gettext |
774 |
- virtual/pkgconfig |
775 |
- valgrind? ( dev-util/valgrind ) |
776 |
- >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}] |
777 |
- dri3? ( |
778 |
- >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}] |
779 |
- >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}] |
780 |
- ) |
781 |
- >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}] |
782 |
- >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}] |
783 |
- >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}] |
784 |
- >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}] |
785 |
-" |
786 |
-[[ ${PV} == 9999 ]] && DEPEND+=" |
787 |
- sys-devel/bison |
788 |
- sys-devel/flex |
789 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
790 |
-" |
791 |
- |
792 |
-S="${WORKDIR}/${MY_P}" |
793 |
-EGIT_CHECKOUT_DIR=${S} |
794 |
- |
795 |
-QA_WX_LOAD=" |
796 |
-x86? ( |
797 |
- !pic? ( |
798 |
- usr/lib*/libglapi.so.0.0.0 |
799 |
- usr/lib*/libGLESv1_CM.so.1.1.0 |
800 |
- usr/lib*/libGLESv2.so.2.0.0 |
801 |
- usr/lib*/libGL.so.1.2.0 |
802 |
- usr/lib*/libOSMesa.so.8.0.0 |
803 |
- ) |
804 |
-)" |
805 |
- |
806 |
-llvm_check_deps() { |
807 |
- local flags=${MULTILIB_USEDEP} |
808 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
809 |
- then |
810 |
- flags+=",llvm_targets_AMDGPU(-)" |
811 |
- fi |
812 |
- |
813 |
- if use opencl; then |
814 |
- has_version "sys-devel/clang[${flags}]" || return 1 |
815 |
- fi |
816 |
- has_version "sys-devel/llvm[${flags}]" |
817 |
-} |
818 |
- |
819 |
-pkg_setup() { |
820 |
- # warning message for bug 459306 |
821 |
- if use llvm && has_version sys-devel/llvm[!debug=]; then |
822 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
823 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
824 |
- fi |
825 |
- |
826 |
- if use llvm; then |
827 |
- llvm_pkg_setup |
828 |
- fi |
829 |
- python-any-r1_pkg_setup |
830 |
-} |
831 |
- |
832 |
-src_prepare() { |
833 |
- [[ ${PV} == 9999 ]] && eautoreconf |
834 |
- eapply_user |
835 |
-} |
836 |
- |
837 |
-multilib_src_configure() { |
838 |
- local myconf |
839 |
- |
840 |
- if use classic; then |
841 |
- # Configurable DRI drivers |
842 |
- driver_enable swrast |
843 |
- |
844 |
- # Intel code |
845 |
- driver_enable video_cards_i915 i915 |
846 |
- driver_enable video_cards_i965 i965 |
847 |
- if ! use video_cards_i915 && \ |
848 |
- ! use video_cards_i965; then |
849 |
- driver_enable video_cards_intel i915 i965 |
850 |
- fi |
851 |
- |
852 |
- # Nouveau code |
853 |
- driver_enable video_cards_nouveau nouveau |
854 |
- |
855 |
- # ATI code |
856 |
- driver_enable video_cards_r100 radeon |
857 |
- driver_enable video_cards_r200 r200 |
858 |
- if ! use video_cards_r100 && \ |
859 |
- ! use video_cards_r200; then |
860 |
- driver_enable video_cards_radeon radeon r200 |
861 |
- fi |
862 |
- fi |
863 |
- |
864 |
- if use egl; then |
865 |
- myconf+=" --with-platforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm")" |
866 |
- fi |
867 |
- |
868 |
- if use gallium; then |
869 |
- myconf+=" |
870 |
- $(use_enable d3d9 nine) |
871 |
- $(use_enable llvm) |
872 |
- $(use_enable openmax omx) |
873 |
- $(use_enable vaapi va) |
874 |
- $(use_enable vdpau) |
875 |
- $(use_enable xa) |
876 |
- $(use_enable xvmc) |
877 |
- " |
878 |
- use vaapi && myconf+=" --with-va-libdir=/usr/$(get_libdir)/va/drivers" |
879 |
- |
880 |
- gallium_enable swrast |
881 |
- gallium_enable video_cards_vc4 vc4 |
882 |
- gallium_enable video_cards_vivante etnaviv |
883 |
- gallium_enable video_cards_vmware svga |
884 |
- gallium_enable video_cards_nouveau nouveau |
885 |
- gallium_enable video_cards_i915 i915 |
886 |
- gallium_enable video_cards_imx imx |
887 |
- if ! use video_cards_i915 && \ |
888 |
- ! use video_cards_i965; then |
889 |
- gallium_enable video_cards_intel i915 |
890 |
- fi |
891 |
- |
892 |
- gallium_enable video_cards_r300 r300 |
893 |
- gallium_enable video_cards_r600 r600 |
894 |
- gallium_enable video_cards_radeonsi radeonsi |
895 |
- if ! use video_cards_r300 && \ |
896 |
- ! use video_cards_r600; then |
897 |
- gallium_enable video_cards_radeon r300 r600 |
898 |
- fi |
899 |
- |
900 |
- gallium_enable video_cards_freedreno freedreno |
901 |
- # opencl stuff |
902 |
- if use opencl; then |
903 |
- myconf+=" |
904 |
- $(use_enable opencl) |
905 |
- --with-clang-libdir="${EPREFIX}/usr/lib" |
906 |
- " |
907 |
- fi |
908 |
- |
909 |
- gallium_enable video_cards_virgl virgl |
910 |
- fi |
911 |
- |
912 |
- if use vulkan; then |
913 |
- vulkan_enable video_cards_i965 intel |
914 |
- vulkan_enable video_cards_radeonsi radeon |
915 |
- fi |
916 |
- |
917 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
918 |
- if [[ ${ABI} == x86 ]]; then |
919 |
- myconf+=" $(use_enable pax_kernel glx-read-only-text)" |
920 |
- fi |
921 |
- |
922 |
- # on abi_x86_32 hardened we need to have asm disable |
923 |
- if [[ ${ABI} == x86* ]] && use pic; then |
924 |
- myconf+=" --disable-asm" |
925 |
- fi |
926 |
- |
927 |
- if use gallium; then |
928 |
- myconf+=" $(use_enable osmesa gallium-osmesa)" |
929 |
- else |
930 |
- myconf+=" $(use_enable osmesa)" |
931 |
- fi |
932 |
- |
933 |
- # build fails with BSD indent, bug #428112 |
934 |
- use userland_GNU || export INDENT=cat |
935 |
- |
936 |
- ECONF_SOURCE="${S}" \ |
937 |
- econf \ |
938 |
- --enable-dri \ |
939 |
- --enable-glx \ |
940 |
- --enable-shared-glapi \ |
941 |
- $(use_enable !bindist texture-float) \ |
942 |
- $(use_enable d3d9 nine) \ |
943 |
- $(use_enable debug) \ |
944 |
- $(use_enable dri3) \ |
945 |
- $(use_enable egl) \ |
946 |
- $(use_enable gbm) \ |
947 |
- $(use_enable gles1) \ |
948 |
- $(use_enable gles2) \ |
949 |
- $(use_enable nptl glx-tls) \ |
950 |
- $(use_enable unwind libunwind) \ |
951 |
- --enable-valgrind=$(usex valgrind auto no) \ |
952 |
- --enable-llvm-shared-libs \ |
953 |
- --with-dri-drivers=${DRI_DRIVERS} \ |
954 |
- --with-gallium-drivers=${GALLIUM_DRIVERS} \ |
955 |
- --with-vulkan-drivers=${VULKAN_DRIVERS} \ |
956 |
- PYTHON2="${PYTHON}" \ |
957 |
- ${myconf} |
958 |
-} |
959 |
- |
960 |
-multilib_src_install() { |
961 |
- emake install DESTDIR="${D}" |
962 |
- |
963 |
- if use classic || use gallium; then |
964 |
- ebegin "Moving DRI/Gallium drivers for dynamic switching" |
965 |
- local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so ) |
966 |
- keepdir /usr/$(get_libdir)/dri |
967 |
- dodir /usr/$(get_libdir)/mesa |
968 |
- for x in ${gallium_drivers[@]}; do |
969 |
- if [ -f "$(get_libdir)/gallium/${x}" ]; then |
970 |
- mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \ |
971 |
- || die "Failed to move ${x}" |
972 |
- fi |
973 |
- done |
974 |
- if use classic; then |
975 |
- emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install |
976 |
- fi |
977 |
- for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do |
978 |
- if [ -f ${x} -o -L ${x} ]; then |
979 |
- mv -f "${x}" "${x/dri/mesa}" \ |
980 |
- || die "Failed to move ${x}" |
981 |
- fi |
982 |
- done |
983 |
- pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed" |
984 |
- ln -s ../mesa/*.so . || die "Creating symlink failed" |
985 |
- # remove symlinks to drivers known to eselect |
986 |
- for x in ${gallium_drivers[@]}; do |
987 |
- if [ -f ${x} -o -L ${x} ]; then |
988 |
- rm "${x}" || die "Failed to remove ${x}" |
989 |
- fi |
990 |
- done |
991 |
- popd |
992 |
- eend $? |
993 |
- fi |
994 |
- if use opencl; then |
995 |
- ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching" |
996 |
- local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa" |
997 |
- dodir ${cl_dir}/{lib,include} |
998 |
- if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then |
999 |
- mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \ |
1000 |
- "${ED}"${cl_dir} |
1001 |
- fi |
1002 |
- if [ -f "${ED}/usr/include/CL/opencl.h" ]; then |
1003 |
- mv -f "${ED}"/usr/include/CL \ |
1004 |
- "${ED}"${cl_dir}/include |
1005 |
- fi |
1006 |
- eend $? |
1007 |
- fi |
1008 |
- |
1009 |
- if use openmax; then |
1010 |
- echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx" |
1011 |
- doenvd "${T}"/99mesaxdgomx |
1012 |
- keepdir /usr/share/mesa/xdg |
1013 |
- fi |
1014 |
-} |
1015 |
- |
1016 |
-multilib_src_install_all() { |
1017 |
- find "${ED}" -name '*.la' -delete |
1018 |
- einstalldocs |
1019 |
- |
1020 |
- if use !bindist; then |
1021 |
- dodoc docs/patents.txt |
1022 |
- fi |
1023 |
- |
1024 |
- # Install config file for eselect mesa |
1025 |
- insinto /usr/share/mesa |
1026 |
- newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf |
1027 |
-} |
1028 |
- |
1029 |
-multilib_src_test() { |
1030 |
- if use llvm; then |
1031 |
- 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' |
1032 |
- pushd src/gallium/drivers/llvmpipe >/dev/null || die |
1033 |
- emake ${llvm_tests} |
1034 |
- pax-mark m ${llvm_tests} |
1035 |
- popd >/dev/null || die |
1036 |
- fi |
1037 |
- emake check |
1038 |
-} |
1039 |
- |
1040 |
-pkg_postinst() { |
1041 |
- # Switch to the xorg implementation. |
1042 |
- echo |
1043 |
- eselect opengl set --use-old ${OPENGL_DIR} |
1044 |
- |
1045 |
- # Select classic/gallium drivers |
1046 |
- if use classic || use gallium; then |
1047 |
- eselect mesa set --auto |
1048 |
- fi |
1049 |
- |
1050 |
- # Switch to mesa opencl |
1051 |
- if use opencl; then |
1052 |
- eselect opencl set --use-old ${PN} |
1053 |
- fi |
1054 |
- |
1055 |
- # run omxregister-bellagio to make the OpenMAX drivers known system-wide |
1056 |
- if use openmax; then |
1057 |
- ebegin "Registering OpenMAX drivers" |
1058 |
- BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \ |
1059 |
- OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \ |
1060 |
- omxregister-bellagio |
1061 |
- eend $? |
1062 |
- fi |
1063 |
- |
1064 |
- # warn about patent encumbered texture-float |
1065 |
- if use !bindist; then |
1066 |
- elog "USE=\"bindist\" was not set. Potentially patent encumbered code was" |
1067 |
- elog "enabled. Please see patents.txt for an explanation." |
1068 |
- fi |
1069 |
- |
1070 |
- if ! has_version media-libs/libtxc_dxtn; then |
1071 |
- elog "Note that in order to have full S3TC support, it is necessary to install" |
1072 |
- elog "media-libs/libtxc_dxtn as well. This may be necessary to get nice" |
1073 |
- elog "textures in some apps, and some others even require this to run." |
1074 |
- fi |
1075 |
-} |
1076 |
- |
1077 |
-pkg_prerm() { |
1078 |
- if use openmax; then |
1079 |
- rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister |
1080 |
- fi |
1081 |
-} |
1082 |
- |
1083 |
-# $1 - VIDEO_CARDS flag |
1084 |
-# other args - names of DRI drivers to enable |
1085 |
-# TODO: avoid code duplication for a more elegant implementation |
1086 |
-driver_enable() { |
1087 |
- case $# in |
1088 |
- # for enabling unconditionally |
1089 |
- 1) |
1090 |
- DRI_DRIVERS+=",$1" |
1091 |
- ;; |
1092 |
- *) |
1093 |
- if use $1; then |
1094 |
- shift |
1095 |
- for i in $@; do |
1096 |
- DRI_DRIVERS+=",${i}" |
1097 |
- done |
1098 |
- fi |
1099 |
- ;; |
1100 |
- esac |
1101 |
-} |
1102 |
- |
1103 |
-gallium_enable() { |
1104 |
- case $# in |
1105 |
- # for enabling unconditionally |
1106 |
- 1) |
1107 |
- GALLIUM_DRIVERS+=",$1" |
1108 |
- ;; |
1109 |
- *) |
1110 |
- if use $1; then |
1111 |
- shift |
1112 |
- for i in $@; do |
1113 |
- GALLIUM_DRIVERS+=",${i}" |
1114 |
- done |
1115 |
- fi |
1116 |
- ;; |
1117 |
- esac |
1118 |
-} |
1119 |
- |
1120 |
-vulkan_enable() { |
1121 |
- case $# in |
1122 |
- # for enabling unconditionally |
1123 |
- 1) |
1124 |
- VULKAN_DRIVERS+=",$1" |
1125 |
- ;; |
1126 |
- *) |
1127 |
- if use $1; then |
1128 |
- shift |
1129 |
- for i in $@; do |
1130 |
- VULKAN_DRIVERS+=",${i}" |
1131 |
- done |
1132 |
- fi |
1133 |
- ;; |
1134 |
- esac |
1135 |
-} |
1136 |
|
1137 |
diff --git a/media-libs/mesa/mesa-17.3.8.ebuild b/media-libs/mesa/mesa-17.3.8.ebuild |
1138 |
deleted file mode 100644 |
1139 |
index c1821f5ec1b..00000000000 |
1140 |
--- a/media-libs/mesa/mesa-17.3.8.ebuild |
1141 |
+++ /dev/null |
1142 |
@@ -1,582 +0,0 @@ |
1143 |
-# Copyright 1999-2018 Gentoo Foundation |
1144 |
-# Distributed under the terms of the GNU General Public License v2 |
1145 |
- |
1146 |
-EAPI=6 |
1147 |
- |
1148 |
-EGIT_REPO_URI="https://anongit.freedesktop.org/git/mesa/mesa.git" |
1149 |
- |
1150 |
-if [[ ${PV} = 9999 ]]; then |
1151 |
- GIT_ECLASS="git-r3" |
1152 |
- EXPERIMENTAL="true" |
1153 |
-fi |
1154 |
- |
1155 |
-PYTHON_COMPAT=( python2_7 ) |
1156 |
- |
1157 |
-inherit autotools llvm multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS} |
1158 |
- |
1159 |
-OPENGL_DIR="xorg-x11" |
1160 |
- |
1161 |
-MY_P="${P/_/-}" |
1162 |
- |
1163 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
1164 |
-HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" |
1165 |
- |
1166 |
-if [[ $PV == 9999 ]]; then |
1167 |
- SRC_URI="" |
1168 |
-else |
1169 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
1170 |
- KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
1171 |
-fi |
1172 |
- |
1173 |
-LICENSE="MIT" |
1174 |
-SLOT="0" |
1175 |
-RESTRICT="!bindist? ( bindist )" |
1176 |
- |
1177 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
1178 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
1179 |
-for card in ${VIDEO_CARDS}; do |
1180 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
1181 |
-done |
1182 |
- |
1183 |
-IUSE="${IUSE_VIDEO_CARDS} |
1184 |
- bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 unwind |
1185 |
- +llvm +nptl opencl osmesa pax_kernel openmax pic selinux vaapi valgrind |
1186 |
- vdpau vulkan wayland xvmc xa" |
1187 |
- |
1188 |
-REQUIRED_USE=" |
1189 |
- d3d9? ( dri3 gallium ) |
1190 |
- llvm? ( gallium ) |
1191 |
- opencl? ( gallium llvm ) |
1192 |
- openmax? ( gallium ) |
1193 |
- gles1? ( egl ) |
1194 |
- gles2? ( egl ) |
1195 |
- vaapi? ( gallium ) |
1196 |
- vdpau? ( gallium ) |
1197 |
- vulkan? ( || ( video_cards_i965 video_cards_radeonsi ) |
1198 |
- video_cards_radeonsi? ( llvm ) ) |
1199 |
- wayland? ( egl gbm ) |
1200 |
- xa? ( gallium ) |
1201 |
- video_cards_freedreno? ( gallium ) |
1202 |
- video_cards_intel? ( classic ) |
1203 |
- video_cards_i915? ( || ( classic gallium ) ) |
1204 |
- video_cards_i965? ( classic ) |
1205 |
- video_cards_imx? ( gallium video_cards_vivante ) |
1206 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
1207 |
- video_cards_radeon? ( || ( classic gallium ) |
1208 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
1209 |
- video_cards_r100? ( classic ) |
1210 |
- video_cards_r200? ( classic ) |
1211 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
1212 |
- video_cards_r600? ( gallium ) |
1213 |
- video_cards_radeonsi? ( gallium llvm ) |
1214 |
- video_cards_vc4? ( gallium ) |
1215 |
- video_cards_virgl? ( gallium ) |
1216 |
- video_cards_vivante? ( gallium gbm ) |
1217 |
- video_cards_vmware? ( gallium ) |
1218 |
-" |
1219 |
- |
1220 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.89" |
1221 |
-# keep correct libdrm and dri2proto dep |
1222 |
-# keep blocks in rdepend for binpkg |
1223 |
-RDEPEND=" |
1224 |
- !<x11-base/xorg-server-1.7 |
1225 |
- !<=x11-proto/xf86driproto-2.0.3 |
1226 |
- classic? ( app-eselect/eselect-mesa ) |
1227 |
- gallium? ( app-eselect/eselect-mesa ) |
1228 |
- >=app-eselect/eselect-opengl-1.3.0 |
1229 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
1230 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
1231 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
1232 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
1233 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
1234 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
1235 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
1236 |
- >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}] |
1237 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
1238 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
1239 |
- llvm? ( |
1240 |
- video_cards_radeonsi? ( |
1241 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1242 |
- ) |
1243 |
- video_cards_r600? ( |
1244 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1245 |
- ) |
1246 |
- video_cards_radeon? ( |
1247 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1248 |
- ) |
1249 |
- ) |
1250 |
- opencl? ( |
1251 |
- app-eselect/eselect-opencl |
1252 |
- dev-libs/libclc |
1253 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1254 |
- ) |
1255 |
- openmax? ( |
1256 |
- >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] |
1257 |
- x11-misc/xdg-utils |
1258 |
- ) |
1259 |
- vaapi? ( |
1260 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
1261 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
1262 |
- ) |
1263 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
1264 |
- wayland? ( |
1265 |
- >=dev-libs/wayland-1.11.0:=[${MULTILIB_USEDEP}] |
1266 |
- >=dev-libs/wayland-protocols-1.8 |
1267 |
- ) |
1268 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
1269 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
1270 |
- |
1271 |
- video_cards_intel? ( |
1272 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
1273 |
- ) |
1274 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
1275 |
-" |
1276 |
-for card in ${RADEON_CARDS}; do |
1277 |
- RDEPEND="${RDEPEND} |
1278 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
1279 |
- " |
1280 |
-done |
1281 |
-RDEPEND="${RDEPEND} |
1282 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
1283 |
-" |
1284 |
- |
1285 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
1286 |
-# we need to *really* make sure we're not pulling one than more slot |
1287 |
-# simultaneously. |
1288 |
-# |
1289 |
-# How to use it: |
1290 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
1291 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
1292 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
1293 |
-LLVM_MAX_SLOT="5" |
1294 |
-LLVM_DEPSTR=" |
1295 |
- || ( |
1296 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
1297 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
1298 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
1299 |
- ) |
1300 |
- <sys-devel/llvm-6:=[${MULTILIB_USEDEP}] |
1301 |
-" |
1302 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
1303 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
1304 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
1305 |
-RDEPEND="${RDEPEND} |
1306 |
- llvm? ( |
1307 |
- opencl? ( |
1308 |
- video_cards_r600? ( |
1309 |
- ${CLANG_DEPSTR_AMDGPU} |
1310 |
- ) |
1311 |
- !video_cards_r600? ( |
1312 |
- video_cards_radeonsi? ( |
1313 |
- ${CLANG_DEPSTR_AMDGPU} |
1314 |
- ) |
1315 |
- ) |
1316 |
- !video_cards_r600? ( |
1317 |
- !video_cards_radeonsi? ( |
1318 |
- video_cards_radeon? ( |
1319 |
- ${CLANG_DEPSTR_AMDGPU} |
1320 |
- ) |
1321 |
- ) |
1322 |
- ) |
1323 |
- !video_cards_r600? ( |
1324 |
- !video_cards_radeon? ( |
1325 |
- !video_cards_radeonsi? ( |
1326 |
- ${CLANG_DEPSTR} |
1327 |
- ) |
1328 |
- ) |
1329 |
- ) |
1330 |
- ) |
1331 |
- !opencl? ( |
1332 |
- video_cards_r600? ( |
1333 |
- ${LLVM_DEPSTR_AMDGPU} |
1334 |
- ) |
1335 |
- !video_cards_r600? ( |
1336 |
- video_cards_radeonsi? ( |
1337 |
- ${LLVM_DEPSTR_AMDGPU} |
1338 |
- ) |
1339 |
- ) |
1340 |
- !video_cards_r600? ( |
1341 |
- !video_cards_radeonsi? ( |
1342 |
- video_cards_radeon? ( |
1343 |
- ${LLVM_DEPSTR_AMDGPU} |
1344 |
- ) |
1345 |
- ) |
1346 |
- ) |
1347 |
- !video_cards_r600? ( |
1348 |
- !video_cards_radeon? ( |
1349 |
- !video_cards_radeonsi? ( |
1350 |
- ${LLVM_DEPSTR} |
1351 |
- ) |
1352 |
- ) |
1353 |
- ) |
1354 |
- ) |
1355 |
- ) |
1356 |
-" |
1357 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
1358 |
- |
1359 |
-DEPEND="${RDEPEND} |
1360 |
- ${PYTHON_DEPS} |
1361 |
- opencl? ( |
1362 |
- >=sys-devel/gcc-4.6 |
1363 |
- ) |
1364 |
- sys-devel/gettext |
1365 |
- virtual/pkgconfig |
1366 |
- valgrind? ( dev-util/valgrind ) |
1367 |
- >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}] |
1368 |
- dri3? ( |
1369 |
- >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}] |
1370 |
- >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}] |
1371 |
- ) |
1372 |
- >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}] |
1373 |
- >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}] |
1374 |
- >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}] |
1375 |
- >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}] |
1376 |
- vulkan? ( |
1377 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
1378 |
- ) |
1379 |
-" |
1380 |
-[[ ${PV} == 9999 ]] && DEPEND+=" |
1381 |
- sys-devel/bison |
1382 |
- sys-devel/flex |
1383 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
1384 |
-" |
1385 |
- |
1386 |
-S="${WORKDIR}/${MY_P}" |
1387 |
-EGIT_CHECKOUT_DIR=${S} |
1388 |
- |
1389 |
-QA_WX_LOAD=" |
1390 |
-x86? ( |
1391 |
- !pic? ( |
1392 |
- usr/lib*/libglapi.so.0.0.0 |
1393 |
- usr/lib*/libGLESv1_CM.so.1.1.0 |
1394 |
- usr/lib*/libGLESv2.so.2.0.0 |
1395 |
- usr/lib*/libGL.so.1.2.0 |
1396 |
- usr/lib*/libOSMesa.so.8.0.0 |
1397 |
- ) |
1398 |
-)" |
1399 |
- |
1400 |
-llvm_check_deps() { |
1401 |
- local flags=${MULTILIB_USEDEP} |
1402 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
1403 |
- then |
1404 |
- flags+=",llvm_targets_AMDGPU(-)" |
1405 |
- fi |
1406 |
- |
1407 |
- if use opencl; then |
1408 |
- has_version "sys-devel/clang[${flags}]" || return 1 |
1409 |
- fi |
1410 |
- has_version "sys-devel/llvm[${flags}]" |
1411 |
-} |
1412 |
- |
1413 |
-pkg_setup() { |
1414 |
- # warning message for bug 459306 |
1415 |
- if use llvm && has_version sys-devel/llvm[!debug=]; then |
1416 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
1417 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
1418 |
- fi |
1419 |
- |
1420 |
- if use llvm; then |
1421 |
- llvm_pkg_setup |
1422 |
- fi |
1423 |
- python-any-r1_pkg_setup |
1424 |
-} |
1425 |
- |
1426 |
-src_prepare() { |
1427 |
- [[ ${PV} == 9999 ]] && eautoreconf |
1428 |
- eapply_user |
1429 |
-} |
1430 |
- |
1431 |
-multilib_src_configure() { |
1432 |
- local myconf |
1433 |
- |
1434 |
- if use classic; then |
1435 |
- # Configurable DRI drivers |
1436 |
- driver_enable swrast |
1437 |
- |
1438 |
- # Intel code |
1439 |
- driver_enable video_cards_i915 i915 |
1440 |
- driver_enable video_cards_i965 i965 |
1441 |
- if ! use video_cards_i915 && \ |
1442 |
- ! use video_cards_i965; then |
1443 |
- driver_enable video_cards_intel i915 i965 |
1444 |
- fi |
1445 |
- |
1446 |
- # Nouveau code |
1447 |
- driver_enable video_cards_nouveau nouveau |
1448 |
- |
1449 |
- # ATI code |
1450 |
- driver_enable video_cards_r100 radeon |
1451 |
- driver_enable video_cards_r200 r200 |
1452 |
- if ! use video_cards_r100 && \ |
1453 |
- ! use video_cards_r200; then |
1454 |
- driver_enable video_cards_radeon radeon r200 |
1455 |
- fi |
1456 |
- fi |
1457 |
- |
1458 |
- if use egl; then |
1459 |
- myconf+=" --with-platforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm")" |
1460 |
- fi |
1461 |
- |
1462 |
- if use gallium; then |
1463 |
- myconf+=" |
1464 |
- $(use_enable d3d9 nine) |
1465 |
- $(use_enable llvm) |
1466 |
- $(use_enable openmax omx-bellagio) |
1467 |
- $(use_enable vaapi va) |
1468 |
- $(use_enable vdpau) |
1469 |
- $(use_enable xa) |
1470 |
- $(use_enable xvmc) |
1471 |
- " |
1472 |
- use vaapi && myconf+=" --with-va-libdir=/usr/$(get_libdir)/va/drivers" |
1473 |
- |
1474 |
- gallium_enable swrast |
1475 |
- gallium_enable video_cards_vc4 vc4 |
1476 |
- gallium_enable video_cards_vivante etnaviv |
1477 |
- gallium_enable video_cards_vmware svga |
1478 |
- gallium_enable video_cards_nouveau nouveau |
1479 |
- gallium_enable video_cards_i915 i915 |
1480 |
- gallium_enable video_cards_imx imx |
1481 |
- if ! use video_cards_i915 && \ |
1482 |
- ! use video_cards_i965; then |
1483 |
- gallium_enable video_cards_intel i915 |
1484 |
- fi |
1485 |
- |
1486 |
- gallium_enable video_cards_r300 r300 |
1487 |
- gallium_enable video_cards_r600 r600 |
1488 |
- gallium_enable video_cards_radeonsi radeonsi |
1489 |
- if ! use video_cards_r300 && \ |
1490 |
- ! use video_cards_r600; then |
1491 |
- gallium_enable video_cards_radeon r300 r600 |
1492 |
- fi |
1493 |
- |
1494 |
- gallium_enable video_cards_freedreno freedreno |
1495 |
- # opencl stuff |
1496 |
- if use opencl; then |
1497 |
- myconf+=" |
1498 |
- $(use_enable opencl) |
1499 |
- --with-clang-libdir="${EPREFIX}/usr/lib" |
1500 |
- " |
1501 |
- fi |
1502 |
- |
1503 |
- gallium_enable video_cards_virgl virgl |
1504 |
- fi |
1505 |
- |
1506 |
- if use vulkan; then |
1507 |
- vulkan_enable video_cards_i965 intel |
1508 |
- vulkan_enable video_cards_radeonsi radeon |
1509 |
- fi |
1510 |
- |
1511 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
1512 |
- if [[ ${ABI} == x86 ]]; then |
1513 |
- myconf+=" $(use_enable pax_kernel glx-read-only-text)" |
1514 |
- fi |
1515 |
- |
1516 |
- # on abi_x86_32 hardened we need to have asm disable |
1517 |
- if [[ ${ABI} == x86* ]] && use pic; then |
1518 |
- myconf+=" --disable-asm" |
1519 |
- fi |
1520 |
- |
1521 |
- if use gallium; then |
1522 |
- myconf+=" $(use_enable osmesa gallium-osmesa)" |
1523 |
- else |
1524 |
- myconf+=" $(use_enable osmesa)" |
1525 |
- fi |
1526 |
- |
1527 |
- # build fails with BSD indent, bug #428112 |
1528 |
- use userland_GNU || export INDENT=cat |
1529 |
- |
1530 |
- ECONF_SOURCE="${S}" \ |
1531 |
- econf \ |
1532 |
- --enable-dri \ |
1533 |
- --enable-glx \ |
1534 |
- --enable-shared-glapi \ |
1535 |
- $(use_enable !bindist texture-float) \ |
1536 |
- $(use_enable d3d9 nine) \ |
1537 |
- $(use_enable debug) \ |
1538 |
- $(use_enable dri3) \ |
1539 |
- $(use_enable egl) \ |
1540 |
- $(use_enable gbm) \ |
1541 |
- $(use_enable gles1) \ |
1542 |
- $(use_enable gles2) \ |
1543 |
- $(use_enable nptl glx-tls) \ |
1544 |
- $(use_enable unwind libunwind) \ |
1545 |
- --enable-valgrind=$(usex valgrind auto no) \ |
1546 |
- --enable-llvm-shared-libs \ |
1547 |
- --with-dri-drivers=${DRI_DRIVERS} \ |
1548 |
- --with-gallium-drivers=${GALLIUM_DRIVERS} \ |
1549 |
- --with-vulkan-drivers=${VULKAN_DRIVERS} \ |
1550 |
- PYTHON2="${PYTHON}" \ |
1551 |
- ${myconf} |
1552 |
-} |
1553 |
- |
1554 |
-multilib_src_install() { |
1555 |
- emake install DESTDIR="${D}" |
1556 |
- |
1557 |
- if use classic || use gallium; then |
1558 |
- ebegin "Moving DRI/Gallium drivers for dynamic switching" |
1559 |
- local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so ) |
1560 |
- keepdir /usr/$(get_libdir)/dri |
1561 |
- dodir /usr/$(get_libdir)/mesa |
1562 |
- for x in ${gallium_drivers[@]}; do |
1563 |
- if [ -f "$(get_libdir)/gallium/${x}" ]; then |
1564 |
- mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \ |
1565 |
- || die "Failed to move ${x}" |
1566 |
- fi |
1567 |
- done |
1568 |
- if use classic; then |
1569 |
- emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install |
1570 |
- fi |
1571 |
- for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do |
1572 |
- if [ -f ${x} -o -L ${x} ]; then |
1573 |
- mv -f "${x}" "${x/dri/mesa}" \ |
1574 |
- || die "Failed to move ${x}" |
1575 |
- fi |
1576 |
- done |
1577 |
- pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed" |
1578 |
- ln -s ../mesa/*.so . || die "Creating symlink failed" |
1579 |
- # remove symlinks to drivers known to eselect |
1580 |
- for x in ${gallium_drivers[@]}; do |
1581 |
- if [ -f ${x} -o -L ${x} ]; then |
1582 |
- rm "${x}" || die "Failed to remove ${x}" |
1583 |
- fi |
1584 |
- done |
1585 |
- popd |
1586 |
- eend $? |
1587 |
- fi |
1588 |
- if use opencl; then |
1589 |
- ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching" |
1590 |
- local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa" |
1591 |
- dodir ${cl_dir}/{lib,include} |
1592 |
- if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then |
1593 |
- mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \ |
1594 |
- "${ED}"${cl_dir} |
1595 |
- fi |
1596 |
- if [ -f "${ED}/usr/include/CL/opencl.h" ]; then |
1597 |
- mv -f "${ED}"/usr/include/CL \ |
1598 |
- "${ED}"${cl_dir}/include |
1599 |
- fi |
1600 |
- eend $? |
1601 |
- fi |
1602 |
- |
1603 |
- if use openmax; then |
1604 |
- echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx" |
1605 |
- doenvd "${T}"/99mesaxdgomx |
1606 |
- keepdir /usr/share/mesa/xdg |
1607 |
- fi |
1608 |
-} |
1609 |
- |
1610 |
-multilib_src_install_all() { |
1611 |
- find "${ED}" -name '*.la' -delete |
1612 |
- einstalldocs |
1613 |
- |
1614 |
- if use !bindist; then |
1615 |
- dodoc docs/patents.txt |
1616 |
- fi |
1617 |
- |
1618 |
- # Install config file for eselect mesa |
1619 |
- insinto /usr/share/mesa |
1620 |
- newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf |
1621 |
-} |
1622 |
- |
1623 |
-multilib_src_test() { |
1624 |
- if use llvm; then |
1625 |
- 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' |
1626 |
- pushd src/gallium/drivers/llvmpipe >/dev/null || die |
1627 |
- emake ${llvm_tests} |
1628 |
- pax-mark m ${llvm_tests} |
1629 |
- popd >/dev/null || die |
1630 |
- fi |
1631 |
- emake check |
1632 |
-} |
1633 |
- |
1634 |
-pkg_postinst() { |
1635 |
- # Switch to the xorg implementation. |
1636 |
- echo |
1637 |
- eselect opengl set --use-old ${OPENGL_DIR} |
1638 |
- |
1639 |
- # Select classic/gallium drivers |
1640 |
- if use classic || use gallium; then |
1641 |
- eselect mesa set --auto |
1642 |
- fi |
1643 |
- |
1644 |
- # Switch to mesa opencl |
1645 |
- if use opencl; then |
1646 |
- eselect opencl set --use-old ${PN} |
1647 |
- fi |
1648 |
- |
1649 |
- # run omxregister-bellagio to make the OpenMAX drivers known system-wide |
1650 |
- if use openmax; then |
1651 |
- ebegin "Registering OpenMAX drivers" |
1652 |
- BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \ |
1653 |
- OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \ |
1654 |
- omxregister-bellagio |
1655 |
- eend $? |
1656 |
- fi |
1657 |
- |
1658 |
- # warn about patent encumbered texture-float |
1659 |
- if use !bindist; then |
1660 |
- elog "USE=\"bindist\" was not set. Potentially patent encumbered code was" |
1661 |
- elog "enabled. Please see /usr/share/doc/${P}/patents.txt.bz2 for an" |
1662 |
- elog "explanation." |
1663 |
- fi |
1664 |
-} |
1665 |
- |
1666 |
-pkg_prerm() { |
1667 |
- if use openmax; then |
1668 |
- rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister |
1669 |
- fi |
1670 |
-} |
1671 |
- |
1672 |
-# $1 - VIDEO_CARDS flag |
1673 |
-# other args - names of DRI drivers to enable |
1674 |
-# TODO: avoid code duplication for a more elegant implementation |
1675 |
-driver_enable() { |
1676 |
- case $# in |
1677 |
- # for enabling unconditionally |
1678 |
- 1) |
1679 |
- DRI_DRIVERS+=",$1" |
1680 |
- ;; |
1681 |
- *) |
1682 |
- if use $1; then |
1683 |
- shift |
1684 |
- for i in $@; do |
1685 |
- DRI_DRIVERS+=",${i}" |
1686 |
- done |
1687 |
- fi |
1688 |
- ;; |
1689 |
- esac |
1690 |
-} |
1691 |
- |
1692 |
-gallium_enable() { |
1693 |
- case $# in |
1694 |
- # for enabling unconditionally |
1695 |
- 1) |
1696 |
- GALLIUM_DRIVERS+=",$1" |
1697 |
- ;; |
1698 |
- *) |
1699 |
- if use $1; then |
1700 |
- shift |
1701 |
- for i in $@; do |
1702 |
- GALLIUM_DRIVERS+=",${i}" |
1703 |
- done |
1704 |
- fi |
1705 |
- ;; |
1706 |
- esac |
1707 |
-} |
1708 |
- |
1709 |
-vulkan_enable() { |
1710 |
- case $# in |
1711 |
- # for enabling unconditionally |
1712 |
- 1) |
1713 |
- VULKAN_DRIVERS+=",$1" |
1714 |
- ;; |
1715 |
- *) |
1716 |
- if use $1; then |
1717 |
- shift |
1718 |
- for i in $@; do |
1719 |
- VULKAN_DRIVERS+=",${i}" |
1720 |
- done |
1721 |
- fi |
1722 |
- ;; |
1723 |
- esac |
1724 |
-} |
1725 |
|
1726 |
diff --git a/media-libs/mesa/mesa-18.0.0.ebuild b/media-libs/mesa/mesa-18.0.0.ebuild |
1727 |
deleted file mode 100644 |
1728 |
index 6cdc82a5cc3..00000000000 |
1729 |
--- a/media-libs/mesa/mesa-18.0.0.ebuild |
1730 |
+++ /dev/null |
1731 |
@@ -1,583 +0,0 @@ |
1732 |
-# Copyright 1999-2018 Gentoo Foundation |
1733 |
-# Distributed under the terms of the GNU General Public License v2 |
1734 |
- |
1735 |
-EAPI=6 |
1736 |
- |
1737 |
-EGIT_REPO_URI="https://anongit.freedesktop.org/git/mesa/mesa.git" |
1738 |
- |
1739 |
-if [[ ${PV} = 9999 ]]; then |
1740 |
- GIT_ECLASS="git-r3" |
1741 |
- EXPERIMENTAL="true" |
1742 |
-fi |
1743 |
- |
1744 |
-PYTHON_COMPAT=( python2_7 ) |
1745 |
- |
1746 |
-inherit autotools llvm multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS} |
1747 |
- |
1748 |
-OPENGL_DIR="xorg-x11" |
1749 |
- |
1750 |
-MY_P="${P/_/-}" |
1751 |
- |
1752 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
1753 |
-HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" |
1754 |
- |
1755 |
-if [[ $PV == 9999 ]]; then |
1756 |
- SRC_URI="" |
1757 |
-else |
1758 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
1759 |
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
1760 |
-fi |
1761 |
- |
1762 |
-LICENSE="MIT" |
1763 |
-SLOT="0" |
1764 |
-RESTRICT="!bindist? ( bindist )" |
1765 |
- |
1766 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
1767 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
1768 |
-for card in ${VIDEO_CARDS}; do |
1769 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
1770 |
-done |
1771 |
- |
1772 |
-IUSE="${IUSE_VIDEO_CARDS} |
1773 |
- bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 unwind |
1774 |
- +llvm +nptl opencl osmesa pax_kernel openmax pic selinux vaapi valgrind |
1775 |
- vdpau vulkan wayland xvmc xa" |
1776 |
- |
1777 |
-REQUIRED_USE=" |
1778 |
- d3d9? ( dri3 gallium ) |
1779 |
- llvm? ( gallium ) |
1780 |
- opencl? ( gallium llvm ) |
1781 |
- openmax? ( gallium ) |
1782 |
- gles1? ( egl ) |
1783 |
- gles2? ( egl ) |
1784 |
- vaapi? ( gallium ) |
1785 |
- vdpau? ( gallium ) |
1786 |
- vulkan? ( || ( video_cards_i965 video_cards_radeonsi ) |
1787 |
- video_cards_radeonsi? ( llvm ) ) |
1788 |
- wayland? ( egl gbm ) |
1789 |
- xa? ( gallium ) |
1790 |
- video_cards_freedreno? ( gallium ) |
1791 |
- video_cards_intel? ( classic ) |
1792 |
- video_cards_i915? ( || ( classic gallium ) ) |
1793 |
- video_cards_i965? ( classic ) |
1794 |
- video_cards_imx? ( gallium video_cards_vivante ) |
1795 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
1796 |
- video_cards_radeon? ( || ( classic gallium ) |
1797 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
1798 |
- video_cards_r100? ( classic ) |
1799 |
- video_cards_r200? ( classic ) |
1800 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
1801 |
- video_cards_r600? ( gallium ) |
1802 |
- video_cards_radeonsi? ( gallium llvm ) |
1803 |
- video_cards_vc4? ( gallium ) |
1804 |
- video_cards_virgl? ( gallium ) |
1805 |
- video_cards_vivante? ( gallium gbm ) |
1806 |
- video_cards_vmware? ( gallium ) |
1807 |
-" |
1808 |
- |
1809 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.89" |
1810 |
-# keep correct libdrm and dri2proto dep |
1811 |
-# keep blocks in rdepend for binpkg |
1812 |
-RDEPEND=" |
1813 |
- !<x11-base/xorg-server-1.7 |
1814 |
- !<=x11-proto/xf86driproto-2.0.3 |
1815 |
- classic? ( app-eselect/eselect-mesa ) |
1816 |
- gallium? ( app-eselect/eselect-mesa ) |
1817 |
- >=app-eselect/eselect-opengl-1.3.0 |
1818 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
1819 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
1820 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
1821 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
1822 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
1823 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
1824 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
1825 |
- >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}] |
1826 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
1827 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
1828 |
- llvm? ( |
1829 |
- video_cards_radeonsi? ( |
1830 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1831 |
- ) |
1832 |
- video_cards_r600? ( |
1833 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1834 |
- ) |
1835 |
- video_cards_radeon? ( |
1836 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1837 |
- ) |
1838 |
- ) |
1839 |
- opencl? ( |
1840 |
- app-eselect/eselect-opencl |
1841 |
- dev-libs/libclc |
1842 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1843 |
- ) |
1844 |
- openmax? ( |
1845 |
- >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] |
1846 |
- x11-misc/xdg-utils |
1847 |
- ) |
1848 |
- vaapi? ( |
1849 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
1850 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
1851 |
- ) |
1852 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
1853 |
- wayland? ( |
1854 |
- >=dev-libs/wayland-1.11.0:=[${MULTILIB_USEDEP}] |
1855 |
- >=dev-libs/wayland-protocols-1.8 |
1856 |
- ) |
1857 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
1858 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
1859 |
- |
1860 |
- video_cards_intel? ( |
1861 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
1862 |
- ) |
1863 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
1864 |
-" |
1865 |
-for card in ${RADEON_CARDS}; do |
1866 |
- RDEPEND="${RDEPEND} |
1867 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
1868 |
- " |
1869 |
-done |
1870 |
-RDEPEND="${RDEPEND} |
1871 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
1872 |
-" |
1873 |
- |
1874 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
1875 |
-# we need to *really* make sure we're not pulling one than more slot |
1876 |
-# simultaneously. |
1877 |
-# |
1878 |
-# How to use it: |
1879 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
1880 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
1881 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
1882 |
-LLVM_DEPSTR=" |
1883 |
- || ( |
1884 |
- sys-devel/llvm:6[${MULTILIB_USEDEP}] |
1885 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
1886 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
1887 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
1888 |
- ) |
1889 |
- sys-devel/llvm:=[${MULTILIB_USEDEP}] |
1890 |
-" |
1891 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
1892 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
1893 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
1894 |
-RDEPEND="${RDEPEND} |
1895 |
- llvm? ( |
1896 |
- opencl? ( |
1897 |
- video_cards_r600? ( |
1898 |
- ${CLANG_DEPSTR_AMDGPU} |
1899 |
- ) |
1900 |
- !video_cards_r600? ( |
1901 |
- video_cards_radeonsi? ( |
1902 |
- ${CLANG_DEPSTR_AMDGPU} |
1903 |
- ) |
1904 |
- ) |
1905 |
- !video_cards_r600? ( |
1906 |
- !video_cards_radeonsi? ( |
1907 |
- video_cards_radeon? ( |
1908 |
- ${CLANG_DEPSTR_AMDGPU} |
1909 |
- ) |
1910 |
- ) |
1911 |
- ) |
1912 |
- !video_cards_r600? ( |
1913 |
- !video_cards_radeon? ( |
1914 |
- !video_cards_radeonsi? ( |
1915 |
- ${CLANG_DEPSTR} |
1916 |
- ) |
1917 |
- ) |
1918 |
- ) |
1919 |
- ) |
1920 |
- !opencl? ( |
1921 |
- video_cards_r600? ( |
1922 |
- ${LLVM_DEPSTR_AMDGPU} |
1923 |
- ) |
1924 |
- !video_cards_r600? ( |
1925 |
- video_cards_radeonsi? ( |
1926 |
- ${LLVM_DEPSTR_AMDGPU} |
1927 |
- ) |
1928 |
- ) |
1929 |
- !video_cards_r600? ( |
1930 |
- !video_cards_radeonsi? ( |
1931 |
- video_cards_radeon? ( |
1932 |
- ${LLVM_DEPSTR_AMDGPU} |
1933 |
- ) |
1934 |
- ) |
1935 |
- ) |
1936 |
- !video_cards_r600? ( |
1937 |
- !video_cards_radeon? ( |
1938 |
- !video_cards_radeonsi? ( |
1939 |
- ${LLVM_DEPSTR} |
1940 |
- ) |
1941 |
- ) |
1942 |
- ) |
1943 |
- ) |
1944 |
- ) |
1945 |
-" |
1946 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
1947 |
- |
1948 |
-DEPEND="${RDEPEND} |
1949 |
- ${PYTHON_DEPS} |
1950 |
- opencl? ( |
1951 |
- >=sys-devel/gcc-4.6 |
1952 |
- ) |
1953 |
- sys-devel/gettext |
1954 |
- virtual/pkgconfig |
1955 |
- valgrind? ( dev-util/valgrind ) |
1956 |
- >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}] |
1957 |
- dri3? ( |
1958 |
- >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}] |
1959 |
- >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}] |
1960 |
- ) |
1961 |
- >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}] |
1962 |
- >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}] |
1963 |
- >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}] |
1964 |
- >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}] |
1965 |
- vulkan? ( |
1966 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
1967 |
- ) |
1968 |
-" |
1969 |
-[[ ${PV} == 9999 ]] && DEPEND+=" |
1970 |
- sys-devel/bison |
1971 |
- sys-devel/flex |
1972 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
1973 |
-" |
1974 |
- |
1975 |
-S="${WORKDIR}/${MY_P}" |
1976 |
-EGIT_CHECKOUT_DIR=${S} |
1977 |
- |
1978 |
-QA_WX_LOAD=" |
1979 |
-x86? ( |
1980 |
- !pic? ( |
1981 |
- usr/lib*/libglapi.so.0.0.0 |
1982 |
- usr/lib*/libGLESv1_CM.so.1.1.0 |
1983 |
- usr/lib*/libGLESv2.so.2.0.0 |
1984 |
- usr/lib*/libGL.so.1.2.0 |
1985 |
- usr/lib*/libOSMesa.so.8.0.0 |
1986 |
- ) |
1987 |
-)" |
1988 |
- |
1989 |
-llvm_check_deps() { |
1990 |
- local flags=${MULTILIB_USEDEP} |
1991 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
1992 |
- then |
1993 |
- flags+=",llvm_targets_AMDGPU(-)" |
1994 |
- fi |
1995 |
- |
1996 |
- if use opencl; then |
1997 |
- has_version "sys-devel/clang[${flags}]" || return 1 |
1998 |
- fi |
1999 |
- has_version "sys-devel/llvm[${flags}]" |
2000 |
-} |
2001 |
- |
2002 |
-pkg_setup() { |
2003 |
- # warning message for bug 459306 |
2004 |
- if use llvm && has_version sys-devel/llvm[!debug=]; then |
2005 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
2006 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
2007 |
- fi |
2008 |
- |
2009 |
- if use llvm; then |
2010 |
- llvm_pkg_setup |
2011 |
- fi |
2012 |
- python-any-r1_pkg_setup |
2013 |
-} |
2014 |
- |
2015 |
-src_prepare() { |
2016 |
- [[ ${PV} == 9999 ]] && eautoreconf |
2017 |
- eapply_user |
2018 |
-} |
2019 |
- |
2020 |
-multilib_src_configure() { |
2021 |
- local myconf |
2022 |
- |
2023 |
- if use classic; then |
2024 |
- # Configurable DRI drivers |
2025 |
- driver_enable swrast |
2026 |
- |
2027 |
- # Intel code |
2028 |
- driver_enable video_cards_i915 i915 |
2029 |
- driver_enable video_cards_i965 i965 |
2030 |
- if ! use video_cards_i915 && \ |
2031 |
- ! use video_cards_i965; then |
2032 |
- driver_enable video_cards_intel i915 i965 |
2033 |
- fi |
2034 |
- |
2035 |
- # Nouveau code |
2036 |
- driver_enable video_cards_nouveau nouveau |
2037 |
- |
2038 |
- # ATI code |
2039 |
- driver_enable video_cards_r100 radeon |
2040 |
- driver_enable video_cards_r200 r200 |
2041 |
- if ! use video_cards_r100 && \ |
2042 |
- ! use video_cards_r200; then |
2043 |
- driver_enable video_cards_radeon radeon r200 |
2044 |
- fi |
2045 |
- fi |
2046 |
- |
2047 |
- if use egl; then |
2048 |
- myconf+=" --with-platforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm")" |
2049 |
- fi |
2050 |
- |
2051 |
- if use gallium; then |
2052 |
- myconf+=" |
2053 |
- $(use_enable d3d9 nine) |
2054 |
- $(use_enable llvm) |
2055 |
- $(use_enable openmax omx-bellagio) |
2056 |
- $(use_enable vaapi va) |
2057 |
- $(use_enable vdpau) |
2058 |
- $(use_enable xa) |
2059 |
- $(use_enable xvmc) |
2060 |
- " |
2061 |
- use vaapi && myconf+=" --with-va-libdir=/usr/$(get_libdir)/va/drivers" |
2062 |
- |
2063 |
- gallium_enable swrast |
2064 |
- gallium_enable video_cards_vc4 vc4 |
2065 |
- gallium_enable video_cards_vivante etnaviv |
2066 |
- gallium_enable video_cards_vmware svga |
2067 |
- gallium_enable video_cards_nouveau nouveau |
2068 |
- gallium_enable video_cards_i915 i915 |
2069 |
- gallium_enable video_cards_imx imx |
2070 |
- if ! use video_cards_i915 && \ |
2071 |
- ! use video_cards_i965; then |
2072 |
- gallium_enable video_cards_intel i915 |
2073 |
- fi |
2074 |
- |
2075 |
- gallium_enable video_cards_r300 r300 |
2076 |
- gallium_enable video_cards_r600 r600 |
2077 |
- gallium_enable video_cards_radeonsi radeonsi |
2078 |
- if ! use video_cards_r300 && \ |
2079 |
- ! use video_cards_r600; then |
2080 |
- gallium_enable video_cards_radeon r300 r600 |
2081 |
- fi |
2082 |
- |
2083 |
- gallium_enable video_cards_freedreno freedreno |
2084 |
- # opencl stuff |
2085 |
- if use opencl; then |
2086 |
- myconf+=" |
2087 |
- $(use_enable opencl) |
2088 |
- --with-clang-libdir="${EPREFIX}/usr/lib" |
2089 |
- " |
2090 |
- fi |
2091 |
- |
2092 |
- gallium_enable video_cards_virgl virgl |
2093 |
- fi |
2094 |
- |
2095 |
- if use vulkan; then |
2096 |
- vulkan_enable video_cards_i965 intel |
2097 |
- vulkan_enable video_cards_radeonsi radeon |
2098 |
- fi |
2099 |
- |
2100 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
2101 |
- if [[ ${ABI} == x86 ]]; then |
2102 |
- myconf+=" $(use_enable pax_kernel glx-read-only-text)" |
2103 |
- fi |
2104 |
- |
2105 |
- # on abi_x86_32 hardened we need to have asm disable |
2106 |
- if [[ ${ABI} == x86* ]] && use pic; then |
2107 |
- myconf+=" --disable-asm" |
2108 |
- fi |
2109 |
- |
2110 |
- if use gallium; then |
2111 |
- myconf+=" $(use_enable osmesa gallium-osmesa)" |
2112 |
- else |
2113 |
- myconf+=" $(use_enable osmesa)" |
2114 |
- fi |
2115 |
- |
2116 |
- # build fails with BSD indent, bug #428112 |
2117 |
- use userland_GNU || export INDENT=cat |
2118 |
- |
2119 |
- ECONF_SOURCE="${S}" \ |
2120 |
- econf \ |
2121 |
- --enable-dri \ |
2122 |
- --enable-glx \ |
2123 |
- --enable-shared-glapi \ |
2124 |
- $(use_enable !bindist texture-float) \ |
2125 |
- $(use_enable d3d9 nine) \ |
2126 |
- $(use_enable debug) \ |
2127 |
- $(use_enable dri3) \ |
2128 |
- $(use_enable egl) \ |
2129 |
- $(use_enable gbm) \ |
2130 |
- $(use_enable gles1) \ |
2131 |
- $(use_enable gles2) \ |
2132 |
- $(use_enable nptl glx-tls) \ |
2133 |
- $(use_enable unwind libunwind) \ |
2134 |
- --enable-valgrind=$(usex valgrind auto no) \ |
2135 |
- --enable-llvm-shared-libs \ |
2136 |
- --disable-opencl-icd \ |
2137 |
- --with-dri-drivers=${DRI_DRIVERS} \ |
2138 |
- --with-gallium-drivers=${GALLIUM_DRIVERS} \ |
2139 |
- --with-vulkan-drivers=${VULKAN_DRIVERS} \ |
2140 |
- PYTHON2="${PYTHON}" \ |
2141 |
- ${myconf} |
2142 |
-} |
2143 |
- |
2144 |
-multilib_src_install() { |
2145 |
- emake install DESTDIR="${D}" |
2146 |
- |
2147 |
- if use classic || use gallium; then |
2148 |
- ebegin "Moving DRI/Gallium drivers for dynamic switching" |
2149 |
- local gallium_drivers=( i915_dri.so i965_dri.so r300_dri.so r600_dri.so swrast_dri.so ) |
2150 |
- keepdir /usr/$(get_libdir)/dri |
2151 |
- dodir /usr/$(get_libdir)/mesa |
2152 |
- for x in ${gallium_drivers[@]}; do |
2153 |
- if [ -f "$(get_libdir)/gallium/${x}" ]; then |
2154 |
- mv -f "${ED}/usr/$(get_libdir)/dri/${x}" "${ED}/usr/$(get_libdir)/dri/${x/_dri.so/g_dri.so}" \ |
2155 |
- || die "Failed to move ${x}" |
2156 |
- fi |
2157 |
- done |
2158 |
- if use classic; then |
2159 |
- emake -C "${BUILD_DIR}/src/mesa/drivers/dri" DESTDIR="${D}" install |
2160 |
- fi |
2161 |
- for x in "${ED}"/usr/$(get_libdir)/dri/*.so; do |
2162 |
- if [ -f ${x} -o -L ${x} ]; then |
2163 |
- mv -f "${x}" "${x/dri/mesa}" \ |
2164 |
- || die "Failed to move ${x}" |
2165 |
- fi |
2166 |
- done |
2167 |
- pushd "${ED}"/usr/$(get_libdir)/dri || die "pushd failed" |
2168 |
- ln -s ../mesa/*.so . || die "Creating symlink failed" |
2169 |
- # remove symlinks to drivers known to eselect |
2170 |
- for x in ${gallium_drivers[@]}; do |
2171 |
- if [ -f ${x} -o -L ${x} ]; then |
2172 |
- rm "${x}" || die "Failed to remove ${x}" |
2173 |
- fi |
2174 |
- done |
2175 |
- popd |
2176 |
- eend $? |
2177 |
- fi |
2178 |
- if use opencl; then |
2179 |
- ebegin "Moving Gallium/Clover OpenCL implementation for dynamic switching" |
2180 |
- local cl_dir="/usr/$(get_libdir)/OpenCL/vendors/mesa" |
2181 |
- dodir ${cl_dir}/{lib,include} |
2182 |
- if [ -f "${ED}/usr/$(get_libdir)/libOpenCL.so" ]; then |
2183 |
- mv -f "${ED}"/usr/$(get_libdir)/libOpenCL.so* \ |
2184 |
- "${ED}"${cl_dir} |
2185 |
- fi |
2186 |
- if [ -f "${ED}/usr/include/CL/opencl.h" ]; then |
2187 |
- mv -f "${ED}"/usr/include/CL \ |
2188 |
- "${ED}"${cl_dir}/include |
2189 |
- fi |
2190 |
- eend $? |
2191 |
- fi |
2192 |
- |
2193 |
- if use openmax; then |
2194 |
- echo "XDG_DATA_DIRS=\"${EPREFIX}/usr/share/mesa/xdg\"" > "${T}/99mesaxdgomx" |
2195 |
- doenvd "${T}"/99mesaxdgomx |
2196 |
- keepdir /usr/share/mesa/xdg |
2197 |
- fi |
2198 |
-} |
2199 |
- |
2200 |
-multilib_src_install_all() { |
2201 |
- find "${ED}" -name '*.la' -delete |
2202 |
- einstalldocs |
2203 |
- |
2204 |
- if use !bindist; then |
2205 |
- dodoc docs/patents.txt |
2206 |
- fi |
2207 |
- |
2208 |
- # Install config file for eselect mesa |
2209 |
- insinto /usr/share/mesa |
2210 |
- newins "${FILESDIR}/eselect-mesa.conf.9.2" eselect-mesa.conf |
2211 |
-} |
2212 |
- |
2213 |
-multilib_src_test() { |
2214 |
- if use llvm; then |
2215 |
- 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' |
2216 |
- pushd src/gallium/drivers/llvmpipe >/dev/null || die |
2217 |
- emake ${llvm_tests} |
2218 |
- pax-mark m ${llvm_tests} |
2219 |
- popd >/dev/null || die |
2220 |
- fi |
2221 |
- emake check |
2222 |
-} |
2223 |
- |
2224 |
-pkg_postinst() { |
2225 |
- # Switch to the xorg implementation. |
2226 |
- echo |
2227 |
- eselect opengl set --use-old ${OPENGL_DIR} |
2228 |
- |
2229 |
- # Select classic/gallium drivers |
2230 |
- if use classic || use gallium; then |
2231 |
- eselect mesa set --auto |
2232 |
- fi |
2233 |
- |
2234 |
- # Switch to mesa opencl |
2235 |
- if use opencl; then |
2236 |
- eselect opencl set --use-old ${PN} |
2237 |
- fi |
2238 |
- |
2239 |
- # run omxregister-bellagio to make the OpenMAX drivers known system-wide |
2240 |
- if use openmax; then |
2241 |
- ebegin "Registering OpenMAX drivers" |
2242 |
- BELLAGIO_SEARCH_PATH="${EPREFIX}/usr/$(get_libdir)/libomxil-bellagio0" \ |
2243 |
- OMX_BELLAGIO_REGISTRY=${EPREFIX}/usr/share/mesa/xdg/.omxregister \ |
2244 |
- omxregister-bellagio |
2245 |
- eend $? |
2246 |
- fi |
2247 |
- |
2248 |
- # warn about patent encumbered texture-float |
2249 |
- if use !bindist; then |
2250 |
- elog "USE=\"bindist\" was not set. Potentially patent encumbered code was" |
2251 |
- elog "enabled. Please see /usr/share/doc/${P}/patents.txt.bz2 for an" |
2252 |
- elog "explanation." |
2253 |
- fi |
2254 |
-} |
2255 |
- |
2256 |
-pkg_prerm() { |
2257 |
- if use openmax; then |
2258 |
- rm "${EPREFIX}"/usr/share/mesa/xdg/.omxregister |
2259 |
- fi |
2260 |
-} |
2261 |
- |
2262 |
-# $1 - VIDEO_CARDS flag |
2263 |
-# other args - names of DRI drivers to enable |
2264 |
-# TODO: avoid code duplication for a more elegant implementation |
2265 |
-driver_enable() { |
2266 |
- case $# in |
2267 |
- # for enabling unconditionally |
2268 |
- 1) |
2269 |
- DRI_DRIVERS+=",$1" |
2270 |
- ;; |
2271 |
- *) |
2272 |
- if use $1; then |
2273 |
- shift |
2274 |
- for i in $@; do |
2275 |
- DRI_DRIVERS+=",${i}" |
2276 |
- done |
2277 |
- fi |
2278 |
- ;; |
2279 |
- esac |
2280 |
-} |
2281 |
- |
2282 |
-gallium_enable() { |
2283 |
- case $# in |
2284 |
- # for enabling unconditionally |
2285 |
- 1) |
2286 |
- GALLIUM_DRIVERS+=",$1" |
2287 |
- ;; |
2288 |
- *) |
2289 |
- if use $1; then |
2290 |
- shift |
2291 |
- for i in $@; do |
2292 |
- GALLIUM_DRIVERS+=",${i}" |
2293 |
- done |
2294 |
- fi |
2295 |
- ;; |
2296 |
- esac |
2297 |
-} |
2298 |
- |
2299 |
-vulkan_enable() { |
2300 |
- case $# in |
2301 |
- # for enabling unconditionally |
2302 |
- 1) |
2303 |
- VULKAN_DRIVERS+=",$1" |
2304 |
- ;; |
2305 |
- *) |
2306 |
- if use $1; then |
2307 |
- shift |
2308 |
- for i in $@; do |
2309 |
- VULKAN_DRIVERS+=",${i}" |
2310 |
- done |
2311 |
- fi |
2312 |
- ;; |
2313 |
- esac |
2314 |
-} |
2315 |
|
2316 |
diff --git a/media-libs/mesa/mesa-18.0.1.ebuild b/media-libs/mesa/mesa-18.0.1.ebuild |
2317 |
deleted file mode 100644 |
2318 |
index 6cdc82a5cc3..00000000000 |
2319 |
--- a/media-libs/mesa/mesa-18.0.1.ebuild |
2320 |
+++ /dev/null |
2321 |
@@ -1,583 +0,0 @@ |
2322 |
-# Copyright 1999-2018 Gentoo Foundation |
2323 |
-# Distributed under the terms of the GNU General Public License v2 |
2324 |
- |
2325 |
-EAPI=6 |
2326 |
- |
2327 |
-EGIT_REPO_URI="https://anongit.freedesktop.org/git/mesa/mesa.git" |
2328 |
- |
2329 |
-if [[ ${PV} = 9999 ]]; then |
2330 |
- GIT_ECLASS="git-r3" |
2331 |
- EXPERIMENTAL="true" |
2332 |
-fi |
2333 |
- |
2334 |
-PYTHON_COMPAT=( python2_7 ) |
2335 |
- |
2336 |
-inherit autotools llvm multilib-minimal python-any-r1 pax-utils ${GIT_ECLASS} |
2337 |
- |
2338 |
-OPENGL_DIR="xorg-x11" |
2339 |
- |
2340 |
-MY_P="${P/_/-}" |
2341 |
- |
2342 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
2343 |
-HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" |
2344 |
- |
2345 |
-if [[ $PV == 9999 ]]; then |
2346 |
- SRC_URI="" |
2347 |
-else |
2348 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
2349 |
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
2350 |
-fi |
2351 |
- |
2352 |
-LICENSE="MIT" |
2353 |
-SLOT="0" |
2354 |
-RESTRICT="!bindist? ( bindist )" |
2355 |
- |
2356 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
2357 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
2358 |
-for card in ${VIDEO_CARDS}; do |
2359 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
2360 |
-done |
2361 |
- |
2362 |
-IUSE="${IUSE_VIDEO_CARDS} |
2363 |
- bindist +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 unwind |
2364 |
- +llvm +nptl opencl osmesa pax_kernel openmax pic selinux vaapi valgrind |
2365 |
- vdpau vulkan wayland xvmc xa" |
2366 |
- |
2367 |
-REQUIRED_USE=" |
2368 |
- d3d9? ( dri3 gallium ) |
2369 |
- llvm? ( gallium ) |
2370 |
- opencl? ( gallium llvm ) |
2371 |
- openmax? ( gallium ) |
2372 |
- gles1? ( egl ) |
2373 |
- gles2? ( egl ) |
2374 |
- vaapi? ( gallium ) |
2375 |
- vdpau? ( gallium ) |
2376 |
- vulkan? ( || ( video_cards_i965 video_cards_radeonsi ) |
2377 |
- video_cards_radeonsi? ( llvm ) ) |
2378 |
- wayland? ( egl gbm ) |
2379 |
- xa? ( gallium ) |
2380 |
- video_cards_freedreno? ( gallium ) |
2381 |
- video_cards_intel? ( classic ) |
2382 |
- video_cards_i915? ( || ( classic gallium ) ) |
2383 |
- video_cards_i965? ( classic ) |
2384 |
- video_cards_imx? ( gallium video_cards_vivante ) |
2385 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
2386 |
- video_cards_radeon? ( || ( classic gallium ) |
2387 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
2388 |
- video_cards_r100? ( classic ) |
2389 |
- video_cards_r200? ( classic ) |
2390 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
2391 |
- video_cards_r600? ( gallium ) |
2392 |
- video_cards_radeonsi? ( gallium llvm ) |
2393 |
- video_cards_vc4? ( gallium ) |
2394 |
- video_cards_virgl? ( gallium ) |
2395 |
- video_cards_vivante? ( gallium gbm ) |
2396 |
- video_cards_vmware? ( gallium ) |
2397 |
-" |
2398 |
- |
2399 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.89" |
2400 |
-# keep correct libdrm and dri2proto dep |
2401 |
-# keep blocks in rdepend for binpkg |
2402 |
-RDEPEND=" |
2403 |
- !<x11-base/xorg-server-1.7 |
2404 |
- !<=x11-proto/xf86driproto-2.0.3 |
2405 |
- classic? ( app-eselect/eselect-mesa ) |
2406 |
- gallium? ( app-eselect/eselect-mesa ) |
2407 |
- >=app-eselect/eselect-opengl-1.3.0 |
2408 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
2409 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
2410 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
2411 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
2412 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
2413 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
2414 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
2415 |
- >=x11-libs/libxcb-1.9.3:=[${MULTILIB_USEDEP}] |
2416 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
2417 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
2418 |
- llvm? ( |
2419 |
- video_cards_radeonsi? ( |
2420 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
2421 |
- ) |
2422 |
- video_cards_r600? ( |
2423 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
2424 |
- ) |
2425 |
- video_cards_radeon? ( |
2426 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
2427 |
- ) |
2428 |
- ) |
2429 |
- opencl? ( |
2430 |
- app-eselect/eselect-opencl |
2431 |
- dev-libs/libclc |
2432 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
2433 |
- ) |
2434 |
- openmax? ( |
2435 |
- >=media-libs/libomxil-bellagio-0.9.3:=[${MULTILIB_USEDEP}] |
2436 |
- x11-misc/xdg-utils |
2437 |
- ) |
2438 |
- vaapi? ( |
2439 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
2440 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
2441 |
- ) |
2442 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
2443 |
- wayland? ( |
2444 |
- >=dev-libs/wayland-1.11.0:=[${MULTILIB_USEDEP}] |
2445 |
- >=dev-libs/wayland-protocols-1.8 |
2446 |
- ) |
2447 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
2448 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
2449 |
- |
2450 |
- video_cards_intel? ( |
2451 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
2452 |
- ) |
2453 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
2454 |
-" |
2455 |
-for card in ${RADEON_CARDS}; do |
2456 |
- RDEPEND="${RDEPEND} |
2457 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
2458 |
- " |
2459 |
-done |
2460 |
-RDEPEND="${RDEPEND} |
2461 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
2462 |
-" |
2463 |
- |
2464 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
2465 |
-# we need to *really* make sure we're not pulling one than more slot |
2466 |
-# simultaneously. |
2467 |
-# |
2468 |
-# How to use it: |
2469 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
2470 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
2471 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
2472 |
-LLVM_DEPSTR=" |
2473 |
- || ( |
2474 |
- sys-devel/llvm:6[${MULTILIB_USEDEP}] |
2475 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
2476 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
2477 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
2478 |
- ) |
2479 |
- sys-devel/llvm:=[${MULTILIB_USEDEP}] |
2480 |
-" |
2481 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
2482 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
2483 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
2484 |
-RDEPEND="${RDEPEND} |
2485 |
- llvm? ( |
2486 |
- opencl? ( |
2487 |
- video_cards_r600? ( |
2488 |
- ${CLANG_DEPSTR_AMDGPU} |
2489 |
- ) |
2490 |
- !video_cards_r600? ( |
2491 |
- video_cards_radeonsi? ( |
2492 |
- ${CLANG_DEPSTR_AMDGPU} |
2493 |
- ) |
2494 |
- ) |
2495 |
- !video_cards_r600? ( |
2496 |
- !video_cards_radeonsi? ( |
2497 |
- video_cards_radeon? ( |
2498 |
- ${CLANG_DEPSTR_AMDGPU} |
2499 |
- ) |
2500 |
- ) |
2501 |
- ) |
2502 |
- !video_cards_r600? ( |
2503 |
- !video_cards_radeon? ( |
2504 |
- !video_cards_radeonsi? ( |
2505 |
- ${CLANG_DEPSTR} |
2506 |
- ) |
2507 |
- ) |
2508 |
- ) |
2509 |
- ) |
2510 |
- !opencl? ( |
2511 |
- video_cards_r600? ( |
2512 |
- ${LLVM_DEPSTR_AMDGPU} |
2513 |
- ) |
2514 |
- !video_cards_r600? ( |
2515 |
- video_cards_radeonsi? ( |
2516 |
- ${LLVM_DEPSTR_AMDGPU} |
2517 |
- ) |
2518 |
- ) |
2519 |
- !video_cards_r600? ( |
2520 |
- !video_cards_radeonsi? ( |
2521 |
- video_cards_radeon? ( |
2522 |
- ${LLVM_DEPSTR_AMDGPU} |
2523 |
- ) |
2524 |
- ) |
2525 |
- ) |
2526 |
- !video_cards_r600? ( |
2527 |
- !video_cards_radeon? ( |
2528 |
- !video_cards_radeonsi? ( |
2529 |
- ${LLVM_DEPSTR} |
2530 |
- ) |
2531 |
- ) |
2532 |
- ) |
2533 |
- ) |
2534 |
- ) |
2535 |
-" |
2536 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
2537 |
- |
2538 |
-DEPEND="${RDEPEND} |
2539 |
- ${PYTHON_DEPS} |
2540 |
- opencl? ( |
2541 |
- >=sys-devel/gcc-4.6 |
2542 |
- ) |
2543 |
- sys-devel/gettext |
2544 |
- virtual/pkgconfig |
2545 |
- valgrind? ( dev-util/valgrind ) |
2546 |
- >=x11-proto/dri2proto-2.8-r1:=[${MULTILIB_USEDEP}] |
2547 |
- dri3? ( |
2548 |
- >=x11-proto/dri3proto-1.0:=[${MULTILIB_USEDEP}] |
2549 |
- >=x11-proto/presentproto-1.0:=[${MULTILIB_USEDEP}] |
2550 |
- ) |
2551 |
- >=x11-proto/glproto-1.4.17-r1:=[${MULTILIB_USEDEP}] |
2552 |
- >=x11-proto/xextproto-7.2.1-r1:=[${MULTILIB_USEDEP}] |
2553 |
- >=x11-proto/xf86driproto-2.1.1-r1:=[${MULTILIB_USEDEP}] |
2554 |
- >=x11-proto/xf86vidmodeproto-2.3.1-r1:=[${MULTILIB_USEDEP}] |
2555 |
- vulkan? ( |
2556 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
2557 |
- ) |
2558 |
-" |
2559 |
-[[ ${PV} == 9999 ]] && DEPEND+=" |
2560 |
- sys-devel/bison |
2561 |
- sys-devel/flex |
2562 |
- $(python_gen_any_dep ">=dev-python/mako-0.7.3[\${PYTHON_USEDEP}]") |
2563 |
-" |
2564 |
- |
2565 |
-S="${WORKDIR}/${MY_P}" |
2566 |
-EGIT_CHECKOUT_DIR=${S} |
2567 |
- |
2568 |
-QA_WX_LOAD=" |
2569 |
-x86? ( |
2570 |
- !pic? ( |
2571 |
- usr/lib*/libglapi.so.0.0.0 |
2572 |
- usr/lib*/libGLESv1_CM.so.1.1.0 |
2573 |
- usr/lib*/libGLESv2.so.2.0.0 |
2574 |
- usr/lib*/libGL.so.1.2.0 |
2575 |
- usr/lib*/libOSMesa.so.8.0.0 |
2576 |
- ) |
2577 |
-)" |
2578 |
- |
2579 |
-llvm_check_deps() { |
2580 |
- local flags=${MULTILIB_USEDEP} |
2581 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
2582 |
- then |
2583 |
- flags+=",llvm_targets_AMDGPU(-)" |
2584 |
- fi |
2585 |
- |
2586 |
- if use opencl; then |
|