- removed OpenGL*-devel provides from -devel (headers no longer provided)
[packages/xorg-driver-video-nvidia.git] / xorg-driver-video-nvidia.spec
CommitLineData
2b14e59b 1# TODO
17fdb673 2# - should -libs Require main package?
8a7af30b 3# - drop binary-only nvidia-settings from here, and use nvidia-settings.spec for it?
0dbede64 4# - kernel-drm is required on never kernels. driver for kernel-longterm not requires drm
28142503
PS
5#
6# Conditional build:
b55b4acb 7%bcond_with system_libglvnd # use system libglvnd
bf683e7a 8%bcond_without kernel # without kernel packages
1820d34b 9%bcond_without userspace # don't build userspace programs
5da85237 10%bcond_with settings # package nvidia-settings here (GPL version of same packaged from nvidia-settings.spec)
a14b5013 11%bcond_with verbose # verbose build (V=1)
12
e4947020
JR
13# The goal here is to have main, userspace, package built once with
14# simple release number, and only rebuild kernel packages with kernel
15# version as part of release number, without the need to bump release
16# with every kernel change.
17%if 0%{?_pld_builder:1} && %{with kernel} && %{with userspace}
18%{error:kernel and userspace cannot be built at the same time on PLD builders}
19exit 1
20%endif
21
7cbecde6 22%define no_install_post_check_so 1
c5bb5957 23
a6591e72 24%define rel 2
f3bf0f30 25%define pname xorg-driver-video-nvidia
974295b8 26Summary: Linux Drivers for nVidia GeForce/Quadro Chips
754fc4fe 27Summary(hu.UTF-8): Linux meghajtók nVidia GeForce/Quadro chipekhez
974295b8 28Summary(pl.UTF-8): Sterowniki do kart graficznych nVidia GeForce/Quadro
e4947020 29Name: %{pname}%{?_pld_builder:%{?with_kernel:-kernel}}%{_alt_kernel}
8a7af30b 30# when updating version here, keep nvidia-settings.spec in sync as well
09759ac2 31Version: 465.27
e4947020 32Release: %{rel}%{?_pld_builder:%{?with_kernel:@%{_kernel_ver_str}}}
d7c1ffa0 33Epoch: 1
28142503 34License: nVidia Binary
4a185d32 35Group: X11
dd40547e 36Source0: https://us.download.nvidia.com/XFree86/Linux-x86_64/%{version}/NVIDIA-Linux-x86_64-%{version}.run
09759ac2 37# Source0-md5: 212e7765216ca3961409637360acce4c
a14b5013 38Source2: %{pname}-xinitrc.sh
236b5374 39Source3: gl.pc.in
cd436d42
JR
40Source4: 10-nvidia.conf
41Source5: 10-nvidia-modules.conf
117b7720 42Patch0: X11-driver-nvidia-desktop.patch
164c61ac 43URL: https://www.nvidia.com/en-us/drivers/unix/
9ec7e8e8 44BuildRequires: rpm-build >= 4.6
679b0225 45BuildRequires: rpmbuild(macros) >= 1.752
f1773542 46%{?with_kernel:%{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6.32}}
039c7221 47BuildRequires: sed >= 4.0
0ed6aeef 48BuildConflicts: XFree86-nvidia
0703c7e8 49Requires: %{pname}-libs = %{epoch}:%{version}-%{rel}
8343d24d 50Requires: xorg-xserver-server
78d034da 51Requires: xorg-xserver-server(videodrv-abi) <= 24.1
f1773542 52Requires: xorg-xserver-server(videodrv-abi) >= 4.0
857c0a69
JP
53Provides: ocl-icd(nvidia)
54Provides: ocl-icd-driver
ba44513b 55Provides: vulkan(icd) = 1.2.155
f3bf0f30 56Provides: xorg-driver-video
4e3e8de1 57Provides: xorg-xserver-module(glx)
d56b66df
JB
58Obsoletes: XFree86-driver-nvidia < 1.0.5336-4
59Obsoletes: XFree86-nvidia < 1.0
28142503 60Conflicts: XFree86-OpenGL-devel <= 4.2.0-3
c202a266 61ExclusiveArch: %{?with_userspace:%{ix86}} %{x8664}
b67880c3 62BuildRoot: %{tmpdir}/%{pname}-%{version}-root-%(id -u -n)
28142503 63
5ce5c6c8
JR
64%define _enable_debug_packages 0
65
04ec5f0a
JR
66%define _noautoreqdep libGL.so.1 libnvcuvid.so
67# libnvidia-encode.so.*.* links with libnvcuvid.so instead of libnvcuvid.so.1
68%define _noautoreq libnvcuvid.so
28142503
PS
69
70%description
974295b8
JB
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. Supported hardware:
74modern NVIDIA GeForce (from GeForce2 MX) and Quadro (Quadro4 and up)
75based graphics accelerators.
28142503 76
974295b8
JB
77The older graphics chips are unsupported:
78- NV1 and RIVA 128/128ZX chips are supported in the base Xorg install
79 (nv driver)
80- TNT/TNT2/GeForce 256/GeForce2 Ultra/Quadro2 are suported by -legacy
81 drivers.
28142503 82
754fc4fe
ZU
83%description -l hu.UTF-8
84Ez a meghajtó kibővíti az Xorg X szerver 2D működését OpenGL
85gyorsítással, AGP támogatással és támogatja a több monitort.
86Támogatott hardverek: modern NVIDIA GeForce (GeForce2 MX-től) és
87Quadro (Quadro4 és újabbak) alapú grafikai gyorsítók.
88
89A régekbbi grafikus chipek nem támogatottak:
90- NV1 és RIVA 128/128ZX chipek az alap Xorg telepítéssel (nv meghajtó)
91- TNT/TNT2/GeForce 256/GeForce2 Ultra/Quadro2 a -legacy driverekkel
92 támogatottak.
93
c311612f 94%description -l pl.UTF-8
974295b8
JB
95Usprawnione sterowniki dla kart graficznych nVidia do serwera Xorg,
96dające wysokowydajną akcelerację OpenGL, obsługę AGP i wielu monitorów
972D. Obsługują w miarę nowe karty NVIDIA GeForce (od wersji GeForce2
98MX) oraz Quadro (od wersji Quadro4).
28142503 99
974295b8
JB
100Starsze układy graficzne nie są obsługiwane przez ten pakiet:
101- NV1 i RIVA 128/128ZX są obsługiwane przez sterownik nv z Xorg
102- TNT/TNT2/GeForce 256/GeForce 2 Ultra/Quadro 2 są obsługiwane przez
103 sterowniki -legacy
28142503 104
17fdb673
JR
105%package libs
106Summary: OpenGL (GL and GLX) Nvidia libraries
107Summary(pl.UTF-8): Biblioteki OpenGL (GL i GLX) Nvidia
108Group: X11/Development/Libraries
f3b8319b 109Requires(post,postun): /sbin/ldconfig
1011cf4a 110%if %{with system_libglvnd}
538b2e0c
JP
111Requires: libglvnd
112Requires: libglvnd-libGL
113Requires: libglvnd-libGLES
114%endif
76db0ca8 115Requires: libvdpau >= 0.3
ba4c5c19 116Provides: OpenGL = 3.3
17fdb673 117Provides: OpenGL-GLX = 1.4
17fdb673
JR
118Obsoletes: X11-OpenGL-core < 1:7.0.0
119Obsoletes: X11-OpenGL-libGL < 1:7.0.0
120Obsoletes: XFree86-OpenGL-core < 1:7.0.0
121Obsoletes: XFree86-OpenGL-libGL < 1:7.0.0
b55b4acb
JB
122%if %{with system_libglvnd}
123Obsoletes: xorg-driver-video-nvidia-devel < 465.27-2
124%endif
17fdb673 125
4c842b35 126%description libs
17fdb673
JR
127NVIDIA OpenGL (GL and GLX only) implementation libraries.
128
4c842b35 129%description libs -l pl.UTF-8
17fdb673
JR
130Implementacja OpenGL (tylko GL i GLX) firmy NVIDIA.
131
28142503 132%package devel
63c6d4b1 133Summary: OpenGL (GL and GLX) header files
754fc4fe 134Summary(hu.UTF-8): OpenGL (GL és GLX) fejléc fájlok
63c6d4b1 135Summary(pl.UTF-8): Pliki nagłówkowe OpenGL (GL i GLX)
28142503 136Group: X11/Development/Libraries
0703c7e8 137Requires: %{pname}-libs = %{epoch}:%{version}-%{rel}
d56b66df
JB
138Obsoletes: X11-OpenGL-devel-base < 1:7.0.0
139Obsoletes: XFree86-OpenGL-devel-base < 1:7.0.0
140Obsoletes: XFree86-driver-nvidia-devel < 1.0.5336-4
28142503
PS
141Conflicts: XFree86-OpenGL-devel < 4.3.99.902-0.3
142
143%description devel
63c6d4b1
JB
144OpenGL header files (GL and GLX only) for NVIDIA OpenGL
145implementation.
28142503 146
754fc4fe
ZU
147%description devel -l hu.UTF-8
148OpenGL fejléc fájlok (csak GL és GLX) NVIDIA OpenGL implementációhoz.
149
c311612f 150%description devel -l pl.UTF-8
63c6d4b1
JB
151Pliki nagłówkowe OpenGL (tylko GL i GLX) dla implementacji OpenGL
152firmy NVIDIA.
153
a9160796
ER
154%package doc
155Summary: Documentation for NVIDIA Graphics Driver
9ec7e8e8 156Summary(pl.UTF-8): Dokumentacja do sterownika graficznego NVIDIA
a9160796 157Group: Documentation
37ef2ff1 158BuildArch: noarch
a9160796
ER
159
160%description doc
161NVIDIA Accelerated Linux Graphics Driver README and Installation
162Guide.
163
9ec7e8e8
JB
164%description doc -l pl.UTF-8
165Plik README oraz przewodnik instalacji do akcelerowanego sterownika
166graficznego NVIDIA dla Linuksa.
167
28142503
PS
168%package progs
169Summary: Tools for advanced control of nVidia graphic cards
754fc4fe 170Summary(hu.UTF-8): Eszközök az nVidia grafikus kártyák beállításához
b37addd9 171Summary(pl.UTF-8): Narzędzia do zarządzania kartami graficznymi nVidia
f12e8b24 172Group: Applications/System
0056ee0e 173Requires: %{pname} = %{epoch}:%{version}
c29343e3 174Suggests: pkgconfig
d56b66df 175Obsoletes: XFree86-driver-nvidia-progs < 1.0.5336-4
28142503
PS
176
177%description progs
178Tools for advanced control of nVidia graphic cards.
179
754fc4fe
ZU
180%description progs -l hu.UTF-8
181Eszközök az nVidia grafikus kártyák beállításához.
182
c311612f
JR
183%description progs -l pl.UTF-8
184Narzędzia do zarządzania kartami graficznymi nVidia.
28142503 185
e4947020
JR
186%define kernel_pkg()\
187%package -n kernel%{_alt_kernel}-video-nvidia\
188Summary: nVidia kernel module for nVidia Architecture support\
189Summary(de.UTF-8): Das nVidia-Kern-Modul für die nVidia-Architektur-Unterstützung\
190Summary(hu.UTF-8): nVidia Architektúra támogatás Linux kernelhez.\
191Summary(pl.UTF-8): Moduł jądra dla obsługi kart graficznych nVidia\
192Release: %{rel}@%{_kernel_ver_str}\
193Group: Base/Kernel\
194Requires(post,postun): /sbin/depmod\
195Requires: dev >= 2.7.7-10\
e4947020
JR
196%requires_releq_kernel\
197%if %{_kernel_version_code} >= %{_kernel_version_magic 3 10 0}\
198Requires: %{releq_kernel -n drm}\
199%endif\
200Requires(postun): %releq_kernel\
e4947020
JR
201Requires: %{pname} = %{epoch}:%{version}\
202Provides: X11-driver-nvidia(kernel)\
d56b66df 203Obsoletes: XFree86-nvidia-kernel < 1.0.5336-4\
e4947020
JR
204\
205%description -n kernel%{_alt_kernel}-video-nvidia\
206nVidia Architecture support for Linux kernel.\
207\
208%description -n kernel%{_alt_kernel}-video-nvidia -l de.UTF-8\
209Die nVidia-Architektur-Unterstützung für den Linux-Kern.\
210\
211%description -n kernel%{_alt_kernel}-video-nvidia -l hu.UTF-8\
212nVidia Architektúra támogatás Linux kernelhez.\
213\
214%description -n kernel%{_alt_kernel}-video-nvidia -l pl.UTF-8\
215Obsługa architektury nVidia dla jądra Linuksa. Pakiet wymagany przez\
216sterownik nVidii dla Xorg/XFree86.\
217\
218%if %{with kernel}\
219%files -n kernel%{_alt_kernel}-video-nvidia\
220%defattr(644,root,root,755)\
221/lib/modules/%{_kernel_ver}/misc/*.ko*\
222%endif\
223\
224%post -n kernel%{_alt_kernel}-video-nvidia\
225%depmod %{_kernel_ver}\
226\
227%postun -n kernel%{_alt_kernel}-video-nvidia\
228%depmod %{_kernel_ver}\
229%{nil}
230
231%define build_kernel_pkg()\
e4947020 232cd kernel\
e4947020 233%{__make} SYSSRC=%{_kernelsrcdir} clean\
ef40d8b8 234%{__make} SYSSRC=%{_kernelsrcdir} IGNORE_CC_MISMATCH=1 NV_VERBOSE=1 CC=%{__cc} module\
e4947020 235cd ..\
10e941a4 236%install_kernel_modules -D installed -m kernel/nvidia,kernel/nvidia-drm,kernel/nvidia-modeset -d misc\
cad4d6b5 237%install_kernel_modules -D installed -m kernel/nvidia-uvm -d misc\
e4947020
JR
238%{nil}
239
db599715 240%ifarch %{x8664}
fb27eb94 241%{?with_kernel:%{expand:%create_kernel_packages}}
d626b139 242%endif
28142503 243
28142503
PS
244%prep
245cd %{_builddir}
7f0cefc2 246rm -rf NVIDIA-Linux-x86_64-%{version}
28142503 247/bin/sh %{SOURCE0} --extract-only
7f0cefc2 248%setup -qDT -n NVIDIA-Linux-x86_64-%{version}
bcf69910 249%patch0 -p1
8481604b 250echo 'EXTRA_CFLAGS += -Wno-pointer-arith -Wno-sign-compare -Wno-unused' >> kernel/Makefile.kbuild
28142503
PS
251
252%build
d626b139 253%ifarch %{x8664}
fb27eb94 254%{?with_kernel:%{expand:%build_kernel_packages}}
d626b139 255%endif
28142503
PS
256
257%install
258rm -rf $RPM_BUILD_ROOT
1820d34b
ER
259
260%if %{with userspace}
cd436d42 261install -d $RPM_BUILD_ROOT%{_libdir}/{nvidia,xorg/modules/{drivers,extensions/nvidia}} \
117b7720 262 $RPM_BUILD_ROOT{%{_libdir}/vdpau,%{_bindir},%{_mandir}/man1} \
054fcee3 263 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},/etc/X11/xinit/xinitrc.d} \
6c7b79fe 264 $RPM_BUILD_ROOT%{_sysconfdir}/{OpenCL/vendors,ld.so.conf.d,X11/xorg.conf.d} \
96251f94 265 $RPM_BUILD_ROOT%{_datadir}/{glvnd/egl_vendor.d,nvidia,vulkan/icd.d}
28142503 266
d626b139 267%ifarch %{x8664}
5da85237
ER
268%if %{with settings}
269install -p nvidia-settings $RPM_BUILD_ROOT%{_bindir}
270cp -p nvidia-settings.1* $RPM_BUILD_ROOT%{_mandir}/man1
f3bf0f30
ER
271cp -p nvidia-settings.desktop $RPM_BUILD_ROOT%{_desktopdir}
272cp -p nvidia-settings.png $RPM_BUILD_ROOT%{_pixmapsdir}
f3b8319b 273install -p %{SOURCE2} $RPM_BUILD_ROOT/etc/X11/xinit/xinitrc.d/nvidia-settings.sh
5da85237
ER
274%endif
275
276install -p nvidia-{smi,xconfig,bug-report.sh} $RPM_BUILD_ROOT%{_bindir}
df1704ce
KK
277install -p nvidia-cuda-mps-{control,server} $RPM_BUILD_ROOT%{_bindir}
278cp -p nvidia-{smi,xconfig,cuda-mps-control}.1* $RPM_BUILD_ROOT%{_mandir}/man1
f3bf0f30 279install -p nvidia.icd $RPM_BUILD_ROOT%{_sysconfdir}/OpenCL/vendors
eb6ba6c9 280
cd436d42
JR
281install %{SOURCE4} $RPM_BUILD_ROOT/etc/X11/xorg.conf.d
282install %{SOURCE5} $RPM_BUILD_ROOT/etc/X11/xorg.conf.d
283sed -i -e 's|@@LIBDIR@@|%{_libdir}|g' $RPM_BUILD_ROOT/etc/X11/xorg.conf.d/10-nvidia-modules.conf
c6948e82 284install -p nvidia-drm-outputclass.conf $RPM_BUILD_ROOT/etc/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf
da05371c 285
28bd8abb
JP
286install -p nvidia-application-profiles-%{version}-key-documentation $RPM_BUILD_ROOT%{_datadir}/nvidia
287install -p nvidia-application-profiles-%{version}-rc $RPM_BUILD_ROOT%{_datadir}/nvidia
d626b139
JR
288%endif
289
290%ifarch %{ix86}
291%define srcdir 32
292%else
293%define srcdir .
294%endif
28bd8abb 295
eb6ba6c9 296for f in \
75de51d2 297%if %{without system_libglvnd}
d626b139
JR
298 %{srcdir}/libGL.so.1.7.0 \
299 %{srcdir}/libGLX.so.0 \
300 %{srcdir}/libOpenGL.so.0 \
301 %{srcdir}/libGLdispatch.so.0 \
302 %{srcdir}/libGLESv1_CM.so.1.2.0 \
303 %{srcdir}/libGLESv2.so.2.1.0 \
304 %{srcdir}/libEGL.so.1.1.0 \
305%endif
306 %{srcdir}/libGLX_nvidia.so.%{version} \
307 %{srcdir}/libEGL_nvidia.so.%{version} \
308 %{srcdir}/libGLESv1_CM_nvidia.so.%{version} \
309 %{srcdir}/libGLESv2_nvidia.so.%{version} \
310%ifarch %{x8664}
0bbb9c86 311 %{srcdir}/libnvidia-egl-wayland.so.1.1.5 \
d626b139 312 %{srcdir}/libnvidia-eglcore.so.%{version} \
d626b139
JR
313%endif
314 %{srcdir}/libcuda.so.%{version} \
315 %{srcdir}/libnvcuvid.so.%{version} \
316%ifarch %{x8664}
0f1616f9 317 %{srcdir}/libnvidia-cbl.so.%{version} \
d626b139 318 %{srcdir}/libnvidia-cfg.so.%{version} \
594c0c86 319 %{srcdir}/libnvidia-ngx.so.%{version} \
0f1616f9
JP
320 %{srcdir}/libnvidia-rtcore.so.%{version} \
321 %{srcdir}/libnvoptix.so.%{version} \
d626b139 322%endif
594c0c86 323 %{srcdir}/libnvidia-allocator.so.%{version} \
d626b139
JR
324 %{srcdir}/libnvidia-compiler.so.%{version} \
325 %{srcdir}/libnvidia-encode.so.%{version} \
d626b139
JR
326 %{srcdir}/libnvidia-fbc.so.%{version} \
327 %{srcdir}/libnvidia-glcore.so.%{version} \
328 %{srcdir}/libnvidia-glsi.so.%{version} \
329 %{srcdir}/libnvidia-glvkspirv.so.%{version} \
330 %{srcdir}/libnvidia-ifr.so.%{version} \
331 %{srcdir}/libnvidia-ml.so.%{version} \
332 %{srcdir}/libnvidia-opencl.so.%{version} \
594c0c86 333 %{srcdir}/libnvidia-opticalflow.so.%{version} \
d626b139 334 %{srcdir}/libnvidia-ptxjitcompiler.so.%{version} \
f1773542 335 %{srcdir}/libnvidia-tls.so.%{version} \
eb6ba6c9 336; do
cd436d42 337 install -p $f $RPM_BUILD_ROOT%{_libdir}/nvidia
ffec07c8 338done
76db0ca8 339
672bc855 340install -p %{srcdir}/libvdpau_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/vdpau
eb6ba6c9 341
d626b139 342%ifarch %{x8664}
117b7720
JP
343install -p libglxserver_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/xorg/modules/extensions/nvidia
344ln -s libglxserver_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/xorg/modules/extensions/nvidia/libglxserver_nvidia.so
7400930f
ER
345install -p nvidia_drv.so $RPM_BUILD_ROOT%{_libdir}/xorg/modules/drivers/nvidia_drv.so.%{version}
346ln -s nvidia_drv.so.%{version} $RPM_BUILD_ROOT%{_libdir}/xorg/modules/drivers/nvidia_drv.so
d626b139 347%endif
cd436d42
JR
348
349/sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}/nvidia
350/sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}/xorg/modules/extensions/nvidia
28142503 351
76db0ca8 352ln -sf libvdpau_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/vdpau/libvdpau_nvidia.so.1
28142503 353
d626b139 354%ifarch %{x8664}
a116bc07
JR
355echo %{_libdir}/nvidia >$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia64.conf
356echo %{_libdir}/vdpau >>$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia64.conf
d626b139
JR
357%else
358echo %{_libdir}/nvidia >$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia.conf
359echo %{_libdir}/vdpau >>$RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/nvidia.conf
360%endif
ffec07c8
JR
361
362# OpenGL ABI for Linux compatibility
75de51d2 363%if %{without system_libglvnd}
94175128 364ln -sf libGL.so.1.7.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGL.so.1
75de51d2
JP
365ln -sf libGL.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGL.so
366ln -sf libGLX.so.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLX.so
367ln -sf libOpenGL.so.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libOpenGL.so
94175128 368ln -sf libGLESv1_CM.so.1.2.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv1_CM.so.1
75de51d2 369ln -sf libGLESv1_CM.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv1_CM.so
94175128 370ln -sf libGLESv2.so.2.1.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv2.so.2
75de51d2 371ln -sf libGLESv2.so.2 $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv2.so
94175128 372ln -sf libEGL.so.1.1.0 $RPM_BUILD_ROOT%{_libdir}/nvidia/libEGL.so.1
c2ff5cb2 373ln -sf libEGL.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libEGL.so
75de51d2 374%endif
538b2e0c 375ln -sf libGLX_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLX_nvidia.so.0
10e941a4 376ln -sf libGLX_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLX_indirect.so.0
538b2e0c
JP
377ln -sf libEGL_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libEGL_nvidia.so.0
378ln -sf libGLESv1_CM_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv1_CM_nvidia.so.1
379ln -sf libGLESv2_nvidia.so.%{version} $RPM_BUILD_ROOT%{_libdir}/nvidia/libGLESv2_nvidia.so.2
3427c6f3 380
d626b139 381%ifarch %{x8664}
3427c6f3 382install -p 10_nvidia.json $RPM_BUILD_ROOT%{_datadir}/glvnd/egl_vendor.d
d626b139 383%endif
cd436d42
JR
384ln -sf libcuda.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libcuda.so
385ln -sf libnvcuvid.so.1 $RPM_BUILD_ROOT%{_libdir}/nvidia/libnvcuvid.so
6c7b79fe 386
d626b139 387%ifarch %{x8664}
1f3a72f3 388install -p nvidia_icd.json $RPM_BUILD_ROOT%{_datadir}/vulkan/icd.d
ffec07c8 389%endif
d626b139 390%endif
28142503 391
d626b139 392%ifarch %{x8664}
1fdf7dcc 393%if %{with kernel}
e4947020
JR
394install -d $RPM_BUILD_ROOT
395cp -a installed/* $RPM_BUILD_ROOT
1fdf7dcc 396%endif
d626b139 397%endif
28142503 398
236b5374 399install -d $RPM_BUILD_ROOT%{_pkgconfigdir}
02b832fe
ER
400sed -e '
401 s|@@prefix@@|%{_prefix}|g;
402 s|@@libdir@@|%{_libdir}|g;
02b832fe 403 s|@@version@@|%{version}|g' < %{SOURCE3} \
236b5374 404 > $RPM_BUILD_ROOT%{_pkgconfigdir}/gl.pc
405
28142503
PS
406%clean
407rm -rf $RPM_BUILD_ROOT
408
a641155e 409%post
2b14e59b
ER
410cat << 'EOF'
411NOTE: You must also install kernel module for this driver to work
5ff69e47 412 kernel%{_alt_kernel}-video-nvidia-%{version}
2b14e59b 413
25b520ff 414EOF
f3b8319b 415
5ff69e47 416%post libs -p /sbin/ldconfig
cd436d42 417%postun libs -p /sbin/ldconfig
25b520ff 418
1820d34b 419%if %{with userspace}
d626b139 420%ifarch %{x8664}
28142503
PS
421%files
422%defattr(644,root,root,755)
8481604b 423%doc LICENSE NVIDIA_Changelog README.txt
007619d4 424%dir %{_libdir}/xorg/modules/extensions/nvidia
117b7720
JP
425%attr(755,root,root) %{_libdir}/xorg/modules/extensions/nvidia/libglxserver_nvidia.so.*
426%attr(755,root,root) %{_libdir}/xorg/modules/extensions/nvidia/libglxserver_nvidia.so
7400930f 427%attr(755,root,root) %{_libdir}/xorg/modules/drivers/nvidia_drv.so.*
cd436d42 428%attr(755,root,root) %{_libdir}/xorg/modules/drivers/nvidia_drv.so
65e71729 429%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/X11/xorg.conf.d/10-nvidia.conf
cd436d42 430%{_sysconfdir}/X11/xorg.conf.d/10-nvidia-modules.conf
c6948e82 431%{_sysconfdir}/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf
28bd8abb
JP
432%dir %{_datadir}/nvidia
433%{_datadir}/nvidia/nvidia-application-profiles-%{version}-key-documentation
434%{_datadir}/nvidia/nvidia-application-profiles-%{version}-rc
d626b139 435%endif
17fdb673
JR
436
437%files libs
f3b8319b 438%defattr(644,root,root,755)
d626b139 439%ifarch %{x8664}
f3bf0f30
ER
440%dir %{_sysconfdir}/OpenCL
441%dir %{_sysconfdir}/OpenCL/vendors
442%{_sysconfdir}/OpenCL/vendors/nvidia.icd
6d0509d9 443%endif
a116bc07 444%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ld.so.conf.d/nvidia*.conf
ffec07c8 445%dir %{_libdir}/nvidia
75de51d2 446%if %{without system_libglvnd}
94175128 447%attr(755,root,root) %{_libdir}/nvidia/libGL.so.1.7.0
75de51d2 448%attr(755,root,root) %ghost %{_libdir}/nvidia/libGL.so.1
b55b4acb 449%attr(755,root,root) %{_libdir}/nvidia/libGL.so
75de51d2
JP
450%attr(755,root,root) %{_libdir}/nvidia/libGLX.so.0
451%attr(755,root,root) %{_libdir}/nvidia/libOpenGL.so.0
452%attr(755,root,root) %{_libdir}/nvidia/libGLdispatch.so.0
94175128
JP
453%attr(755,root,root) %{_libdir}/nvidia/libGLESv1_CM.so.1.2.0
454%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv1_CM.so.1
455%attr(755,root,root) %{_libdir}/nvidia/libGLESv2.so.2.1.0
456%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv2.so.2
457%attr(755,root,root) %{_libdir}/nvidia/libEGL.so.1.1.0
458%attr(755,root,root) %ghost %{_libdir}/nvidia/libEGL.so.1
c2ff5cb2 459%endif
10e941a4
JP
460%attr(755,root,root) %ghost %{_libdir}/nvidia/libEGL_nvidia.so.0
461%attr(755,root,root) %{_libdir}/nvidia/libEGL_nvidia.so.*.*
10e941a4
JP
462%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv1_CM_nvidia.so.1
463%attr(755,root,root) %{_libdir}/nvidia/libGLESv1_CM_nvidia.so.*.*
10e941a4
JP
464%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLESv2_nvidia.so.2
465%attr(755,root,root) %{_libdir}/nvidia/libGLESv2_nvidia.so.*.*
10e941a4
JP
466%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLX_indirect.so.0
467%attr(755,root,root) %ghost %{_libdir}/nvidia/libGLX_nvidia.so.0
468%attr(755,root,root) %{_libdir}/nvidia/libGLX_nvidia.so.*.*
d626b139 469%ifarch %{x8664}
538b2e0c 470%attr(755,root,root) %{_libdir}/nvidia/libnvidia-egl-wayland.so.*.*.*
b440dd78 471%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-egl-wayland.so.1
538b2e0c 472%attr(755,root,root) %{_libdir}/nvidia/libnvidia-eglcore.so.*.*
d626b139 473%endif
cd436d42
JR
474%attr(755,root,root) %{_libdir}/nvidia/libcuda.so.*.*
475%attr(755,root,root) %ghost %{_libdir}/nvidia/libcuda.so.1
476%attr(755,root,root) %{_libdir}/nvidia/libcuda.so
477%attr(755,root,root) %{_libdir}/nvidia/libnvcuvid.so.*.*
478%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvcuvid.so.1
479%attr(755,root,root) %{_libdir}/nvidia/libnvcuvid.so
d626b139 480%ifarch %{x8664}
0f1616f9 481%attr(755,root,root) %{_libdir}/nvidia/libnvidia-cbl.so.*.*
cd436d42
JR
482%attr(755,root,root) %{_libdir}/nvidia/libnvidia-cfg.so.*.*
483%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-cfg.so.1
594c0c86
JP
484%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ngx.so.*.*
485%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ngx.so.1
0f1616f9
JP
486%attr(755,root,root) %{_libdir}/nvidia/libnvidia-rtcore.so.*.*
487%attr(755,root,root) %{_libdir}/nvidia/libnvoptix.so.*.*
488%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvoptix.so.1
d626b139 489%endif
594c0c86
JP
490%attr(755,root,root) %{_libdir}/nvidia/libnvidia-allocator.so.*.*
491%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-allocator.so.1
cd436d42 492%attr(755,root,root) %{_libdir}/nvidia/libnvidia-compiler.so.*.*
5ee8f0c8
JR
493%attr(755,root,root) %{_libdir}/nvidia/libnvidia-encode.so.*.*
494%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-encode.so.1
10e941a4
JP
495%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-fbc.so.1
496%attr(755,root,root) %{_libdir}/nvidia/libnvidia-fbc.so.*.*
cd436d42 497%attr(755,root,root) %{_libdir}/nvidia/libnvidia-glcore.so.*.*
10e941a4 498%attr(755,root,root) %{_libdir}/nvidia/libnvidia-glsi.so.*.*
7f0cefc2 499%attr(755,root,root) %{_libdir}/nvidia/libnvidia-glvkspirv.so.*.*
10e941a4
JP
500%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ifr.so.1
501%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ifr.so.*.*
cd436d42
JR
502%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ml.so.*.*
503%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ml.so.1
5ee8f0c8
JR
504%attr(755,root,root) %{_libdir}/nvidia/libnvidia-opencl.so.*.*
505%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-opencl.so.1
594c0c86
JP
506%attr(755,root,root) %{_libdir}/nvidia/libnvidia-opticalflow.so.*.*
507%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-opticalflow.so.1
10e941a4 508%attr(755,root,root) %{_libdir}/nvidia/libnvidia-ptxjitcompiler.so.*.*
594c0c86 509%attr(755,root,root) %ghost %{_libdir}/nvidia/libnvidia-ptxjitcompiler.so.1
cd436d42 510%attr(755,root,root) %{_libdir}/nvidia/libnvidia-tls.so.*.*
76db0ca8 511%attr(755,root,root) %{_libdir}/vdpau/libvdpau_nvidia.so.*.*
f3b8319b 512%attr(755,root,root) %ghost %{_libdir}/vdpau/libvdpau_nvidia.so.1
d626b139 513%ifarch %{x8664}
96251f94 514%{_datadir}/glvnd/egl_vendor.d/10_nvidia.json
7c831f98 515%{_datadir}/vulkan/icd.d/nvidia_icd.json
d626b139 516%endif
28142503 517
b55b4acb 518%if %{without system_libglvnd}
28142503
PS
519%files devel
520%defattr(644,root,root,755)
75de51d2
JP
521%attr(755,root,root) %{_libdir}/nvidia/libGLX.so
522%attr(755,root,root) %{_libdir}/nvidia/libOpenGL.so
523%attr(755,root,root) %{_libdir}/nvidia/libGLESv1_CM.so
524%attr(755,root,root) %{_libdir}/nvidia/libGLESv2.so
10e941a4 525%attr(755,root,root) %{_libdir}/nvidia/libEGL.so
236b5374 526%{_pkgconfigdir}/gl.pc
b55b4acb 527%endif
63c6d4b1 528
a9160796
ER
529%files doc
530%defattr(644,root,root,755)
8481604b 531%doc html/*
a9160796 532
d626b139 533%ifarch %{x8664}
d4a34ce2 534%files progs
01766b04 535%defattr(644,root,root,755)
8481604b 536%attr(755,root,root) %{_bindir}/nvidia-bug-report.sh
df1704ce
KK
537%attr(755,root,root) %{_bindir}/nvidia-cuda-mps-control
538%attr(755,root,root) %{_bindir}/nvidia-cuda-mps-server
8481604b 539%attr(755,root,root) %{_bindir}/nvidia-smi
225cc701 540%attr(755,root,root) %{_bindir}/nvidia-xconfig
df1704ce 541%{_mandir}/man1/nvidia-cuda-mps-control.1*
5da85237
ER
542%{_mandir}/man1/nvidia-smi.1*
543%{_mandir}/man1/nvidia-xconfig.1*
544%if %{with settings}
b55b4acb 545%attr(755,root,root) /etc/X11/xinit/xinitrc.d/nvidia-settings.sh
5da85237
ER
546%attr(755,root,root) %{_bindir}/nvidia-settings
547%{_mandir}/man1/nvidia-settings.1*
225cc701 548%{_desktopdir}/nvidia-settings.desktop
225cc701 549%{_pixmapsdir}/nvidia-settings.png
1820d34b 550%endif
d626b139
JR
551%endif
552%endif
This page took 0.441179 seconds and 4 git commands to generate.