/[packages]/cauldron/mesa/current/SPECS/mesa.spec
ViewVC logotype

Contents of /cauldron/mesa/current/SPECS/mesa.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1051613 - (show annotations) (download)
Mon Sep 12 12:57:00 2016 UTC (7 years, 7 months ago) by tv
File size: 23939 byte(s)
define driver_list like FC does (SILENT)
1 %if "%distro_section" == "tainted"
2 %global build_plf 1
3 %else
4 %global build_plf 0
5 %endif
6
7 # (cg) Cheater...
8 %define Werror_cflags %nil
9
10 # (aco) Needed for the dri drivers
11 %define _disable_ld_no_undefined 1
12
13 # http://cgit.freedesktop.org/mesa/mesa/commit/?h=9.1&id=38e728498b8ef63bb7dce77c64af11c98ec2efa4
14 %define git 0
15 %define git_branch 9.2
16 %bcond_without hardware_gallium
17
18 %define opengl_ver 4.3
19
20 # define version, RC & release
21 %define main_version 12.0.2
22 %define relc %nil
23 %define rel 1.1
24
25 %define release %mkrel %{rel}
26 %define vsuffix %nil
27
28 %if 0%{?relc}
29 %define vsuffix -rc%{relc}
30 %endif
31
32 %if %{git}
33 %if %{relc}
34 %define release %mkrel 1~rc%{relc}.1.git%{git}.%{rel}
35 %else
36 %define release %mkrel 1.git%{git}.%{rel}
37 %endif
38 %endif
39
40 %define makedepend %{_bindir}/gccmakedep
41
42 %define d3dname d3d
43 %define eglname mesaegl
44 %define glname mesagl
45 %define glwname mesaglw
46 %define glesv1name mesaglesv1
47 %define glesv2name mesaglesv2
48 %define openvgname mesaopenvg
49 %define glapiname glapi
50 %define gbmname gbm
51 %define waylandeglname wayland-egl
52 %define xaname xatracker
53 %define vulkanname vulkan
54
55 %define d3dmajor 1
56 %define eglmajor 1
57 %define glmajor 1
58 %define glwmajor 1
59 %define glesv1major 1
60 %define glesv2major 2
61 %define openvgmajor 1
62 %define glapimajor 0
63 %define gbmmajor 1
64 %define waylandeglmajor 1
65 %define osmesamajor 8
66 %define xamajor 2
67
68 %define libd3dname %mklibname %{d3dname} %{d3dmajor}
69 %define libeglname %mklibname %{eglname} %{eglmajor}
70 %define libglname %mklibname %{glname} %{glmajor}
71 %define libglwname %mklibname %{glwname} %{glwmajor}
72 %define libglesv1name %mklibname %{glesv1name}_ %{glesv1major}
73 %define libglesv2name %mklibname %{glesv2name}_ %{glesv2major}
74 %define libopenvgname %mklibname %{openvgname} %{openvgmajor}
75 %define libglapiname %mklibname %{glapiname} %{glapimajor}
76 %define libgbmname %mklibname %{gbmname} %{gbmmajor}
77 %define libwaylandeglname %mklibname %{waylandeglname} %{waylandeglmajor}
78 %define libosmesaname %mklibname osmesa %{osmesamajor}
79 %define libxaname %mklibname %{xaname} %{xamajor}
80 %define libvulkanname %mklibname %{vulkanname}
81
82 %define dridrivers %mklibname dri-drivers
83
84 %define osmesadevel %mklibname osmesa -d
85
86 # Architecture-independent Virtual provides:
87 %define libd3dname_virt lib%{d3dname}
88 %define libeglname_virt lib%{eglname}
89 %define libglname_virt lib%{glname}
90 %define libglwname_virt lib%{glwname}
91 %define libglesv1name_virt lib%{glesv1name}
92 %define libglesv2name_virt lib%{glesv2name}
93 %define libopenvgname_virt lib%{openvgname}
94 %define libglapiname_virt lib%{glapiname}
95 %define libgbmname_virt lib%{gbmname}
96 %define libwaylandeglname_virt lib%{waylandeglname}
97 %define libxaname_virt lib%{xaname}
98
99 %define oldlibglname %mklibname MesaGL 1
100
101 %define mesasrcdir %{_prefix}/src/Mesa/
102 %define driver_dir %{_libdir}/dri
103
104 %define enable_egl 1
105 %define enable_vg 0
106 %define enable_wayland 1
107
108 # (akien) Not adding on arm as it would break the build there
109 %define enable_vulkan 0
110 %ifarch %{ix86} x86_64
111 %define enable_vulkan 1
112 %endif
113
114 %define base_drivers swrast,nouveau,radeon,r200
115 %ifarch %{ix86} x86_64
116 %define platform_drivers ,i915,i965
117 %endif
118 %define dri_drivers --with-dri-drivers=%{?base_drivers}%{?platform_drivers}
119
120 Name: mesa
121 Version: %{main_version}
122 Release: %{release}
123 Summary: OpenGL %{opengl_ver} compatible 3D graphics library
124 Group: System/Libraries
125
126 BuildRequires: pkgconfig(xfixes) >= 4.0.3
127 BuildRequires: pkgconfig(xshmfence)
128 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 BuildRequires: libexpat-devel >= 2.0.1
133 BuildRequires: gccmakedep
134 BuildRequires: x11-proto-devel >= 7.3
135 BuildRequires: pkgconfig(libdrm) >= 2.4.60
136 BuildRequires: pkgconfig(xcb-dri3)
137 BuildRequires: pkgconfig(xcb-present) >= 1.11
138 BuildRequires: pkgconfig(xext) >= 1.1.1
139 BuildRequires: pkgconfig(xxf86vm) >= 1.1.0
140 BuildRequires: pkgconfig(xi) >= 1.3
141 BuildRequires: pkgconfig(talloc)
142 BuildRequires: libxml2-python
143 BuildRequires: python-mako
144 BuildRequires: makedepend
145 BuildRequires: bison
146 BuildRequires: flex
147 BuildRequires: libelf-devel
148 %if %{with hardware_gallium}
149 BuildRequires: llvm-devel >= 3.8
150 %endif
151 BuildRequires: pkgconfig(libudev)
152 BuildRequires: pkgconfig(libva)
153 BuildRequires: pkgconfig(vdpau)
154 %if %{enable_wayland}
155 BuildRequires: wayland-devel
156 %endif
157 %if %{enable_vulkan}
158 BuildRequires: libgcrypt-devel
159 %endif
160
161 URL: http://www.mesa3d.org
162 %if %{git}
163 Source0: %{name}-%{git}.tar.bz2
164 # (blino) snapshot of 9.0 branch
165 #Source0: %{name}-%{git_branch}-%{git}.tar.bz2
166 %else
167 Source0: ftp://ftp.freedesktop.org/pub/mesa/%{main_version}/mesa-%{main_version}%{vsuffix}.tar.xz
168 %endif
169 Source3: make-git-snapshot.sh
170
171 # Instructions to setup your repository clone
172 # git://git.freedesktop.org/git/mesa/mesa
173 # git checkout mesa_7_5_branch
174 # git branch mdv-cherry-picks
175 # git am ../02??-*.patch
176 # git branch mdv-redhat
177 # git am ../03??-*.patch
178 # git branch mdv-patches
179 # git am ../09??-*.patch
180 # In order to update to the branch via patches, issue this command:
181 # git format-patch --start-number 100 mesa_7_5_1..mesa_7_5_branch | sed 's/^0\([0-9]\+\)-/Patch\1: 0\1-/'
182
183 # upstream fixes
184 Patch102: 0102-i956-Add-more-Kabylake-PCI-IDs.patch
185 Patch103: 0103-i965-Removing-PCI-IDs-that-are-no-longer-listed-as-K.patch
186 Patch106: 0106-mesa-Don-t-call-GenerateMipmap-if-Width-or-Height-0.patch
187
188 # Cherry picks
189 # git format-patch --start-number 200 mesa_7_5_branch..mdv-cherry-picks
190 Patch201: 0201-revert-fix-glxinitializevisualconfigfromtags-handling.patch
191
192 # Patches "liberated" from Fedora:
193 # http://cvs.fedoraproject.org/viewvc/rpms/mesa/devel/
194 # git format-patch --start-number 300 mdv-cherry-picks..mdv-redhat
195
196 # Patches from ChromiumOS
197 # http://git.chromium.org/gitweb/?p=chromiumos/overlays/chromiumos-overlay.git;a=tree;f=media-libs/mesa/files;hb=HEAD
198
199 # Mageia/Mandriva patches
200 # git format-patch --start-number 900 mdv-redhat..mdv-patches
201 # (blino) llvmpipe test programs link fails when ld --as-needed option is used, reported as fdo #52167
202 #Patch901: 0901-gallium-only-link-static-archives-between-ld-start-e.patch
203
204 #------------------------------------------------------------------------------
205
206 # package mesa
207 License: MIT
208 Requires: %{libglname} = %{version}-%{release}
209 Provides: hackMesa = %{version}
210 Obsoletes: hackMesa <= %{version}
211 Provides: Mesa = %{version}
212 Obsoletes: Mesa < %{version}
213
214 %package -n %{libglname}
215 Summary: Files for Mesa (GL and GLX libs)
216 Group: System/Libraries
217 Obsoletes: %{oldlibglname} < 6.4
218 Provides: %{oldlibglname} = %{version}-%{release}
219 Provides: %{libglname_virt} = %{version}-%{release}
220 Requires: %{dridrivers} >= %{version}-%{release}
221 %if %{build_plf}
222 Requires: %mklibname txc-dxtn
223 %endif
224
225 # (anssi) Forces the upgrade of x11-server-common to happen before
226 # alternatives removal, which allows x11-server-common to grab the symlink.
227 Conflicts: x11-server-common < 1.3.0.0-17
228
229 %package -n %{dridrivers}
230 Summary: Mesa DRI drivers
231 Group: System/Libraries
232 # do not require exact release to avoid conflicts when having
233 # x86_64 dri drivers from tainted and i586 dri drivers from core
234 Requires: mesa = %{version}
235 Conflicts: %{_lib}MesaGL1 < 7.7-5
236 Obsoletes: %{_lib}dri-drivers-experimental < 7.11.2-4
237 Provides: %{_lib}dri-drivers-experimental = %{version}-%{release}
238
239 %if %{with hardware_gallium}
240 %package -n %{libd3dname}
241 Summary: Mesa Direct3D9 state tracker
242 Group: System/Libraries
243 Provides: %{libd3dname_virt} = %{version}-%{release}
244
245 %package -n %{libd3dname}-devel
246 Summary: Development files for Mesa Direct3D9 state tracker
247 Group: Development/C
248 Requires: %{libd3dname} = %{version}-%{release}
249 Provides: lib%{d3dname}-devel
250 Provides: %{d3dname}-devel
251 Provides: libd3d-devel
252 %endif
253
254 %package -n %{libglname}-devel
255 Summary: Development files for Mesa (OpenGL compatible 3D lib)
256 Group: Development/C
257 Requires: %{libglname} = %{version}-%{release}
258 Provides: lib%{glname}-devel = %{version}-%{release}
259 Provides: %{glname}-devel = %{version}-%{release}
260 Provides: GL-devel
261 Obsoletes: %{oldlibglname}-devel < 6.4
262 Provides: %{oldlibglname}-devel = %{version}-%{release}
263 Provides: libMesaGL-devel = %{version}-%{release}
264 Provides: MesaGL-devel = %{version}-%{release}
265 Provides: libgl-devel
266
267 %if %{enable_egl}
268 %package -n %{libeglname}
269 Summary: Files for Mesa (EGL libs)
270 Group: System/Libraries
271 Provides: %{libeglname_virt} = %{version}-%{release}
272
273 %package -n %{libeglname}-devel
274 Summary: Development files for Mesa (EGL libs)
275 Group: Development/C
276 Requires: %{libeglname} = %{version}-%{release}
277 Provides: EGL-devel
278 Provides: lib%{eglname}-devel
279 Provides: %{eglname}-devel
280 Provides: libegl-devel
281 %endif
282
283 %package -n %{libosmesaname}
284 Summary: Mesa offscreen rendering library
285 Group: System/Libraries
286
287 %package -n %{osmesadevel}
288 Summary: Development files for libosmesa
289 Group: Development/C
290 Requires: %{libosmesaname} = %{version}-%{release}
291 Provides: osmesa-devel = %{version}-%{release}
292 Conflicts: MesaGL-devel < 8.1.0-0.git20120727.3
293
294 %package -n %{libglapiname}
295 Summary: Files for mesa (glapi libs)
296 Group: System/Libraries
297 Provides: %{libglapiname_virt} = %{version}-%{release}
298
299 %package -n %{libglapiname}-devel
300 Summary: Development files for glapi libs
301 Group: Development/C
302 Requires: %{libglapiname_virt} = %{version}-%{release}
303 Provides: lib%{glapiname}-devel
304 Provides: %{libglapiname}-devel
305
306 %package -n %{libglesv1name}
307 Summary: Files for Mesa (glesv1 libs)
308 Group: System/Libraries
309 Provides: %{libglesv1name_virt} = %{version}-%{release}
310
311 %package -n %{libglesv1name}-devel
312 Summary: Development files for glesv1 libs
313 Group: Development/C
314 Requires: %{libglesv1name} = %{version}-%{release}
315 Provides: lib%{glesv1name}-devel
316 Provides: %{glesv1name}-devel
317 Provides: libglesv1-devel
318
319 %package -n %{libglesv2name}
320 Summary: Files for Mesa (glesv2 libs)
321 Group: System/Libraries
322 Provides: %{libglesv2name_virt} = %{version}-%{release}
323
324 %package -n %{libglesv2name}-devel
325 Summary: Development files for glesv2 libs
326 Group: Development/C
327 Requires: %{libglesv2name} = %{version}-%{release}
328 Requires: %{libeglname}-devel = %{version}-%{release}
329 Provides: lib%{glesv2name}-devel
330 Provides: %{glesv2name}-devel
331 Provides: libglesv2-devel
332
333 %if %{enable_vg}
334 %package -n %{libopenvgname}
335 Summary: Files for MESA (OpenVG libs)
336 Group: System/Libraries
337 Provides: %{libopenvgname_virt} = %{version}-%{release}
338
339 %package -n %{libopenvgname}-devel
340 Summary: Development files vor OpenVG libs
341 Group: Development/C
342 Requires: %{libopenvgname} = %{version}-%{release}
343 Provides: lib%{openvgname}-devel
344 Provides: %{openvgname}-devel
345 Provides: libopenvg-devel
346 %endif
347
348 %if %{enable_wayland}
349 %package -n %{libgbmname}
350 Summary: Files for Mesa (gbm libs)
351 Group: System/Libraries
352 Provides: %{libgbmname_virt} = %{version}-%{release}
353
354 %package -n %{libgbmname}-devel
355 Summary: Development files for Mesa (gbm libs)
356 Group: Development/C
357 Requires: %{libgbmname} = %{version}-%{release}
358 Provides: lib%{gbmname}-devel
359 Provides: %{gbmname}-devel
360
361 %package -n %{libwaylandeglname}
362 Summary: Files for Mesa (Wayland EGL libs)
363 Group: System/Libraries
364 Provides: %{libwaylandeglname_virt} = %{version}-%{release}
365
366 %package -n %{libwaylandeglname}-devel
367 Summary: Development files for Mesa (Wayland EGL libs)
368 Group: Development/C
369 Requires: %{libwaylandeglname} = %{version}-%{release}
370 Provides: lib%{waylandeglname}-devel
371 Provides: %{waylandeglname}-devel
372 %endif
373
374 %if %{with hardware_gallium}
375 %package -n %{_lib}vdpau-driver-nouveau
376 Summary: VDPAU plugin for nouveau driver
377 Group: System/Libraries
378 # temporary:
379 %rename vdpau-driver-nouveau
380
381 %package -n %{_lib}vdpau-driver-r300
382 Summary: VDPAU plugin for r300 driver
383 Group: System/Libraries
384 # temporary:
385 %rename vdpau-driver-r300
386
387 %package -n %{_lib}vdpau-driver-r600
388 Summary: VDPAU plugin for r600 driver
389 Group: System/Libraries
390 # temporary:
391 %rename vdpau-driver-r600
392
393 %package -n %{_lib}vdpau-driver-radeonsi
394 Summary: VDPAU plugin for radeonsi driver
395 Group: System/Libraries
396 # temporary:
397 %rename vdpau-driver-radeonsi
398
399 %package -n %{libxaname}
400 Summary: Files for Mesa XA state tracker
401 Group: System/Libraries
402 Provides: %{libxaname_virt} = %{version}-%{release}
403
404 %package -n %{libxaname}-devel
405 Summary: Development files for XA libs
406 Group: Development/C
407 Requires: %{libxaname_virt} = %{version}-%{release}
408 Provides: lib%{xaname}-devel
409 Provides: %{libxaname}-devel
410 %endif
411
412 %if %{enable_vulkan}
413 %package -n %{libvulkanname}_intel
414 Summary: Mesa vulkan driver for Intel GPU
415 Group: System/Libraries
416
417 %package -n %{libvulkanname}-devel
418 Summary: Mesa's Vulkan development files
419 Group: Development/C
420 Requires: %{libvulkanname}_intel = %{version}-%{release}
421 Provides: libvulkan-devel
422 Provides: libvulkan_intel-devel
423 %endif
424
425 %package common-devel
426 Summary: Meta package for mesa devel
427 Group: Development/C
428 Provides: Mesa-common-devel = %{version}-%{release}
429 Provides: hackMesa-common-devel = %{version}
430 Obsoletes: Mesa-common-devel < %{version}
431 Obsoletes: hackMesa-common-devel < %{version}
432 Requires: %{libglname}-devel = %{version}
433 Requires: mesaglu-devel
434 Requires: freeglut-devel
435 Requires: %{libeglname}-devel = %{version}
436 Requires: %{libglesv1name}-devel = %{version}
437 Requires: %{libglesv2name}-devel = %{version}
438
439 #------------------------------------------------------------------------------
440
441 %description
442 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
443 %if %{build_plf}
444
445 This package is in the "tainted" section because it enables some
446 OpenGL extentions that are covered by software patents.
447 %endif
448
449 %description common-devel
450 Mesa common metapackage devel
451
452 %if %{enable_egl}
453 %description -n %{libeglname}
454 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
455 EGL parts.
456
457 %description -n %{libeglname}-devel
458 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
459 EGL development parts.
460 %endif
461
462 %description -n %{libglname}
463 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
464 GL and GLX parts.
465
466 %if %{build_plf}
467 This package is in the "tainted" section because it enables some
468 OpenGL extentions that are covered by software patents.
469 %endif
470
471 %description -n %{dridrivers}
472 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
473 DRI drivers.
474
475 %description -n %{libglname}-devel
476 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
477
478 This package contains the headers needed to compile Mesa programs.
479
480 %description -n %{libglesv1name}
481 OpenGL ES is a low-level, lightweight API for advanced embedded graphics using
482 well-defined subset profiles of OpenGL.
483
484 This package provides the OpenGL ES library version 1.
485
486 %description -n %{libosmesaname}
487 Mesa offscreen rendering libraries for rendering OpenGL into
488 application-allocated blocks of memory.
489
490 %description -n %{osmesadevel}
491 This package contains the headers needed to compile programs against
492 the Mesa offscreen rendering library.
493
494 %description -n %{libglapiname}
495 This packages provides the glapi shared library used by gallium.
496
497 %description -n %{libglapiname}-devel
498 This package contains the headers needed to compile programes against glapi shared library.
499
500 %description -n %{libglesv1name}-devel
501 This package contains the headers needed to compile OpenGL ES 1 programs.
502
503 %if %{with hardware_gallium}
504 %description -n %{libd3dname}
505 Mesa Direct3D9 state tracker.
506
507 %description -n %{libd3dname}-devel
508 Mesa Direct3D9 state tracker development package.
509 %endif
510
511 %description -n %{libglesv2name}
512 OpenGL ES is a low-level, lightweight API for advanced embedded graphics using
513 well-defined subset profiles of OpenGL.
514
515 This package provides the OpenGL ES library version 2.
516
517 %description -n %{libglesv2name}-devel
518 This package contains the headers needed to compile OpenGL ES 2 programs.
519
520 %if %{enable_vg}
521 %description -n %{libopenvgname}
522 OpenVG is a royalty-free, cross-platform API that provides a low-level hardware
523 acceleration interface for vector graphics libraries such as Flash and SVG.
524
525 %description -n %{libopenvgname}-devel
526 Development files for OpenVG library.
527 %endif
528
529 %if %{enable_wayland}
530 %description -n %{libgbmname}
531 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
532 GBM (Graphics Buffer Manager) parts.
533
534 %description -n %{libgbmname}-devel
535 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
536 GBM (Graphics Buffer Manager) development parts.
537
538 %description -n %{libwaylandeglname}
539 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
540 Wayland EGL platform parts.
541
542 %description -n %{libwaylandeglname}-devel
543 Mesa is an OpenGL %{opengl_ver} compatible 3D graphics library.
544 Wayland EGL platform development parts.
545 %endif
546
547 %if %{with hardware_gallium}
548 %description -n %{libxaname}
549 This packages provides the xa shared library used by gallium.
550
551 %description -n %{libxaname}-devel
552 This package contains the headers needed to compile programes against xa shared library.
553
554 %description -n %{_lib}vdpau-driver-nouveau
555 This packages provides a VPDAU plugin to enable video acceleration
556 with the nouveau driver.
557
558 %description -n %{_lib}vdpau-driver-r300
559 This packages provides a VPDAU plugin to enable video acceleration
560 with the r300 driver.
561
562 %description -n %{_lib}vdpau-driver-r600
563 This packages provides a VPDAU plugin to enable video acceleration
564 with the r600 driver.
565
566 %description -n %{_lib}vdpau-driver-radeonsi
567 This packages provides a VPDAU plugin to enable video acceleration
568 with the radeonsi driver.
569 %endif
570
571 %if %{enable_vulkan}
572 %description -n %{libvulkanname}_intel
573 This package contains the Vulkan parts for Mesa's Intel driver.
574
575 %description -n %{libvulkanname}-devel
576 This package contains the development files for Mesa's Vulkan implementation.
577 %endif
578
579 #------------------------------------------------------------------------------
580
581 %prep
582 %if %{git}
583 %setup -q -n mesa-%{git}
584 #setup -q -n mesa-%{git_branch}-%{git}
585 %else
586 %setup -q -n mesa-%{main_version}%{vsuffix}
587 %endif
588
589 %autopatch -p1
590
591 # Duplicate source tree for OSMesa, since building both versions out-of-tree
592 # would break build. - Anssi 12/2012
593 all=$(ls)
594 mkdir -p build-osmesa
595 cp -al $all build-osmesa
596
597 %build
598 # (re)generate auto* generated files using our autotools and libtoolize
599 autoreconf -vfi
600
601 # for bin/test-driver:
602 automake --add-missing
603
604 %configure2_5x --enable-dri \
605 --enable-glx \
606 --enable-glx-tls \
607 --with-dri-driverdir=%{driver_dir} \
608 %if %{enable_vulkan}
609 --with-vulkan-drivers=intel \
610 %endif
611 --enable-va \
612 %if %{enable_egl}
613 --enable-egl \
614 %else
615 --disable-egl \
616 %endif
617 %if %{enable_wayland}
618 --with-egl-platforms=x11,wayland,drm \
619 --enable-gbm \
620 --enable-shared-glapi \
621 %endif
622 --enable-gles1 \
623 --enable-gles2 \
624 %if %{enable_vg}
625 --enable-openvg \
626 %endif
627 --enable-gallium-egl \
628 --disable-xvmc \
629 --enable-vdpau \
630 %if %{with hardware_gallium}
631 --with-gallium-drivers=r300,r600,radeonsi,nouveau,svga,swrast,virgl \
632 --enable-gallium-llvm \
633 --enable-xa \
634 --enable-nine \
635 %else
636 --disable-gallium-llvm \
637 --with-gallium-drivers=swrast \
638 %endif
639 %if %{build_plf}
640 --enable-texture-float \
641 %endif
642 %{?dri_drivers}
643 # end of configure options
644
645
646 # Build OSMesa separately, since we want to build OSMesa without shared-glapi,
647 # since doing that causes OSMesa to miss the OpenGL symbols.
648 # See e.g. https://bugs.launchpad.net/ubuntu/+source/mesa/+bug/1066599
649 # -Anssi 12/2012
650
651 pushd build-osmesa
652 autoreconf -vfi
653 %configure2_5x \
654 --enable-osmesa \
655 --disable-dri \
656 --disable-glx \
657 --disable-egl \
658 --enable-shared-glapi \
659 --without-gallium-drivers
660 popd
661
662 %make
663 %make -C build-osmesa || ( %make -C build-osmesa/src/mesa/program libprogram.la && %make -C build-osmesa )
664
665 %install
666 %make_install -C build-osmesa
667 %make_install
668
669 # FIXME: strip will likely break the hardlink
670 # (blino) hardlink libGL files in %{_libdir}/mesa
671 # to prevent proprietary driver installers from removing them
672 mkdir -p $RPM_BUILD_ROOT%{_libdir}/mesa
673 pushd $RPM_BUILD_ROOT%{_libdir}/mesa
674 for l in ../libGL.so.*; do cp -a $l .; done
675 popd
676
677 %ifarch %{x86_64}
678 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib/dri
679 %endif
680
681 # .so files are not needed by vdpau
682 rm -f %{buildroot}%{_libdir}/vdpau/libvdpau_*.so
683
684 # .la files are not needed by mesa
685 find %{buildroot} -name '*.la' -delete
686
687 # use swrastg if built (Anssi 12/2011)
688 [ -e %{buildroot}%{_libdir}/dri/swrastg_dri.so ] && mv %{buildroot}%{_libdir}/dri/swrast{g,}_dri.so
689
690 #------------------------------------------------------------------------------
691
692 %files
693 %config(noreplace) %{_sysconfdir}/drirc
694
695 %files -n %{dridrivers}
696 %dir %{_libdir}/dri
697 %{_libdir}/dri/*_dri.so
698 %{_libdir}/dri/*_drv*.so
699
700 %files -n %{libglname}
701 %{_libdir}/libGL.so.*
702 %dir %{_libdir}/mesa
703 %{_libdir}/mesa/libGL.so.%{glmajor}{,.*}
704
705 %if %{enable_egl}
706 %files -n %{libeglname}
707 %{_libdir}/libEGL.so.%{eglmajor}{,.*}
708 %if !%{enable_wayland}
709 # st_GL, built only when shared glapi is not enabled
710 %{_libdir}/egl/st_GL.so
711 %endif
712 %endif
713
714 %files -n %{libosmesaname}
715 %{_libdir}/libOSMesa.so.%{osmesamajor}{,.*}
716
717 %files -n %{libglapiname}
718 %{_libdir}/libglapi.so.%{glapimajor}{,.*}
719
720 %files -n %{libglesv1name}
721 %{_libdir}/libGLESv1_CM.so.%{glesv1major}{,.*}
722
723 %if %{with hardware_gallium}
724 %files -n %{libd3dname}
725 %{_libdir}/d3d/*.so.*
726 %endif
727
728 %files -n %{libglesv2name}
729 %{_libdir}/libGLESv2.so.%{glesv2major}{,.*}
730
731 %if %{enable_vg}
732 %files -n %{libopenvgname}
733 %{_libdir}/libOpenVG.so.%{openvgmajor}{,.*}
734 %endif
735
736 %if %{enable_wayland}
737 %files -n %{libgbmname}
738 %{_libdir}/libgbm.so.%{gbmmajor}
739 %{_libdir}/libgbm.so.%{gbmmajor}.*
740
741 %files -n %{libwaylandeglname}
742 %{_libdir}/libwayland-egl.so.%{waylandeglmajor}
743 %{_libdir}/libwayland-egl.so.%{waylandeglmajor}.*
744 %endif
745
746 %if %{with hardware_gallium}
747 %files -n %{libxaname}
748 %{_libdir}/libxatracker.so.%{xamajor}{,.*}
749 %endif
750
751 %files -n %{libglname}-devel
752 %dir %{_includedir}/GL
753 %{_includedir}/GL/gl.h
754 %{_includedir}/GL/glcorearb.h
755 %{_includedir}/GL/glext.h
756 %{_includedir}/GL/gl_mangle.h
757 %{_includedir}/GL/glx.h
758 %{_includedir}/GL/glxext.h
759 %{_includedir}/GL/glx_mangle.h
760 %{_includedir}/GL/mesa_glinterop.h
761 %{_includedir}/GL/wglext.h
762 %{_libdir}/libGL.so
763 %{_libdir}/pkgconfig/gl.pc
764 %{_libdir}/pkgconfig/dri.pc
765
766 %dir %{_includedir}/GL/internal
767 %{_includedir}/GL/internal/dri_interface.h
768
769 %files common-devel
770 %if %{enable_egl}
771 %files -n %{libeglname}-devel
772 %{_includedir}/EGL
773 %{_includedir}/KHR
774 %{_libdir}/libEGL.so
775 %{_libdir}/pkgconfig/egl.pc
776 %endif
777
778 %files -n %{osmesadevel}
779 %dir %{_includedir}/GL
780 %{_includedir}/GL/osmesa.h
781 %{_libdir}/libOSMesa.so
782 %{_libdir}/pkgconfig/osmesa.pc
783
784 %files -n %{libglapiname}-devel
785 %{_libdir}/libglapi.so
786
787 %files -n %{libglesv1name}-devel
788 %{_includedir}/GLES
789 %{_libdir}/libGLESv1_CM.so
790 %{_libdir}/pkgconfig/glesv1_cm.pc
791
792 %files -n %{libglesv2name}-devel
793 %{_includedir}/GLES2
794 %{_includedir}/GLES3
795 %{_libdir}/libGLESv2.so
796 %{_libdir}/pkgconfig/glesv2.pc
797
798 %if %{with hardware_gallium}
799 %files -n %{libd3dname}-devel
800 %{_includedir}/d3dadapter
801 %{_libdir}/d3d/*.so
802 %{_libdir}/pkgconfig/d3d.pc
803 %endif
804
805 %if %{enable_vg}
806 %files -n %{libopenvgname}-devel
807 %{_includedir}/VG
808 %{_libdir}/libOpenVG.so
809 %{_libdir}/pkgconfig/vg.pc
810 %endif
811
812 %if %{enable_wayland}
813 %files -n %{libgbmname}-devel
814 %{_includedir}/gbm.h
815 %{_libdir}/libgbm.so
816 %{_libdir}/pkgconfig/gbm.pc
817
818 %files -n %{libwaylandeglname}-devel
819 %{_libdir}/libwayland-egl.so
820 %{_libdir}/pkgconfig/wayland-egl.pc
821 %endif
822
823 %if %{with hardware_gallium}
824 %files -n %{libxaname}-devel
825 %{_libdir}/libxatracker.so
826 %{_includedir}/xa_tracker.h
827 %{_includedir}/xa_composite.h
828 %{_includedir}/xa_context.h
829 %{_libdir}/pkgconfig/xatracker.pc
830
831 %files -n %{_lib}vdpau-driver-nouveau
832 %{_libdir}/vdpau/libvdpau_nouveau.so.*
833
834 %files -n %{_lib}vdpau-driver-r300
835 %{_libdir}/vdpau/libvdpau_r300.so.*
836
837 %files -n %{_lib}vdpau-driver-r600
838 %{_libdir}/vdpau/libvdpau_r600.so.*
839
840 %files -n %{_lib}vdpau-driver-radeonsi
841 %{_libdir}/vdpau/libvdpau_radeonsi.so.*
842 %endif
843
844 %if %{enable_vulkan}
845 %files -n %{libvulkanname}_intel
846 %dir %{_datadir}/vulkan
847 %dir %{_datadir}/vulkan/icd.d
848 %{_datadir}/vulkan/icd.d/intel_icd.json
849 # (akien) No lib major?
850 %{_libdir}/libvulkan_intel.so
851
852 %files -n %{libvulkanname}-devel
853 %{_includedir}/vulkan/
854 %endif

  ViewVC Help
Powered by ViewVC 1.1.30