1 |
rtp |
18133 |
%define bootstrap 0 |
2 |
|
|
%{?_without_bootstrap: %global bootstrap 0} |
3 |
|
|
%{?_with_bootstrap: %global bootstrap 1} |
4 |
|
|
|
5 |
tv |
135155 |
%if "%distro_section" == "tainted" |
6 |
|
|
%global build_plf 1 |
7 |
|
|
%else |
8 |
|
|
%global build_plf 0 |
9 |
|
|
%endif |
10 |
|
|
|
11 |
pterjan |
5340 |
# (cg) Cheater... |
12 |
|
|
%define Werror_cflags %nil |
13 |
|
|
|
14 |
|
|
# (aco) Needed for the dri drivers |
15 |
|
|
%define _disable_ld_no_undefined 1 |
16 |
|
|
|
17 |
cjw |
398478 |
# http://cgit.freedesktop.org/mesa/mesa/commit/?h=9.1&id=38e728498b8ef63bb7dce77c64af11c98ec2efa4 |
18 |
tmb |
400079 |
%define git 0 |
19 |
tv |
469145 |
%define git_branch 9.2 |
20 |
mikala |
112356 |
%define with_hardware 1 |
21 |
|
|
|
22 |
blino |
289603 |
%define opengl_ver 3.0 |
23 |
blino |
289598 |
|
24 |
tv |
600225 |
%define relc 0 |
25 |
pterjan |
5340 |
%define name mesa |
26 |
tv |
585816 |
%define fversion 10.1.0 |
27 |
|
|
%define version 10.1.0 |
28 |
tv |
586838 |
%define rel 2 |
29 |
pterjan |
5340 |
|
30 |
|
|
%define release %mkrel %{rel} |
31 |
|
|
%define src_type tar.bz2 |
32 |
tv |
173693 |
#define vsuffix %{expand:} |
33 |
|
|
%define vsuffix %nil |
34 |
pterjan |
5340 |
|
35 |
|
|
%if %{relc} |
36 |
|
|
%define release %mkrel 0.rc%{relc}.%{rel} |
37 |
|
|
%define vsuffix -rc%{relc} |
38 |
|
|
%define src_type tar.bz2 |
39 |
|
|
%endif |
40 |
|
|
|
41 |
|
|
%if %{git} |
42 |
|
|
%if %{relc} |
43 |
mikala |
123310 |
%define release %mkrel 0.rc%{relc}.1.git%{git}.%{rel} |
44 |
pterjan |
5340 |
%else |
45 |
|
|
%define release %mkrel 0.git%{git}.%{rel} |
46 |
|
|
%endif |
47 |
|
|
%endif |
48 |
|
|
|
49 |
|
|
%define makedepend %{_bindir}/gccmakedep |
50 |
|
|
|
51 |
|
|
%define eglname mesaegl |
52 |
|
|
%define glname mesagl |
53 |
|
|
%define glwname mesaglw |
54 |
tv |
88442 |
%define glesv1name mesaglesv1 |
55 |
|
|
%define glesv2name mesaglesv2 |
56 |
tv |
88445 |
%define openvgname mesaopenvg |
57 |
mikala |
112356 |
%define glapiname glapi |
58 |
blino |
215979 |
%define gbmname gbm |
59 |
|
|
%define waylandeglname wayland-egl |
60 |
tv |
88442 |
|
61 |
pterjan |
5340 |
%define eglmajor 1 |
62 |
|
|
%define glmajor 1 |
63 |
|
|
%define glwmajor 1 |
64 |
tv |
88442 |
%define glesv1major 1 |
65 |
|
|
%define glesv2major 2 |
66 |
tv |
88445 |
%define openvgmajor 1 |
67 |
mikala |
112356 |
%define glapimajor 0 |
68 |
blino |
215979 |
%define gbmmajor 1 |
69 |
|
|
%define waylandeglmajor 1 |
70 |
blino |
289617 |
%define osmesamajor 8 |
71 |
tv |
88442 |
|
72 |
pterjan |
5340 |
%define libeglname %mklibname %{eglname} %{eglmajor} |
73 |
|
|
%define libglname %mklibname %{glname} %{glmajor} |
74 |
|
|
%define libglwname %mklibname %{glwname} %{glwmajor} |
75 |
tv |
88442 |
%define libglesv1name %mklibname %{glesv1name}_ %{glesv1major} |
76 |
|
|
%define libglesv2name %mklibname %{glesv2name}_ %{glesv2major} |
77 |
tv |
88445 |
%define libopenvgname %mklibname %{openvgname} %{openvgmajor} |
78 |
mikala |
112356 |
%define libglapiname %mklibname %{glapiname} %{glapimajor} |
79 |
blino |
215979 |
%define libgbmname %mklibname %{gbmname} %{gbmmajor} |
80 |
|
|
%define libwaylandeglname %mklibname %{waylandeglname} %{waylandeglmajor} |
81 |
anssi |
278008 |
%define libosmesaname %mklibname osmesa %{osmesamajor} |
82 |
pterjan |
5340 |
|
83 |
|
|
%define dridrivers %mklibname dri-drivers |
84 |
|
|
|
85 |
anssi |
278008 |
%define osmesadevel %mklibname osmesa -d |
86 |
|
|
|
87 |
pterjan |
5340 |
# Architecture-independent Virtual provides: |
88 |
|
|
%define libeglname_virt lib%{eglname} |
89 |
|
|
%define libglname_virt lib%{glname} |
90 |
|
|
%define libglwname_virt lib%{glwname} |
91 |
tv |
88442 |
%define libglesv1name_virt lib%{glesv1name} |
92 |
|
|
%define libglesv2name_virt lib%{glesv2name} |
93 |
tv |
88445 |
%define libopenvgname_virt lib%{openvgname} |
94 |
mikala |
112356 |
%define libglapiname_virt lib%{glapiname} |
95 |
blino |
215979 |
%define libgbmname_virt lib%{gbmname} |
96 |
|
|
%define libwaylandeglname_virt lib%{waylandeglname} |
97 |
pterjan |
5340 |
|
98 |
|
|
%define oldlibglname %mklibname MesaGL 1 |
99 |
|
|
|
100 |
|
|
%define mesasrcdir %{_prefix}/src/Mesa/ |
101 |
|
|
%define driver_dir %{_libdir}/dri |
102 |
|
|
|
103 |
tv |
88451 |
%define enable_egl 1 |
104 |
blino |
215979 |
%define enable_wayland 1 |
105 |
pterjan |
5340 |
|
106 |
|
|
#FIXME: (for 386/485) unset SSE, MMX and 3dnow flags |
107 |
|
|
#FIXME: (for >=i586) disable sse |
108 |
|
|
# SSE seems to have problem on some apps (gtulpas) for probing. |
109 |
tv |
207029 |
%define dri_drivers_i386 "i915,i965,nouveau,r200,radeon,swrast" |
110 |
pterjan |
5340 |
%define dri_drivers_x86_64 %{dri_drivers_i386} |
111 |
tv |
207029 |
%define dri_drivers_ppc "r200,radeon,swrast" |
112 |
pterjan |
5340 |
%define dri_drivers_ppc64 "" |
113 |
tv |
207029 |
%define dri_drivers_ia64 "i915,i965,mga,r200,radeon,swrast" |
114 |
|
|
%define dri_drivers_alpha "r200,radeon,swrast" |
115 |
|
|
%define dri_drivers_sparc "ffb,radeon,swrast" |
116 |
|
|
%define dri_drivers_mipsel "r200,radeon,swrast" |
117 |
rtp |
302732 |
%define dri_drivers_arm "nouveau,r200,radeon,swrast" |
118 |
pterjan |
5340 |
%define dri_drivers %{expand:%{dri_drivers_%{_arch}}} |
119 |
|
|
|
120 |
|
|
Name: %{name} |
121 |
|
|
Version: %{version} |
122 |
|
|
Release: %{release} |
123 |
blino |
289598 |
Summary: OpenGL %{opengl_ver} compatible 3D graphics library |
124 |
pterjan |
5340 |
Group: System/Libraries |
125 |
|
|
|
126 |
mikala |
127466 |
BuildRequires: pkgconfig(xfixes) >= 4.0.3 |
127 |
tv |
585816 |
BuildRequires: pkgconfig(xshmfence) |
128 |
mikala |
127466 |
BuildRequires: pkgconfig(xt) >= 1.0.5 |
129 |
|
|
BuildRequires: pkgconfig(xmu) >= 1.0.3 |
130 |
|
|
BuildRequires: pkgconfig(x11) >= 1.3.3 |
131 |
|
|
BuildRequires: pkgconfig(xdamage) >= 1.1.1 |
132 |
pterjan |
5340 |
BuildRequires: libexpat-devel >= 2.0.1 |
133 |
|
|
BuildRequires: gccmakedep |
134 |
|
|
BuildRequires: x11-proto-devel >= 7.3 |
135 |
tv |
585820 |
BuildRequires: pkgconfig(libdrm) >= 2.4.52 |
136 |
pterjan |
5340 |
|
137 |
tv |
585825 |
BuildRequires: pkgconfig(xcb-dri3) |
138 |
|
|
BuildRequires: pkgconfig(xcb-present) |
139 |
mikala |
127466 |
BuildRequires: pkgconfig(xext) >= 1.1.1 |
140 |
|
|
BuildRequires: pkgconfig(xxf86vm) >= 1.1.0 |
141 |
|
|
BuildRequires: pkgconfig(xi) >= 1.3 |
142 |
|
|
BuildRequires: pkgconfig(talloc) |
143 |
tv |
88443 |
BuildRequires: libxml2-python |
144 |
tmb |
35532 |
BuildRequires: makedepend |
145 |
dmorgan |
106004 |
BuildRequires: bison flex |
146 |
tv |
469143 |
BuildRequires: libelf-devel |
147 |
tv |
586838 |
BuildRequires: llvm-devel > 3.4-1 |
148 |
mikala |
127466 |
BuildRequires: pkgconfig(libudev) |
149 |
blino |
270761 |
BuildRequires: pkgconfig(vdpau) |
150 |
blino |
215979 |
%if %{enable_wayland} |
151 |
|
|
BuildRequires: wayland-devel |
152 |
|
|
%endif |
153 |
pterjan |
5340 |
|
154 |
|
|
URL: http://www.mesa3d.org |
155 |
|
|
%if %{git} |
156 |
cjw |
336175 |
Source0: %{name}-%{git}.tar.bz2 |
157 |
blino |
289278 |
# (blino) snapshot of 9.0 branch |
158 |
cjw |
336175 |
#Source0: %{name}-%{git_branch}-%{git}.tar.bz2 |
159 |
pterjan |
5340 |
%else |
160 |
tv |
303797 |
Source0: ftp://ftp.freedesktop.org/pub/mesa/%version/MesaLib-%{fversion}%{vsuffix}.%{src_type} |
161 |
pterjan |
5340 |
%endif |
162 |
|
|
Source3: make-git-snapshot.sh |
163 |
tmb |
491931 |
# (tmb) disable as it breaks the build |
164 |
|
|
#Patch0: MesaLib-9.2.0-rc1-automake-1.14.patch |
165 |
pterjan |
5340 |
|
166 |
|
|
# Instructions to setup your repository clone |
167 |
|
|
# git://git.freedesktop.org/git/mesa/mesa |
168 |
|
|
# git checkout mesa_7_5_branch |
169 |
|
|
# git branch mdv-cherry-picks |
170 |
|
|
# git am ../02??-*.patch |
171 |
|
|
# git branch mdv-redhat |
172 |
|
|
# git am ../03??-*.patch |
173 |
|
|
# git branch mdv-patches |
174 |
|
|
# git am ../09??-*.patch |
175 |
|
|
# In order to update to the branch via patches, issue this command: |
176 |
|
|
# git format-patch --start-number 100 mesa_7_5_1..mesa_7_5_branch | sed 's/^0\([0-9]\+\)-/Patch\1: 0\1-/' |
177 |
|
|
|
178 |
tmb |
564877 |
# Upstream git |
179 |
|
|
|
180 |
pterjan |
5340 |
# Cherry picks |
181 |
|
|
# git format-patch --start-number 200 mesa_7_5_branch..mdv-cherry-picks |
182 |
|
|
Patch201: 0201-revert-fix-glxinitializevisualconfigfromtags-handling.patch |
183 |
tmb |
411326 |
|
184 |
blino |
289280 |
# (blino) should be pushed to 9.0 branch upstream |
185 |
tv |
303796 |
#Patch202: 0202-radeon-llvm-Cleanup-makefile.patch |
186 |
|
|
#Patch203: 0203-radeon-llvm-Remove-R600InstrInfo.td-from-TD_FILES.patch |
187 |
pterjan |
5340 |
|
188 |
tv |
88247 |
# Patches "liberated" from Fedora: |
189 |
pterjan |
5340 |
# http://cvs.fedoraproject.org/viewvc/rpms/mesa/devel/ |
190 |
|
|
# git format-patch --start-number 300 mdv-cherry-picks..mdv-redhat |
191 |
|
|
|
192 |
blino |
278732 |
# Patches from ChromiumOS |
193 |
|
|
# http://git.chromium.org/gitweb/?p=chromiumos/overlays/chromiumos-overlay.git;a=tree;f=media-libs/mesa/files;hb=HEAD |
194 |
|
|
|
195 |
blino |
271493 |
# Mageia/Mandriva patches |
196 |
pterjan |
5340 |
# git format-patch --start-number 900 mdv-redhat..mdv-patches |
197 |
blino |
271493 |
# (blino) llvmpipe test programs link fails when ld --as-needed option is used, reported as fdo #52167 |
198 |
cjw |
388874 |
#Patch901: 0901-gallium-only-link-static-archives-between-ld-start-e.patch |
199 |
pterjan |
5340 |
|
200 |
tv |
88440 |
#------------------------------------------------------------------------------ |
201 |
|
|
|
202 |
|
|
# package mesa |
203 |
pterjan |
5340 |
License: MIT |
204 |
|
|
Requires: %{libglname} = %{version}-%{release} |
205 |
|
|
Provides: hackMesa = %{version} |
206 |
|
|
Obsoletes: hackMesa <= %{version} |
207 |
|
|
Provides: Mesa = %{version} |
208 |
|
|
Obsoletes: Mesa < %{version} |
209 |
|
|
|
210 |
|
|
%package -n %{libglname} |
211 |
|
|
Summary: Files for Mesa (GL and GLX libs) |
212 |
|
|
Group: System/Libraries |
213 |
tv |
88247 |
Obsoletes: %{oldlibglname} < 6.4 |
214 |
pterjan |
5340 |
Provides: %{oldlibglname} = %{version}-%{release} |
215 |
|
|
Provides: %{libglname_virt} = %{version}-%{release} |
216 |
|
|
Requires: %{dridrivers} >= %{version}-%{release} |
217 |
tv |
135172 |
%if %{build_plf} |
218 |
|
|
Requires: %mklibname txc-dxtn |
219 |
|
|
%endif |
220 |
pterjan |
5340 |
|
221 |
|
|
# (anssi) Forces the upgrade of x11-server-common to happen before |
222 |
|
|
# alternatives removal, which allows x11-server-common to grab the symlink. |
223 |
|
|
Conflicts: x11-server-common < 1.3.0.0-17 |
224 |
|
|
|
225 |
|
|
%package -n %{dridrivers} |
226 |
|
|
Summary: Mesa DRI drivers |
227 |
|
|
Group: System/Libraries |
228 |
blino |
274132 |
# do not require exact release to avoid conflicts when having |
229 |
|
|
# x86_64 dri drivers from tainted and i586 dri drivers from core |
230 |
|
|
Requires: mesa = %{version} |
231 |
pterjan |
5340 |
Conflicts: %{_lib}MesaGL1 < 7.7-5 |
232 |
anssi |
181478 |
Obsoletes: %{_lib}dri-drivers-experimental < 7.11.2-4 |
233 |
|
|
Provides: %{_lib}dri-drivers-experimental = %{version}-%{release} |
234 |
pterjan |
5340 |
|
235 |
|
|
%package -n %{libglname}-devel |
236 |
|
|
Summary: Development files for Mesa (OpenGL compatible 3D lib) |
237 |
|
|
Group: Development/C |
238 |
tv |
88237 |
Requires: %{libglname} = %{version}-%{release} |
239 |
pterjan |
5340 |
Provides: lib%{glname}-devel = %{version}-%{release} |
240 |
|
|
Provides: %{glname}-devel = %{version}-%{release} |
241 |
|
|
Provides: GL-devel |
242 |
|
|
Obsoletes: %{oldlibglname}-devel < 6.4 |
243 |
|
|
Provides: %{oldlibglname}-devel = %{version}-%{release} |
244 |
|
|
Provides: libMesaGL-devel = %{version}-%{release} |
245 |
|
|
Provides: MesaGL-devel = %{version}-%{release} |
246 |
tv |
88438 |
Provides: libgl-devel |
247 |
pterjan |
5340 |
|
248 |
tv |
88433 |
%if %{enable_egl} |
249 |
|
|
%package -n %{libeglname} |
250 |
|
|
Summary: Files for Mesa (EGL libs) |
251 |
|
|
Group: System/Libraries |
252 |
|
|
Provides: %{libeglname_virt} = %{version}-%{release} |
253 |
|
|
|
254 |
|
|
%package -n %{libeglname}-devel |
255 |
|
|
Summary: Development files for Mesa (EGL libs) |
256 |
|
|
Group: Development/C |
257 |
tv |
88439 |
Requires: %{libeglname} = %{version}-%{release} |
258 |
tv |
88433 |
Provides: EGL-devel |
259 |
tv |
88438 |
Provides: lib%{eglname}-devel |
260 |
|
|
Provides: %{eglname}-devel |
261 |
|
|
Provides: libegl-devel |
262 |
tv |
88433 |
%endif |
263 |
|
|
|
264 |
anssi |
278008 |
%package -n %{libosmesaname} |
265 |
|
|
Summary: Mesa offscreen rendering library |
266 |
|
|
Group: System/Libraries |
267 |
|
|
|
268 |
|
|
%package -n %{osmesadevel} |
269 |
|
|
Summary: Development files for libosmesa |
270 |
|
|
Group: Development/C |
271 |
|
|
Requires: %{libosmesaname} = %{version}-%{release} |
272 |
|
|
Provides: osmesa-devel = %{version}-%{release} |
273 |
|
|
Conflicts: MesaGL-devel < 8.1.0-0.git20120727.3 |
274 |
|
|
|
275 |
mikala |
112356 |
%package -n %{libglapiname} |
276 |
|
|
Summary: Files for mesa (glapi libs) |
277 |
|
|
Group: System/Libraries |
278 |
|
|
Provides: %{libglapiname_virt} = %{version}-%{release} |
279 |
tv |
88442 |
|
280 |
mikala |
112356 |
%package -n %{libglapiname}-devel |
281 |
|
|
Summary: Development files for glapi libs |
282 |
|
|
Group: Development/C |
283 |
|
|
Requires: %{libglapiname_virt} = %{version}-%{release} |
284 |
|
|
Provides: lib%{glapiname}-devel |
285 |
|
|
Provides: %{libglapiname}-devel |
286 |
|
|
|
287 |
tv |
88442 |
%package -n %{libglesv1name} |
288 |
|
|
Summary: Files for Mesa (glesv1 libs) |
289 |
|
|
Group: System/Libraries |
290 |
|
|
Provides: %{libglesv1name_virt} = %{version}-%{release} |
291 |
|
|
|
292 |
|
|
%package -n %{libglesv1name}-devel |
293 |
|
|
Summary: Development files for glesv1 libs |
294 |
|
|
Group: Development/C |
295 |
|
|
Requires: %{libglesv1name} = %{version}-%{release} |
296 |
|
|
Provides: lib%{glesv1name}-devel |
297 |
|
|
Provides: %{glesv1name}-devel |
298 |
|
|
Provides: libglesv1-devel |
299 |
|
|
|
300 |
|
|
%package -n %{libglesv2name} |
301 |
|
|
Summary: Files for Mesa (glesv2 libs) |
302 |
|
|
Group: System/Libraries |
303 |
|
|
Provides: %{libglesv2name_virt} = %{version}-%{release} |
304 |
|
|
|
305 |
|
|
%package -n %{libglesv2name}-devel |
306 |
|
|
Summary: Development files for glesv2 libs |
307 |
|
|
Group: Development/C |
308 |
|
|
Requires: %{libglesv2name} = %{version}-%{release} |
309 |
blino |
216556 |
Requires: %{libeglname}-devel = %{version}-%{release} |
310 |
tv |
88442 |
Provides: lib%{glesv2name}-devel |
311 |
|
|
Provides: %{glesv2name}-devel |
312 |
|
|
Provides: libglesv2-devel |
313 |
|
|
|
314 |
tv |
88445 |
%package -n %{libopenvgname} |
315 |
|
|
Summary: Files for MESA (OpenVG libs) |
316 |
|
|
Group: System/Libraries |
317 |
|
|
Provides: %{libopenvgname_virt} = %{version}-%{release} |
318 |
|
|
|
319 |
|
|
%package -n %{libopenvgname}-devel |
320 |
|
|
Summary: Development files vor OpenVG libs |
321 |
|
|
Group: Development/C |
322 |
|
|
Requires: %{libopenvgname} = %{version}-%{release} |
323 |
|
|
Provides: lib%{openvgname}-devel |
324 |
|
|
Provides: %{openvgname}-devel |
325 |
|
|
Provides: libopenvg-devel |
326 |
|
|
|
327 |
blino |
215979 |
%if %{enable_wayland} |
328 |
|
|
%package -n %{libgbmname} |
329 |
|
|
Summary: Files for Mesa (gbm libs) |
330 |
|
|
Group: System/Libraries |
331 |
|
|
Provides: %{libgbmname_virt} = %{version}-%{release} |
332 |
|
|
|
333 |
|
|
%package -n %{libgbmname}-devel |
334 |
|
|
Summary: Development files for Mesa (gbm libs) |
335 |
|
|
Group: Development/C |
336 |
|
|
Requires: %{libgbmname} = %{version}-%{release} |
337 |
|
|
Provides: lib%{gbmname}-devel |
338 |
|
|
Provides: %{gbmname}-devel |
339 |
|
|
|
340 |
|
|
%package -n %{libwaylandeglname} |
341 |
|
|
Summary: Files for Mesa (Wayland EGL libs) |
342 |
|
|
Group: System/Libraries |
343 |
|
|
Provides: %{libwaylandeglname_virt} = %{version}-%{release} |
344 |
|
|
|
345 |
|
|
%package -n %{libwaylandeglname}-devel |
346 |
|
|
Summary: Development files for Mesa (Wayland EGL libs) |
347 |
|
|
Group: Development/C |
348 |
|
|
Requires: %{libwaylandeglname} = %{version}-%{release} |
349 |
|
|
Provides: lib%{waylandeglname}-devel |
350 |
|
|
Provides: %{waylandeglname}-devel |
351 |
|
|
%endif |
352 |
|
|
|
353 |
tv |
301233 |
%package -n %{_lib}vdpau-driver-nouveau |
354 |
blino |
270761 |
Summary: VDPAU plugin for nouveau driver |
355 |
blino |
300616 |
Group: System/Libraries |
356 |
tv |
302568 |
# temporary: |
357 |
|
|
%rename vdpau-driver-nouveau |
358 |
blino |
270761 |
|
359 |
tv |
301233 |
%package -n %{_lib}vdpau-driver-r600 |
360 |
blino |
270761 |
Summary: VDPAU plugin for r600 driver |
361 |
blino |
300616 |
Group: System/Libraries |
362 |
tv |
302568 |
# temporary: |
363 |
|
|
%rename vdpau-driver-r600 |
364 |
blino |
270761 |
|
365 |
tv |
301233 |
%package -n %{_lib}vdpau-driver-radeonsi |
366 |
blino |
289282 |
Summary: VDPAU plugin for radeonsi driver |
367 |
|
|
Group: System/Libraries |
368 |
tv |
302568 |
# temporary: |
369 |
|
|
%rename vdpau-driver-radeonsi |
370 |
blino |
289282 |
|
371 |
pterjan |
5340 |
%package common-devel |
372 |
|
|
Summary: Meta package for mesa devel |
373 |
|
|
Group: Development/C |
374 |
tv |
88247 |
Provides: Mesa-common-devel = %{version}-%{release} |
375 |
pterjan |
5340 |
Provides: hackMesa-common-devel = %{version} |
376 |
tv |
88247 |
Obsoletes: Mesa-common-devel < %{version} |
377 |
pterjan |
5340 |
Obsoletes: hackMesa-common-devel < %{version} |
378 |
|
|
Requires: %{libglname}-devel = %{version} |
379 |
blino |
289355 |
Requires: mesaglu-devel |
380 |
tv |
135156 |
Requires: freeglut-devel |
381 |
tv |
88442 |
Requires: %{libeglname}-devel = %{version} |
382 |
|
|
Requires: %{libglesv1name}-devel = %{version} |
383 |
|
|
Requires: %{libglesv2name}-devel = %{version} |
384 |
pterjan |
5340 |
|
385 |
tv |
88440 |
#------------------------------------------------------------------------------ |
386 |
pterjan |
5340 |
|
387 |
|
|
%description |
388 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
389 |
tv |
135173 |
%if %{build_plf} |
390 |
pterjan |
5340 |
|
391 |
tv |
135173 |
This package is in the "tainted" section because it enables some |
392 |
|
|
OpenGL extentions that are covered by software patents. |
393 |
|
|
%endif |
394 |
|
|
|
395 |
pterjan |
5340 |
%description common-devel |
396 |
|
|
Mesa common metapackage devel |
397 |
|
|
|
398 |
|
|
%if %{enable_egl} |
399 |
|
|
%description -n %{libeglname} |
400 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
401 |
pterjan |
5340 |
EGL parts. |
402 |
|
|
|
403 |
|
|
%description -n %{libeglname}-devel |
404 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
405 |
pterjan |
5340 |
EGL development parts. |
406 |
|
|
%endif |
407 |
|
|
|
408 |
|
|
%description -n %{libglname} |
409 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
410 |
pterjan |
5340 |
GL and GLX parts. |
411 |
|
|
|
412 |
tv |
135155 |
%if %{build_plf} |
413 |
|
|
This package is in the "tainted" section because it enables some |
414 |
|
|
OpenGL extentions that are covered by software patents. |
415 |
|
|
%endif |
416 |
|
|
|
417 |
pterjan |
5340 |
%description -n %{dridrivers} |
418 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
419 |
pterjan |
5340 |
DRI drivers. |
420 |
|
|
|
421 |
|
|
%description -n %{libglname}-devel |
422 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
423 |
pterjan |
5340 |
|
424 |
|
|
This package contains the headers needed to compile Mesa programs. |
425 |
|
|
|
426 |
tv |
88442 |
%description -n %{libglesv1name} |
427 |
|
|
OpenGL ES is a low-level, lightweight API for advanced embedded graphics using |
428 |
|
|
well-defined subset profiles of OpenGL. |
429 |
|
|
|
430 |
|
|
This package provides the OpenGL ES library version 1. |
431 |
|
|
|
432 |
anssi |
278008 |
%description -n %{libosmesaname} |
433 |
|
|
Mesa offscreen rendering libraries for rendering OpenGL into |
434 |
|
|
application-allocated blocks of memory. |
435 |
|
|
|
436 |
|
|
%description -n %{osmesadevel} |
437 |
|
|
This package contains the headers needed to compile programs against |
438 |
|
|
the Mesa offscreen rendering library. |
439 |
|
|
|
440 |
mikala |
112356 |
%description -n %{libglapiname} |
441 |
|
|
This packages provides the glapi shared library used by gallium. |
442 |
|
|
|
443 |
|
|
%description -n %{libglapiname}-devel |
444 |
|
|
This package contains the headers needed to compile programes against glapi shared library. |
445 |
|
|
|
446 |
tv |
88442 |
%description -n %{libglesv1name}-devel |
447 |
|
|
This package contains the headers needed to compile OpenGL ES 1 programs. |
448 |
|
|
|
449 |
|
|
%description -n %{libglesv2name} |
450 |
|
|
OpenGL ES is a low-level, lightweight API for advanced embedded graphics using |
451 |
|
|
well-defined subset profiles of OpenGL. |
452 |
|
|
|
453 |
|
|
This package provides the OpenGL ES library version 2. |
454 |
|
|
|
455 |
|
|
%description -n %{libglesv2name}-devel |
456 |
|
|
This package contains the headers needed to compile OpenGL ES 2 programs. |
457 |
|
|
|
458 |
tv |
88445 |
%description -n %{libopenvgname} |
459 |
|
|
OpenVG is a royalty-free, cross-platform API that provides a low-level hardware |
460 |
|
|
acceleration interface for vector graphics libraries such as Flash and SVG. |
461 |
|
|
|
462 |
|
|
%description -n %{libopenvgname}-devel |
463 |
|
|
Development files for OpenVG library. |
464 |
|
|
|
465 |
blino |
215979 |
%if %{enable_wayland} |
466 |
|
|
%description -n %{libgbmname} |
467 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
468 |
blino |
215979 |
GBM (Graphics Buffer Manager) parts. |
469 |
|
|
|
470 |
|
|
%description -n %{libgbmname}-devel |
471 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
472 |
blino |
215979 |
GBM (Graphics Buffer Manager) development parts. |
473 |
|
|
|
474 |
|
|
%description -n %{libwaylandeglname} |
475 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
476 |
blino |
215979 |
Wayland EGL platform parts. |
477 |
|
|
|
478 |
|
|
%description -n %{libwaylandeglname}-devel |
479 |
blino |
289598 |
Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library. |
480 |
blino |
215979 |
Wayland EGL platform development parts. |
481 |
|
|
%endif |
482 |
|
|
|
483 |
tv |
301233 |
%description -n %{_lib}vdpau-driver-nouveau |
484 |
blino |
270761 |
This packages provides a VPDAU plugin to enable video acceleration |
485 |
|
|
with the nouveau driver. |
486 |
|
|
|
487 |
tv |
301233 |
%description -n %{_lib}vdpau-driver-r600 |
488 |
blino |
270761 |
This packages provides a VPDAU plugin to enable video acceleration |
489 |
|
|
with the r600 driver. |
490 |
|
|
|
491 |
tv |
301233 |
%description -n %{_lib}vdpau-driver-radeonsi |
492 |
blino |
289282 |
This packages provides a VPDAU plugin to enable video acceleration |
493 |
|
|
with the radeonsi driver. |
494 |
|
|
|
495 |
tv |
88440 |
#------------------------------------------------------------------------------ |
496 |
|
|
|
497 |
pterjan |
5340 |
%prep |
498 |
|
|
%if %{git} |
499 |
cjw |
336175 |
%setup -q -n mesa-%{git} |
500 |
|
|
#setup -q -n mesa-%{git_branch}-%{git} |
501 |
pterjan |
5340 |
%else |
502 |
tv |
303797 |
%setup -q -n Mesa-%{fversion}%{vsuffix} |
503 |
pterjan |
5340 |
%endif |
504 |
|
|
|
505 |
blino |
278731 |
%apply_patches |
506 |
pterjan |
5340 |
|
507 |
anssi |
332631 |
# Duplicate source tree for OSMesa, since building both versions out-of-tree |
508 |
|
|
# would break build. - Anssi 12/2012 |
509 |
cjw |
336233 |
all=$(ls) |
510 |
|
|
mkdir -p build-osmesa |
511 |
|
|
cp -al $all build-osmesa |
512 |
anssi |
332631 |
|
513 |
pterjan |
5340 |
%build |
514 |
cjw |
336175 |
# (re)generate auto* generated files using our autotools and libtoolize |
515 |
|
|
autoreconf -vfi |
516 |
|
|
|
517 |
tv |
551068 |
# for bin/test-driver: |
518 |
|
|
automake --add-missing |
519 |
|
|
|
520 |
anssi |
278008 |
# fix build - TODO: should this be fixed in llvm somehow, or maybe the library |
521 |
|
|
# symlinks should be moved to %{_libdir}? -Anssi 08/2012 |
522 |
|
|
export LDFLAGS="-L%{_libdir}/llvm" |
523 |
|
|
|
524 |
|
|
%configure2_5x --enable-dri \ |
525 |
|
|
--enable-glx \ |
526 |
pterjan |
5340 |
--with-dri-driverdir=%{driver_dir} \ |
527 |
|
|
--with-dri-drivers="%{dri_drivers}" \ |
528 |
|
|
%if %{enable_egl} |
529 |
|
|
--enable-egl \ |
530 |
|
|
%else |
531 |
|
|
--disable-egl \ |
532 |
|
|
%endif |
533 |
blino |
215979 |
%if %{enable_wayland} |
534 |
|
|
--with-egl-platforms=x11,wayland,drm \ |
535 |
|
|
--enable-gbm \ |
536 |
|
|
--enable-shared-glapi \ |
537 |
|
|
%endif |
538 |
tv |
88442 |
--enable-gles1 \ |
539 |
|
|
--enable-gles2 \ |
540 |
tv |
88445 |
--enable-openvg \ |
541 |
mikala |
112356 |
--enable-gallium-egl \ |
542 |
blino |
270761 |
--disable-xvmc \ |
543 |
|
|
--enable-vdpau \ |
544 |
mikala |
112356 |
%if %{with_hardware} |
545 |
blino |
289282 |
--with-gallium-drivers=r300,r600,radeonsi,nouveau,swrast \ |
546 |
mikala |
112356 |
--enable-gallium-llvm \ |
547 |
|
|
%else |
548 |
|
|
--disable-gallium-llvm \ |
549 |
|
|
--with-gallium-drivers=swrast \ |
550 |
|
|
%endif |
551 |
tv |
135155 |
%if %{build_plf} |
552 |
|
|
--enable-texture-float \ |
553 |
|
|
%endif |
554 |
blino |
270723 |
# end of configure options |
555 |
pterjan |
5340 |
|
556 |
anssi |
332631 |
|
557 |
|
|
# Build OSMesa separately, since we want to build OSMesa without shared-glapi, |
558 |
|
|
# since doing that causes OSMesa to miss the OpenGL symbols. |
559 |
|
|
# See e.g. https://bugs.launchpad.net/ubuntu/+source/mesa/+bug/1066599 |
560 |
|
|
# -Anssi 12/2012 |
561 |
|
|
|
562 |
cjw |
336233 |
pushd build-osmesa |
563 |
|
|
autoreconf -vfi |
564 |
|
|
%configure2_5x \ |
565 |
|
|
--enable-osmesa \ |
566 |
|
|
--disable-dri \ |
567 |
|
|
--disable-glx \ |
568 |
|
|
--disable-egl \ |
569 |
|
|
--disable-shared-glapi \ |
570 |
|
|
--without-gallium-drivers |
571 |
|
|
popd |
572 |
anssi |
332631 |
|
573 |
anssi |
165988 |
%make |
574 |
cjw |
388874 |
%make -C build-osmesa || ( %make -C build-osmesa/src/mesa/program libprogram.la && %make -C build-osmesa ) |
575 |
pterjan |
5340 |
|
576 |
|
|
%install |
577 |
cjw |
336233 |
%makeinstall_std -C build-osmesa |
578 |
tv |
88249 |
%makeinstall_std |
579 |
pterjan |
5340 |
|
580 |
blino |
216556 |
# FIXME: strip will likely break the hardlink |
581 |
pterjan |
5340 |
# (blino) hardlink libGL files in %{_libdir}/mesa |
582 |
|
|
# to prevent proprietary driver installers from removing them |
583 |
|
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}/mesa |
584 |
|
|
pushd $RPM_BUILD_ROOT%{_libdir}/mesa |
585 |
|
|
for l in ../libGL.so.*; do cp -a $l .; done |
586 |
|
|
popd |
587 |
|
|
|
588 |
|
|
%ifarch %{x86_64} |
589 |
|
|
mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib/dri |
590 |
|
|
%endif |
591 |
|
|
|
592 |
blino |
270761 |
# .so files are not needed by vdpau |
593 |
|
|
rm -f %{buildroot}%{_libdir}/vdpau/libvdpau_*.so |
594 |
|
|
|
595 |
blino |
271144 |
# .la files are not needed by mesa |
596 |
|
|
find %{buildroot} -name '*.la' -exec rm {} \; |
597 |
|
|
|
598 |
anssi |
181478 |
# use swrastg if built (Anssi 12/2011) |
599 |
|
|
[ -e %{buildroot}%{_libdir}/dri/swrastg_dri.so ] && mv %{buildroot}%{_libdir}/dri/swrast{g,}_dri.so |
600 |
|
|
|
601 |
tv |
88440 |
#------------------------------------------------------------------------------ |
602 |
|
|
|
603 |
pterjan |
5340 |
%files |
604 |
|
|
%defattr(-,root,root) |
605 |
blino |
271481 |
%doc docs/COPYING |
606 |
blino |
271500 |
%config(noreplace) %{_sysconfdir}/drirc |
607 |
pterjan |
5340 |
|
608 |
|
|
%files -n %{dridrivers} |
609 |
|
|
%defattr(-,root,root) |
610 |
|
|
%doc docs/COPYING |
611 |
|
|
%ifnarch ppc64 |
612 |
|
|
%dir %{_libdir}/dri |
613 |
blino |
271495 |
# (blino) new mesa 8.1 build system seems to use a static libglsl |
614 |
|
|
#%{_libdir}/dri/libglsl.so |
615 |
pterjan |
5340 |
%{_libdir}/dri/*_dri.so |
616 |
|
|
%endif |
617 |
|
|
|
618 |
tv |
88433 |
%files -n %{libglname} |
619 |
|
|
%defattr(-,root,root) |
620 |
|
|
%doc docs/COPYING |
621 |
|
|
%{_libdir}/libGL.so.* |
622 |
|
|
%dir %{_libdir}/mesa |
623 |
tv |
88434 |
%{_libdir}/mesa/libGL.so.%{glmajor}* |
624 |
tv |
88433 |
|
625 |
|
|
%if %{enable_egl} |
626 |
|
|
%files -n %{libeglname} |
627 |
|
|
%defattr(-,root,root) |
628 |
tv |
88442 |
%doc docs/COPYING |
629 |
tv |
88434 |
%{_libdir}/libEGL.so.%{eglmajor}* |
630 |
tv |
88442 |
%dir %{_libdir}/egl |
631 |
blino |
215979 |
%if !%{enable_wayland} |
632 |
|
|
# st_GL, built only when shared glapi is not enabled |
633 |
mikala |
112356 |
%{_libdir}/egl/st_GL.so |
634 |
blino |
215979 |
%endif |
635 |
mikala |
127466 |
%{_libdir}/egl/egl_gallium.so |
636 |
tv |
88441 |
%endif |
637 |
tv |
88433 |
|
638 |
anssi |
278008 |
%files -n %{libosmesaname} |
639 |
|
|
%defattr(-,root,root) |
640 |
|
|
%{_libdir}/libOSMesa.so.%{osmesamajor}* |
641 |
|
|
|
642 |
mikala |
112356 |
%files -n %{libglapiname} |
643 |
|
|
%defattr(-,root,root) |
644 |
|
|
%{_libdir}/libglapi.so.%{glapimajor}* |
645 |
|
|
|
646 |
tv |
88442 |
%files -n %{libglesv1name} |
647 |
|
|
%defattr(-,root,root) |
648 |
|
|
%doc docs/COPYING |
649 |
|
|
%{_libdir}/libGLESv1_CM.so.%{glesv1major}* |
650 |
|
|
|
651 |
|
|
%files -n %{libglesv2name} |
652 |
|
|
%defattr(-,root,root) |
653 |
|
|
%doc docs/COPYING |
654 |
|
|
%{_libdir}/libGLESv2.so.%{glesv2major}* |
655 |
|
|
|
656 |
tv |
88445 |
%files -n %{libopenvgname} |
657 |
|
|
%defattr(-,root,root) |
658 |
|
|
%doc docs/COPYING |
659 |
|
|
%{_libdir}/libOpenVG.so.%{openvgmajor}* |
660 |
|
|
|
661 |
blino |
215979 |
%if %{enable_wayland} |
662 |
|
|
%files -n %{libgbmname} |
663 |
|
|
%{_libdir}/libgbm.so.%{gbmmajor} |
664 |
blino |
271141 |
%{_libdir}/libgbm.so.%{gbmmajor}.* |
665 |
blino |
215979 |
%{_libdir}/gbm/gbm_*.so |
666 |
cjw |
388874 |
%{_libdir}/gallium-pipe/pipe_*.so |
667 |
tv |
88445 |
|
668 |
blino |
215979 |
%files -n %{libwaylandeglname} |
669 |
|
|
%{_libdir}/libwayland-egl.so.%{waylandeglmajor} |
670 |
blino |
271141 |
%{_libdir}/libwayland-egl.so.%{waylandeglmajor}.* |
671 |
blino |
215979 |
%endif |
672 |
|
|
|
673 |
|
|
|
674 |
pterjan |
5340 |
%files -n %{libglname}-devel |
675 |
|
|
%defattr(-,root,root) |
676 |
|
|
%doc docs/COPYING |
677 |
anssi |
278008 |
%dir %{_includedir}/GL |
678 |
pterjan |
5340 |
%{_includedir}/GL/gl.h |
679 |
|
|
%{_includedir}/GL/glext.h |
680 |
|
|
%{_includedir}/GL/gl_mangle.h |
681 |
|
|
%{_includedir}/GL/wglext.h |
682 |
|
|
%{_includedir}/GL/glx.h |
683 |
|
|
%{_includedir}/GL/glxext.h |
684 |
|
|
%{_includedir}/GL/glx_mangle.h |
685 |
|
|
%{_libdir}/libGL.so |
686 |
tv |
88436 |
%{_libdir}/pkgconfig/gl.pc |
687 |
|
|
%{_libdir}/pkgconfig/dri.pc |
688 |
pterjan |
5340 |
|
689 |
|
|
#FIXME: check those headers |
690 |
cjw |
336175 |
#{_includedir}/GL/vms_x_fix.h |
691 |
pterjan |
5340 |
%{_includedir}/GL/wmesa.h |
692 |
|
|
%dir %{_includedir}/GL/internal |
693 |
|
|
%{_includedir}/GL/internal/dri_interface.h |
694 |
|
|
|
695 |
|
|
%files common-devel |
696 |
|
|
%defattr(-,root,root) |
697 |
|
|
|
698 |
tv |
88441 |
%if %{enable_egl} |
699 |
tv |
88433 |
%files -n %{libeglname}-devel |
700 |
|
|
%defattr(-,root,root) |
701 |
tv |
88442 |
%doc docs/COPYING |
702 |
|
|
%{_includedir}/EGL |
703 |
|
|
%{_includedir}/KHR |
704 |
tv |
88433 |
%{_libdir}/libEGL.so |
705 |
tv |
88436 |
%{_libdir}/pkgconfig/egl.pc |
706 |
tv |
88433 |
%endif |
707 |
pterjan |
5340 |
|
708 |
anssi |
278008 |
%files -n %{osmesadevel} |
709 |
|
|
%defattr(-,root,root) |
710 |
|
|
%dir %{_includedir}/GL |
711 |
|
|
%{_includedir}/GL/osmesa.h |
712 |
|
|
%{_libdir}/libOSMesa.so |
713 |
|
|
%{_libdir}/pkgconfig/osmesa.pc |
714 |
|
|
|
715 |
mikala |
112356 |
%files -n %{libglapiname}-devel |
716 |
|
|
%defattr(-,root,root) |
717 |
|
|
%{_libdir}/libglapi.so |
718 |
pterjan |
5340 |
|
719 |
tv |
88442 |
%files -n %{libglesv1name}-devel |
720 |
|
|
%defattr(-,root,root) |
721 |
|
|
%{_includedir}/GLES |
722 |
|
|
%{_libdir}/libGLESv1_CM.so |
723 |
|
|
%{_libdir}/pkgconfig/glesv1_cm.pc |
724 |
tv |
88433 |
|
725 |
tv |
88442 |
%files -n %{libglesv2name}-devel |
726 |
|
|
%defattr(-,root,root) |
727 |
|
|
%{_includedir}/GLES2 |
728 |
cjw |
336175 |
%{_includedir}/GLES3 |
729 |
tv |
88442 |
%{_libdir}/libGLESv2.so |
730 |
|
|
%{_libdir}/pkgconfig/glesv2.pc |
731 |
tv |
88445 |
|
732 |
|
|
%files -n %{libopenvgname}-devel |
733 |
|
|
%defattr(-,root,root) |
734 |
|
|
%{_includedir}/VG |
735 |
|
|
%{_libdir}/libOpenVG.so |
736 |
|
|
%{_libdir}/pkgconfig/vg.pc |
737 |
blino |
215979 |
|
738 |
|
|
%if %{enable_wayland} |
739 |
|
|
%files -n %{libgbmname}-devel |
740 |
|
|
%{_includedir}/gbm.h |
741 |
|
|
%{_libdir}/libgbm.so |
742 |
|
|
%{_libdir}/pkgconfig/gbm.pc |
743 |
|
|
|
744 |
|
|
%files -n %{libwaylandeglname}-devel |
745 |
|
|
%{_libdir}/libwayland-egl.so |
746 |
|
|
%{_libdir}/pkgconfig/wayland-egl.pc |
747 |
|
|
%endif |
748 |
blino |
270761 |
|
749 |
tv |
301233 |
%files -n %{_lib}vdpau-driver-nouveau |
750 |
blino |
270761 |
%{_libdir}/vdpau/libvdpau_nouveau.so.* |
751 |
|
|
|
752 |
tv |
301233 |
%files -n %{_lib}vdpau-driver-r600 |
753 |
blino |
270761 |
%{_libdir}/vdpau/libvdpau_r600.so.* |
754 |
|
|
|
755 |
tv |
301233 |
%files -n %{_lib}vdpau-driver-radeonsi |
756 |
blino |
289282 |
%{_libdir}/vdpau/libvdpau_radeonsi.so.* |
757 |
|
|
|