File Mesa.spec of Package Mesa

1416
 
1
#
2
# spec file for package Mesa
3
#
4
# Copyright (c) 2025 SUSE LLC
5
#
6
# All modifications and additions to the file contributed by third parties
7
# remain the property of their copyright owners, unless otherwise agreed
8
# upon. The license for this file, and modifications and additions to the
9
# file, is the same license as for the pristine package itself (unless the
10
# license for the pristine package is not an Open Source License, in which
11
# case the license is the MIT License). An "Open Source License" is a
12
# license that conforms to the Open Source Definition (Version 1.9)
13
# published by the Open Source Initiative.
14
15
# Please submit bugfixes or comments via https://bugs.opensuse.org/
16
#
17
18
19
#!BuildIgnore: Mesa-dri
20
21
%global flavor @BUILD_FLAVOR@%{nil}
22
%if "%{flavor}" == "drivers"
23
%global psuffix -drivers
24
%else
25
%global psuffix %{nil}
26
%endif
27
28
%ifarch %{ix86} x86_64 armv6l armv6hl
29
%define _lto_cflags %{nil}
30
%endif
31
32
# Possible patent issues, see
33
# https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15258
34
# for more details
35
%if 0%{?BUILD_ORIG}
36
%define video_codecs 1
37
%else
38
%define video_codecs 0
39
%endif
40
41
%define drivers 0
42
43
%define glamor 1
44
%define _name_archive mesa
45
%ifnarch s390x
46
%define _version 24.3.3
47
%else
48
%define _version 24.1.7
49
%endif
50
%define with_opencl 0
51
%define with_rusticl 0
52
%define with_vulkan 0
53
%define with_llvm 0
54
55
%ifarch %{ix86} x86_64 %{arm} aarch64 ppc64 ppc64le riscv64
56
  %define gallium_loader 1
57
%else
58
  %define gallium_loader 0
59
%endif
60
61
%define vdpau_nouveau 0
62
%define vdpau_radeon 0
63
%define vdpau_virtio_gpu 0
64
%define vdpau_d3d12 0
65
66
%ifarch %{ix86} x86_64 aarch64 %{arm} ppc64 ppc64le riscv64
67
  %define vdpau_nouveau 1
68
  %define vdpau_radeon 1
69
  %define vdpau_virtio_gpu 1
70
%ifarch %{ix86} x86_64
71
  %define vdpau_d3d12 1
72
%endif
73
%endif
74
75
%ifarch %{ix86} x86_64
76
  %define with_nine 1
77
%endif
78
79
%if 0%{gallium_loader}
80
  %define with_opencl 1
81
  %ifarch %{ix86} x86_64
82
    %define with_vulkan 1
83
    %if 0%{?suse_version} > 1600
84
    %define vulkan_drivers swrast,amd,intel,intel_hasvk,nouveau
85
    %else
86
    %define vulkan_drivers swrast,amd,intel,intel_hasvk
87
    %endif
88
  %endif
89
  %ifarch %{arm} aarch64
90
    %define with_vulkan 1
91
    %if 0%{?suse_version} > 1600
92
    %define vulkan_drivers swrast,amd,broadcom,freedreno,intel,intel_hasvk,nouveau
93
    %else
94
    %define vulkan_drivers swrast,amd,broadcom,freedreno,intel,intel_hasvk
95
    %endif
96
  %endif
97
  %ifarch riscv64
98
    %define with_vulkan 1
99
    %define vulkan_drivers swrast,amd,intel,intel_hasvk
100
  %endif
101
%endif
102
103
%ifarch aarch64 %{arm} ppc64 ppc64le riscv64 s390x %{ix86} x86_64 ix86
104
  %define with_llvm 1
105
%endif
106
107
%if 0%{with_opencl}
108
%define have_gallium 1
109
%else
110
%define have_gallium 0
111
%endif
112
113
%if "%{flavor}" == "drivers"
114
  %define glamor 1
115
%if 0%{?suse_version} >= 1550 && 0%{with_opencl}
116
  %define with_rusticl 1
117
%endif
118
%else
119
  # No llvm dependencies
120
  %define with_llvm 0
121
122
  # OpenCL requires clang (LLVM)
123
  %define with_opencl 0
124
125
  # nine requires at least one non-swrast gallium driver
126
  %define with_nine 0
127
128
  # Not built because radeon driver is not built.
129
  %define vdpau_radeon 0
130
131
  # Not built because nouveau driver is not built.
132
  %define vdpau_nouveau 0
133
134
  # Not built because virtio_gpu driver is not built.
135
  %define vdpau_virtio_gpu 0
136
137
  # Not built because d3d12 driver is not built.
138
  %define vdpau_d3d12 0
139
140
  # Vulkan includes radv driver which requires llvm
141
  %define with_vulkan 0
