up to 515.48.07
[packages/xorg-driver-video-nvidia.git] / xorg-driver-video-nvidia.spec
... / ...
CommitLineData
1# TODO
2# - drop binary-only nvidia-settings from here, and use nvidia-settings.spec for it
3# - kernel-drm is required on never kernels. driver for kernel-longterm not requires drm
4#
5# Conditional build:
6%bcond_without system_libglvnd # use system libglvnd
7%bcond_without kernel # without kernel packages
8%bcond_without userspace # don't build userspace programs
9%bcond_with settings # package nvidia-settings here (GPL version of same packaged from nvidia-settings.spec)
10%bcond_with verbose # verbose build (V=1)
11
12# The goal here is to have main, userspace, package built once with
13# simple release number, and only rebuild kernel packages with kernel
14# version as part of release number, without the need to bump release
15# with every kernel change.
16%if 0%{?_pld_builder:1} && %{with kernel} && %{with userspace}
17%{error:kernel and userspace cannot be built at the same time on PLD builders}
18exit 1
19%endif
20
21%define no_install_post_check_so 1
22
23%define rel 1
24%define pname xorg-driver-video-nvidia
25Summary: Linux Drivers for nVidia GeForce/Quadro Chips
26Summary(hu.UTF-8): Linux meghajtók nVidia GeForce/Quadro chipekhez
27Summary(pl.UTF-8): Sterowniki do kart graficznych nVidia GeForce/Quadro
28Name: %{pname}%{?_pld_builder:%{?with_kernel:-kernel}}%{_alt_kernel}
29# when updating version here, keep nvidia-settings.spec in sync as well
30Version: 515.48.07
31Release: %{rel}%{?_pld_builder:%{?with_kernel:@%{_kernel_ver_str}}}
32Epoch: 1
33License: nVidia Binary
34Group: X11
35Source0: https://us.download.nvidia.com/XFree86/Linux-x86_64/%{version}/NVIDIA-Linux-x86_64-%{version}.run
36# Source0-md5: d8529109092e1db0760becb9296abcfd
37Source2: %{pname}-xinitrc.sh
38Source3: gl.pc.in
39Source4: 10-nvidia.conf
40Source5: 10-nvidia-modules.conf
41Patch0: X11-driver-nvidia-desktop.patch
42URL: https://www.nvidia.com/en-us/drivers/unix/
43BuildRequires: rpm-build >= 4.6
44BuildRequires: rpmbuild(macros) >= 1.752
45%{?with_kernel:%{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:3.10}}
46BuildRequires: sed >= 4.0
47BuildConflicts: XFree86-nvidia
48Requires: %{pname}-libs = %{epoch}:%{version}-%{rel}
49Requires: xorg-xserver-server
50Requires: xorg-xserver-server(videodrv-abi) <= 25.2
51Requires: xorg-xserver-server(videodrv-abi) >= 4.0
52Provides: ocl-icd(nvidia)
53Provides: ocl-icd-driver
54Provides: vulkan(icd) = 1.3.194
55Provides: xorg-driver-video
56Provides: xorg-xserver-module(glx)
57Obsoletes: XFree86-driver-nvidia < 1.0.5336-4
58Obsoletes: XFree86-nvidia < 1.0
59Conflicts: XFree86-OpenGL-devel <= 4.2.0-3
60ExclusiveArch: %{?with_userspace:%{ix86}} %{x8664}
61BuildRoot: %{tmpdir}/%{pname}-%{version}-root-%(id -u -n)
62
63%define _enable_debug_packages 0
64
65# libnvidia-encode.so.*.* links with libnvcuvid.so instead of libnvcuvid.so.1
66%define _noautoreq libnvcuvid.so
67
68%define _noautostrip .*/lib/firmware/.*
69
70%description
71This driver set adds improved 2D functionality to the Xorg X server as
72well as high performance OpenGL acceleration, AGP support, support for
73most flat panels, and 2D multiple monitor support.
74
75Supported hardware:
76- GeForce 600 series (excluding 605/GT 610/GT 620/GT 645)
77- GeForce 600M series (GT 640M LE only)
78- GeForce 700 series (excluding GT 705)
79- GeForce 800M series (830M/840M/845M/850M/860M only)
80- GeForce 900/900M series (excluding 910M/920M)
81- GeForce 10 series (including GT 1010)
82- GeForce 10 mobile series
83- GeForce 16 series (also mobile)
84- GeForce MX100 series
85- GeForce MX200 series
86- GeForce MX300 series
87- GeForce MX400 series
88- GeForce RTX 20 series (also mobile)
89- GeForce RTX 30 series (also mobile)
90- GeForce TITAN series (GTX TITAN X/GTX TITAN Black/GTX TITAN Z)
91- NVIDIA RTX series (also mobile)
92- NVIDIA TITAN series (RTX/V/Xp)
93- NVS series (NVS 510/NVS 810 only)
94- Quadro NVS series (NVS 510/NVS 810 only)
95- Quadro Blade/Embedded series (M3000 SE/M5000 SE/P3000/P5000 only)
96- Quadro mobile series (K620M/K2200M/M*/P*/T* only)
97- Quadro series (410/K*/M*/P*/GP100/GV100 only)
98- Quadro RTX series (also mobile)
99- GRID series (K520)
100
101For older hardware see appropriate xorg-driver-video-nvidia-legacy-*
102driver series.
103
104%description -l hu.UTF-8
105Ez a meghajtó kibővíti az Xorg X szerver 2D működését OpenGL
106gyorsítással, AGP támogatással és támogatja a több monitort.
107
108Támogatott hardverek:
109- GeForce 600 series (- 605/GT 610/GT 620/GT 645)
110- GeForce 600M series (GT 640M LE)
111- GeForce 700 series (- GT 705)
112- GeForce 800M series (830M/840M/845M/850M/860M)
113- GeForce 900/900M series (- 910M/920M)
114- GeForce 10 series
115- GeForce 10 mobile series
116- GeForce 16 series (+mobile)
117- GeForce MX100 series
118- GeForce MX200 series
119- GeForce MX300 series
120- GeForce MX400 series
121- GeForce RTX 20 series (+mobile)
122- GeForce RTX 30 series (+mobile)
123- GeForce TITAN series (GTX TITAN X/GTX TITAN Black/GTX TITAN Z)
124- NVIDIA RTX series (+mobile)
125- NVIDIA TITAN series (RTX/V/Xp)
126- NVS series (NVS 510/NVS 810)
127- Quadro NVS series (NVS 510/NVS 810)
128- Quadro Blade/Embedded series (M3000 SE/M5000 SE/P3000/P5000)
129- Quadro mobile series (K620M/K2200M/M*/P*/T*)
130- Quadro series (410/K*/M*/P*/GP100/GV100)
131- Quadro RTX series (+mobile)
132- GRID series (K520)
133
134%description -l pl.UTF-8
135Usprawnione sterowniki dla kart graficznych nVidia do serwera Xorg,
136dające wysokowydajną akcelerację OpenGL, obsługę AGP i wielu monitorów
1372D.
138
139Obsługują karty:
140- GeForce serii 600 (oprócz 605/GT 610/GT 620/GT 645)
141- GeForce serii 600M (tylko GT 640M LE)
142- GeForce serii 700 (oprócz GT 705)
143- GeForce serii 800M (tylko 830M/840M/845M/850M/860M)
144- GeForce serii 900/900M series (oprócz 910M/920M)
145- GeForce serii 10 (wraz z GT 1010)
146- GeForce serii 10 mobile
147- GeForce serii 16 (także mobile)
148- GeForce serii MX100
149- GeForce serii MX200
150- GeForce serii MX300
151- GeForce serii MX400
152- GeForce serii RTX 20 (także mobile)
153- GeForce serii RTX 30 (także mobile)
154- GeForce serii TITAN (GTX TITAN X/GTX TITAN Black/GTX TITAN Z)
155- NVIDIA serii RTX (także mobile)
156- NVIDIA serii TITAN (RTX/V/Xp)
157- serii NVS (tylko NVS 510/NVS 810)
158- Quadro serii NVS (tylko NVS 510/NVS 810)
159- Quadro serii Blade/Embedded (tylko M3000 SE/M5000 SE/P3000/P5000)
160- Quadro mobile (tylko K620M/K2200M/M*/P*/T*)
161- Quadro (tylko 410/K*/M*/P*/GP100/GV100)
162- Quadro serii RTX (także mobile)
163- GRID (K520)
164
165%package libs
166Summary: OpenGL (GL and GLX) Nvidia libraries
167Summary(pl.UTF-8): Biblioteki OpenGL (GL i GLX) Nvidia
168Group: X11/Development/Libraries
169Requires(post,postun): /sbin/ldconfig
170%if %{with system_libglvnd}
171Requires: libglvnd >= 1.3.4-2
172Requires: libglvnd-libGL >= 1.3.4-2
173Requires: libglvnd-libGLES >= 1.3.4-2
174%endif
175Requires: libvdpau >= 0.3
176Provides: OpenGL = 4.6
177Provides: OpenGL-GLX = 1.4
178Obsoletes: X11-OpenGL-core < 1:7.0.0
179Obsoletes: X11-OpenGL-libGL < 1:7.0.0
180Obsoletes: XFree86-OpenGL-core < 1:7.0.0
181Obsoletes: XFree86-OpenGL-libGL < 1:7.0.0
182%if %{with system_libglvnd}
183Obsoletes: xorg-driver-video-nvidia-devel < 465.27-2
184%endif
185
186%description libs
187NVIDIA OpenGL (GL and GLX only) implementation libraries.
188
189%description libs -l pl.UTF-8
190Implementacja OpenGL (tylko GL i GLX) firmy NVIDIA.
191
192%package devel
193Summary: OpenGL (GL and GLX) header files
194Summary(hu.UTF-8): OpenGL (GL és GLX) fejléc fájlok
195Summary(pl.UTF-8): Pliki nagłówkowe OpenGL (GL i GLX)
196Group: X11/Development/Libraries
197Requires: %{pname}-libs = %{epoch}:%{version}-%{rel}
198Obsoletes: X11-OpenGL-devel-base < 1:7.0.0
199Obsoletes: XFree86-OpenGL-devel-base < 1:7.0.0
200Obsoletes: XFree86-driver-nvidia-devel < 1.0.5336-4
201Conflicts: XFree86-OpenGL-devel < 4.3.99.902-0.3
202
203%description devel
204OpenGL header files (GL and GLX only) for NVIDIA OpenGL
205implementation.
206
207%description devel -l hu.UTF-8
208OpenGL fejléc fájlok (csak GL és GLX) NVIDIA OpenGL implementációhoz.
209
210%description devel -l pl.UTF-8
211Pliki nagłówkowe OpenGL (tylko GL i GLX) dla implementacji OpenGL
212firmy NVIDIA.
213
214%package doc
215Summary: Documentation for NVIDIA Graphics Driver
216Summary(pl.UTF-8): Dokumentacja do sterownika graficznego NVIDIA
217Group: Documentation
218BuildArch: noarch
219
220%description doc
221NVIDIA Accelerated Linux Graphics Driver README and Installation
222Guide.
223
224%description doc -l pl.UTF-8
225Plik README oraz przewodnik instalacji do akcelerowanego sterownika
226graficznego NVIDIA dla Linuksa.
227
228%package progs
229Summary: Tools for advanced control of nVidia graphic cards
230Summary(hu.UTF-8): Eszközök az nVidia grafikus kártyák beállításához
231Summary(pl.UTF-8): Narzędzia do zarządzania kartami graficznymi nVidia
232Group: Applications/System
233Requires: %{pname} = %{epoch}:%{version}
234Suggests: pkgconfig
235Obsoletes: XFree86-driver-nvidia-progs < 1.0.5336-4
236
237%description progs
238Tools for advanced control of nVidia graphic cards.
239
240%description progs -l hu.UTF-8
241Eszközök az nVidia grafikus kártyák beállításához.
242
243%description progs -l pl.UTF-8
244Narzędzia do zarządzania kartami graficznymi nVidia.
245
246%define kernel_pkg()\
247%package -n kernel%{_alt_kernel}-video-nvidia\
248Summary: nVidia kernel module for nVidia Architecture support\
249Summary(de.UTF-8): Das nVidia-Kern-Modul für die nVidia-Architektur-Unterstützung\
250Summary(hu.UTF-8): nVidia Architektúra támogatás Linux kernelhez.\
251Summary(pl.UTF-8): Moduł jądra dla obsługi kart graficznych nVidia\
252Release: %{rel}@%{_kernel_ver_str}\
253Group: Base/Kernel\
254Requires(post,postun): /sbin/depmod\
255Requires: dev >= 2.7.7-10\
256%requires_releq_kernel\
257%if %{_kernel_version_code} >= %{_kernel_version_magic 3 10 0}\
258Requires: %{releq_kernel -n drm}\
259%endif\
260Requires(postun): %releq_kernel\
261Requires: %{pname} = %{epoch}:%{version}\
262Provides: X11-driver-nvidia(kernel)\
263Obsoletes: XFree86-nvidia-kernel < 1.0.5336-4\
264\
265%description -n kernel%{_alt_kernel}-video-nvidia\
266nVidia Architecture support for Linux kernel.\
267\
268%description -n kernel%{_alt_kernel}-video-nvidia -l de.UTF-8\
269Die nVidia-Architektur-Unterstützung für den Linux-Kern.\
270\
271%description -n kernel%{_alt_kernel}-video-nvidia -l hu.UTF-8\
272nVidia Architektúra támogatás Linux kernelhez.\
273\
274%description -n kernel%{_alt_kernel}-video-nvidia -l pl.UTF-8\
275Obsługa architektury nVidia dla jądra Linuksa. Pakiet wymagany przez\
276sterownik nVidii dla Xorg/XFree86.\
277\
278%if %{with kernel}\
279%files -n kernel%{_alt_kernel}-video-nvidia\
280%defattr(644,root,root,755)\
281%dir /lib/firmware/nvidia\
282%dir /lib/firmware/nvidia/%{version}\
283/lib/firmware/nvidia/%{version}/gsp.bin\
284/lib/modules/%{_kernel_ver}/misc/*.ko*\
285%endif\
286\
287%post -n kernel%{_alt_kernel}-video-nvidia\
288%depmod %{_kernel_ver}\
289\
290%postun -n kernel%{_alt_kernel}-video-nvidia\
291%depmod %{_kernel_ver}\
292%{nil}
293
294%define build_kernel_pkg()\
295cd kernel\
296%{__make} SYSSRC=%{_kernelsrcdir} clean\
297%{__make} SYSSRC=%{_kernelsrcdir} IGNORE_CC_MISMATCH=1 NV_VERBOSE=1 CC=%{__cc} module\
298cd ..\
299%install_kernel_modules -D installed -m kernel/nvidia,kernel/nvidia-drm,kernel/nvidia-modeset -d misc\
300%install_kernel_modules -D installed -m kernel/nvidia-uvm -d misc\
301%{nil}
302
303%ifarch %{x8664}
304%{?with_kernel:%{expand:%create_kernel_packages}}
305%endif
306
307%prep
308cd %{_builddir}
309rm -rf NVIDIA-Linux-x86_64-%{version}
310/bin/sh %{SOURCE0} --extract-only
311%setup -qDT -n NVIDIA-Linux-x86_64-%{version}
312%patch0 -p1
313echo 'EXTRA_CFLAGS += -Wno-pointer-arith -Wno-sign-compare -Wno-unused' >> kernel/Makefile.kbuild
314
315%build
316%ifarch %{x8664}
317%{?with_kernel:%{expand:%build_kernel_packages}}
318%endif
319
320%install
321rm -rf $RPM_BUILD_ROOT
322
323%if %{with userspace}
324install -d $RPM_BUILD_ROOT%{_libdir}/{gbm,nvidia,xorg/modules/{drivers,extensions/nvidia}} \
325 $RPM_BUILD_ROOT{%{_libdir}/vdpau,%{_bindir},%{_mandir}/man1} \
326 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},/etc/X11/xinit/xinitrc.d} \
327 $RPM_BUILD_ROOT%{_sysconfdir}/{OpenCL/vendors,ld.so.conf.d,X11/xorg.conf.d} \
328 $RPM_BUILD_ROOT%{_datadir}/{glvnd/egl_vendor.d,nvidia,vulkan/icd.d,egl/egl_external_platform.d}
329
330%ifarch %{x8664}
331%if %{with settings}
332install -p nvidia-settings $RPM_BUILD_ROOT%{_bindir}
333cp -p nvidia-settings.1* $RPM_BUILD_ROOT%{_mandir}/man1
334cp -p nvidia-settings.desktop $RPM_BUILD_ROOT%{_desktopdir}
335cp -p nvidia-settings.png $RPM_BUILD_ROOT%{_pixmapsdir}
336install -p %{SOURCE2} $RPM_BUILD_ROOT/etc/X11/xinit/xinitrc.d/nvidia-settings.sh
337%endif
338
339install -p nvidia-{smi,xconfig,bug-report.sh} $RPM_BUILD_ROOT%{_bindir}
340install -p nvidia-cuda-mps-{control,server} $RPM_BUILD_ROOT%{_bindir}
341cp -p nvidia-{smi,xconfig,cuda-mps-control}.1* $RPM_BUILD_ROOT%{_mandir}/man1
342install -p nvidia.icd $RPM_BUILD_ROOT%{_sysconfdir}/OpenCL/vendors
343
344install %{SOURCE4} $RPM_BUILD_ROOT/etc/X11/xorg.conf.d
345install %{SOURCE5} $RPM_BUILD_ROOT/etc/X11/xorg.conf.d
346sed -i -e 's|@@LIBDIR@@|%{_libdir}|g' $RPM_BUILD_ROOT/etc/X11/xorg.conf.d/10-nvidia-modules.conf
347install -p nvidia-drm-outputclass.conf $RPM_BUILD_ROOT/etc/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf
348
349install -p nvidia-application-profiles-%{version}-key-documentation $RPM_BUILD_ROOT%{_datadir}/nvidia
350install -p nvidia-application-profiles-%{version}-rc $RPM_BUILD_ROOT%{_datadir}/nvidia
351%endif
352
353%ifarch %{ix86}
354%define srcdir 32
355%else
356%define srcdir .
357%endif
358
359for f in \
360%if %{without system_libglvnd}
361 %{srcdir}/libGL.so.1.7.0 \
362 %{srcdir}/libGLX.so.0 \
363 %{srcdir}/libOpenGL.so.0 \
364 %{srcdir}/libGLdispatch.so.0 \
365 %{srcdir}/libGLESv1_CM.so.1.2.0 \
366 %{srcdir}/libGLESv2.so.2.1.0 \
367 %{srcdir}/libEGL.so.1.1.0 \
368%endif
369 %{srcdir}/libGLX_nvidia.so.%{version} \
370 %{srcdir}/libEGL_nvidia.so.%{version} \
371 %{srcdir}/libGLESv1_CM_nvidia.so.%{version} \
372 %{srcdir}/libGLESv2_nvidia.so.%{version} \
373%ifarch %{x8664}
374 %{srcdir}/libnvidia-egl-gbm.so.1.1.0 \
375 %{srcdir}/libnvidia-egl-wayland.so.1.1.9 \
376 %{srcdir}/libnvidia-eglcore.so.%{version} \
377%endif
378 %{srcdir}/libcuda.so.%{version} \
379 %{srcdir}/libnvcuvid.so.%{version} \
380%ifarch %{x8664}
381 %{srcdir}/libnvidia-cfg.so.%{version} \
382 %{srcdir}/libnvidia-ngx.so.%{version} \
383 %{srcdir}/libnvidia-rtcore.so.%{version} \
384 %{srcdir}/libnvidia-vulkan-producer.so.%{version} \
385 %{srcdir}/libnvoptix.so.%{version} \
386%endif
387 %{srcdir}/libnvidia-allocator.so.%{version} \
388 %{srcdir}/libnvidia-compiler.so.%{version} \
389 %{srcdir}/libnvidia-encode.so.%{version} \
390 %{srcdir}/libnvidia-fbc.so.%{version} \
391 %{srcdir}/libnvidia-glcore.so.%{version} \
392 %{srcdir}/libnvidia-glsi.so.%{version} \
393 %{srcdir}/libnvidia-glvkspirv.so.%{version} \
394 %{srcdir}/libnvidia-ml.so.%{version} \
395 %{srcdir}/libnvidia-nvvm.so.%{version} \
396 %{srcdir}/libnvidia-opencl.so.%{version} \
397 %{srcdir}/libnvidia-opticalflow.so.%{version} \
398 %{srcdir}/libnvidia-ptxjitcompiler.so.%{version} \
399 %{srcdir}/libnvidia-tls.so.%{version} \
400; do
401 install -p $f $RPM_BUILD_ROOT%{_libdir}/nvidia
402done
403
404install -p %{srcdir}/libvdpau_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/vdpau
405
406%ifarch %{x8664}
407install -p libglxserver_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/xorg/modules/extensions/nvidia
408ln -s libglxserver_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/xorg/modules/extensions/nvidia/libglxserver_nvidia.so
409install -p nvidia_drv.so $RPM_BUILD_ROOT%{_libdir}/xorg/modules/drivers/nvidia_drv.so.%{version}
410ln -s nvidia_drv.so.%{version} $RPM_BUILD_ROOT%{_libdir}/xorg/modules/drivers/nvidia_drv.so
411%endif
412
413/sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}/nvidia
414/sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}/xorg/modules/extensions/nvidia
415
416ln -sf libvdpau_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/vdpau/libvdpau_nvidia.so.1
417
418%ifarch %{x8664}
419echo %{_libdir}/nvidia >$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia64.conf
420echo %{_libdir}/vdpau >>$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia64.conf
421%else
422echo %{_libdir}/nvidia >$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia.conf
423echo %{_libdir}/vdpau >>$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia.conf
424%endif
425
426# OpenGL ABI for Linux compatibility
427%if %{without system_libglvnd}
428ln -sf libGL.so.1.7.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGL.so.1
429ln -sf libGL.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGL.so
430ln -sf libGLX.so.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLX.so
431ln -sf libOpenGL.so.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libOpenGL.so
432ln -sf libGLESv1_CM.so.1.2.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv1_CM.so.1
433ln -sf libGLESv1_CM.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv1_CM.so
434ln -sf libGLESv2.so.2.1.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv2.so.2
435ln -sf libGLESv2.so.2 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv2.so
436ln -sf libEGL.so.1.1.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libEGL.so.1
437ln -sf libEGL.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libEGL.so
438%endif
439ln -sf libGLX_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLX_nvidia.so.0
440ln -sf libGLX_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLX_indirect.so.0
441ln -sf libEGL_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libEGL_nvidia.so.0
442ln -sf libGLESv1_CM_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv1_CM_nvidia.so.1
443ln -sf libGLESv2_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv2_nvidia.so.2
444
445ln -sf ../nvidia/libnvidia-allocator.so.%{version} $RPM_BUILD_ROOT%{_libdir}/gbm/nvidia-drm_gbm.so
446
447%ifarch %{x8664}
448install -p 10_nvidia.json $RPM_BUILD_ROOT%{_datadir}/glvnd/egl_vendor.d
449install -p 15_nvidia_gbm.json $RPM_BUILD_ROOT%{_datadir}/egl/egl_external_platform.d
450install -p nvidia_icd.json $RPM_BUILD_ROOT%{_datadir}/vulkan/icd.d
451%endif
452ln -sf libcuda.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libcuda.so
453ln -sf libnvcuvid.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libnvcuvid.so
454
455%endif
456
457%ifarch %{x8664}
458%if %{with kernel}
459install -d $RPM_BUILD_ROOT
460cp -a installed/* $RPM_BUILD_ROOT
461install -D firmware/gsp.bin $RPM_BUILD_ROOT/lib/firmware/nvidia/%{version}/gsp.bin
462%endif
463%endif
464
465install -d $RPM_BUILD_ROOT%{_pkgconfigdir}
466sed -e '
467 s|@@prefix@@|%{_prefix}|g;
468 s|@@libdir@@|%{_libdir}|g;
469 s|@@version@@|%{version}|g' < %{SOURCE3} \
470 > $RPM_BUILD_ROOT%{_pkgconfigdir}/gl.pc
471
472%clean
473rm -rf $RPM_BUILD_ROOT
474
475%post
476cat << 'EOF'
477NOTE: You must also install kernel module for this driver to work
478 kernel%{_alt_kernel}-video-nvidia-%{version}
479
480EOF
481
482%post libs -p /sbin/ldconfig
483%postun libs -p /sbin/ldconfig
484
485%if %{with userspace}
486%ifarch %{x8664}
487%files
488%defattr(644,root,root,755)
489%doc LICENSE NVIDIA_Changelog README.txt
490%dir %{_libdir}/xorg/modules/extensions/nvidia
491%attr(755,root,root) %{_libdir}/xorg/modules/extensions/nvidia/libglxserver_nvidia.so.*
492%attr(755,root,root) %{_libdir}/xorg/modules/extensions/nvidia/libglxserver_nvidia.so
493%attr(755,root,root) %{_libdir}/xorg/modules/drivers/nvidia_drv.so.*
494%attr(755,root,root) %{_libdir}/xorg/modules/drivers/nvidia_drv.so
495%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/X11/xorg.conf.d/10-nvidia.conf
496%{_sysconfdir}/X11/xorg.conf.d/10-nvidia-modules.conf
497%{_sysconfdir}/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf
498%dir %{_datadir}/nvidia
499%{_datadir}/nvidia/nvidia-application-profiles-%{version}-key-documentation
500%{_datadir}/nvidia/nvidia-application-profiles-%{version}-rc
501%endif
502
503%files libs
504%defattr(644,root,root,755)
505%ifarch %{x8664}
506%dir %{_sysconfdir}/OpenCL
507%dir %{_sysconfdir}/OpenCL/vendors
508%{_sysconfdir}/OpenCL/vendors/nvidia.icd
509%endif
510%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ld.so.conf.d/nvidia*.conf
511%attr(755,root,root) %{_libdir}/gbm/nvidia-drm_gbm.so
512%dir %{_libdir}/nvidia
513%if %{without system_libglvnd}
514%attr(755,root,root) %{_libdir}/nvidia/libGL.so.1.7.0
515%attr(755,root,root) %ghost %{_libdir}/nvidia/libGL.so.1
516%attr(755,root,root) %{_libdir}/nvidia/libGL.so
517%attr(755,root,root) %{_libdir}/nvidia/libGLX.so.0
518%attr(755,root,root) %{_libdir}/nvidia/libOpenGL.so.0
519%attr(755,root,root) %{_libdir}/nvidia/libGLdispatch.so.0
520%attr(755,root,root) %{_libdir}/nvidia/libGLESv1_CM.so.1.2.0
521%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv1_CM.so.1
522%attr(755,root,root) %{_libdir}/nvidia/libGLESv2.so.2.1.0
523%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv2.so.2
524%attr(755,root,root) %{_libdir}/nvidia/libEGL.so.1.1.0
525%attr(755,root,root) %ghost %{_libdir}/nvidia/libEGL.so.1
526%endif
527%attr(755,root,root) %ghost %{_libdir}/nvidia/libEGL_nvidia.so.0
528%attr(755,root,root) %{_libdir}/nvidia/libEGL_nvidia.so.*.*
529%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv1_CM_nvidia.so.1
530%attr(755,root,root) %{_libdir}/nvidia/libGLESv1_CM_nvidia.so.*.*
531%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv2_nvidia.so.2
532%attr(755,root,root) %{_libdir}/nvidia/libGLESv2_nvidia.so.*.*
533%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLX_indirect.so.0
534%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLX_nvidia.so.0
535%attr(755,root,root) %{_libdir}/nvidia/libGLX_nvidia.so.*.*
536%ifarch %{x8664}
537%attr(755,root,root) %{_libdir}/nvidia/libnvidia-egl-gbm.so.*.*.*
538%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-egl-gbm.so.1
539%attr(755,root,root) %{_libdir}/nvidia/libnvidia-egl-wayland.so.*.*.*
540%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-egl-wayland.so.1
541%attr(755,root,root) %{_libdir}/nvidia/libnvidia-eglcore.so.*.*
542%endif
543%attr(755,root,root) %{_libdir}/nvidia/libcuda.so.*.*
544%attr(755,root,root) %ghost %{_libdir}/nvidia/libcuda.so.1
545%attr(755,root,root) %{_libdir}/nvidia/libcuda.so
546%attr(755,root,root) %{_libdir}/nvidia/libnvcuvid.so.*.*
547%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvcuvid.so.1
548%attr(755,root,root) %{_libdir}/nvidia/libnvcuvid.so
549%ifarch %{x8664}
550%attr(755,root,root) %{_libdir}/nvidia/libnvidia-cfg.so.*.*
551%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-cfg.so.1
552%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ngx.so.*.*
553%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ngx.so.1
554%attr(755,root,root) %{_libdir}/nvidia/libnvidia-rtcore.so.*.*
555%attr(755,root,root) %{_libdir}/nvidia/libnvidia-vulkan-producer.so.*.*
556%attr(755,root,root) %{_libdir}/nvidia/libnvoptix.so.*.*
557%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvoptix.so.1
558%endif
559%attr(755,root,root) %{_libdir}/nvidia/libnvidia-allocator.so.*.*
560%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-allocator.so.1
561%attr(755,root,root) %{_libdir}/nvidia/libnvidia-compiler.so.*.*
562%attr(755,root,root) %{_libdir}/nvidia/libnvidia-encode.so.*.*
563%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-encode.so.1
564%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-fbc.so.1
565%attr(755,root,root) %{_libdir}/nvidia/libnvidia-fbc.so.*.*
566%attr(755,root,root) %{_libdir}/nvidia/libnvidia-glcore.so.*.*
567%attr(755,root,root) %{_libdir}/nvidia/libnvidia-glsi.so.*.*
568%attr(755,root,root) %{_libdir}/nvidia/libnvidia-glvkspirv.so.*.*
569%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ml.so.*.*
570%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ml.so.1
571%attr(755,root,root) %{_libdir}/nvidia/libnvidia-nvvm.so.*.*.*
572%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-nvvm.so.4
573%attr(755,root,root) %{_libdir}/nvidia/libnvidia-opencl.so.*.*
574%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-opencl.so.1
575%attr(755,root,root) %{_libdir}/nvidia/libnvidia-opticalflow.so.*.*
576%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-opticalflow.so.1
577%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ptxjitcompiler.so.*.*
578%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ptxjitcompiler.so.1
579%attr(755,root,root) %{_libdir}/nvidia/libnvidia-tls.so.*.*
580%attr(755,root,root) %{_libdir}/vdpau/libvdpau_nvidia.so.*.*
581%attr(755,root,root) %ghost %{_libdir}/vdpau/libvdpau_nvidia.so.1
582%ifarch %{x8664}
583# which package should own those?
584%dir %{_datadir}/egl
585%dir %{_datadir}/egl/egl_external_platform.d
586%{_datadir}/egl/egl_external_platform.d/15_nvidia_gbm.json
587%{_datadir}/glvnd/egl_vendor.d/10_nvidia.json
588%{_datadir}/vulkan/icd.d/nvidia_icd.json
589%endif
590
591%if %{without system_libglvnd}
592%files devel
593%defattr(644,root,root,755)
594%attr(755,root,root) %{_libdir}/nvidia/libGLX.so
595%attr(755,root,root) %{_libdir}/nvidia/libOpenGL.so
596%attr(755,root,root) %{_libdir}/nvidia/libGLESv1_CM.so
597%attr(755,root,root) %{_libdir}/nvidia/libGLESv2.so
598%attr(755,root,root) %{_libdir}/nvidia/libEGL.so
599%{_pkgconfigdir}/gl.pc
600%endif
601
602%files doc
603%defattr(644,root,root,755)
604%doc html/*
605
606%ifarch %{x8664}
607%files progs
608%defattr(644,root,root,755)
609%attr(755,root,root) %{_bindir}/nvidia-bug-report.sh
610%attr(755,root,root) %{_bindir}/nvidia-cuda-mps-control
611%attr(755,root,root) %{_bindir}/nvidia-cuda-mps-server
612%attr(755,root,root) %{_bindir}/nvidia-smi
613%attr(755,root,root) %{_bindir}/nvidia-xconfig
614%{_mandir}/man1/nvidia-cuda-mps-control.1*
615%{_mandir}/man1/nvidia-smi.1*
616%{_mandir}/man1/nvidia-xconfig.1*
617%if %{with settings}
618%attr(755,root,root) /etc/X11/xinit/xinitrc.d/nvidia-settings.sh
619%attr(755,root,root) %{_bindir}/nvidia-settings
620%{_mandir}/man1/nvidia-settings.1*
621%{_desktopdir}/nvidia-settings.desktop
622%{_pixmapsdir}/nvidia-settings.png
623%endif
624%endif
625%endif
This page took 0.079518 seconds and 5 git commands to generate.