1 |
%define bootstrap 0 |
2 |
%{?_without_bootstrap: %global bootstrap 0} |
3 |
%{?_with_bootstrap: %global bootstrap 1} |
4 |
|
5 |
%if "%distro_section" == "tainted" |
6 |
%global build_plf 1 |
7 |
%else |
8 |
%global build_plf 0 |
9 |
%endif |
10 |
|
11 |
# (cg) Cheater... |
12 |
%define Werror_cflags %nil |
13 |
|
14 |
# (aco) Needed for the dri drivers |
15 |
%define _disable_ld_no_undefined 1 |
16 |
|
17 |
|
18 |
%define git 0 |
19 |
%define with_hardware 1 |
20 |
|
21 |
%define relc 0 |
22 |
%define name mesa |
23 |
%define version 8.0.1 |
24 |
%define rel 3 |
25 |
|
26 |
%define release %mkrel %{rel} |
27 |
%define src_type tar.bz2 |
28 |
#define vsuffix %{expand:} |
29 |
%define vsuffix %nil |
30 |
|
31 |
%if %{relc} |
32 |
%define release %mkrel 0.rc%{relc}.%{rel} |
33 |
%define vsuffix -rc%{relc} |
34 |
%define src_type tar.bz2 |
35 |
%endif |
36 |
|
37 |
%if %{git} |
38 |
%if %{relc} |
39 |
%define release %mkrel 0.rc%{relc}.1.git%{git}.%{rel} |
40 |
%else |
41 |
%define release %mkrel 0.git%{git}.%{rel} |
42 |
%endif |
43 |
%endif |
44 |
|
45 |
%define makedepend %{_bindir}/gccmakedep |
46 |
|
47 |
%define eglname mesaegl |
48 |
%define glname mesagl |
49 |
%define gluname mesaglu |
50 |
%define glwname mesaglw |
51 |
%define glesv1name mesaglesv1 |
52 |
%define glesv2name mesaglesv2 |
53 |
%define openvgname mesaopenvg |
54 |
%define glapiname glapi |
55 |
%define gbmname gbm |
56 |
%define waylandeglname wayland-egl |
57 |
|
58 |
%define eglmajor 1 |
59 |
%define glmajor 1 |
60 |
%define glumajor 1 |
61 |
%define glwmajor 1 |
62 |
%define glesv1major 1 |
63 |
%define glesv2major 2 |
64 |
%define openvgmajor 1 |
65 |
%define glapimajor 0 |
66 |
%define gbmmajor 1 |
67 |
%define waylandeglmajor 1 |
68 |
|
69 |
%define libeglname %mklibname %{eglname} %{eglmajor} |
70 |
%define libglname %mklibname %{glname} %{glmajor} |
71 |
%define libgluname %mklibname %{gluname} %{glumajor} |
72 |
%define libglwname %mklibname %{glwname} %{glwmajor} |
73 |
%define libglesv1name %mklibname %{glesv1name}_ %{glesv1major} |
74 |
%define libglesv2name %mklibname %{glesv2name}_ %{glesv2major} |
75 |
%define libopenvgname %mklibname %{openvgname} %{openvgmajor} |
76 |
%define libglapiname %mklibname %{glapiname} %{glapimajor} |
77 |
%define libgbmname %mklibname %{gbmname} %{gbmmajor} |
78 |
%define libwaylandeglname %mklibname %{waylandeglname} %{waylandeglmajor} |
79 |
|
80 |
%define dridrivers %mklibname dri-drivers |
81 |
|
82 |
# Architecture-independent Virtual provides: |
83 |
%define libeglname_virt lib%{eglname} |
84 |
%define libglname_virt lib%{glname} |
85 |
%define libgluname_virt lib%{gluname} |
86 |
%define libglwname_virt lib%{glwname} |
87 |
%define libglesv1name_virt lib%{glesv1name} |
88 |
%define libglesv2name_virt lib%{glesv2name} |
89 |
%define libopenvgname_virt lib%{openvgname} |
90 |
%define libglapiname_virt lib%{glapiname} |
91 |
%define libgbmname_virt lib%{gbmname} |
92 |
%define libwaylandeglname_virt lib%{waylandeglname} |
93 |
|
94 |
%define oldlibglname %mklibname MesaGL 1 |
95 |
%define oldlibgluname %mklibname MesaGLU 1 |
96 |
|
97 |
%define mesasrcdir %{_prefix}/src/Mesa/ |
98 |
%define driver_dir %{_libdir}/dri |
99 |
|
100 |
%define enable_egl 1 |
101 |
%define enable_wayland 1 |
102 |
|
103 |
#FIXME: (for 386/485) unset SSE, MMX and 3dnow flags |
104 |
#FIXME: (for >=i586) disable sse |
105 |
# SSE seems to have problem on some apps (gtulpas) for probing. |
106 |
%define dri_drivers_i386 "i915,i965,nouveau,r200,radeon,swrast" |
107 |
%define dri_drivers_x86_64 %{dri_drivers_i386} |
108 |
%define dri_drivers_ppc "r200,radeon,swrast" |
109 |
%define dri_drivers_ppc64 "" |
110 |
%define dri_drivers_ia64 "i915,i965,mga,r200,radeon,swrast" |
111 |
%define dri_drivers_alpha "r200,radeon,swrast" |
112 |
%define dri_drivers_sparc "ffb,radeon,swrast" |
113 |
%define dri_drivers_mipsel "r200,radeon,swrast" |
114 |
%define dri_drivers_arm "swrast" |
115 |
%define dri_drivers %{expand:%{dri_drivers_%{_arch}}} |
116 |
|
117 |
Name: %{name} |
118 |
Version: %{version} |
119 |
Release: %{release} |
120 |
Summary: OpenGL 2.1 compatible 3D graphics library |
121 |
Group: System/Libraries |
122 |
|
123 |
BuildRequires: pkgconfig(xfixes) >= 4.0.3 |
124 |
BuildRequires: pkgconfig(xt) >= 1.0.5 |
125 |
BuildRequires: pkgconfig(xmu) >= 1.0.3 |
126 |
BuildRequires: pkgconfig(x11) >= 1.3.3 |
127 |
BuildRequires: pkgconfig(xdamage) >= 1.1.1 |
128 |
BuildRequires: libexpat-devel >= 2.0.1 |
129 |
BuildRequires: gccmakedep |
130 |
BuildRequires: x11-proto-devel >= 7.3 |
131 |
BuildRequires: pkgconfig(libdrm) >= 2.4.21 |
132 |
|
133 |
BuildRequires: pkgconfig(xext) >= 1.1.1 |
134 |
BuildRequires: pkgconfig(xxf86vm) >= 1.1.0 |
135 |
BuildRequires: pkgconfig(xi) >= 1.3 |
136 |
BuildRequires: pkgconfig(talloc) |
137 |
BuildRequires: libxml2-python |
138 |
BuildRequires: makedepend |
139 |
BuildRequires: bison flex |
140 |
BuildRequires: llvm |
141 |
BuildRequires: pkgconfig(libudev) |
142 |
%if %{enable_wayland} |
143 |
BuildRequires: wayland-devel |
144 |
%endif |
145 |
|
146 |
URL: http://www.mesa3d.org |
147 |
%if %{git} |
148 |
# (cg) Current commit ref: origin/mesa_7_5_branch |
149 |
Source0: %{name}-%{git}.tar.bz2 |
150 |
%else |
151 |
Source0: ftp://ftp.freedesktop.org/pub/mesa/%version/MesaLib-%{version}%{vsuffix}.%{src_type} |
152 |
%endif |
153 |
Source3: make-git-snapshot.sh |
154 |
Source5: mesa-driver-install |
155 |
|
156 |
|
157 |
# Instructions to setup your repository clone |
158 |
# git://git.freedesktop.org/git/mesa/mesa |
159 |
# git checkout mesa_7_5_branch |
160 |
# git branch mdv-cherry-picks |
161 |
# git am ../02??-*.patch |
162 |
# git branch mdv-redhat |
163 |
# git am ../03??-*.patch |
164 |
# git branch mdv-patches |
165 |
# git am ../09??-*.patch |
166 |
|
167 |
# In order to update to the branch via patches, issue this command: |
168 |
# git format-patch --start-number 100 mesa_7_5_1..mesa_7_5_branch | sed 's/^0\([0-9]\+\)-/Patch\1: 0\1-/' |
169 |
|
170 |
# Cherry picks |
171 |
# git format-patch --start-number 200 mesa_7_5_branch..mdv-cherry-picks |
172 |
Patch201: 0201-revert-fix-glxinitializevisualconfigfromtags-handling.patch |
173 |
Patch202: 0202-fix-includes-for-latest-libdrm.patch |
174 |
|
175 |
# Patches "liberated" from Fedora: |
176 |
# http://cvs.fedoraproject.org/viewvc/rpms/mesa/devel/ |
177 |
# git format-patch --start-number 300 mdv-cherry-picks..mdv-redhat |
178 |
|
179 |
# Mandriva patches |
180 |
# git format-patch --start-number 900 mdv-redhat..mdv-patches |
181 |
Patch902: 0902-remove-unfinished-GLX_ARB_render_texture.patch |
182 |
Patch903: 0903-Fix-NULL-pointer-dereference-in-viaXMesaWindowMoved.patch |
183 |
Patch904: Mesa-7.9-salome.patch |
184 |
|
185 |
Patch2004: mesa_652_mips.patch |
186 |
|
187 |
#------------------------------------------------------------------------------ |
188 |
|
189 |
# package mesa |
190 |
License: MIT |
191 |
Requires: %{libglname} = %{version}-%{release} |
192 |
Provides: hackMesa = %{version} |
193 |
Obsoletes: hackMesa <= %{version} |
194 |
Provides: Mesa = %{version} |
195 |
Obsoletes: Mesa < %{version} |
196 |
|
197 |
%package -n %{libglname} |
198 |
Summary: Files for Mesa (GL and GLX libs) |
199 |
Group: System/Libraries |
200 |
Obsoletes: %{oldlibglname} < 6.4 |
201 |
Provides: %{oldlibglname} = %{version}-%{release} |
202 |
Provides: %{libglname_virt} = %{version}-%{release} |
203 |
Requires: %{dridrivers} >= %{version}-%{release} |
204 |
%if %{build_plf} |
205 |
Requires: %mklibname txc-dxtn |
206 |
%endif |
207 |
|
208 |
# (anssi) Forces the upgrade of x11-server-common to happen before |
209 |
# alternatives removal, which allows x11-server-common to grab the symlink. |
210 |
Conflicts: x11-server-common < 1.3.0.0-17 |
211 |
|
212 |
%package -n %{dridrivers} |
213 |
Summary: Mesa DRI drivers |
214 |
Group: System/Libraries |
215 |
Conflicts: %{_lib}MesaGL1 < 7.7-5 |
216 |
Obsoletes: %{_lib}dri-drivers-experimental < 7.11.2-4 |
217 |
Provides: %{_lib}dri-drivers-experimental = %{version}-%{release} |
218 |
|
219 |
%package -n %{libglname}-devel |
220 |
Summary: Development files for Mesa (OpenGL compatible 3D lib) |
221 |
Group: Development/C |
222 |
Requires: %{libglname} = %{version}-%{release} |
223 |
Provides: lib%{glname}-devel = %{version}-%{release} |
224 |
Provides: %{glname}-devel = %{version}-%{release} |
225 |
Provides: GL-devel |
226 |
Obsoletes: %{oldlibglname}-devel < 6.4 |
227 |
Provides: %{oldlibglname}-devel = %{version}-%{release} |
228 |
Provides: libMesaGL-devel = %{version}-%{release} |
229 |
Provides: MesaGL-devel = %{version}-%{release} |
230 |
Provides: libgl-devel |
231 |
|
232 |
%package -n %{libgluname} |
233 |
Summary: Files for Mesa (GLU libs) |
234 |
Group: System/Libraries |
235 |
Obsoletes: %{oldlibgluname} < 6.4 |
236 |
Provides: %{oldlibgluname} = %{version}-%{release} |
237 |
Provides: %{libgluname_virt} = %{version}-%{release} |
238 |
|
239 |
%package -n %{libgluname}-devel |
240 |
Summary: Development files for GLU libs |
241 |
Group: Development/C |
242 |
Requires: %{libgluname} = %{version}-%{release} |
243 |
Provides: lib%{gluname}-devel = %{version}-%{release} |
244 |
Provides: %{gluname}-devel = %{version}-%{release} |
245 |
Obsoletes: %{oldlibgluname}-devel < 6.4 |
246 |
Provides: %{oldlibgluname}-devel = %{version}-%{release} |
247 |
Provides: libMesaGLU-devel = %{version}-%{release} |
248 |
Provides: MesaGLU-devel = %{version}-%{release} |
249 |
Provides: libglu-devel |
250 |
# pkgconfig files moved from libgl-devel: |
251 |
Conflicts: %{libglname}-devel < 7.10.2-4 |
252 |
|
253 |
%if %{enable_egl} |
254 |
%package -n %{libeglname} |
255 |
Summary: Files for Mesa (EGL libs) |
256 |
Group: System/Libraries |
257 |
Provides: %{libeglname_virt} = %{version}-%{release} |
258 |
|
259 |
%package -n %{libeglname}-devel |
260 |
Summary: Development files for Mesa (EGL libs) |
261 |
Group: Development/C |
262 |
Requires: %{libeglname} = %{version}-%{release} |
263 |
Provides: EGL-devel |
264 |
Provides: lib%{eglname}-devel |
265 |
Provides: %{eglname}-devel |
266 |
Provides: libegl-devel |
267 |
%endif |
268 |
|
269 |
%package -n %{libglapiname} |
270 |
Summary: Files for mesa (glapi libs) |
271 |
Group: System/Libraries |
272 |
Provides: %{libglapiname_virt} = %{version}-%{release} |
273 |
|
274 |
%package -n %{libglapiname}-devel |
275 |
Summary: Development files for glapi libs |
276 |
Group: Development/C |
277 |
Requires: %{libglapiname_virt} = %{version}-%{release} |
278 |
Provides: lib%{glapiname}-devel |
279 |
Provides: %{libglapiname}-devel |
280 |
|
281 |
%package -n %{libglesv1name} |
282 |
Summary: Files for Mesa (glesv1 libs) |
283 |
Group: System/Libraries |
284 |
Provides: %{libglesv1name_virt} = %{version}-%{release} |
285 |
|
286 |
%package -n %{libglesv1name}-devel |
287 |
Summary: Development files for glesv1 libs |
288 |
Group: Development/C |
289 |
Requires: %{libglesv1name} = %{version}-%{release} |
290 |
Provides: lib%{glesv1name}-devel |
291 |
Provides: %{glesv1name}-devel |
292 |
Provides: libglesv1-devel |
293 |
|
294 |
%package -n %{libglesv2name} |
295 |
Summary: Files for Mesa (glesv2 libs) |
296 |
Group: System/Libraries |
297 |
Provides: %{libglesv2name_virt} = %{version}-%{release} |
298 |
|
299 |
%package -n %{libglesv2name}-devel |
300 |
Summary: Development files for glesv2 libs |
301 |
Group: Development/C |
302 |
Requires: %{libglesv2name} = %{version}-%{release} |
303 |
Requires: %{libeglname}-devel = %{version}-%{release} |
304 |
Provides: lib%{glesv2name}-devel |
305 |
Provides: %{glesv2name}-devel |
306 |
Provides: libglesv2-devel |
307 |
|
308 |
%package -n %{libopenvgname} |
309 |
Summary: Files for MESA (OpenVG libs) |
310 |
Group: System/Libraries |
311 |
Provides: %{libopenvgname_virt} = %{version}-%{release} |
312 |
|
313 |
%package -n %{libopenvgname}-devel |
314 |
Summary: Development files vor OpenVG libs |
315 |
Group: Development/C |
316 |
Requires: %{libopenvgname} = %{version}-%{release} |
317 |
Provides: lib%{openvgname}-devel |
318 |
Provides: %{openvgname}-devel |
319 |
Provides: libopenvg-devel |
320 |
|
321 |
%if %{enable_wayland} |
322 |
%package -n %{libgbmname} |
323 |
Summary: Files for Mesa (gbm libs) |
324 |
Group: System/Libraries |
325 |
Provides: %{libgbmname_virt} = %{version}-%{release} |
326 |
|
327 |
%package -n %{libgbmname}-devel |
328 |
Summary: Development files for Mesa (gbm libs) |
329 |
Group: Development/C |
330 |
Requires: %{libgbmname} = %{version}-%{release} |
331 |
Provides: lib%{gbmname}-devel |
332 |
Provides: %{gbmname}-devel |
333 |
|
334 |
%package -n %{libwaylandeglname} |
335 |
Summary: Files for Mesa (Wayland EGL libs) |
336 |
Group: System/Libraries |
337 |
Provides: %{libwaylandeglname_virt} = %{version}-%{release} |
338 |
|
339 |
%package -n %{libwaylandeglname}-devel |
340 |
Summary: Development files for Mesa (Wayland EGL libs) |
341 |
Group: Development/C |
342 |
Requires: %{libwaylandeglname} = %{version}-%{release} |
343 |
Provides: lib%{waylandeglname}-devel |
344 |
Provides: %{waylandeglname}-devel |
345 |
%endif |
346 |
|
347 |
%package common-devel |
348 |
Summary: Meta package for mesa devel |
349 |
Group: Development/C |
350 |
Provides: Mesa-common-devel = %{version}-%{release} |
351 |
Provides: hackMesa-common-devel = %{version} |
352 |
Obsoletes: Mesa-common-devel < %{version} |
353 |
Obsoletes: hackMesa-common-devel < %{version} |
354 |
Requires: %{libglname}-devel = %{version} |
355 |
Requires: %{libgluname}-devel = %{version} |
356 |
Requires: freeglut-devel |
357 |
Requires: %{libeglname}-devel = %{version} |
358 |
Requires: %{libglesv1name}-devel = %{version} |
359 |
Requires: %{libglesv2name}-devel = %{version} |
360 |
|
361 |
#------------------------------------------------------------------------------ |
362 |
|
363 |
%description |
364 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
365 |
%if %{build_plf} |
366 |
|
367 |
This package is in the "tainted" section because it enables some |
368 |
OpenGL extentions that are covered by software patents. |
369 |
%endif |
370 |
|
371 |
%description common-devel |
372 |
Mesa common metapackage devel |
373 |
|
374 |
%if %{enable_egl} |
375 |
%description -n %{libeglname} |
376 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
377 |
EGL parts. |
378 |
|
379 |
%description -n %{libeglname}-devel |
380 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
381 |
EGL development parts. |
382 |
%endif |
383 |
|
384 |
%description -n %{libglname} |
385 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
386 |
GL and GLX parts. |
387 |
|
388 |
%if %{build_plf} |
389 |
This package is in the "tainted" section because it enables some |
390 |
OpenGL extentions that are covered by software patents. |
391 |
%endif |
392 |
|
393 |
%description -n %{dridrivers} |
394 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
395 |
DRI drivers. |
396 |
|
397 |
%description -n %{libglname}-devel |
398 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
399 |
|
400 |
This package contains the headers needed to compile Mesa programs. |
401 |
|
402 |
%description -n %{libgluname} |
403 |
GLU is the OpenGL Utility Library. |
404 |
It provides a number of functions upon the base OpenGL library to provide |
405 |
higher-level drawing routines from the more primitive routines provided by |
406 |
OpenGL. |
407 |
|
408 |
%description -n %{libgluname}-devel |
409 |
This package contains the headers needed to compile programs with GLU. |
410 |
|
411 |
%description -n %{libglesv1name} |
412 |
OpenGL ES is a low-level, lightweight API for advanced embedded graphics using |
413 |
well-defined subset profiles of OpenGL. |
414 |
|
415 |
This package provides the OpenGL ES library version 1. |
416 |
|
417 |
%description -n %{libglapiname} |
418 |
This packages provides the glapi shared library used by gallium. |
419 |
|
420 |
%description -n %{libglapiname}-devel |
421 |
This package contains the headers needed to compile programes against glapi shared library. |
422 |
|
423 |
%description -n %{libglesv1name}-devel |
424 |
This package contains the headers needed to compile OpenGL ES 1 programs. |
425 |
|
426 |
%description -n %{libglesv2name} |
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 2. |
431 |
|
432 |
%description -n %{libglesv2name}-devel |
433 |
This package contains the headers needed to compile OpenGL ES 2 programs. |
434 |
|
435 |
%description -n %{libopenvgname} |
436 |
OpenVG is a royalty-free, cross-platform API that provides a low-level hardware |
437 |
acceleration interface for vector graphics libraries such as Flash and SVG. |
438 |
|
439 |
%description -n %{libopenvgname}-devel |
440 |
Development files for OpenVG library. |
441 |
|
442 |
%if %{enable_wayland} |
443 |
%description -n %{libgbmname} |
444 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
445 |
GBM (Graphics Buffer Manager) parts. |
446 |
|
447 |
%description -n %{libgbmname}-devel |
448 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
449 |
GBM (Graphics Buffer Manager) development parts. |
450 |
|
451 |
%description -n %{libwaylandeglname} |
452 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
453 |
Wayland EGL platform parts. |
454 |
|
455 |
%description -n %{libwaylandeglname}-devel |
456 |
Mesa is an OpenGL 2.1 compatible 3D graphics library. |
457 |
Wayland EGL platform development parts. |
458 |
%endif |
459 |
|
460 |
#------------------------------------------------------------------------------ |
461 |
|
462 |
%prep |
463 |
%if %{git} |
464 |
%setup -q -n mesa-%{git} |
465 |
%else |
466 |
%setup -q -n Mesa-%{version}%{vsuffix} |
467 |
%endif |
468 |
|
469 |
%patch201 -p1 |
470 |
#%patch202 -p1 |
471 |
|
472 |
#%patch902 -p1 |
473 |
#%patch903 -p1 |
474 |
#%patch904 -p1 |
475 |
|
476 |
#%patch2004 -p1 |
477 |
|
478 |
chmod +x %{SOURCE5} |
479 |
|
480 |
%build |
481 |
%if %{git} |
482 |
./autogen.sh -v |
483 |
%endif |
484 |
|
485 |
# Required by patch200: |
486 |
autoreconf -vfi |
487 |
%configure2_5x --with-driver=dri \ |
488 |
--with-dri-driverdir=%{driver_dir} \ |
489 |
--with-dri-drivers="%{dri_drivers}" \ |
490 |
--with-state-trackers=dri \ |
491 |
--enable-shared-dricore \ |
492 |
--enable-gallium-nouveau \ |
493 |
%if %{enable_egl} |
494 |
--enable-egl \ |
495 |
%else |
496 |
--disable-egl \ |
497 |
%endif |
498 |
%if %{enable_wayland} |
499 |
--with-egl-platforms=x11,wayland,drm \ |
500 |
--enable-gbm \ |
501 |
--enable-shared-glapi \ |
502 |
%endif |
503 |
--enable-gles1 \ |
504 |
--enable-gles2 \ |
505 |
--enable-openvg \ |
506 |
--enable-gallium-egl \ |
507 |
%if %{with_hardware} |
508 |
--with-gallium-drivers=r300,r600,nouveau,swrast \ |
509 |
--enable-gallium-llvm \ |
510 |
%else |
511 |
--disable-gallium-llvm \ |
512 |
--with-gallium-drivers=swrast \ |
513 |
%endif |
514 |
%if %{build_plf} |
515 |
--enable-texture-float \ |
516 |
%endif |
517 |
--disable-glut |
518 |
|
519 |
%make |
520 |
|
521 |
%install |
522 |
%makeinstall_std |
523 |
|
524 |
# FIXME: strip will likely break the hardlink |
525 |
# (blino) hardlink libGL files in %{_libdir}/mesa |
526 |
# to prevent proprietary driver installers from removing them |
527 |
mkdir -p $RPM_BUILD_ROOT%{_libdir}/mesa |
528 |
pushd $RPM_BUILD_ROOT%{_libdir}/mesa |
529 |
for l in ../libGL.so.*; do cp -a $l .; done |
530 |
popd |
531 |
|
532 |
%ifarch %{x86_64} |
533 |
mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib/dri |
534 |
%endif |
535 |
|
536 |
rm -f %{buildroot}/%{_includedir}/GL/glut.h |
537 |
rm -f %{buildroot}/%{_includedir}/GL/glutf90.h |
538 |
|
539 |
# use swrastg if built (Anssi 12/2011) |
540 |
[ -e %{buildroot}%{_libdir}/dri/swrastg_dri.so ] && mv %{buildroot}%{_libdir}/dri/swrast{g,}_dri.so |
541 |
|
542 |
#------------------------------------------------------------------------------ |
543 |
|
544 |
%files |
545 |
%defattr(-,root,root) |
546 |
%doc docs/COPYING docs/README.* |
547 |
|
548 |
%files -n %{dridrivers} |
549 |
%defattr(-,root,root) |
550 |
%doc docs/COPYING |
551 |
%ifnarch ppc64 |
552 |
%dir %{_libdir}/dri |
553 |
%{_libdir}/dri/libdricore.so |
554 |
%{_libdir}/dri/libglsl.so |
555 |
%{_libdir}/dri/*_dri.so |
556 |
%endif |
557 |
|
558 |
%files -n %{libglname} |
559 |
%defattr(-,root,root) |
560 |
%doc docs/COPYING |
561 |
%{_libdir}/libGL.so.* |
562 |
%dir %{_libdir}/mesa |
563 |
%{_libdir}/mesa/libGL.so.%{glmajor}* |
564 |
|
565 |
%files -n %{libgluname} |
566 |
%defattr(-,root,root) |
567 |
%doc docs/COPYING |
568 |
%{_libdir}/libGLU.so.%{glumajor}* |
569 |
|
570 |
%if %{enable_egl} |
571 |
%files -n %{libeglname} |
572 |
%defattr(-,root,root) |
573 |
%doc docs/COPYING |
574 |
%{_libdir}/libEGL.so.%{eglmajor}* |
575 |
%dir %{_libdir}/egl |
576 |
%if !%{enable_wayland} |
577 |
# st_GL, built only when shared glapi is not enabled |
578 |
%{_libdir}/egl/st_GL.so |
579 |
%endif |
580 |
%{_libdir}/egl/egl_gallium.so |
581 |
%endif |
582 |
|
583 |
%files -n %{libglapiname} |
584 |
%defattr(-,root,root) |
585 |
%{_libdir}/libglapi.so.%{glapimajor}* |
586 |
|
587 |
%files -n %{libglesv1name} |
588 |
%defattr(-,root,root) |
589 |
%doc docs/COPYING |
590 |
%{_libdir}/libGLESv1_CM.so.%{glesv1major}* |
591 |
|
592 |
%files -n %{libglesv2name} |
593 |
%defattr(-,root,root) |
594 |
%doc docs/COPYING |
595 |
%{_libdir}/libGLESv2.so.%{glesv2major}* |
596 |
|
597 |
%files -n %{libopenvgname} |
598 |
%defattr(-,root,root) |
599 |
%doc docs/COPYING |
600 |
%{_libdir}/libOpenVG.so.%{openvgmajor}* |
601 |
|
602 |
%if %{enable_wayland} |
603 |
%files -n %{libgbmname} |
604 |
%{_libdir}/libgbm.so.%{gbmmajor} |
605 |
%{_libdir}/libgbm.so.%{gbmmajor}.0 |
606 |
%{_libdir}/gbm/gbm_*.so |
607 |
%{_libdir}/gbm/pipe_*.so |
608 |
|
609 |
%files -n %{libwaylandeglname} |
610 |
%{_libdir}/libwayland-egl.so.%{waylandeglmajor} |
611 |
%{_libdir}/libwayland-egl.so.%{waylandeglmajor}.0 |
612 |
%endif |
613 |
|
614 |
|
615 |
%files -n %{libglname}-devel |
616 |
%defattr(-,root,root) |
617 |
%doc docs/COPYING |
618 |
%{_includedir}/GL/gl.h |
619 |
%{_includedir}/GL/glext.h |
620 |
%{_includedir}/GL/gl_mangle.h |
621 |
%{_includedir}/GL/osmesa.h |
622 |
%{_includedir}/GL/wglext.h |
623 |
%{_includedir}/GL/glx.h |
624 |
%{_includedir}/GL/glxext.h |
625 |
%{_includedir}/GL/glx_mangle.h |
626 |
%{_libdir}/libGL.so |
627 |
%{_libdir}/pkgconfig/gl.pc |
628 |
%{_libdir}/pkgconfig/dri.pc |
629 |
|
630 |
#FIXME: check those headers |
631 |
%{_includedir}/GL/vms_x_fix.h |
632 |
%{_includedir}/GL/wmesa.h |
633 |
%dir %{_includedir}/GL/internal |
634 |
%{_includedir}/GL/internal/dri_interface.h |
635 |
|
636 |
%files -n %{libgluname}-devel |
637 |
%defattr(-,root,root) |
638 |
%doc docs/COPYING |
639 |
%{_includedir}/GL/glu.h |
640 |
%{_includedir}/GL/glu_mangle.h |
641 |
%{_libdir}/libGLU.so |
642 |
%{_libdir}/pkgconfig/glu.pc |
643 |
|
644 |
%files common-devel |
645 |
%defattr(-,root,root) |
646 |
|
647 |
%if %{enable_egl} |
648 |
%files -n %{libeglname}-devel |
649 |
%defattr(-,root,root) |
650 |
%doc docs/COPYING |
651 |
%{_includedir}/EGL |
652 |
%{_includedir}/KHR |
653 |
%{_libdir}/libEGL.so |
654 |
%{_libdir}/pkgconfig/egl.pc |
655 |
%endif |
656 |
|
657 |
%files -n %{libglapiname}-devel |
658 |
%defattr(-,root,root) |
659 |
%{_libdir}/libglapi.so |
660 |
|
661 |
%files -n %{libglesv1name}-devel |
662 |
%defattr(-,root,root) |
663 |
%{_includedir}/GLES |
664 |
%{_libdir}/libGLESv1_CM.so |
665 |
%{_libdir}/pkgconfig/glesv1_cm.pc |
666 |
|
667 |
%files -n %{libglesv2name}-devel |
668 |
%defattr(-,root,root) |
669 |
%{_includedir}/GLES2 |
670 |
%{_libdir}/libGLESv2.so |
671 |
%{_libdir}/pkgconfig/glesv2.pc |
672 |
|
673 |
%files -n %{libopenvgname}-devel |
674 |
%defattr(-,root,root) |
675 |
%{_includedir}/VG |
676 |
%{_libdir}/libOpenVG.so |
677 |
%{_libdir}/pkgconfig/vg.pc |
678 |
|
679 |
%if %{enable_wayland} |
680 |
%files -n %{libgbmname}-devel |
681 |
%{_includedir}/gbm.h |
682 |
%{_libdir}/libgbm.so |
683 |
%{_libdir}/pkgconfig/gbm.pc |
684 |
|
685 |
%files -n %{libwaylandeglname}-devel |
686 |
%{_libdir}/libwayland-egl.so |
687 |
%{_libdir}/pkgconfig/wayland-egl.pc |
688 |
%endif |