142
%endif
143
144
# NVK aka Vulkan Nouveau dependencies
145
%global _unicode_ident_crate_ver 1.0.12
146
%global _syn_crate_ver 2.0.68
147
%global _quote_crate_ver 1.0.33
148
%global _proc_macro2_ver 1.0.86
149
%global _paste_crate_ver 1.0.14
150
151
# Leap 15 and SLES 15 defaults to GCC 7, which does not have stable C++17 ABI.
152
# See https://bugzilla.suse.com/show_bug.cgi?id=1235697
153
%if 0%{?suse_version} < 1600
154
%define gcc_version 13
155
%endif
156
157
Name:           Mesa%{psuffix}
158
%ifnarch s390x
159
Version:        24.3.3
160
%else
161
Version:        24.1.7
162
%endif
163
Release:        0
164
Summary:        System for rendering 3-D graphics
165
License:        MIT
166
Group:          System/Libraries
167
URL:            https://www.mesa3d.org
168
#Git-Clone:     git://anongit.freedesktop.org/mesa/mesa
169
Source0:        https://archive.mesa3d.org/%{_name_archive}-%{_version}.tar.xz
170
Source1:        https://archive.mesa3d.org/%{_name_archive}-%{_version}.tar.xz.sig
171
# NVK aka Vulkan Nouveau dependencies
172
# Explainer:
173
# Since Rust crates are not installed or discouraged to be installed as system
174
# dependencies because of the maintenance burden of being the next crates.io,
175
# we will have to download the following crates as vendored dependencies.
176
# Hence, do not be scared if the dependencies are done like this
177
# To check new crates or update the versions, just go to the subprojects folder and
178
# run `grep -r crates .` then set versions appropriately.
179
Source2:        http://crates.io/api/v1/crates/unicode-ident/%{_unicode_ident_crate_ver}/download#/unicode-ident-%{_unicode_ident_crate_ver}.tar.gz
180
Source3:        http://crates.io/api/v1/crates/syn/%{_syn_crate_ver}/download#/syn-%{_syn_crate_ver}.tar.gz
181
Source4:        http://crates.io/api/v1/crates/quote/%{_quote_crate_ver}/download#/quote-%{_quote_crate_ver}.tar.gz
182
Source5:        http://crates.io/api/v1/crates/proc-macro2/%{_proc_macro2_ver}/download#/proc-macro2-%{_proc_macro2_ver}.tar.gz
183
Source6:        http://crates.io/api/v1/crates/paste/%{_paste_crate_ver}/download#/paste-%{_paste_crate_ver}.tar.gz
184
Source7:        baselibs.conf
185
Source8:        README.updates
186
Source9:        manual-pages.tar.bz2
187
Source10:       Mesa-rpmlintrc
188
Source11:       Mesa.keyring
189
Source12:       README-suse-maintenance.md
190
Source20:       https://archive.mesa3d.org/%{_name_archive}-24.3.3.tar.xz
191
Source21:       https://archive.mesa3d.org/%{_name_archive}-24.3.3.tar.xz.sig
192
Patch2:         n_add-Mesa-headers-again.patch
193
Patch11:        u_0001-intel-genxml-Drop-from-__future__-import-annotations.patch
194
Patch12:        u_0002-intel-genxml-Add-a-untyped-OrderedDict-fallback-for-.patch
195
%ifnarch s390x
196
Patch13:        python36-buildfix1.patch
197
%else
198
Patch13:        python36-buildfix1-s390x.patch
199
%endif
200
Patch14:        python36-buildfix2.patch
201
Patch17:        tlsdesc_test.patch
202
# never to be upstreamed
203
Patch54:        n_drirc-disable-rgb10-for-chromium-on-amd.patch
204
Patch100:       U_fix-mpeg1_2-decode-mesa-20.2.patch
205
Patch400:       n_stop-iris-flicker.patch
206
%ifnarch s390x
207
Patch500:       u_dep_xcb.patch
208
%else
209
Patch500:       u_dep_xcb-s390x.patch
210
%endif
211
%ifnarch s390x
212
Patch600:       U_egl-never-select-swrast-for-vmwgfx.patch
213
Patch701:       U_0001-svga-add-svga_resource_create_with_modifiers-functio.patch
214
Patch702:       U_0002-svga-fix-printing-64-bit-value-for-32-bit-build.patch
215
%endif
216
%ifnarch s390x
217
Patch1222040:   u_mesa-CVE-2023-45913.patch
218
%else
219
Patch1222040:   u_mesa-CVE-2023-45913-s390x.patch
220
%endif
221
Patch1222041:   u_mesa-CVE-2023-45919.patch
222
Patch1222042:   u_mesa-CVE-2023-45922.patch
223
224
%ifarch %{ix86} x86_64
225
BuildRequires:  DirectX-Headers >= 1.613.0
226
%endif
227
BuildRequires:  bison
228
BuildRequires:  cmake
229
BuildRequires:  fdupes
230
BuildRequires:  flex
231
BuildRequires:  gcc%{?gcc_version} >= 9
232
BuildRequires:  gcc%{?gcc_version}-c++ >= 9
233
BuildRequires:  glslang-devel
234
BuildRequires:  imake
235
BuildRequires:  libtool
236
BuildRequires:  memory-constraints
237
%if 0%{with_rusticl}
238
BuildRequires:  meson >= 1.4.0
239
%else
240
BuildRequires:  meson >= 1.1.0
241
%endif
242
BuildRequires:  pkgconfig
243
BuildRequires:  python3-base
244
# dataclasses is in standard library of python >= 3.7
245
%if 0%{?suse_version} < 1550
246
BuildRequires:  python3-dataclasses
247
%endif
248
BuildRequires:  python3-Mako
249
BuildRequires:  python3-PyYAML
250
BuildRequires:  python3-xml
251
BuildRequires:  pkgconfig(dri2proto)
252
BuildRequires:  pkgconfig(dri3proto)
253
BuildRequires:  pkgconfig(expat)
254
BuildRequires:  pkgconfig(glproto)
255
BuildRequires:  pkgconfig(libdrm) >= 2.4.109
256
BuildRequires:  pkgconfig(libdrm_amdgpu) >= 2.4.121
257
BuildRequires:  pkgconfig(libdrm_nouveau) >= 2.4.66
258
BuildRequires:  pkgconfig(libdrm_radeon) >= 2.4.71
259
BuildRequires:  pkgconfig(libglvnd) >= 1.3.2
260
%ifarch aarch64 x86_64 ppc64le s390x riscv64
261
BuildRequires:  pkgconfig(valgrind)
262
%endif
263
BuildRequires:  pkgconfig(libva)
264
BuildRequires:  pkgconfig(presentproto)
265
%if "%{flavor}" == "drivers"
266
BuildRequires:  pkgconfig(vdpau) >= 1.5
267
%ifarch %{ix86} x86_64
268
BuildRequires:  pkgconfig(vulkan)
269
%endif
270
%endif
271
BuildRequires:  pkgconfig(x11)
272
BuildRequires:  pkgconfig(x11-xcb)
273
BuildRequires:  pkgconfig(xcb-dri2)
274
BuildRequires:  pkgconfig(xcb-dri3)
275
BuildRequires:  pkgconfig(xcb-glx)
276
BuildRequires:  pkgconfig(xcb-present)
277
BuildRequires:  pkgconfig(xdamage)
278
BuildRequires:  pkgconfig(xext)
279
BuildRequires:  pkgconfig(xfixes)
280
BuildRequires:  pkgconfig(xrandr)
281
BuildRequires:  pkgconfig(xshmfence)
282
BuildRequires:  pkgconfig(xxf86vm)
283
BuildRequires:  pkgconfig(zlib)
284
Provides:       Mesa7 = %{version}
285
Obsoletes:      Mesa7 < %{version}
286
Provides:       intel-i810-Mesa = %{version}
287
Obsoletes:      intel-i810-Mesa < %{version}
288
Provides:       Mesa-libIndirectGL1 = %{version}
289
Obsoletes:      Mesa-libIndirectGL1 < %{version}
290
Provides:       Mesa-nouveau3d = %{version}
291
Provides:       xorg-x11-Mesa = %{version}
292
Obsoletes:      Mesa-nouveau3d < %{version}
293
Obsoletes:      xorg-x11-Mesa < %{version}
294
Provides:       s2tc = %{version}
295
Obsoletes:      s2tc < %{version}
296
Provides:       libXvMC_nouveau = %{version}
297
Obsoletes:      libXvMC_nouveau < %{version}
298
Provides:       libXvMC_r600 = %{version}
299
Obsoletes:      libXvMC_r600 < %{version}
300
Provides:       libtxc_dxtn = %{version}
301
Obsoletes:      libtxc_dxtn < %{version}
302
%ifarch %{arm} aarch64
303
%if 0%{?suse_version} >= 1550
304
BuildRequires:  python3-pycparser >= 2.20
305
BuildRequires:  pkgconfig(libdrm_etnaviv) >= 2.4.89
306
%endif
307
BuildRequires:  pkgconfig(libdrm_freedreno) >= 2.4.74
308
BuildRequires:  pkgconfig(libelf)
309
%endif
310
%ifarch x86_64 %{ix86} aarch64 %{arm} riscv64
311
BuildRequires:  libelf-devel
312
BuildRequires:  pkgconfig(libdrm_intel) >= 2.4.75
313
%else
314
%if 0%{with_opencl}
315
BuildRequires:  libelf-devel
316
%endif
317
%endif
318
# Requirements for wayland bumped up from 17.0
319
BuildRequires:  pkgconfig(wayland-client) >= 1.11
320
BuildRequires:  pkgconfig(wayland-protocols) >= 1.8
321
BuildRequires:  pkgconfig(wayland-server) >= 1.11
322
%if 0%{with_llvm}
323
%if 0%{?suse_version} >= 1550
324
BuildRequires:  llvm-devel >= 15
325
%else
326
%if 0%{?sle_version} >= 150600
327
BuildRequires:  llvm19-devel
328
%endif
329
%endif
330
%endif
331
332
%if 0%{with_opencl}
333
%if 0%{?suse_version} >= 1550
334
BuildRequires:  clang-devel
335
%else
336
%if 0%{?sle_version} >= 150600
337
BuildRequires:  clang19-devel
338
%endif
339
%endif
340
BuildRequires:  libclc
341
BuildRequires:  pkgconfig(LLVMSPIRVLib)
342
BuildRequires:  pkgconfig(SPIRV-Tools)
343
# For NVK or libvulkan_nouveau.so
344
# Rust Cbindgen >=0.25 is required
345
# but it's only available on tumbleweed
346
%if 0%{?suse_version} > 1600
347
BuildRequires:  rust-cbindgen >= 0.25
348
%endif
349
%if 0%{with_rusticl}
350
BuildRequires:  rust
351
BuildRequires:  rust-bindgen
352
%endif
353
%endif
354
355
Requires:       Mesa-libEGL1 = %{version}
356
Requires:       Mesa-libGL1 = %{version}
357
Requires:       libglvnd >= 0.1.0
358
359
# This dependency on Mesa-dri and Mesa-gallium is here to make sure users that
360
# do not install recommends on their system still get working Mesa. It is
361
# ignored in obs when Mesa is installed as build dependency.
362
Requires:       Mesa-dri = %{version}
363
%if 0%{have_gallium}
364
Requires:       Mesa-gallium = %{version}
365
%endif
366
367
%description
368
Mesa is a 3-D graphics library with an API which is very similar to
369
that of OpenGL.* To the extent that Mesa utilizes the OpenGL command
370
syntax or state machine, it is being used with authorization from
371
Silicon Graphics, Inc.(SGI). However, the author does not possess an
372
OpenGL license from SGI, and makes no claim that Mesa is in any way a
373
compatible replacement for OpenGL or associated with SGI. Those who
374
want a licensed implementation of OpenGL should contact a licensed
375
vendor.
376
377
Please do not refer to the library as MesaGL (for legal reasons). It's
378
just Mesa or The Mesa 3-D graphics library.
379
380
* OpenGL is a trademark of Silicon Graphics Incorporated.
381
382
%package devel
383
Summary:        Libraries, includes and more to develop Mesa applications
384
Group:          Development/Libraries/X11
385
Requires:       Mesa = %{version}
386
Requires:       Mesa-dri-devel = %{version}
387
Requires:       Mesa-libEGL-devel = %{version}
388
Requires:       Mesa-libGL-devel = %{version}
389
Requires:       Mesa-libGLESv1_CM-devel = %{version}
390
Requires:       Mesa-libGLESv2-devel = %{version}
391
Requires:       Mesa-libglapi-devel = %{version}
392
Requires:       libOSMesa-devel = %{version}
393
Requires:       libgbm-devel = %{version}
394
Provides:       Mesa-devel-static = %{version}
395
Provides:       xorg-x11-Mesa-devel = %{version}
396
Requires:       libglvnd-devel >= 1.2.0
397
Obsoletes:      Mesa-devel-static < %{version}
398
Obsoletes:      xorg-x11-Mesa-devel < %{version}
399
Provides:       Mesa-libIndirectGL-devel = %{version}
400
Obsoletes:      Mesa-libIndirectGL-devel < %{version}
401
Provides:       s2tc-devel = %{version}
402
Obsoletes:      s2tc-devel < %{version}
403
Provides:       libtxc_dxtn-devel = %{version}
404
Obsoletes:      libtxc_dxtn-devel < %{version}
405
406
%description devel
407
Mesa is a 3-D graphics library with an API which is very similar to
408
that of OpenGL.* To the extent that Mesa utilizes the OpenGL command
409
syntax or state machine, it is being used with authorization from
410
Silicon Graphics, Inc.(SGI). However, the author does not possess an
411
OpenGL license from SGI, and makes no claim that Mesa is in any way a
412
compatible replacement for OpenGL or associated with SGI. Those who
413
want a licensed implementation of OpenGL should contact a licensed
414
vendor.
415
416
Please do not refer to the library as MesaGL (for legal reasons). It's
417
just Mesa or The Mesa 3-D graphics library.
418
419
* OpenGL is a trademark of Silicon Graphics Incorporated.
420
421
%package libEGL1
422
# Kudos to Debian for the descriptions
423
Summary:        EGL API implementation
424
Group:          System/Libraries
425
Requires:       libglvnd >= 0.1.0
426
427
%description libEGL1
428
This package contains the EGL native platform graphics interface
429
library. EGL provides a platform-agnostic mechanism for creating
430
rendering surfaces for use with other graphics libraries, such as
431
OpenGL|ES and OpenVG.
432
433
This package contains modules to interface with the existing system
434
GLX or DRI2 drivers to provide OpenGL via EGL. The Mesa main package
435
provides drivers to provide hardware-accelerated OpenGL|ES and OpenVG
436
support.
437
438
%package libEGL-devel
439
Summary:        Development files for the EGL API
440
Group:          Development/Libraries/C and C++
441
Requires:       Mesa-KHR-devel = %{version}
442
Requires:       Mesa-libEGL1 = %{version}
443
Requires:       libglvnd-devel >= 0.1.0
444
Requires:       pkgconfig(x11)
445
# Other requires taken care of by pkgconfig already
446
447
%description libEGL-devel
448
This package contains the development environment required for
449
compiling programs against EGL native platform graphics interface
450
library. EGL provides a platform-agnostic mechanism for creating
451
rendering surfaces for use with other graphics libraries, such as
452
OpenGL|ES and OpenVG.
453
454
This package provides the development environment for compiling
455
programs against the EGL library.
456
457
%package KHR-devel
458
Summary:        Mesa Khronos development headers
459
Group:          Development/Libraries/C and C++
460
Provides:       Mesa-libGL-devel:/usr/include/KHR/khrplatform.h
461
462
%description KHR-devel
463
Mesa Khronos development headers.
464
465
%package libGL1
466
Summary:        The GL/GLX runtime of the Mesa 3D graphics library
467
Group:          System/Libraries
468
Requires:       Mesa = %{version}
469
Requires:       libglvnd >= 0.1.0
470
471
%description libGL1
472
Mesa is a software library for 3D computer graphics that provides a
473
generic OpenGL implementation for rendering three-dimensional
474
graphics.
475
476
GLX ("OpenGL Extension to the X Window System") provides the
477
interface connecting OpenGL and the X Window System: it enables
478
programs wishing to use OpenGL to do so within a window provided by
479
the X Window System.
480
481
%package libGL-devel
482
Summary:        GL/GLX development files of the OpenGL API
483
Group:          Development/Libraries/C and C++
484
Requires:       Mesa-KHR-devel = %{version}
485
Requires:       Mesa-libGL1 = %{version}
486
Requires:       libglvnd-devel >= 0.1.0
487
Requires:       pkgconfig(x11)
488
489
%description libGL-devel
490
Mesa is a software library for 3D computer graphics that provides a
491
generic OpenGL implementation for rendering three-dimensional
492
graphics.
493
494
This package includes headers and static libraries for compiling
495
programs with Mesa.
496
497
%package libGLESv1_CM-devel
498
Summary:        Development files for the OpenGL ES 1.x API
499
Group:          Development/Libraries/C and C++
500
Requires:       Mesa-KHR-devel = %{version}
501
Requires:       libglvnd-devel >= 0.1.0
502
Requires:       pkgconfig(egl)
503
504
%description libGLESv1_CM-devel
505
OpenGL|ES is an API for full-function 2D and 3D
506
graphics on embedded systems - including consoles, phones, appliances
507
and vehicles. It contains a subset of OpenGL plus a number of
508
extensions for the special needs of embedded systems.
509
510
OpenGL|ES 1.x provides an API for fixed-function hardware.
511
512
This package provides a development environment for building programs
513
using the OpenGL|ES 1.x APIs.
514
515
%package libGLESv2-devel
516
Summary:        Development files for the OpenGL ES 2.x API
517
Group:          Development/Libraries/C and C++
518
Requires:       Mesa-KHR-devel = %{version}
519
Requires:       libglvnd-devel >= 0.1.0
520
Requires:       pkgconfig(egl)
521
522
%description libGLESv2-devel
523
OpenGL|ES is an API for full-function 2D and 3D
524
graphics on embedded systems - including consoles, phones, appliances
525
and vehicles. It contains a subset of OpenGL plus a number of
526
extensions for the special needs of embedded systems.
527
528
OpenGL|ES 2.x provides an API for programmable hardware including
529
vertex and fragment shaders.
530
531
This package provides a development environment for building
532
applications using the OpenGL|ES 2.x APIs.
533
534
%package libGLESv3-devel
535
Summary:        Development files for the OpenGL ES 3.x API
536
Group:          Development/Libraries/C and C++
537
Requires:       Mesa-KHR-devel = %{version}
538
Requires:       pkgconfig(egl)
539
540
%description libGLESv3-devel
541
OpenGL|ES is an API for full-function 2D and 3D
542
graphics on embedded systems - including consoles, phones, appliances
543
and vehicles. It contains a subset of OpenGL plus a number of
544
extensions for the special needs of embedded systems.
545
546
This package provides a development environment for building
547
applications using the OpenGL|ES 3.x APIs.
548
549
%package -n libOSMesa8
550
Summary:        Mesa Off-screen rendering extension
551
# Wrongly named package shipped .so.8
552
Group:          System/Libraries
553
Obsoletes:      libOSMesa9 < %{version}
554
Provides:       libOSMesa9 = %{version}
555
556
%description -n libOSMesa8
557
OSmesa is a Mesa extension that allows programs to render to an
558
off-screen buffer using the OpenGL API without having to create a
559
rendering context on an X Server. It uses a pure software renderer.
560
561
%package -n libOSMesa-devel
562
Summary:        Development files for the Mesa Offscreen Rendering extension
563
Group:          Development/Libraries/C and C++
564
Requires:       libOSMesa8 = %{version}
565
566
%description -n libOSMesa-devel
567
Development files for the OSmesa Mesa extension that allows programs to render to an
568
off-screen buffer using the OpenGL API without having to create a
569
rendering context on an X Server. It uses a pure software renderer.
570
571
%package libglapi0
572
Summary:        Free implementation of the GL API
573
Group:          System/Libraries
574
575
%description libglapi0
576
The Mesa GL API module is responsible for dispatching all the gl*
577
functions. It is intended to be mainly used by the Mesa-libGLES*
578
packages.
579
580
%package libglapi-devel
581
Summary:        Development files for the Mesa GL API implementation
582
Group:          Development/Libraries/C and C++
583
Requires:       Mesa-libglapi0 = %{version}
584
585
%description libglapi-devel
586
Development files for the Mesa GL API module which is responsible for
587
dispatching all the gl* functions. It is intended to be mainly used by
588
the Mesa-libGLES* packages.
589
590
%package -n Mesa-dri
591
Summary:        DRI plug-ins for 3D acceleration
592
Group:          System/Libraries
593
Requires:       Mesa = %{version}
594
Requires:       libvulkan1
595
Supplements:    Mesa
596
# merged into libgallium in 24.2.3
597
Provides:       libvdpau_gallium = %{version}-%{release}
598
Obsoletes:      libvdpau_gallium < %{version}-%{release}
599
600
%description -n Mesa-dri
601
This package contains Mesa DRI drivers for 3D acceleration.
602
603
%package dri-devel
604
Summary:        Development files for the DRI API
605
Group:          Development/Libraries/C and C++
606
Requires:       Mesa = %{version}
607
608
%description dri-devel
609
This package contains the development environment required for
610
compiling programs and libraries using the DRI API.
611
612
%package -n Mesa-dri-nouveau
613
Summary:        Mesa DRI plug-in for 3D acceleration via Nouveau
614
Group:          System/Libraries
615
Requires:       Mesa = %{version}
616
617
%description -n Mesa-dri-nouveau
618
This package contains nouveau_dri.so, which is necessary for
619
Nouveau's 3D acceleration to work. It is packaged separately
620
since it is still experimental.
621
622
%package -n Mesa-dri-vc4
623
Summary:        Mesa DRI plug-in for 3D acceleration on Raspberry Pi
624
Group:          System/Libraries
625
Requires:       Mesa = %{version}
626
627
%description -n Mesa-dri-vc4
628
This package contains vc4_dri.so, which is necessary for 3D
629
acceleration on the Raspberry Pi to work. It is packaged separately
630
since it is still experimental.
631
632
%package -n Mesa-gallium
633
Summary:        Mesa Gallium GPU drivers
634
Group:          System/Libraries
635
Requires:       Mesa = %{version}
636
Supplements:    Mesa
637
638
%description -n Mesa-gallium
639
This package contains Mesa Gallium drivers for 3D acceleration.
640
641
%package -n libgbm1
642
Summary:        Generic buffer management API
643
Group:          System/Libraries
644
645
%description -n libgbm1
646
This package contains the GBM buffer management library. It provides
647
a mechanism for allocating buffers for graphics rendering tied to
648
Mesa.
649
650
GBM is intended to be used as a native platform for EGL on drm or
651
openwfd.
652
653
%package -n libgbm-devel
654
Summary:        Development files for the EGL API
655
Group:          Development/Libraries/C and C++
656
Requires:       libgbm1 = %{version}
657
658
%description -n libgbm-devel
659
This package contains the GBM buffer management library. It provides
660
a mechanism for allocating buffers for graphics rendering tied to
661
Mesa.
662
663
GBM is intended to be used as a native platform for EGL on drm or
664
openwfd.
665
666
This package provides the development environment for compiling
667
programs against the GBM library.
668
669
%package -n Mesa-libd3d
670
Summary:        Mesa Direct3D9 state tracker
671
# Manually provide d3d library (bnc#918294)
672
Group:          System/Libraries
673
%ifarch x86_64 s390x ppc64 ppc64le aarch64 riscv64
674
Provides:       d3dadapter9.so.1()(64bit)
675
%else
676
Provides:       d3dadapter9.so.1
677
%endif
678
679
%description -n Mesa-libd3d
680
Mesa Direct3D9 state tracker
681
682
%package -n Mesa-libd3d-devel
683
Summary:        Mesa Direct3D9 state tracker development package
684
Group:          Development/Libraries/C and C++
685
Requires:       Mesa-libd3d = %{version}
686
687
%description -n Mesa-libd3d-devel
688
Mesa Direct3D9 state tracker development package
689
690
%package -n libvdpau_nouveau
691
Summary:        VDPAU state tracker for Nouveau
692
Group:          System/Libraries
693
Supplements:    modalias(pci:v000010DEd*sv*sd*bc03sc*i*)
694
Supplements:    modalias(pci:v000012D2d*sv*sd*bc03sc*i*)
695
696
%description -n libvdpau_nouveau
697
This package contains the VDPAU state tracker for Nouveau.
698
699
%package -n libvdpau_r600
700
Summary:        VDPAU state tracker for R600
701
Group:          System/Libraries
702
Supplements:    modalias(pci:v00001002d*sv*sd*bc03sc*i*)
703
704
%description -n libvdpau_r600
705
This package contains the VDPAU state tracker for R600.
706
707
%package -n libvdpau_radeonsi
708
Summary:        VDPAU state tracker for radeonsi
709
Group:          System/Libraries
710
Supplements:    modalias(pci:v00001002d*sv*sd*bc03sc*i*)
711
712
%description -n libvdpau_radeonsi
713
This package contains the VDPAU state tracker for radeonsi.
714
715
%package -n libvdpau_virtio_gpu
716
Summary:        VDPAU state tracker for VirtIO GPU
717
Group:          System/Libraries
718
719
%description -n libvdpau_virtio_gpu
720
This package contains the VDPAU state tracker for VirtIO GPU.
721
722
%package -n libvdpau_d3d12
723
Summary:        VDPAU state tracker for d3d12
724
Group:          System/Libraries
725
726
%description -n libvdpau_d3d12
727
This package contains the VDPAU state tracker for d3d12
728
729
%package -n Mesa-libOpenCL
730
Summary:        Mesa OpenCL implementation (Clover)
731
Group:          System/Libraries
732
%if 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150300
733
Requires:       libclc(llvm%{_llvm_sonum})
734
%else
735
Requires:       libclc
736
%endif
737
738
%description -n Mesa-libOpenCL
739
This package contains the Mesa OpenCL implementation or GalliumCompute.
740
741
%package -n Mesa-libRusticlOpenCL
742
Summary:        Mesa OpenCL implementation (Rusticl)
743
Group:          System/Libraries
744
%if 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150300
745
Requires:       libclc(llvm%{_llvm_sonum})
746
%else
747
Requires:       libclc
748
%endif
749
750
%description -n Mesa-libRusticlOpenCL
751
This package contains the Mesa Rust-written OpenCL implementation.
752
753
%package -n Mesa-libva
754
Summary:        Mesa VA-API implementation
755
Group:          System/Libraries
756
Supplements:    Mesa
757
758
%description -n Mesa-libva
759
This package contains the Mesa VA-API implementation provided through gallium.
760
761
%package -n libvulkan_intel
762
Summary:        Mesa vulkan driver for Intel GPU
763
Group:          System/Libraries
764
Supplements:    modalias(pci:v00008086d*sv*sd*bc03sc*i*)
765
Requires:       Mesa-vulkan-device-select = %{version}
766
# get rid of this package, which is no longer neeeded at all
767
Provides:       Mesa-libVulkan-devel = 22.0.0
768
Obsoletes:      Mesa-libVulkan-devel < 22.0.0
769
770
%description -n libvulkan_intel
771
This package contains the Vulkan parts for Mesa.
772
773
# Only available on Tumbleweed because of rust-cbindgen >= 1.25 requirement
774
%if 0%{?suse_version} > 1600
775
%package -n libvulkan_nouveau
776
Summary:        Mesa vulkan driver for NVK (Nouveau Vulkan)
777
Group:          System/Libraries
778
Requires:       Mesa-vulkan-device-select = %{version}
779
780
%description -n libvulkan_nouveau
781
This package contains the Vulkan parts for Mesa.
782
%endif
783
784
%package -n libvulkan_radeon
785
Summary:        Mesa vulkan driver for AMD GPU
786
Group:          System/Libraries
787
Supplements:    modalias(pci:v00001002d*sv*sd*bc03sc*i*)
788
Requires:       Mesa-vulkan-device-select = %{version}
789
790
%description -n libvulkan_radeon
791
This package contains the Vulkan parts for Mesa.
792
793
%package -n libvulkan_lvp
794
Summary:        Mesa vulkan driver for LVP
795
Group:          System/Libraries
796
Requires:       Mesa-vulkan-device-select = %{version}
797
798
%description -n libvulkan_lvp
799
This package contains the Vulkan parts for Mesa.
800
801
%ifarch %{arm} aarch64
802
%package -n libvulkan_broadcom
803
Summary:        Mesa vulkan driver for Broadcom
804
Group:          System/Libraries
805
806
%description -n libvulkan_broadcom
807
This package contains the Vulkan parts for Mesa.
808
809
%package -n libvulkan_freedreno
810
Summary:        Mesa vulkan driver for Freedreno
811
Group:          System/Libraries
812
813
%description -n libvulkan_freedreno
814
This package contains the Vulkan parts for Mesa.
815
%endif
816
817
%package -n Mesa-vulkan-device-select
818
Summary:        Vulkan layer to select Vulkan devices provided by Mesa
819
Group:          System/Libraries
820
821
%description -n Mesa-vulkan-device-select
822
This package contains the VK_MESA_device_select Vulkan layer
823
824
%package -n Mesa-vulkan-overlay
825
Summary:        Mesa Vulkan Overlay layer
826
Group:          System/Libraries
827
828
%description -n Mesa-vulkan-overlay
829
This package contains the VK_MESA_Overlay Vulkan layer
830
831
%package -n libxatracker2
832
Version:        1.0.0
833
Summary:        XA state tracker
834
Group:          System/Libraries
835
836
%description -n libxatracker2
837
This package contains the XA state tracker for gallium3D driver.
838
It superseeds the Xorg state tracker and provides an infrastructure
839
to accelerate Xorg 2D operations. It is currently used by vmwgfx
840
video driver.
841
842
%package -n libxatracker-devel
843
Version:        1.0.0
844
Summary:        Development files for the XA API
845
Group:          Development/Libraries/C and C++
846
Requires:       libxatracker2 = %{version}
847
848
%description -n libxatracker-devel
849
This package contains the XA state tracker for gallium3D driver.
850
It superseeds the Xorg state tracker and provides an infrastructure
851
to accelerate Xorg 2D operations. It is currently used by vmwgfx
852
video driver.
853
854
This package provides the development environment for compiling
855
programs against the XA state tracker.
856
857
%prep
858
%setup -q -n %{_name_archive}-%{_version} -b9
859
# remove some docs
860
rm -rf docs/README.{VMS,WIN32,OS2}
861
862
# Rust crates to subprojects
863
mkdir -p subprojects/packagecache
864
cp %{SOURCE2} subprojects/packagecache/
865
cp %{SOURCE3} subprojects/packagecache/
866
cp %{SOURCE4} subprojects/packagecache/
867
cp %{SOURCE5} subprojects/packagecache/
868
cp %{SOURCE6} subprojects/packagecache/
869
870
%patch -P 2 -p1
871
# fixes build against python 3.6
872
%patch -P 11 -p1
873
%patch -P 12 -p1
874
%patch -P 13 -p1
875
%if 0%{?suse_version} < 1550
876
%patch -P 14 -p1
877
%endif
878
%patch -P 17 -p1
879
# no longer needed since gstreamer-plugins-vaapi 1.18.4
880
%if 0%{?suse_version} < 1550
881
%patch -P 54 -p1
882
%endif
883
%patch -P 100 -p1
884
%patch -P 400 -p1
885
%patch -P 500 -p1
886
%ifnarch s390x
887
%patch -P 600 -p1
888
%patch -P 701 -p1
889
%patch -P 702 -p1
890
%endif
891
%patch -P 1222040 -p1
892
%patch -P 1222041 -p1
893
%patch -P 1222042 -p1
894
# Remove requires to vulkan libs from baselibs.conf on platforms
895
# where vulkan build is disabled; ugly ...
896
%if 0%{?with_vulkan} == 0
897
grep -v -i vulkan "%{_sourcedir}/baselibs.conf" >"%{_sourcedir}/temp" && \
898
  mv "%{_sourcedir}/temp" "%{_sourcedir}/baselibs.conf"
