1 |
commit: 9779f087f8fa248b09578a124e083c5f9a1d3166 |
2 |
Author: Matt Turner <mattst88 <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Jan 20 05:39:13 2019 +0000 |
4 |
Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Jan 20 05:43:07 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9779f087 |
7 |
|
8 |
media-libs/mesa: Drop old versions |
9 |
|
10 |
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org> |
11 |
|
12 |
media-libs/mesa/Manifest | 3 - |
13 |
media-libs/mesa/mesa-18.2.7.ebuild | 515 ------------------------------------ |
14 |
media-libs/mesa/mesa-18.3.0.ebuild | 519 ------------------------------------- |
15 |
media-libs/mesa/mesa-18.3.1.ebuild | 519 ------------------------------------- |
16 |
4 files changed, 1556 deletions(-) |
17 |
|
18 |
diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest |
19 |
index c9027aa77d7..9d6c1bb9ac7 100644 |
20 |
--- a/media-libs/mesa/Manifest |
21 |
+++ b/media-libs/mesa/Manifest |
22 |
@@ -1,5 +1,2 @@ |
23 |
-DIST mesa-18.2.7.tar.xz 11356060 BLAKE2B efad9f46ab1a5d007accce557da717ae69fe49e56f7a4bc90193b91a7d7be22ac899fc37d66fd6e9844091450c999a0288515f3ea39612d3fbe63b426a9690ac SHA512 81f7b7108352cb3d8cf4b600ce2b0db6eb8420df550bf9f7087d83c2ab0f8dc32abe188f8ce5f52066e432fb64d9d17fc0edfbc9d0cb0650d0041f14064d9d77 |
24 |
DIST mesa-18.2.8.tar.xz 11385224 BLAKE2B c6fbf71e2ab6837f91dfa996cf7e89e9cae22e219cac56bd4201f7a62c787ddd2f65e7d162a329971018f0b1a796ee1a5b252ee6b43bb3b27a233d67b6cdf615 SHA512 04d5ada9ba3acea853def3ebcbb53ee76936a4cd4229ae753d2ce1b5cf543bea1e5764f2ef2b19735d47d041ba6b0582841bc89e2c9331fdfbd89386f599a1f7 |
25 |
-DIST mesa-18.3.0.tar.xz 11865356 BLAKE2B e9529a6257b3dd914e9bfe5c88bfbc30d652a045dfd9ed1387b12db9e6a89968b3affc5bc91d4d773035c505f32c3749216ae3666787bf97f1b23dcd8e0f7d3a SHA512 6643d8a100c50efee7178fe950e7cccad24c3a98538d3a13c7c6570add30a56776b4e5f279e2b0a20c4038e682e9461ca5a4fd4ac23a7f60d2f4a0c972525c42 |
26 |
-DIST mesa-18.3.1.tar.xz 11865960 BLAKE2B 6863a6d3891d1d2916139f71a5beefd7d83c81a0753d2c6885126636647cb5f7332dc308a9927f149951b122770ed07bc96ff5361dd23fbe1e07fb31d9c05147 SHA512 a68d39158cf1e868d70730d0641a0cfe4c6e5b3cd1bc0c47f54022402aca03503933084f6ddc722bf88c9b6d1281ba5c847ec4fed8092a9b33f90527d08e12db |
27 |
DIST mesa-18.3.2.tar.xz 11868440 BLAKE2B 49612671fd4187e71441bc88094f2cde2057b8b45ad2546357be715a7c69dd38f5ef03b837369e302509e0b9882ba209e7901b172dc3f7d797804fa4ab383c91 SHA512 34b66520728d720b1f3d3d63f8ba5c255d57b9e8fe427264419e4163b474df662ff6db9ca8b81283866da415e34346a4c39fc37bebe2a0929be14480faf4db45 |
28 |
|
29 |
diff --git a/media-libs/mesa/mesa-18.2.7.ebuild b/media-libs/mesa/mesa-18.2.7.ebuild |
30 |
deleted file mode 100644 |
31 |
index d0b6f1befec..00000000000 |
32 |
--- a/media-libs/mesa/mesa-18.2.7.ebuild |
33 |
+++ /dev/null |
34 |
@@ -1,515 +0,0 @@ |
35 |
-# Copyright 1999-2018 Gentoo Authors |
36 |
-# Distributed under the terms of the GNU General Public License v2 |
37 |
- |
38 |
-EAPI=6 |
39 |
- |
40 |
-PYTHON_COMPAT=( python2_7 ) |
41 |
- |
42 |
-inherit llvm meson multilib-minimal pax-utils python-any-r1 |
43 |
- |
44 |
-OPENGL_DIR="xorg-x11" |
45 |
- |
46 |
-MY_P="${P/_/-}" |
47 |
- |
48 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
49 |
-HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" |
50 |
- |
51 |
-if [[ ${PV} == 9999 ]]; then |
52 |
- EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git" |
53 |
- EXPERIMENTAL="true" |
54 |
- inherit git-r3 |
55 |
-else |
56 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
57 |
- KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
58 |
-fi |
59 |
- |
60 |
-LICENSE="MIT" |
61 |
-SLOT="0" |
62 |
-RESTRICT=" |
63 |
- !test? ( test ) |
64 |
-" |
65 |
- |
66 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
67 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
68 |
-for card in ${VIDEO_CARDS}; do |
69 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
70 |
-done |
71 |
- |
72 |
-IUSE="${IUSE_VIDEO_CARDS} |
73 |
- +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm lm_sensors |
74 |
- opencl osmesa pax_kernel pic selinux test unwind vaapi valgrind vdpau |
75 |
- vulkan wayland xa xvmc" |
76 |
- |
77 |
-REQUIRED_USE=" |
78 |
- d3d9? ( dri3 || ( video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) ) |
79 |
- gles1? ( egl ) |
80 |
- gles2? ( egl ) |
81 |
- vulkan? ( dri3 |
82 |
- || ( video_cards_i965 video_cards_radeonsi ) |
83 |
- video_cards_radeonsi? ( llvm ) ) |
84 |
- wayland? ( egl gbm ) |
85 |
- video_cards_freedreno? ( gallium ) |
86 |
- video_cards_intel? ( classic ) |
87 |
- video_cards_i915? ( || ( classic gallium ) ) |
88 |
- video_cards_i965? ( classic ) |
89 |
- video_cards_imx? ( gallium video_cards_vivante ) |
90 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
91 |
- video_cards_radeon? ( || ( classic gallium ) |
92 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
93 |
- video_cards_r100? ( classic ) |
94 |
- video_cards_r200? ( classic ) |
95 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
96 |
- video_cards_r600? ( gallium ) |
97 |
- video_cards_radeonsi? ( gallium llvm ) |
98 |
- video_cards_vc4? ( gallium ) |
99 |
- video_cards_virgl? ( gallium ) |
100 |
- video_cards_vivante? ( gallium gbm ) |
101 |
- video_cards_vmware? ( gallium ) |
102 |
-" |
103 |
- |
104 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.93" |
105 |
-RDEPEND=" |
106 |
- !app-eselect/eselect-mesa |
107 |
- >=app-eselect/eselect-opengl-1.3.0 |
108 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
109 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
110 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
111 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
112 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
113 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
114 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
115 |
- >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}] |
116 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
117 |
- gallium? ( |
118 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
119 |
- llvm? ( |
120 |
- video_cards_radeonsi? ( |
121 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
122 |
- ) |
123 |
- video_cards_r600? ( |
124 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
125 |
- ) |
126 |
- video_cards_radeon? ( |
127 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
128 |
- ) |
129 |
- ) |
130 |
- lm_sensors? ( sys-apps/lm_sensors:=[${MULTILIB_USEDEP}] ) |
131 |
- opencl? ( |
132 |
- dev-libs/ocl-icd[khronos-headers,${MULTILIB_USEDEP}] |
133 |
- dev-libs/libclc |
134 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
135 |
- ) |
136 |
- vaapi? ( |
137 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
138 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
139 |
- ) |
140 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
141 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
142 |
- ) |
143 |
- wayland? ( |
144 |
- >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}] |
145 |
- >=dev-libs/wayland-protocols-1.8 |
146 |
- ) |
147 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
148 |
- |
149 |
- video_cards_intel? ( |
150 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
151 |
- ) |
152 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
153 |
-" |
154 |
-for card in ${RADEON_CARDS}; do |
155 |
- RDEPEND="${RDEPEND} |
156 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
157 |
- " |
158 |
-done |
159 |
-RDEPEND="${RDEPEND} |
160 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
161 |
-" |
162 |
- |
163 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
164 |
-# we need to *really* make sure we're not pulling one than more slot |
165 |
-# simultaneously. |
166 |
-# |
167 |
-# How to use it: |
168 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
169 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
170 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
171 |
-LLVM_MAX_SLOT="7" |
172 |
-LLVM_DEPSTR=" |
173 |
- || ( |
174 |
- sys-devel/llvm:7[${MULTILIB_USEDEP}] |
175 |
- sys-devel/llvm:6[${MULTILIB_USEDEP}] |
176 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
177 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
178 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
179 |
- ) |
180 |
- sys-devel/llvm:=[${MULTILIB_USEDEP}] |
181 |
-" |
182 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
183 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
184 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
185 |
-RDEPEND="${RDEPEND} |
186 |
- llvm? ( |
187 |
- opencl? ( |
188 |
- video_cards_r600? ( |
189 |
- ${CLANG_DEPSTR_AMDGPU} |
190 |
- ) |
191 |
- !video_cards_r600? ( |
192 |
- video_cards_radeonsi? ( |
193 |
- ${CLANG_DEPSTR_AMDGPU} |
194 |
- ) |
195 |
- ) |
196 |
- !video_cards_r600? ( |
197 |
- !video_cards_radeonsi? ( |
198 |
- video_cards_radeon? ( |
199 |
- ${CLANG_DEPSTR_AMDGPU} |
200 |
- ) |
201 |
- ) |
202 |
- ) |
203 |
- !video_cards_r600? ( |
204 |
- !video_cards_radeon? ( |
205 |
- !video_cards_radeonsi? ( |
206 |
- ${CLANG_DEPSTR} |
207 |
- ) |
208 |
- ) |
209 |
- ) |
210 |
- ) |
211 |
- !opencl? ( |
212 |
- video_cards_r600? ( |
213 |
- ${LLVM_DEPSTR_AMDGPU} |
214 |
- ) |
215 |
- !video_cards_r600? ( |
216 |
- video_cards_radeonsi? ( |
217 |
- ${LLVM_DEPSTR_AMDGPU} |
218 |
- ) |
219 |
- ) |
220 |
- !video_cards_r600? ( |
221 |
- !video_cards_radeonsi? ( |
222 |
- video_cards_radeon? ( |
223 |
- ${LLVM_DEPSTR_AMDGPU} |
224 |
- ) |
225 |
- ) |
226 |
- ) |
227 |
- !video_cards_r600? ( |
228 |
- !video_cards_radeon? ( |
229 |
- !video_cards_radeonsi? ( |
230 |
- ${LLVM_DEPSTR} |
231 |
- ) |
232 |
- ) |
233 |
- ) |
234 |
- ) |
235 |
- ) |
236 |
-" |
237 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
238 |
- |
239 |
-DEPEND="${RDEPEND} |
240 |
- ${PYTHON_DEPS} |
241 |
- opencl? ( |
242 |
- >=sys-devel/gcc-4.6 |
243 |
- ) |
244 |
- sys-devel/bison |
245 |
- sys-devel/flex |
246 |
- sys-devel/gettext |
247 |
- virtual/pkgconfig |
248 |
- valgrind? ( dev-util/valgrind ) |
249 |
- x11-base/xorg-proto |
250 |
- x11-libs/libXrandr[${MULTILIB_USEDEP}] |
251 |
- $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]") |
252 |
-" |
253 |
- |
254 |
-S="${WORKDIR}/${MY_P}" |
255 |
-EGIT_CHECKOUT_DIR=${S} |
256 |
- |
257 |
-QA_WX_LOAD=" |
258 |
-x86? ( |
259 |
- !pic? ( |
260 |
- usr/lib*/libglapi.so.0.0.0 |
261 |
- usr/lib*/libGLESv1_CM.so.1.0.0 |
262 |
- usr/lib*/libGLESv2.so.2.0.0 |
263 |
- usr/lib*/libGL.so.1.2.0 |
264 |
- usr/lib*/libOSMesa.so.8.0.0 |
265 |
- ) |
266 |
-)" |
267 |
- |
268 |
-llvm_check_deps() { |
269 |
- local flags=${MULTILIB_USEDEP} |
270 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
271 |
- then |
272 |
- flags+=",llvm_targets_AMDGPU(-)" |
273 |
- fi |
274 |
- |
275 |
- if use opencl; then |
276 |
- has_version "sys-devel/clang[${flags}]" || return 1 |
277 |
- fi |
278 |
- has_version "sys-devel/llvm[${flags}]" |
279 |
-} |
280 |
- |
281 |
-pkg_pretend() { |
282 |
- if use opencl; then |
283 |
- if ! use video_cards_r600 && |
284 |
- ! use video_cards_radeonsi; then |
285 |
- ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi" |
286 |
- fi |
287 |
- fi |
288 |
- |
289 |
- if use vaapi; then |
290 |
- if ! use video_cards_r600 && |
291 |
- ! use video_cards_radeonsi && |
292 |
- ! use video_cards_nouveau; then |
293 |
- ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau" |
294 |
- fi |
295 |
- fi |
296 |
- |
297 |
- if use vdpau; then |
298 |
- if ! use video_cards_r300 && |
299 |
- ! use video_cards_r600 && |
300 |
- ! use video_cards_radeonsi && |
301 |
- ! use video_cards_nouveau; then |
302 |
- ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau" |
303 |
- fi |
304 |
- fi |
305 |
- |
306 |
- if use xa; then |
307 |
- if ! use video_cards_freedreno && |
308 |
- ! use video_cards_nouveau && |
309 |
- ! use video_cards_vmware; then |
310 |
- ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware" |
311 |
- fi |
312 |
- fi |
313 |
- |
314 |
- if use xvmc; then |
315 |
- if ! use video_cards_r600 && |
316 |
- ! use video_cards_nouveau; then |
317 |
- ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau" |
318 |
- fi |
319 |
- fi |
320 |
- |
321 |
- if ! use gallium; then |
322 |
- use lm_sensors && ewarn "Ignoring USE=lm_sensors since USE does not contain gallium" |
323 |
- use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium" |
324 |
- use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium" |
325 |
- use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium" |
326 |
- use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium" |
327 |
- use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium" |
328 |
- use xa && ewarn "Ignoring USE=xa since USE does not contain gallium" |
329 |
- use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium" |
330 |
- fi |
331 |
- |
332 |
- if ! use llvm; then |
333 |
- use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm" |
334 |
- fi |
335 |
-} |
336 |
- |
337 |
-pkg_setup() { |
338 |
- # warning message for bug 459306 |
339 |
- if use llvm && has_version sys-devel/llvm[!debug=]; then |
340 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
341 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
342 |
- fi |
343 |
- |
344 |
- if use llvm; then |
345 |
- llvm_pkg_setup |
346 |
- fi |
347 |
- python-any-r1_pkg_setup |
348 |
-} |
349 |
- |
350 |
-multilib_src_configure() { |
351 |
- local emesonargs=() |
352 |
- |
353 |
- if use classic; then |
354 |
- # Intel code |
355 |
- dri_driver_enable video_cards_i915 i915 |
356 |
- dri_driver_enable video_cards_i965 i965 |
357 |
- if ! use video_cards_i915 && \ |
358 |
- ! use video_cards_i965; then |
359 |
- dri_driver_enable video_cards_intel i915 i965 |
360 |
- fi |
361 |
- |
362 |
- # Nouveau code |
363 |
- dri_driver_enable video_cards_nouveau nouveau |
364 |
- |
365 |
- # ATI code |
366 |
- dri_driver_enable video_cards_r100 r100 |
367 |
- dri_driver_enable video_cards_r200 r200 |
368 |
- if ! use video_cards_r100 && \ |
369 |
- ! use video_cards_r200; then |
370 |
- dri_driver_enable video_cards_radeon r100 r200 |
371 |
- fi |
372 |
- fi |
373 |
- |
374 |
- emesonargs+=( -Dplatforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm") ) |
375 |
- |
376 |
- if use gallium; then |
377 |
- emesonargs+=( |
378 |
- $(meson_use llvm) |
379 |
- $(meson_use lm_sensors lmsensors) |
380 |
- $(meson_use unwind libunwind) |
381 |
- ) |
382 |
- |
383 |
- if use video_cards_r300 || |
384 |
- use video_cards_r600 || |
385 |
- use video_cards_radeonsi || |
386 |
- use video_cards_nouveau || |
387 |
- use video_cards_vmware; then |
388 |
- emesonargs+=($(meson_use d3d9 gallium-nine)) |
389 |
- else |
390 |
- emesonargs+=(-Dgallium-nine=false) |
391 |
- fi |
392 |
- |
393 |
- if use video_cards_r600 || |
394 |
- use video_cards_radeonsi || |
395 |
- use video_cards_nouveau; then |
396 |
- emesonargs+=($(meson_use vaapi gallium-va)) |
397 |
- use vaapi && emesonargs+=( -Dva-libs-path=/usr/$(get_libdir)/va/drivers ) |
398 |
- else |
399 |
- emesonargs+=(-Dgallium-va=false) |
400 |
- fi |
401 |
- |
402 |
- if use video_cards_r300 || |
403 |
- use video_cards_r600 || |
404 |
- use video_cards_radeonsi || |
405 |
- use video_cards_nouveau; then |
406 |
- emesonargs+=($(meson_use vdpau gallium-vdpau)) |
407 |
- else |
408 |
- emesonargs+=(-Dgallium-vdpau=false) |
409 |
- fi |
410 |
- |
411 |
- if use video_cards_freedreno || |
412 |
- use video_cards_nouveau || |
413 |
- use video_cards_vmware; then |
414 |
- emesonargs+=($(meson_use xa gallium-xa)) |
415 |
- else |
416 |
- emesonargs+=(-Dgallium-xa=false) |
417 |
- fi |
418 |
- |
419 |
- if use video_cards_r600 || |
420 |
- use video_cards_nouveau; then |
421 |
- emesonargs+=($(meson_use xvmc gallium-xvmc)) |
422 |
- else |
423 |
- emesonargs+=(-Dgallium-xvmc=false) |
424 |
- fi |
425 |
- |
426 |
- gallium_enable video_cards_vc4 vc4 |
427 |
- gallium_enable video_cards_vivante etnaviv |
428 |
- gallium_enable video_cards_vmware svga |
429 |
- gallium_enable video_cards_nouveau nouveau |
430 |
- gallium_enable video_cards_imx imx |
431 |
- |
432 |
- # Only one i915 driver (classic vs gallium). Default to classic. |
433 |
- if ! use classic; then |
434 |
- gallium_enable video_cards_i915 i915 |
435 |
- if ! use video_cards_i915 && \ |
436 |
- ! use video_cards_i965; then |
437 |
- gallium_enable video_cards_intel i915 |
438 |
- fi |
439 |
- fi |
440 |
- |
441 |
- gallium_enable video_cards_r300 r300 |
442 |
- gallium_enable video_cards_r600 r600 |
443 |
- gallium_enable video_cards_radeonsi radeonsi |
444 |
- if ! use video_cards_r300 && \ |
445 |
- ! use video_cards_r600; then |
446 |
- gallium_enable video_cards_radeon r300 r600 |
447 |
- fi |
448 |
- |
449 |
- gallium_enable video_cards_freedreno freedreno |
450 |
- gallium_enable video_cards_virgl virgl |
451 |
- |
452 |
- # opencl stuff |
453 |
- emesonargs+=( |
454 |
- -Dgallium-opencl="$(usex opencl icd disabled)" |
455 |
- ) |
456 |
- fi |
457 |
- |
458 |
- if use vulkan; then |
459 |
- vulkan_enable video_cards_i965 intel |
460 |
- vulkan_enable video_cards_radeonsi amd |
461 |
- fi |
462 |
- |
463 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
464 |
- if [[ ${ABI} == x86 ]]; then |
465 |
- emesonargs+=( $(meson_use pax_kernel glx-read-only-text) ) |
466 |
- fi |
467 |
- |
468 |
- # on abi_x86_32 hardened we need to have asm disable |
469 |
- if [[ ${ABI} == x86* ]] && use pic; then |
470 |
- emesonargs+=( -Dasm=false ) |
471 |
- fi |
472 |
- |
473 |
- if use gallium; then |
474 |
- gallium_enable -- swrast |
475 |
- emesonargs+=( -Dosmesa=$(usex osmesa gallium none) ) |
476 |
- else |
477 |
- dri_driver_enable -- swrast |
478 |
- emesonargs+=( -Dosmesa=$(usex osmesa classic none) ) |
479 |
- fi |
480 |
- |
481 |
- driver_list() { |
482 |
- local drivers="$(sort -u <<< "${1// /$'\n'}")" |
483 |
- echo "${drivers//$'\n'/,}" |
484 |
- } |
485 |
- |
486 |
- emesonargs+=( |
487 |
- $(meson_use test build-tests) |
488 |
- -Dglx=dri |
489 |
- -Dshared-glapi=true |
490 |
- $(meson_use dri3) |
491 |
- $(meson_use egl) |
492 |
- $(meson_use gbm) |
493 |
- $(meson_use gles1) |
494 |
- $(meson_use gles2) |
495 |
- $(meson_use selinux) |
496 |
- -Dvalgrind=$(usex valgrind auto false) |
497 |
- -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}") |
498 |
- -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}") |
499 |
- -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}") |
500 |
- --buildtype $(usex debug debug plain) |
501 |
- -Db_ndebug=$(usex debug false true) |
502 |
- ) |
503 |
- meson_src_configure |
504 |
-} |
505 |
- |
506 |
-multilib_src_compile() { |
507 |
- meson_src_compile |
508 |
-} |
509 |
- |
510 |
-multilib_src_install() { |
511 |
- meson_src_install |
512 |
-} |
513 |
- |
514 |
-multilib_src_install_all() { |
515 |
- einstalldocs |
516 |
-} |
517 |
- |
518 |
-multilib_src_test() { |
519 |
- meson_src_test |
520 |
-} |
521 |
- |
522 |
-pkg_postinst() { |
523 |
- # Switch to the xorg implementation. |
524 |
- echo |
525 |
- eselect opengl set --use-old ${OPENGL_DIR} |
526 |
-} |
527 |
- |
528 |
-# $1 - VIDEO_CARDS flag (check skipped for "--") |
529 |
-# other args - names of DRI drivers to enable |
530 |
-dri_driver_enable() { |
531 |
- if [[ $1 == -- ]] || use $1; then |
532 |
- shift |
533 |
- DRI_DRIVERS+=("$@") |
534 |
- fi |
535 |
-} |
536 |
- |
537 |
-gallium_enable() { |
538 |
- if [[ $1 == -- ]] || use $1; then |
539 |
- shift |
540 |
- GALLIUM_DRIVERS+=("$@") |
541 |
- fi |
542 |
-} |
543 |
- |
544 |
-vulkan_enable() { |
545 |
- if [[ $1 == -- ]] || use $1; then |
546 |
- shift |
547 |
- VULKAN_DRIVERS+=("$@") |
548 |
- fi |
549 |
-} |
550 |
|
551 |
diff --git a/media-libs/mesa/mesa-18.3.0.ebuild b/media-libs/mesa/mesa-18.3.0.ebuild |
552 |
deleted file mode 100644 |
553 |
index c6579285709..00000000000 |
554 |
--- a/media-libs/mesa/mesa-18.3.0.ebuild |
555 |
+++ /dev/null |
556 |
@@ -1,519 +0,0 @@ |
557 |
-# Copyright 1999-2018 Gentoo Authors |
558 |
-# Distributed under the terms of the GNU General Public License v2 |
559 |
- |
560 |
-EAPI=6 |
561 |
- |
562 |
-PYTHON_COMPAT=( python3_4 python3_5 python3_6 python3_7 ) |
563 |
- |
564 |
-inherit llvm meson multilib-minimal pax-utils python-any-r1 |
565 |
- |
566 |
-OPENGL_DIR="xorg-x11" |
567 |
- |
568 |
-MY_P="${P/_/-}" |
569 |
- |
570 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
571 |
-HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" |
572 |
- |
573 |
-if [[ ${PV} == 9999 ]]; then |
574 |
- EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git" |
575 |
- EXPERIMENTAL="true" |
576 |
- inherit git-r3 |
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 ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
580 |
-fi |
581 |
- |
582 |
-LICENSE="MIT" |
583 |
-SLOT="0" |
584 |
-RESTRICT=" |
585 |
- !test? ( test ) |
586 |
-" |
587 |
- |
588 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
589 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
590 |
-for card in ${VIDEO_CARDS}; do |
591 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
592 |
-done |
593 |
- |
594 |
-IUSE="${IUSE_VIDEO_CARDS} |
595 |
- +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm lm_sensors |
596 |
- opencl osmesa pax_kernel pic selinux test unwind vaapi valgrind vdpau |
597 |
- vulkan wayland xa xvmc" |
598 |
- |
599 |
-REQUIRED_USE=" |
600 |
- d3d9? ( dri3 || ( video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) ) |
601 |
- gles1? ( egl ) |
602 |
- gles2? ( egl ) |
603 |
- vulkan? ( dri3 |
604 |
- || ( video_cards_i965 video_cards_radeonsi ) |
605 |
- video_cards_radeonsi? ( llvm ) ) |
606 |
- wayland? ( egl gbm ) |
607 |
- video_cards_freedreno? ( gallium ) |
608 |
- video_cards_intel? ( classic ) |
609 |
- video_cards_i915? ( || ( classic gallium ) ) |
610 |
- video_cards_i965? ( classic ) |
611 |
- video_cards_imx? ( gallium video_cards_vivante ) |
612 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
613 |
- video_cards_radeon? ( || ( classic gallium ) |
614 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
615 |
- video_cards_r100? ( classic ) |
616 |
- video_cards_r200? ( classic ) |
617 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
618 |
- video_cards_r600? ( gallium ) |
619 |
- video_cards_radeonsi? ( gallium llvm ) |
620 |
- video_cards_vc4? ( gallium ) |
621 |
- video_cards_virgl? ( gallium ) |
622 |
- video_cards_vivante? ( gallium gbm ) |
623 |
- video_cards_vmware? ( gallium ) |
624 |
-" |
625 |
- |
626 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.96" |
627 |
-RDEPEND=" |
628 |
- !app-eselect/eselect-mesa |
629 |
- >=app-eselect/eselect-opengl-1.3.0 |
630 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
631 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
632 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
633 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
634 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
635 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
636 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
637 |
- >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}] |
638 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
639 |
- gallium? ( |
640 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
641 |
- llvm? ( |
642 |
- video_cards_radeonsi? ( |
643 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
644 |
- ) |
645 |
- video_cards_r600? ( |
646 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
647 |
- ) |
648 |
- video_cards_radeon? ( |
649 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
650 |
- ) |
651 |
- ) |
652 |
- lm_sensors? ( sys-apps/lm_sensors:=[${MULTILIB_USEDEP}] ) |
653 |
- opencl? ( |
654 |
- dev-libs/ocl-icd[khronos-headers,${MULTILIB_USEDEP}] |
655 |
- dev-libs/libclc |
656 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
657 |
- ) |
658 |
- vaapi? ( |
659 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
660 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
661 |
- ) |
662 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
663 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
664 |
- ) |
665 |
- wayland? ( |
666 |
- >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}] |
667 |
- >=dev-libs/wayland-protocols-1.8 |
668 |
- ) |
669 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
670 |
- |
671 |
- video_cards_intel? ( |
672 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
673 |
- ) |
674 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
675 |
-" |
676 |
-for card in ${RADEON_CARDS}; do |
677 |
- RDEPEND="${RDEPEND} |
678 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
679 |
- " |
680 |
-done |
681 |
-RDEPEND="${RDEPEND} |
682 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
683 |
-" |
684 |
- |
685 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
686 |
-# we need to *really* make sure we're not pulling one than more slot |
687 |
-# simultaneously. |
688 |
-# |
689 |
-# How to use it: |
690 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
691 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
692 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
693 |
-LLVM_MAX_SLOT="7" |
694 |
-LLVM_DEPSTR=" |
695 |
- || ( |
696 |
- sys-devel/llvm:7[${MULTILIB_USEDEP}] |
697 |
- sys-devel/llvm:6[${MULTILIB_USEDEP}] |
698 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
699 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
700 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
701 |
- ) |
702 |
- sys-devel/llvm:=[${MULTILIB_USEDEP}] |
703 |
-" |
704 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
705 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
706 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
707 |
-RDEPEND="${RDEPEND} |
708 |
- llvm? ( |
709 |
- opencl? ( |
710 |
- video_cards_r600? ( |
711 |
- ${CLANG_DEPSTR_AMDGPU} |
712 |
- ) |
713 |
- !video_cards_r600? ( |
714 |
- video_cards_radeonsi? ( |
715 |
- ${CLANG_DEPSTR_AMDGPU} |
716 |
- ) |
717 |
- ) |
718 |
- !video_cards_r600? ( |
719 |
- !video_cards_radeonsi? ( |
720 |
- video_cards_radeon? ( |
721 |
- ${CLANG_DEPSTR_AMDGPU} |
722 |
- ) |
723 |
- ) |
724 |
- ) |
725 |
- !video_cards_r600? ( |
726 |
- !video_cards_radeon? ( |
727 |
- !video_cards_radeonsi? ( |
728 |
- ${CLANG_DEPSTR} |
729 |
- ) |
730 |
- ) |
731 |
- ) |
732 |
- ) |
733 |
- !opencl? ( |
734 |
- video_cards_r600? ( |
735 |
- ${LLVM_DEPSTR_AMDGPU} |
736 |
- ) |
737 |
- !video_cards_r600? ( |
738 |
- video_cards_radeonsi? ( |
739 |
- ${LLVM_DEPSTR_AMDGPU} |
740 |
- ) |
741 |
- ) |
742 |
- !video_cards_r600? ( |
743 |
- !video_cards_radeonsi? ( |
744 |
- video_cards_radeon? ( |
745 |
- ${LLVM_DEPSTR_AMDGPU} |
746 |
- ) |
747 |
- ) |
748 |
- ) |
749 |
- !video_cards_r600? ( |
750 |
- !video_cards_radeon? ( |
751 |
- !video_cards_radeonsi? ( |
752 |
- ${LLVM_DEPSTR} |
753 |
- ) |
754 |
- ) |
755 |
- ) |
756 |
- ) |
757 |
- ) |
758 |
-" |
759 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
760 |
- |
761 |
-DEPEND="${RDEPEND} |
762 |
- ${PYTHON_DEPS} |
763 |
- opencl? ( |
764 |
- >=sys-devel/gcc-4.6 |
765 |
- ) |
766 |
- sys-devel/bison |
767 |
- sys-devel/flex |
768 |
- sys-devel/gettext |
769 |
- virtual/pkgconfig |
770 |
- valgrind? ( dev-util/valgrind ) |
771 |
- x11-base/xorg-proto |
772 |
- x11-libs/libXrandr[${MULTILIB_USEDEP}] |
773 |
- $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]") |
774 |
-" |
775 |
- |
776 |
-S="${WORKDIR}/${MY_P}" |
777 |
-EGIT_CHECKOUT_DIR=${S} |
778 |
- |
779 |
-QA_WX_LOAD=" |
780 |
-x86? ( |
781 |
- !pic? ( |
782 |
- usr/lib*/libglapi.so.0.0.0 |
783 |
- usr/lib*/libGLESv1_CM.so.1.0.0 |
784 |
- usr/lib*/libGLESv2.so.2.0.0 |
785 |
- usr/lib*/libGL.so.1.2.0 |
786 |
- usr/lib*/libOSMesa.so.8.0.0 |
787 |
- ) |
788 |
-)" |
789 |
- |
790 |
-llvm_check_deps() { |
791 |
- local flags=${MULTILIB_USEDEP} |
792 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
793 |
- then |
794 |
- flags+=",llvm_targets_AMDGPU(-)" |
795 |
- fi |
796 |
- |
797 |
- if use opencl; then |
798 |
- has_version "sys-devel/clang[${flags}]" || return 1 |
799 |
- fi |
800 |
- has_version "sys-devel/llvm[${flags}]" |
801 |
-} |
802 |
- |
803 |
-pkg_pretend() { |
804 |
- if use opencl; then |
805 |
- if ! use video_cards_r600 && |
806 |
- ! use video_cards_radeonsi; then |
807 |
- ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi" |
808 |
- fi |
809 |
- fi |
810 |
- |
811 |
- if use vaapi; then |
812 |
- if ! use video_cards_r600 && |
813 |
- ! use video_cards_radeonsi && |
814 |
- ! use video_cards_nouveau; then |
815 |
- ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau" |
816 |
- fi |
817 |
- fi |
818 |
- |
819 |
- if use vdpau; then |
820 |
- if ! use video_cards_r300 && |
821 |
- ! use video_cards_r600 && |
822 |
- ! use video_cards_radeonsi && |
823 |
- ! use video_cards_nouveau; then |
824 |
- ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau" |
825 |
- fi |
826 |
- fi |
827 |
- |
828 |
- if use xa; then |
829 |
- if ! use video_cards_freedreno && |
830 |
- ! use video_cards_nouveau && |
831 |
- ! use video_cards_vmware; then |
832 |
- ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware" |
833 |
- fi |
834 |
- fi |
835 |
- |
836 |
- if use xvmc; then |
837 |
- if ! use video_cards_r600 && |
838 |
- ! use video_cards_nouveau; then |
839 |
- ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau" |
840 |
- fi |
841 |
- fi |
842 |
- |
843 |
- if ! use gallium; then |
844 |
- use lm_sensors && ewarn "Ignoring USE=lm_sensors since USE does not contain gallium" |
845 |
- use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium" |
846 |
- use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium" |
847 |
- use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium" |
848 |
- use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium" |
849 |
- use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium" |
850 |
- use xa && ewarn "Ignoring USE=xa since USE does not contain gallium" |
851 |
- use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium" |
852 |
- fi |
853 |
- |
854 |
- if ! use llvm; then |
855 |
- use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm" |
856 |
- fi |
857 |
-} |
858 |
- |
859 |
-python_check_deps() { |
860 |
- has_version ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]" |
861 |
-} |
862 |
- |
863 |
-pkg_setup() { |
864 |
- # warning message for bug 459306 |
865 |
- if use llvm && has_version sys-devel/llvm[!debug=]; then |
866 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
867 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
868 |
- fi |
869 |
- |
870 |
- if use llvm; then |
871 |
- llvm_pkg_setup |
872 |
- fi |
873 |
- python-any-r1_pkg_setup |
874 |
-} |
875 |
- |
876 |
-multilib_src_configure() { |
877 |
- local emesonargs=() |
878 |
- |
879 |
- if use classic; then |
880 |
- # Intel code |
881 |
- dri_driver_enable video_cards_i915 i915 |
882 |
- dri_driver_enable video_cards_i965 i965 |
883 |
- if ! use video_cards_i915 && \ |
884 |
- ! use video_cards_i965; then |
885 |
- dri_driver_enable video_cards_intel i915 i965 |
886 |
- fi |
887 |
- |
888 |
- # Nouveau code |
889 |
- dri_driver_enable video_cards_nouveau nouveau |
890 |
- |
891 |
- # ATI code |
892 |
- dri_driver_enable video_cards_r100 r100 |
893 |
- dri_driver_enable video_cards_r200 r200 |
894 |
- if ! use video_cards_r100 && \ |
895 |
- ! use video_cards_r200; then |
896 |
- dri_driver_enable video_cards_radeon r100 r200 |
897 |
- fi |
898 |
- fi |
899 |
- |
900 |
- emesonargs+=( -Dplatforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm") ) |
901 |
- |
902 |
- if use gallium; then |
903 |
- emesonargs+=( |
904 |
- $(meson_use llvm) |
905 |
- $(meson_use lm_sensors lmsensors) |
906 |
- $(meson_use unwind libunwind) |
907 |
- ) |
908 |
- |
909 |
- if use video_cards_r300 || |
910 |
- use video_cards_r600 || |
911 |
- use video_cards_radeonsi || |
912 |
- use video_cards_nouveau || |
913 |
- use video_cards_vmware; then |
914 |
- emesonargs+=($(meson_use d3d9 gallium-nine)) |
915 |
- else |
916 |
- emesonargs+=(-Dgallium-nine=false) |
917 |
- fi |
918 |
- |
919 |
- if use video_cards_r600 || |
920 |
- use video_cards_radeonsi || |
921 |
- use video_cards_nouveau; then |
922 |
- emesonargs+=($(meson_use vaapi gallium-va)) |
923 |
- use vaapi && emesonargs+=( -Dva-libs-path=/usr/$(get_libdir)/va/drivers ) |
924 |
- else |
925 |
- emesonargs+=(-Dgallium-va=false) |
926 |
- fi |
927 |
- |
928 |
- if use video_cards_r300 || |
929 |
- use video_cards_r600 || |
930 |
- use video_cards_radeonsi || |
931 |
- use video_cards_nouveau; then |
932 |
- emesonargs+=($(meson_use vdpau gallium-vdpau)) |
933 |
- else |
934 |
- emesonargs+=(-Dgallium-vdpau=false) |
935 |
- fi |
936 |
- |
937 |
- if use video_cards_freedreno || |
938 |
- use video_cards_nouveau || |
939 |
- use video_cards_vmware; then |
940 |
- emesonargs+=($(meson_use xa gallium-xa)) |
941 |
- else |
942 |
- emesonargs+=(-Dgallium-xa=false) |
943 |
- fi |
944 |
- |
945 |
- if use video_cards_r600 || |
946 |
- use video_cards_nouveau; then |
947 |
- emesonargs+=($(meson_use xvmc gallium-xvmc)) |
948 |
- else |
949 |
- emesonargs+=(-Dgallium-xvmc=false) |
950 |
- fi |
951 |
- |
952 |
- gallium_enable video_cards_vc4 vc4 |
953 |
- gallium_enable video_cards_vivante etnaviv |
954 |
- gallium_enable video_cards_vmware svga |
955 |
- gallium_enable video_cards_nouveau nouveau |
956 |
- gallium_enable video_cards_imx imx |
957 |
- |
958 |
- # Only one i915 driver (classic vs gallium). Default to classic. |
959 |
- if ! use classic; then |
960 |
- gallium_enable video_cards_i915 i915 |
961 |
- if ! use video_cards_i915 && \ |
962 |
- ! use video_cards_i965; then |
963 |
- gallium_enable video_cards_intel i915 |
964 |
- fi |
965 |
- fi |
966 |
- |
967 |
- gallium_enable video_cards_r300 r300 |
968 |
- gallium_enable video_cards_r600 r600 |
969 |
- gallium_enable video_cards_radeonsi radeonsi |
970 |
- if ! use video_cards_r300 && \ |
971 |
- ! use video_cards_r600; then |
972 |
- gallium_enable video_cards_radeon r300 r600 |
973 |
- fi |
974 |
- |
975 |
- gallium_enable video_cards_freedreno freedreno |
976 |
- gallium_enable video_cards_virgl virgl |
977 |
- |
978 |
- # opencl stuff |
979 |
- emesonargs+=( |
980 |
- -Dgallium-opencl="$(usex opencl icd disabled)" |
981 |
- ) |
982 |
- fi |
983 |
- |
984 |
- if use vulkan; then |
985 |
- vulkan_enable video_cards_i965 intel |
986 |
- vulkan_enable video_cards_radeonsi amd |
987 |
- fi |
988 |
- |
989 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
990 |
- if [[ ${ABI} == x86 ]]; then |
991 |
- emesonargs+=( $(meson_use pax_kernel glx-read-only-text) ) |
992 |
- fi |
993 |
- |
994 |
- # on abi_x86_32 hardened we need to have asm disable |
995 |
- if [[ ${ABI} == x86* ]] && use pic; then |
996 |
- emesonargs+=( -Dasm=false ) |
997 |
- fi |
998 |
- |
999 |
- if use gallium; then |
1000 |
- gallium_enable -- swrast |
1001 |
- emesonargs+=( -Dosmesa=$(usex osmesa gallium none) ) |
1002 |
- else |
1003 |
- dri_driver_enable -- swrast |
1004 |
- emesonargs+=( -Dosmesa=$(usex osmesa classic none) ) |
1005 |
- fi |
1006 |
- |
1007 |
- driver_list() { |
1008 |
- local drivers="$(sort -u <<< "${1// /$'\n'}")" |
1009 |
- echo "${drivers//$'\n'/,}" |
1010 |
- } |
1011 |
- |
1012 |
- emesonargs+=( |
1013 |
- $(meson_use test build-tests) |
1014 |
- -Dglx=dri |
1015 |
- -Dshared-glapi=true |
1016 |
- $(meson_use dri3) |
1017 |
- $(meson_use egl) |
1018 |
- $(meson_use gbm) |
1019 |
- $(meson_use gles1) |
1020 |
- $(meson_use gles2) |
1021 |
- $(meson_use selinux) |
1022 |
- -Dvalgrind=$(usex valgrind auto false) |
1023 |
- -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}") |
1024 |
- -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}") |
1025 |
- -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}") |
1026 |
- --buildtype $(usex debug debug plain) |
1027 |
- -Db_ndebug=$(usex debug false true) |
1028 |
- ) |
1029 |
- meson_src_configure |
1030 |
-} |
1031 |
- |
1032 |
-multilib_src_compile() { |
1033 |
- meson_src_compile |
1034 |
-} |
1035 |
- |
1036 |
-multilib_src_install() { |
1037 |
- meson_src_install |
1038 |
-} |
1039 |
- |
1040 |
-multilib_src_install_all() { |
1041 |
- einstalldocs |
1042 |
-} |
1043 |
- |
1044 |
-multilib_src_test() { |
1045 |
- meson_src_test |
1046 |
-} |
1047 |
- |
1048 |
-pkg_postinst() { |
1049 |
- # Switch to the xorg implementation. |
1050 |
- echo |
1051 |
- eselect opengl set --use-old ${OPENGL_DIR} |
1052 |
-} |
1053 |
- |
1054 |
-# $1 - VIDEO_CARDS flag (check skipped for "--") |
1055 |
-# other args - names of DRI drivers to enable |
1056 |
-dri_driver_enable() { |
1057 |
- if [[ $1 == -- ]] || use $1; then |
1058 |
- shift |
1059 |
- DRI_DRIVERS+=("$@") |
1060 |
- fi |
1061 |
-} |
1062 |
- |
1063 |
-gallium_enable() { |
1064 |
- if [[ $1 == -- ]] || use $1; then |
1065 |
- shift |
1066 |
- GALLIUM_DRIVERS+=("$@") |
1067 |
- fi |
1068 |
-} |
1069 |
- |
1070 |
-vulkan_enable() { |
1071 |
- if [[ $1 == -- ]] || use $1; then |
1072 |
- shift |
1073 |
- VULKAN_DRIVERS+=("$@") |
1074 |
- fi |
1075 |
-} |
1076 |
|
1077 |
diff --git a/media-libs/mesa/mesa-18.3.1.ebuild b/media-libs/mesa/mesa-18.3.1.ebuild |
1078 |
deleted file mode 100644 |
1079 |
index c6579285709..00000000000 |
1080 |
--- a/media-libs/mesa/mesa-18.3.1.ebuild |
1081 |
+++ /dev/null |
1082 |
@@ -1,519 +0,0 @@ |
1083 |
-# Copyright 1999-2018 Gentoo Authors |
1084 |
-# Distributed under the terms of the GNU General Public License v2 |
1085 |
- |
1086 |
-EAPI=6 |
1087 |
- |
1088 |
-PYTHON_COMPAT=( python3_4 python3_5 python3_6 python3_7 ) |
1089 |
- |
1090 |
-inherit llvm meson multilib-minimal pax-utils python-any-r1 |
1091 |
- |
1092 |
-OPENGL_DIR="xorg-x11" |
1093 |
- |
1094 |
-MY_P="${P/_/-}" |
1095 |
- |
1096 |
-DESCRIPTION="OpenGL-like graphic library for Linux" |
1097 |
-HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" |
1098 |
- |
1099 |
-if [[ ${PV} == 9999 ]]; then |
1100 |
- EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git" |
1101 |
- EXPERIMENTAL="true" |
1102 |
- inherit git-r3 |
1103 |
-else |
1104 |
- SRC_URI="https://mesa.freedesktop.org/archive/${MY_P}.tar.xz" |
1105 |
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" |
1106 |
-fi |
1107 |
- |
1108 |
-LICENSE="MIT" |
1109 |
-SLOT="0" |
1110 |
-RESTRICT=" |
1111 |
- !test? ( test ) |
1112 |
-" |
1113 |
- |
1114 |
-RADEON_CARDS="r100 r200 r300 r600 radeon radeonsi" |
1115 |
-VIDEO_CARDS="${RADEON_CARDS} freedreno i915 i965 imx intel nouveau vc4 virgl vivante vmware" |
1116 |
-for card in ${VIDEO_CARDS}; do |
1117 |
- IUSE_VIDEO_CARDS+=" video_cards_${card}" |
1118 |
-done |
1119 |
- |
1120 |
-IUSE="${IUSE_VIDEO_CARDS} |
1121 |
- +classic d3d9 debug +dri3 +egl +gallium +gbm gles1 gles2 +llvm lm_sensors |
1122 |
- opencl osmesa pax_kernel pic selinux test unwind vaapi valgrind vdpau |
1123 |
- vulkan wayland xa xvmc" |
1124 |
- |
1125 |
-REQUIRED_USE=" |
1126 |
- d3d9? ( dri3 || ( video_cards_r300 video_cards_r600 video_cards_radeonsi video_cards_nouveau video_cards_vmware ) ) |
1127 |
- gles1? ( egl ) |
1128 |
- gles2? ( egl ) |
1129 |
- vulkan? ( dri3 |
1130 |
- || ( video_cards_i965 video_cards_radeonsi ) |
1131 |
- video_cards_radeonsi? ( llvm ) ) |
1132 |
- wayland? ( egl gbm ) |
1133 |
- video_cards_freedreno? ( gallium ) |
1134 |
- video_cards_intel? ( classic ) |
1135 |
- video_cards_i915? ( || ( classic gallium ) ) |
1136 |
- video_cards_i965? ( classic ) |
1137 |
- video_cards_imx? ( gallium video_cards_vivante ) |
1138 |
- video_cards_nouveau? ( || ( classic gallium ) ) |
1139 |
- video_cards_radeon? ( || ( classic gallium ) |
1140 |
- gallium? ( x86? ( llvm ) amd64? ( llvm ) ) ) |
1141 |
- video_cards_r100? ( classic ) |
1142 |
- video_cards_r200? ( classic ) |
1143 |
- video_cards_r300? ( gallium x86? ( llvm ) amd64? ( llvm ) ) |
1144 |
- video_cards_r600? ( gallium ) |
1145 |
- video_cards_radeonsi? ( gallium llvm ) |
1146 |
- video_cards_vc4? ( gallium ) |
1147 |
- video_cards_virgl? ( gallium ) |
1148 |
- video_cards_vivante? ( gallium gbm ) |
1149 |
- video_cards_vmware? ( gallium ) |
1150 |
-" |
1151 |
- |
1152 |
-LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.96" |
1153 |
-RDEPEND=" |
1154 |
- !app-eselect/eselect-mesa |
1155 |
- >=app-eselect/eselect-opengl-1.3.0 |
1156 |
- >=dev-libs/expat-2.1.0-r3:=[${MULTILIB_USEDEP}] |
1157 |
- >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] |
1158 |
- >=x11-libs/libX11-1.6.2:=[${MULTILIB_USEDEP}] |
1159 |
- >=x11-libs/libxshmfence-1.1:=[${MULTILIB_USEDEP}] |
1160 |
- >=x11-libs/libXdamage-1.1.4-r1:=[${MULTILIB_USEDEP}] |
1161 |
- >=x11-libs/libXext-1.3.2:=[${MULTILIB_USEDEP}] |
1162 |
- >=x11-libs/libXxf86vm-1.1.3:=[${MULTILIB_USEDEP}] |
1163 |
- >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}] |
1164 |
- x11-libs/libXfixes:=[${MULTILIB_USEDEP}] |
1165 |
- gallium? ( |
1166 |
- unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) |
1167 |
- llvm? ( |
1168 |
- video_cards_radeonsi? ( |
1169 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1170 |
- ) |
1171 |
- video_cards_r600? ( |
1172 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1173 |
- ) |
1174 |
- video_cards_radeon? ( |
1175 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1176 |
- ) |
1177 |
- ) |
1178 |
- lm_sensors? ( sys-apps/lm_sensors:=[${MULTILIB_USEDEP}] ) |
1179 |
- opencl? ( |
1180 |
- dev-libs/ocl-icd[khronos-headers,${MULTILIB_USEDEP}] |
1181 |
- dev-libs/libclc |
1182 |
- virtual/libelf:0=[${MULTILIB_USEDEP}] |
1183 |
- ) |
1184 |
- vaapi? ( |
1185 |
- >=x11-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] |
1186 |
- video_cards_nouveau? ( !<=x11-libs/libva-vdpau-driver-0.7.4-r3 ) |
1187 |
- ) |
1188 |
- vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) |
1189 |
- xvmc? ( >=x11-libs/libXvMC-1.0.8:=[${MULTILIB_USEDEP}] ) |
1190 |
- ) |
1191 |
- wayland? ( |
1192 |
- >=dev-libs/wayland-1.15.0:=[${MULTILIB_USEDEP}] |
1193 |
- >=dev-libs/wayland-protocols-1.8 |
1194 |
- ) |
1195 |
- ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] |
1196 |
- |
1197 |
- video_cards_intel? ( |
1198 |
- !video_cards_i965? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
1199 |
- ) |
1200 |
- video_cards_i915? ( ${LIBDRM_DEPSTRING}[video_cards_intel] ) |
1201 |
-" |
1202 |
-for card in ${RADEON_CARDS}; do |
1203 |
- RDEPEND="${RDEPEND} |
1204 |
- video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) |
1205 |
- " |
1206 |
-done |
1207 |
-RDEPEND="${RDEPEND} |
1208 |
- video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) |
1209 |
-" |
1210 |
- |
1211 |
-# Please keep the LLVM dependency block separate. Since LLVM is slotted, |
1212 |
-# we need to *really* make sure we're not pulling one than more slot |
1213 |
-# simultaneously. |
1214 |
-# |
1215 |
-# How to use it: |
1216 |
-# 1. List all the working slots (with min versions) in ||, newest first. |
1217 |
-# 2. Update the := to specify *max* version, e.g. < 7. |
1218 |
-# 3. Specify LLVM_MAX_SLOT, e.g. 6. |
1219 |
-LLVM_MAX_SLOT="7" |
1220 |
-LLVM_DEPSTR=" |
1221 |
- || ( |
1222 |
- sys-devel/llvm:7[${MULTILIB_USEDEP}] |
1223 |
- sys-devel/llvm:6[${MULTILIB_USEDEP}] |
1224 |
- sys-devel/llvm:5[${MULTILIB_USEDEP}] |
1225 |
- sys-devel/llvm:4[${MULTILIB_USEDEP}] |
1226 |
- >=sys-devel/llvm-3.9.0:0[${MULTILIB_USEDEP}] |
1227 |
- ) |
1228 |
- sys-devel/llvm:=[${MULTILIB_USEDEP}] |
1229 |
-" |
1230 |
-LLVM_DEPSTR_AMDGPU=${LLVM_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
1231 |
-CLANG_DEPSTR=${LLVM_DEPSTR//llvm/clang} |
1232 |
-CLANG_DEPSTR_AMDGPU=${CLANG_DEPSTR//]/,llvm_targets_AMDGPU(-)]} |
1233 |
-RDEPEND="${RDEPEND} |
1234 |
- llvm? ( |
1235 |
- opencl? ( |
1236 |
- video_cards_r600? ( |
1237 |
- ${CLANG_DEPSTR_AMDGPU} |
1238 |
- ) |
1239 |
- !video_cards_r600? ( |
1240 |
- video_cards_radeonsi? ( |
1241 |
- ${CLANG_DEPSTR_AMDGPU} |
1242 |
- ) |
1243 |
- ) |
1244 |
- !video_cards_r600? ( |
1245 |
- !video_cards_radeonsi? ( |
1246 |
- video_cards_radeon? ( |
1247 |
- ${CLANG_DEPSTR_AMDGPU} |
1248 |
- ) |
1249 |
- ) |
1250 |
- ) |
1251 |
- !video_cards_r600? ( |
1252 |
- !video_cards_radeon? ( |
1253 |
- !video_cards_radeonsi? ( |
1254 |
- ${CLANG_DEPSTR} |
1255 |
- ) |
1256 |
- ) |
1257 |
- ) |
1258 |
- ) |
1259 |
- !opencl? ( |
1260 |
- video_cards_r600? ( |
1261 |
- ${LLVM_DEPSTR_AMDGPU} |
1262 |
- ) |
1263 |
- !video_cards_r600? ( |
1264 |
- video_cards_radeonsi? ( |
1265 |
- ${LLVM_DEPSTR_AMDGPU} |
1266 |
- ) |
1267 |
- ) |
1268 |
- !video_cards_r600? ( |
1269 |
- !video_cards_radeonsi? ( |
1270 |
- video_cards_radeon? ( |
1271 |
- ${LLVM_DEPSTR_AMDGPU} |
1272 |
- ) |
1273 |
- ) |
1274 |
- ) |
1275 |
- !video_cards_r600? ( |
1276 |
- !video_cards_radeon? ( |
1277 |
- !video_cards_radeonsi? ( |
1278 |
- ${LLVM_DEPSTR} |
1279 |
- ) |
1280 |
- ) |
1281 |
- ) |
1282 |
- ) |
1283 |
- ) |
1284 |
-" |
1285 |
-unset {LLVM,CLANG}_DEPSTR{,_AMDGPU} |
1286 |
- |
1287 |
-DEPEND="${RDEPEND} |
1288 |
- ${PYTHON_DEPS} |
1289 |
- opencl? ( |
1290 |
- >=sys-devel/gcc-4.6 |
1291 |
- ) |
1292 |
- sys-devel/bison |
1293 |
- sys-devel/flex |
1294 |
- sys-devel/gettext |
1295 |
- virtual/pkgconfig |
1296 |
- valgrind? ( dev-util/valgrind ) |
1297 |
- x11-base/xorg-proto |
1298 |
- x11-libs/libXrandr[${MULTILIB_USEDEP}] |
1299 |
- $(python_gen_any_dep ">=dev-python/mako-0.8.0[\${PYTHON_USEDEP}]") |
1300 |
-" |
1301 |
- |
1302 |
-S="${WORKDIR}/${MY_P}" |
1303 |
-EGIT_CHECKOUT_DIR=${S} |
1304 |
- |
1305 |
-QA_WX_LOAD=" |
1306 |
-x86? ( |
1307 |
- !pic? ( |
1308 |
- usr/lib*/libglapi.so.0.0.0 |
1309 |
- usr/lib*/libGLESv1_CM.so.1.0.0 |
1310 |
- usr/lib*/libGLESv2.so.2.0.0 |
1311 |
- usr/lib*/libGL.so.1.2.0 |
1312 |
- usr/lib*/libOSMesa.so.8.0.0 |
1313 |
- ) |
1314 |
-)" |
1315 |
- |
1316 |
-llvm_check_deps() { |
1317 |
- local flags=${MULTILIB_USEDEP} |
1318 |
- if use video_cards_r600 || use video_cards_radeon || use video_cards_radeonsi |
1319 |
- then |
1320 |
- flags+=",llvm_targets_AMDGPU(-)" |
1321 |
- fi |
1322 |
- |
1323 |
- if use opencl; then |
1324 |
- has_version "sys-devel/clang[${flags}]" || return 1 |
1325 |
- fi |
1326 |
- has_version "sys-devel/llvm[${flags}]" |
1327 |
-} |
1328 |
- |
1329 |
-pkg_pretend() { |
1330 |
- if use opencl; then |
1331 |
- if ! use video_cards_r600 && |
1332 |
- ! use video_cards_radeonsi; then |
1333 |
- ewarn "Ignoring USE=opencl since VIDEO_CARDS does not contain r600 or radeonsi" |
1334 |
- fi |
1335 |
- fi |
1336 |
- |
1337 |
- if use vaapi; then |
1338 |
- if ! use video_cards_r600 && |
1339 |
- ! use video_cards_radeonsi && |
1340 |
- ! use video_cards_nouveau; then |
1341 |
- ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain r600, radeonsi, or nouveau" |
1342 |
- fi |
1343 |
- fi |
1344 |
- |
1345 |
- if use vdpau; then |
1346 |
- if ! use video_cards_r300 && |
1347 |
- ! use video_cards_r600 && |
1348 |
- ! use video_cards_radeonsi && |
1349 |
- ! use video_cards_nouveau; then |
1350 |
- ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain r300, r600, radeonsi, or nouveau" |
1351 |
- fi |
1352 |
- fi |
1353 |
- |
1354 |
- if use xa; then |
1355 |
- if ! use video_cards_freedreno && |
1356 |
- ! use video_cards_nouveau && |
1357 |
- ! use video_cards_vmware; then |
1358 |
- ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware" |
1359 |
- fi |
1360 |
- fi |
1361 |
- |
1362 |
- if use xvmc; then |
1363 |
- if ! use video_cards_r600 && |
1364 |
- ! use video_cards_nouveau; then |
1365 |
- ewarn "Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau" |
1366 |
- fi |
1367 |
- fi |
1368 |
- |
1369 |
- if ! use gallium; then |
1370 |
- use lm_sensors && ewarn "Ignoring USE=lm_sensors since USE does not contain gallium" |
1371 |
- use llvm && ewarn "Ignoring USE=llvm since USE does not contain gallium" |
1372 |
- use opencl && ewarn "Ignoring USE=opencl since USE does not contain gallium" |
1373 |
- use vaapi && ewarn "Ignoring USE=vaapi since USE does not contain gallium" |
1374 |
- use vdpau && ewarn "Ignoring USE=vdpau since USE does not contain gallium" |
1375 |
- use unwind && ewarn "Ignoring USE=unwind since USE does not contain gallium" |
1376 |
- use xa && ewarn "Ignoring USE=xa since USE does not contain gallium" |
1377 |
- use xvmc && ewarn "Ignoring USE=xvmc since USE does not contain gallium" |
1378 |
- fi |
1379 |
- |
1380 |
- if ! use llvm; then |
1381 |
- use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm" |
1382 |
- fi |
1383 |
-} |
1384 |
- |
1385 |
-python_check_deps() { |
1386 |
- has_version ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]" |
1387 |
-} |
1388 |
- |
1389 |
-pkg_setup() { |
1390 |
- # warning message for bug 459306 |
1391 |
- if use llvm && has_version sys-devel/llvm[!debug=]; then |
1392 |
- ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" |
1393 |
- ewarn "detected! This can cause problems. For details, see bug 459306." |
1394 |
- fi |
1395 |
- |
1396 |
- if use llvm; then |
1397 |
- llvm_pkg_setup |
1398 |
- fi |
1399 |
- python-any-r1_pkg_setup |
1400 |
-} |
1401 |
- |
1402 |
-multilib_src_configure() { |
1403 |
- local emesonargs=() |
1404 |
- |
1405 |
- if use classic; then |
1406 |
- # Intel code |
1407 |
- dri_driver_enable video_cards_i915 i915 |
1408 |
- dri_driver_enable video_cards_i965 i965 |
1409 |
- if ! use video_cards_i915 && \ |
1410 |
- ! use video_cards_i965; then |
1411 |
- dri_driver_enable video_cards_intel i915 i965 |
1412 |
- fi |
1413 |
- |
1414 |
- # Nouveau code |
1415 |
- dri_driver_enable video_cards_nouveau nouveau |
1416 |
- |
1417 |
- # ATI code |
1418 |
- dri_driver_enable video_cards_r100 r100 |
1419 |
- dri_driver_enable video_cards_r200 r200 |
1420 |
- if ! use video_cards_r100 && \ |
1421 |
- ! use video_cards_r200; then |
1422 |
- dri_driver_enable video_cards_radeon r100 r200 |
1423 |
- fi |
1424 |
- fi |
1425 |
- |
1426 |
- emesonargs+=( -Dplatforms=x11,surfaceless$(use wayland && echo ",wayland")$(use gbm && echo ",drm") ) |
1427 |
- |
1428 |
- if use gallium; then |
1429 |
- emesonargs+=( |
1430 |
- $(meson_use llvm) |
1431 |
- $(meson_use lm_sensors lmsensors) |
1432 |
- $(meson_use unwind libunwind) |
1433 |
- ) |
1434 |
- |
1435 |
- if use video_cards_r300 || |
1436 |
- use video_cards_r600 || |
1437 |
- use video_cards_radeonsi || |
1438 |
- use video_cards_nouveau || |
1439 |
- use video_cards_vmware; then |
1440 |
- emesonargs+=($(meson_use d3d9 gallium-nine)) |
1441 |
- else |
1442 |
- emesonargs+=(-Dgallium-nine=false) |
1443 |
- fi |
1444 |
- |
1445 |
- if use video_cards_r600 || |
1446 |
- use video_cards_radeonsi || |
1447 |
- use video_cards_nouveau; then |
1448 |
- emesonargs+=($(meson_use vaapi gallium-va)) |
1449 |
- use vaapi && emesonargs+=( -Dva-libs-path=/usr/$(get_libdir)/va/drivers ) |
1450 |
- else |
1451 |
- emesonargs+=(-Dgallium-va=false) |
1452 |
- fi |
1453 |
- |
1454 |
- if use video_cards_r300 || |
1455 |
- use video_cards_r600 || |
1456 |
- use video_cards_radeonsi || |
1457 |
- use video_cards_nouveau; then |
1458 |
- emesonargs+=($(meson_use vdpau gallium-vdpau)) |
1459 |
- else |
1460 |
- emesonargs+=(-Dgallium-vdpau=false) |
1461 |
- fi |
1462 |
- |
1463 |
- if use video_cards_freedreno || |
1464 |
- use video_cards_nouveau || |
1465 |
- use video_cards_vmware; then |
1466 |
- emesonargs+=($(meson_use xa gallium-xa)) |
1467 |
- else |
1468 |
- emesonargs+=(-Dgallium-xa=false) |
1469 |
- fi |
1470 |
- |
1471 |
- if use video_cards_r600 || |
1472 |
- use video_cards_nouveau; then |
1473 |
- emesonargs+=($(meson_use xvmc gallium-xvmc)) |
1474 |
- else |
1475 |
- emesonargs+=(-Dgallium-xvmc=false) |
1476 |
- fi |
1477 |
- |
1478 |
- gallium_enable video_cards_vc4 vc4 |
1479 |
- gallium_enable video_cards_vivante etnaviv |
1480 |
- gallium_enable video_cards_vmware svga |
1481 |
- gallium_enable video_cards_nouveau nouveau |
1482 |
- gallium_enable video_cards_imx imx |
1483 |
- |
1484 |
- # Only one i915 driver (classic vs gallium). Default to classic. |
1485 |
- if ! use classic; then |
1486 |
- gallium_enable video_cards_i915 i915 |
1487 |
- if ! use video_cards_i915 && \ |
1488 |
- ! use video_cards_i965; then |
1489 |
- gallium_enable video_cards_intel i915 |
1490 |
- fi |
1491 |
- fi |
1492 |
- |
1493 |
- gallium_enable video_cards_r300 r300 |
1494 |
- gallium_enable video_cards_r600 r600 |
1495 |
- gallium_enable video_cards_radeonsi radeonsi |
1496 |
- if ! use video_cards_r300 && \ |
1497 |
- ! use video_cards_r600; then |
1498 |
- gallium_enable video_cards_radeon r300 r600 |
1499 |
- fi |
1500 |
- |
1501 |
- gallium_enable video_cards_freedreno freedreno |
1502 |
- gallium_enable video_cards_virgl virgl |
1503 |
- |
1504 |
- # opencl stuff |
1505 |
- emesonargs+=( |
1506 |
- -Dgallium-opencl="$(usex opencl icd disabled)" |
1507 |
- ) |
1508 |
- fi |
1509 |
- |
1510 |
- if use vulkan; then |
1511 |
- vulkan_enable video_cards_i965 intel |
1512 |
- vulkan_enable video_cards_radeonsi amd |
1513 |
- fi |
1514 |
- |
1515 |
- # x86 hardened pax_kernel needs glx-rts, bug 240956 |
1516 |
- if [[ ${ABI} == x86 ]]; then |
1517 |
- emesonargs+=( $(meson_use pax_kernel glx-read-only-text) ) |
1518 |
- fi |
1519 |
- |
1520 |
- # on abi_x86_32 hardened we need to have asm disable |
1521 |
- if [[ ${ABI} == x86* ]] && use pic; then |
1522 |
- emesonargs+=( -Dasm=false ) |
1523 |
- fi |
1524 |
- |
1525 |
- if use gallium; then |
1526 |
- gallium_enable -- swrast |
1527 |
- emesonargs+=( -Dosmesa=$(usex osmesa gallium none) ) |
1528 |
- else |
1529 |
- dri_driver_enable -- swrast |
1530 |
- emesonargs+=( -Dosmesa=$(usex osmesa classic none) ) |
1531 |
- fi |
1532 |
- |
1533 |
- driver_list() { |
1534 |
- local drivers="$(sort -u <<< "${1// /$'\n'}")" |
1535 |
- echo "${drivers//$'\n'/,}" |
1536 |
- } |
1537 |
- |
1538 |
- emesonargs+=( |
1539 |
- $(meson_use test build-tests) |
1540 |
- -Dglx=dri |
1541 |
- -Dshared-glapi=true |
1542 |
- $(meson_use dri3) |
1543 |
- $(meson_use egl) |
1544 |
- $(meson_use gbm) |
1545 |
- $(meson_use gles1) |
1546 |
- $(meson_use gles2) |
1547 |
- $(meson_use selinux) |
1548 |
- -Dvalgrind=$(usex valgrind auto false) |
1549 |
- -Ddri-drivers=$(driver_list "${DRI_DRIVERS[*]}") |
1550 |
- -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}") |
1551 |
- -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}") |
1552 |
- --buildtype $(usex debug debug plain) |
1553 |
- -Db_ndebug=$(usex debug false true) |
1554 |
- ) |
1555 |
- meson_src_configure |
1556 |
-} |
1557 |
- |
1558 |
-multilib_src_compile() { |
1559 |
- meson_src_compile |
1560 |
-} |
1561 |
- |
1562 |
-multilib_src_install() { |
1563 |
- meson_src_install |
1564 |
-} |
1565 |
- |
1566 |
-multilib_src_install_all() { |
1567 |
- einstalldocs |
1568 |
-} |
1569 |
- |
1570 |
-multilib_src_test() { |
1571 |
- meson_src_test |
1572 |
-} |
1573 |
- |
1574 |
-pkg_postinst() { |
1575 |
- # Switch to the xorg implementation. |
1576 |
- echo |
1577 |
- eselect opengl set --use-old ${OPENGL_DIR} |
1578 |
-} |
1579 |
- |
1580 |
-# $1 - VIDEO_CARDS flag (check skipped for "--") |
1581 |
-# other args - names of DRI drivers to enable |
1582 |
-dri_driver_enable() { |
1583 |
- if [[ $1 == -- ]] || use $1; then |
1584 |
- shift |
1585 |
- DRI_DRIVERS+=("$@") |
1586 |
- fi |
1587 |
-} |
1588 |
- |
1589 |
-gallium_enable() { |
1590 |
- if [[ $1 == -- ]] || use $1; then |
1591 |
- shift |
1592 |
- GALLIUM_DRIVERS+=("$@") |
1593 |
- fi |
1594 |
-} |
1595 |
- |
1596 |
-vulkan_enable() { |
1597 |
- if [[ $1 == -- ]] || use $1; then |
1598 |
- shift |
1599 |
- VULKAN_DRIVERS+=("$@") |
1600 |
- fi |
1601 |
-} |