899
%endif
900
901
%build
902
# try to avoid OOM on ppc64 (boo#1194739)
903
%ifarch ppc64 ppc64le
904
%limit_build -m 1024
905
%endif
906
%if 0%{?sle_version} >= 150400
907
export CC=gcc-13
908
export CXX=g++-13
909
%endif
910
911
egl_platforms=x11,wayland
912
913
# needed to fix build of Mesa 23.1
914
# Mesa-drivers: -Dshader-cache=enabled
915
# Mesa: -Dxlib-lease=enabled
916
# recommended for both Mesa and Mesa-drivers to avoid some scary messages when
917
# comparing fds: -Dallow-kcmp=enabled
918
# Credits for figuring this out go to "llyyr" <llyyr.public@gmail.com>
919
920
%meson \
921
            --auto-features=disabled \
922
%if "%{flavor}" == "drivers"
923
            -Dosmesa=false \
924
            -Dglx=disabled \
925
            -Dxmlconfig=enabled \
926
            -Dexpat=enabled \
927
            -Dshader-cache=enabled \
928
%else
929
            -Dosmesa=true \
930
            -Dglx=auto \
931
            -Dllvm=disabled \
932
            -Dvulkan-drivers= \
933
%endif
934
            -Dxlib-lease=enabled \
935
            -Dglvnd=enabled \
936
            -Dgles1=enabled \
937
            -Dgles2=enabled \
938
            -Degl=enabled \
939
            -Dallow-kcmp=enabled \
940
            -Dplatforms=$egl_platforms \
941
            -Dshared-glapi=enabled \
942
%if 0%{?with_nine}
943
            -Dgallium-nine=true \
944
%endif
945
%if %{glamor}
946
            -Dgbm=enabled \
947
%endif
948
%if 0%{with_opencl}
949
            -Dgallium-opencl=icd \
950
%if 0%{?suse_version} >= 1550
951
            --sysconfdir=%{_datadir} \
952
%endif
953
%if 0%{with_rusticl}
954
            -Dgallium-rusticl=true \
955
            -Drust_std=2021 \
956
%endif
957
%endif
958
%if 0%{with_llvm}
959
            -Dllvm=enabled \
960
            -Dshared-llvm=enabled \
961
%endif
962
%if "%{flavor}" == "drivers"
963
%if %{video_codecs}
964
            -Dvideo-codecs=all \
965
%endif
966
%if %{gallium_loader}
967
            -Dgallium-vdpau=enabled \
968
            -Dgallium-va=enabled \
969
            -Dgallium-xa=enabled \
970
%endif
971
%if 0%{with_vulkan}
972
            -Dvulkan-drivers=%{?vulkan_drivers} \
973
            -Dvulkan-layers=device-select,overlay \
974
            -Dvulkan-beta=true \
975
%else
976
            -Dvulkan-drivers= \
977
%endif
978
  %ifarch %{ix86} x86_64
979
            -Dgallium-drivers=r300,r600,radeonsi,nouveau,softpipe,llvmpipe,svga,virgl,iris,crocus,i915,d3d12,zink \
980
            -Dgallium-d3d12-video=enabled \
981
            -Dgallium-d3d12-graphics=enabled \
982
  %else
983
  %ifarch %{arm} aarch64
984
%if 0%{?suse_version} >= 1550
985
            -Dgallium-drivers=r300,r600,radeonsi,nouveau,softpipe,llvmpipe,virgl,iris,freedreno,vc4,etnaviv,lima,panfrost,v3d,svga,tegra,zink \
986
%else
987
            -Dgallium-drivers=r300,r600,radeonsi,nouveau,softpipe,llvmpipe,virgl,iris,freedreno,vc4,lima,panfrost,v3d,svga,tegra,zink \
988
%endif
989
  %else
990
  %ifarch ppc64 ppc64le riscv64
991
            -Dgallium-drivers=r300,r600,radeonsi,nouveau,softpipe,llvmpipe,virgl,iris,zink \
992
  %else
993
            -Dgallium-drivers=swrast \
994
  %endif
995
  %endif
996
  %endif
997
%ifarch riscv64
998
            -Dllvm-orcjit=true \
999
%endif
1000
%else
1001
%ifnarch s390x
1002
            -Dgallium-drivers=softpipe \
1003
%else
1004
            -Dgallium-drivers=swrast \
1005
%endif
1006
%endif
1007
%ifarch aarch64 x86_64 ppc64le s390x riscv64
1008
            -Dvalgrind=enabled \
1009
%endif
1010
            -Db_ndebug=true \
1011
            -Dc_args="%{optflags}" \
1012
%ifarch %ix86
1013
            -Dcpp_args="$(echo %{optflags}|sed 's/-flto=auto//')"
1014
%else
1015
            -Dcpp_args="%{optflags}"
1016
%endif
1017
1018
%meson_build
1019
1020
%install
1021
export MESON_PACKAGE_CACHE_DIR="%{_sourcedir}"
1022
%meson_install
1023
find %{buildroot} -type f -name "*.la" -delete -print
1024
1025
# libwayland-egl is provided by wayland itself
1026
rm -f %{buildroot}/%{_libdir}/libwayland-egl.so*
1027
rm -f %{buildroot}/%{_libdir}/pkgconfig/wayland-egl.pc
1028
1029
%if "%{flavor}" == "drivers"
1030
# Delete things that we do not package in the Mesa-drivers variant, but can
1031
# not disable from buildling and installing.
1032
1033
rm -f %{buildroot}/%{_libdir}/libEGL.so*
1034
# in Mesa-libEGL-devel
1035
rm %{buildroot}/%{_includedir}/EGL/egl.h
1036
rm %{buildroot}/%{_includedir}/EGL/eglext.h
1037
rm %{buildroot}/%{_includedir}/EGL/eglext_angle.h
1038
rm %{buildroot}/%{_includedir}/EGL/eglmesaext.h
1039
rm %{buildroot}/%{_includedir}/EGL/eglplatform.h
1040
1041
# in Mesa-libGL-devel
1042
rm -rf %{buildroot}/%{_includedir}/GL
1043
1044
#in Mesa-libGLESv1_CM-devel
1045
rm -rf %{buildroot}/%{_includedir}/GLES
1046
1047
#in Mesa-libGLESv2-devel
1048
rm -rf %{buildroot}/%{_includedir}/GLES2
1049
1050
#in Mesa-libGLESv3-devel
1051
rm -rf %{buildroot}/%{_includedir}/GLES3
1052
1053
#in Mesa-libEGL1
1054
rm -f %{buildroot}/%{_libdir}/libEGL_mesa.so*
1055
rm -rf %{buildroot}/%{_datadir}/glvnd
1056
1057
# in Mesa-libglapi0
1058
rm %{buildroot}/%{_libdir}/libglapi.so*
1059
1060
# in libwayland-egl1
1061
rm -f %{buildroot}/%{_libdir}/libwayland-egl.so*
1062
rm -f %{buildroot}/%{_libdir}/pkgconfig/wayland-egl.pc
1063
1064
# in Mesa-dri-devel
1065
rm %{buildroot}/%{_libdir}/pkgconfig/dri.pc
1066
1067
# in KHR-devel
1068
rm -rf %{buildroot}/%{_includedir}/KHR
1069
1070
# in libgbm-devel
1071
rm -f %{buildroot}%{_includedir}/gbm.h
1072
rm -f %{buildroot}%{_libdir}/libgbm.so*
1073
rm -f %{buildroot}%{_libdir}/pkgconfig/gbm.pc
1074
1075
%else
1076
# package in Mesa-dri
1077
rm -rf %{buildroot}/%{_datadir}/drirc.d
1078
1079
rm -f %{buildroot}/%{_libdir}/dri/*_dri.so
1080
rm -f %{buildroot}%{_libdir}/libgallium-*.so
1081
rm -rf %{buildroot}%{_libdir}/gbm/
1082
1083
rm -f %{buildroot}%{_libdir}/libGLES*
1084
# glvnd needs a default provider for indirect rendering where it cannot
1085
# determine the vendor
1086
ln -s %{_libdir}/libGLX_mesa.so.0 %{buildroot}%{_libdir}/libGLX_indirect.so.0
1087
1088
# pickup pkgconfig files from libglvnd build
1089
rm -f %{buildroot}/%{_libdir}/pkgconfig/{gl,egl,glesv1_cm,glesv2}.pc
1090
install -m 0644 /usr/share/doc/packages/libglvnd/pkgconfig/{gl,egl,glesv1_cm,glesv2}.pc \
1091
   %{buildroot}/%{_libdir}/pkgconfig/
1092
1093
for dir in ../xc/doc/man/{GL/gl,GL/glx}; do
1094
 pushd $dir
1095
   xmkmf -a
1096
   make %{?_smp_mflags} V=1
1097
   make install.man DESTDIR=%{buildroot} MANPATH=%{_mandir} LIBMANSUFFIX=3gl
1098
 popd
1099
done
1100
%endif
1101
1102
%fdupes -s %{buildroot}/%{_mandir}
1103
1104
%if "%{flavor}" != "drivers"
1105
# Use dummy README file that can be included in both Mesa and Mesa-32bit. This way Mesa-32bit will be build (otherwise it would be skipped as empty) and it can be used by the other *-32bit packages.
1106
echo "The \"Mesa\" package does not have the ability to render, but is supplemented by \"Mesa-dri\" and \"Mesa-gallium\" which contain the drivers for rendering" > docs/README.package.%{_arch}
1107
%endif
1108
1109
%post   -p /sbin/ldconfig
1110
1111
%postun -p /sbin/ldconfig
1112
1113
%post   libEGL1 -p /sbin/ldconfig
1114
1115
%postun libEGL1 -p /sbin/ldconfig
1116
1117
%post   libGL1 -p /sbin/ldconfig
1118
1119
%postun libGL1 -p /sbin/ldconfig
1120
1121
%post   -n libOSMesa8 -p /sbin/ldconfig
1122
1123
%postun -n libOSMesa8 -p /sbin/ldconfig
1124
1125
%post   -n libgbm1 -p /sbin/ldconfig
1126
1127
%postun -n libgbm1 -p /sbin/ldconfig
1128
1129
%post   -n libxatracker2 -p /sbin/ldconfig
1130
1131
%postun -n libxatracker2 -p /sbin/ldconfig
1132
1133
%post   libglapi0 -p /sbin/ldconfig
1134
1135
%postun libglapi0 -p /sbin/ldconfig
1136
1137
%post -n Mesa-libd3d -p /sbin/ldconfig
1138
1139
%postun -n Mesa-libd3d -p /sbin/ldconfig
1140
1141
%if "%{flavor}" != "drivers"
1142
%files
1143
%license docs/license.rst
1144
%doc docs/README*
1145
1146
%files libEGL1
1147
%{_libdir}/libEGL_mesa.so*
1148
%dir %{_datadir}/glvnd
1149
%dir %{_datadir}/glvnd/egl_vendor.d
1150
%{_datadir}/glvnd/egl_vendor.d/50_mesa.json
1151
1152
%files libEGL-devel
1153
%{_includedir}/EGL
1154
%{_libdir}/pkgconfig/egl.pc
1155
1156
%files KHR-devel
1157
%{_includedir}/KHR
1158
1159
%files libGL1
1160
%{_libdir}/libGLX_mesa.so*
1161
%{_libdir}/libGLX_indirect.so*
1162
1163
%files libGL-devel
1164
%dir %{_includedir}/GL
1165
%{_includedir}/GL/*.h
1166
%exclude %{_includedir}/GL/osmesa.h
1167
%{_libdir}/pkgconfig/gl.pc
1168
%{_mandir}/man3/gl[A-Z]*
1169
1170
%files libGLESv1_CM-devel
1171
%{_includedir}/GLES
1172
%{_libdir}/pkgconfig/glesv1_cm.pc
1173
1174
%files libGLESv2-devel
1175
%{_includedir}/GLES2
1176
%{_libdir}/pkgconfig/glesv2.pc
1177
1178
%files libGLESv3-devel
1179
%{_includedir}/GLES3
1180
1181
%files -n libOSMesa8
1182
%{_libdir}/libOSMesa.so.8.0.0
1183
%{_libdir}/libOSMesa.so.8
1184
1185
%files -n libOSMesa-devel
1186
%{_includedir}/GL/osmesa.h
1187
%{_libdir}/libOSMesa.so
1188
%{_libdir}/pkgconfig/osmesa.pc
1189
1190
%files -n libgbm1
1191
%{_libdir}/libgbm.so.1*
1192
1193
%files -n libgbm-devel
1194
%{_includedir}/gbm.h
1195
%{_libdir}/libgbm.so
1196
%{_libdir}/pkgconfig/gbm.pc
1197
%endif
1198
1199
%if "%{flavor}" == "drivers"
1200
%ifarch aarch64 %{ix86} x86_64 %{arm} ppc64 ppc64le riscv64
1201
%files -n libxatracker2
1202
%{_libdir}/libxatracker.so.2*
1203
1204
%files -n libxatracker-devel
1205
%{_includedir}/xa_*.h
1206
%{_libdir}/libxatracker.so
1207
%{_libdir}/pkgconfig/xatracker.pc
1208
1209
%endif
1210
1211
%if %{vdpau_nouveau}
1212
%files -n libvdpau_nouveau
1213
%{_libdir}/vdpau/libvdpau_nouveau.so
1214
%{_libdir}/vdpau/libvdpau_nouveau.so.1
1215
%{_libdir}/vdpau/libvdpau_nouveau.so.1.0
1216
%{_libdir}/vdpau/libvdpau_nouveau.so.1.0.0
1217
%endif
1218
1219
%if %{vdpau_radeon}
1220
%files -n libvdpau_r600
1221
%{_libdir}/vdpau/libvdpau_r600.so
1222
%{_libdir}/vdpau/libvdpau_r600.so.1
1223
%{_libdir}/vdpau/libvdpau_r600.so.1.0
1224
%{_libdir}/vdpau/libvdpau_r600.so.1.0.0
1225
1226
%files -n libvdpau_radeonsi
1227
%{_libdir}/vdpau/libvdpau_radeonsi.so
1228
%{_libdir}/vdpau/libvdpau_radeonsi.so.1
1229
%{_libdir}/vdpau/libvdpau_radeonsi.so.1.0
1230
%{_libdir}/vdpau/libvdpau_radeonsi.so.1.0.0
1231
%endif
1232
1233
%if %{vdpau_virtio_gpu}
1234
%files -n libvdpau_virtio_gpu
1235
%{_libdir}/vdpau/libvdpau_virtio_gpu.so
1236
%{_libdir}/vdpau/libvdpau_virtio_gpu.so.1
1237
%{_libdir}/vdpau/libvdpau_virtio_gpu.so.1.0
1238
%{_libdir}/vdpau/libvdpau_virtio_gpu.so.1.0.0
1239
%endif
1240
1241
%if %{vdpau_d3d12}
1242
%files -n libvdpau_d3d12
1243
%{_libdir}/vdpau/libvdpau_d3d12.so
1244
%{_libdir}/vdpau/libvdpau_d3d12.so.1
1245
%{_libdir}/vdpau/libvdpau_d3d12.so.1.0
1246
%{_libdir}/vdpau/libvdpau_d3d12.so.1.0.0
1247
%endif
1248
%endif
1249
1250
%if "%{flavor}" != "drivers"
1251
%files libglapi0
1252
%{_libdir}/libglapi.so.0*
1253
1254
%files libglapi-devel
1255
%{_libdir}/libglapi.so
1256
%endif
1257
1258
%if "%{flavor}" == "drivers"
1259
%files -n Mesa-dri
1260
%dir %{_datadir}/drirc.d
1261
%config %{_datadir}/drirc.d/*
1262
%dir %{_libdir}/dri
1263
%{_libdir}/dri/*_dri.so
1264
%ifarch %{ix86} x86_64 aarch64 %{arm} ppc64 ppc64le riscv64
1265
%exclude %{_libdir}/dri/nouveau_dri.so
1266
%endif
1267
%ifarch %{arm} aarch64
1268
%exclude %{_libdir}/dri/vc4_dri.so
1269
%endif
1270
%ifnarch s390x
1271
%{_libdir}/libgallium-%{_version}.so
1272
%dir %{_libdir}/gbm/
1273
%{_libdir}/gbm/dri_gbm.so
1274
%endif
1275
1276
%if 0%{with_opencl}
1277
# only built with opencl
1278
%files -n Mesa-gallium
1279
%dir %{_libdir}/gallium-pipe/
1280
%{_libdir}/gallium-pipe/pipe_*.so
1281
%endif
1282
1283
%ifarch %{ix86} x86_64 aarch64 %{arm} ppc64 ppc64le riscv64
1284
%files -n Mesa-dri-nouveau
1285
%{_libdir}/dri/nouveau_dri.so
1286
%endif
1287
1288
%ifarch aarch64 %{arm}
1289
%files -n Mesa-dri-vc4
1290
%{_libdir}/dri/vc4_dri.so
1291
%endif
1292
1293
# drivers
1294
%endif
1295
1296
%if "%{flavor}" != "drivers"
1297
%files dri-devel
1298
%{_includedir}/GL/internal
1299
%{_libdir}/pkgconfig/dri.pc
1300
1301
%files devel
1302
%doc docs/*.rst
1303
1304
# !drivers
1305
%endif
1306
1307
%if 0%{?with_nine}
1308
%files -n Mesa-libd3d
1309
%dir %{_libdir}/d3d/
1310
%{_libdir}/d3d/*.so.*
1311
1312
%files -n Mesa-libd3d-devel
1313
%{_libdir}/pkgconfig/d3d.pc
1314
%{_includedir}/d3dadapter/
1315
%{_libdir}/d3d/*.so
1316
%endif
1317
1318
%if 0%{with_opencl}
1319
%files -n Mesa-libOpenCL
1320
%if 0%{?suse_version} >= 1550
1321
%dir %{_datadir}/OpenCL
1322
%dir %{_datadir}/OpenCL/vendors
1323
%{_datadir}/OpenCL/vendors/mesa.icd
1324
%else
1325
%dir %{_sysconfdir}/OpenCL
1326
%dir %{_sysconfdir}/OpenCL/vendors
1327
%{_sysconfdir}/OpenCL/vendors/mesa.icd
1328
%endif
1329
%{_libdir}/libMesaOpenCL.so*
1330
%endif
1331
1332
%if 0%{with_rusticl}
1333
%files -n Mesa-libRusticlOpenCL
1334
%if 0%{?suse_version} >= 1550
1335
%dir %{_datadir}/OpenCL
1336
%dir %{_datadir}/OpenCL/vendors
1337
%{_datadir}/OpenCL/vendors/rusticl.icd
1338
%else
1339
%dir %{_sysconfdir}/OpenCL
1340
%dir %{_sysconfdir}/OpenCL/vendors
1341
%{_sysconfdir}/OpenCL/vendors/rusticl.icd
1342
%endif
1343
%{_libdir}/libRusticlOpenCL.so*
1344
%endif
1345
1346
%if "%{flavor}" == "drivers"
1347
%ifarch %{ix86} x86_64 aarch64 %{arm} ppc64 ppc64le riscv64
1348
%files -n Mesa-libva
1349
%{_libdir}/dri/*_drv_video.so
1350
%endif
1351
%endif
1352
1353
%if 0%{with_vulkan}
1354
%ifarch %{ix86} x86_64 aarch64 %{arm} riscv64
1355
%files -n libvulkan_intel
1356
%dir %{_datadir}/vulkan
1357
%dir %{_datadir}/vulkan/icd.d
1358
%{_datadir}/vulkan/icd.d/intel_icd.*.json
1359
%{_libdir}/libvulkan_intel.so
1360
%{_datadir}/vulkan/icd.d/intel_hasvk_icd.*.json
1361
%{_libdir}/libvulkan_intel_hasvk.so
1362
%endif
1363
1364
%ifarch %{ix86} x86_64 aarch64 %{arm}
1365
# Only available on Tumbleweed because of rust-cbindgen >= 1.25 requirement
1366
%if 0%{?suse_version} > 1600
1367
%files -n libvulkan_nouveau
1368
%{_libdir}/libvulkan_nouveau.so
1369
%{_datadir}/vulkan/icd.d/nouveau_icd.*.json
1370
%dir %{_datadir}/vulkan
1371
%dir %{_datadir}/vulkan/icd.d
1372
%endif
1373
%endif
1374
1375
%files -n libvulkan_radeon
1376
%{_libdir}/libvulkan_radeon.so
1377
%dir %{_datadir}/vulkan
1378
%dir %{_datadir}/vulkan/icd.d
1379
%{_datadir}/vulkan/icd.d/radeon_icd.*.json
1380
1381
%files -n libvulkan_lvp
1382
%{_libdir}/libvulkan_lvp.so
1383
%dir %{_datadir}/vulkan
1384
%dir %{_datadir}/vulkan/icd.d
1385
%{_datadir}/vulkan/icd.d/lvp_icd.*.json
1386
1387
%ifarch %{arm} aarch64
1388
%files -n libvulkan_broadcom
1389
%{_libdir}/libvulkan_broadcom.so
1390
%dir %{_datadir}/vulkan
1391
%dir %{_datadir}/vulkan/icd.d
1392
%{_datadir}/vulkan/icd.d/broadcom_icd.*.json
1393
1394
%files -n libvulkan_freedreno
1395
%{_libdir}/libvulkan_freedreno.so
1396
%dir %{_datadir}/vulkan
1397
%dir %{_datadir}/vulkan/icd.d
1398
%{_datadir}/vulkan/icd.d/freedreno_icd.*.json
1399
%endif
1400
1401
%files -n Mesa-vulkan-device-select
1402
%{_libdir}/libVkLayer_MESA_device_select.so
1403
%dir %{_datadir}/vulkan
1404
%dir %{_datadir}/vulkan/implicit_layer.d
1405
%{_datadir}/vulkan/implicit_layer.d/VkLayer_MESA_device_select.json
1406
1407
%files -n Mesa-vulkan-overlay
1408
%{_bindir}/mesa-overlay-control.py
1409
%{_libdir}/libVkLayer_MESA_overlay.so
1410
%dir %{_datadir}/vulkan
1411
%dir %{_datadir}/vulkan/explicit_layer.d
1412
%{_datadir}/vulkan/explicit_layer.d/VkLayer_MESA_overlay.json
1413
%endif
1414
1415
%changelog
1416