diff --git a/nvidia-drm-outputclass.conf b/nvidia-drm-outputclass.conf new file mode 100644 index 0000000..a94d18c --- /dev/null +++ b/nvidia-drm-outputclass.conf @@ -0,0 +1,8 @@ +Section "OutputClass" + Identifier "nvidia" + MatchDriver "nvidia-drm" + Driver "nvidia" + Option "AllowEmptyInitialConfiguration" + ModulePath "/usr/lib64/nvidia/xorg" + ModulePath "/usr/lib64/xorg/modules" +EndSection diff --git a/nvidia.spec b/nvidia.spec index f78bdc5..d738057 100644 --- a/nvidia.spec +++ b/nvidia.spec @@ -1,7 +1,7 @@ %define nvidia_current_ver %version %define nvidia_current_libver %version Name: nvidia -Version: 390.138 +Version: 465.24.02 Epoch: 1 Release: 2mamba Summary: NVIDIA proprietary accelerated drivers for the Linux Kernel @@ -9,114 +9,91 @@ Group: System/Kernel and Hardware Vendor: openmamba Distribution: openmamba Packager: Silvan Calarco -URL: http://www.nvidia.com/object/unix.html -Source0: http://us.download.nvidia.com/XFree86/Linux-x86/%{nvidia_current_ver}/NVIDIA-Linux-x86-%{nvidia_current_ver}.run -Source1: http://us.download.nvidia.com/XFree86/Linux-x86_64/%{nvidia_current_ver}/NVIDIA-Linux-x86_64-%{nvidia_current_ver}.run +URL: https://www.nvidia.com/object/unix.html +Source0: http://us.download.nvidia.com/XFree86/Linux-x86_64/%{nvidia_current_ver}/NVIDIA-Linux-x86_64-%{nvidia_current_ver}.run +Source1: nvidia.sysusers +Source2: nvidia-drm-outputclass.conf Patch0: nvidia-331.20-x86-conftest.patch Patch1: nvidia-367.35-kernel-4.6.patch License: no OSI Approved ## AUTOBUILDREQ-BEGIN +BuildRequires: glibc-devel +BuildRequires: libX11-devel +BuildRequires: libXext-devel +BuildRequires: libgcc +BuildRequires: libglvnd-devel ## AUTOBUILDREQ-END -ExclusiveArch: i586 x86_64 -BuildRoot: %{_tmppath}/%{name}-%{version}-root +ExclusiveArch: x86_64 %description nvidia proprietary accelerated drivers for the Linux Kernel. These packages contains parts that are not (fully) released under GPL license. These modules are packaged apart from the main kernel modules because they are not fully released as GPL. This means that some modules might have been built from binary objects distributed by the hardware manufacturer. By loading this modules you will "taint" the kernel, which means that your running system won't be 100% GPL. -%package -n xorg-drv-video-nvidia +%package -n xorg-drv-video-%{name} Group: System/Kernel and Hardware Summary: NVIDIA Accelerated Libraries for Xorg Requires: xorg-server >= 1.1.0 Requires(post):kernelheaders Requires(post):dkms -Requires(pre): xorg-ext-libglx-nvidia == %{epoch}:%{version}-%{release} -Requires(pre): libGL-nvidia-X11 == %{epoch}:%{version}-%{release} Provides: Xorg-nvidia Provides: xorgdrvvideo Provides: kernelnvidia Conflicts: xorg-drv-video-nvidia_304 -AutoReq: no +Conflicts: xorg-drv-video-nvidia_340 +Conflicts: xorg-drv-video-nvidia_390 +Conflicts: libGL-nvidia_304-X11 +Conflicts: libGL-nvidia_340-X11 +Conflicts: libGL-nvidia_390-X11 +Obsoletes: libGL-nvidia_450-X11 <= 1:460.39 +Obsoletes: xorg-drv-video-nvidia_450 <= 1:460.39 +Provides: libGL-%{name}-X11 +Obsoletes: libGL-%{name}-X11 < 1:465.24.02-2mamba +Provides: xorg-ext-libglx-%{name} +Obsoletes: xorg-ext-libglx-%{name} < 1:465.24.02-2mamba +Provides: xorg-apps-%{name} +Obsoletes: xorg-apps-%{name} < 1:465.24.02-2mamba +Obsoletes: libglx-nvidia < 1:460.39 +Conflicts: xorg-ext-libglx-nvidia_304 +Conflicts: xorg-ext-libglx-nvidia_340 +Conflicts: xorg-ext-libglx-nvidia_390 +Obsoletes: xorg-ext-libglx-nvidia_450 <= 1:460.39 +Conflicts: xorg-apps-nvidia_304 +Conflicts: xorg-apps-nvidia_340 +Conflicts: xorg-apps-nvidia_390 +Obsoletes: xorg-apps-nvidia_450 <= 1:460.39 -%description -n xorg-drv-video-nvidia +%description -n xorg-drv-video-%{name} The NVIDIA Accelerated Linux Driver Set brings both accelerated 2D functionality and high performance OpenGL support to Linux x86 with theuse of NVIDIA graphics processing units (GPUs). - These drivers provide optimized hardware acceleration of OpenGL applications via a direct-rendering X Server and support nearly all NVIDIA graphics chips. TwinView, TV-Out and flat panel displays are also supported. +This package contains the Xorg libraries, DKMS kernel driver and all the NVIDIA libraries. -This package contains the Xorg libraries. - -%package -n libGL-nvidia-X11 -Group: System/Libraries -Summary: NVIDIA proprietary OpenGL library implementation -Requires: xorg-ext-libglx-nvidia == %{epoch}:%{version}-%{release} -Provides: xorglibGL -Provides: libGL.so.1 -Conflicts: libGL-nvidia_304-X11 - -%description -n libGL-nvidia-X11 -The NVIDIA Accelerated Linux Driver Set brings both accelerated 2D functionality and high performance OpenGL support to Linux x86 with theuse of NVIDIA graphics processing units (GPUs). - -These drivers provide optimized hardware acceleration of OpenGL applications via a direct-rendering X Server and support nearly all NVIDIA graphics chips. -TwinView, TV-Out and flat panel displays are also supported. - -This package contains the NVIDIA proprietary OpenGL library implementation for Xorg. - -%package -n xorg-ext-libglx-nvidia -Group: System/Libraries -Summary: NVIDIA proprietary glx library implementation -Provides: xorglibglx -Obsoletes: libglx-nvidia -Conflicts: xorg-ext-libglx-nvidia_304 - -%description -n xorg-ext-libglx-nvidia -The NVIDIA Accelerated Linux Driver Set brings both accelerated 2D functionality and high performance OpenGL support to Linux x86 with theuse of NVIDIA graphics processing units (GPUs). - -These drivers provide optimized hardware acceleration of OpenGL applications via a direct-rendering X Server and support nearly all NVIDIA graphics chips. -TwinView, TV-Out and flat panel displays are also supported. - -This package contains the NVIDIA proprietary glx library implementation for Xorg. - -%package -n xorg-apps-nvidia -Group: System/Tools -Summary: NVIDIA configuration tools -Conflicts: xorg-apps-nvidia_304 - -%description -n xorg-apps-nvidia -The NVIDIA Accelerated Linux Driver Set brings both accelerated 2D functionality and high performance OpenGL support to Linux x86 with theuse of NVIDIA graphics processing units (GPUs). - -These drivers provide optimized hardware acceleration of OpenGL applications via a direct-rendering X Server and support nearly all NVIDIA graphics chips. -TwinView, TV-Out and flat panel displays are also supported. - -This package contains the NVIDIA tools nvidia-settings, nvidia-xconfig, and nvidia-smi. - -%package -n xorg-drv-video-nvidia-doc +%package -n xorg-drv-video-%{name}-doc Group: Documentation Summary: HTML documentation for NVIDIA Accelerated Libraries for Xorg Conflicts: xorg-drv-video-nvidia_304-doc -AutoReq: no +Conflicts: xorg-drv-video-nvidia_340-doc +Conflicts: xorg-drv-video-nvidia_390-doc +Obsoletes: xorg-drv-video-nvidia_450-doc <= 1:460.39 -%description -n xorg-drv-video-nvidia-doc +%description -n xorg-drv-video-%{name}-doc The NVIDIA Accelerated Linux Driver Set brings both accelerated 2D functionality and high performance OpenGL support to Linux x86 with theuse of NVIDIA graphics processing units (GPUs). - These drivers provide optimized hardware acceleration of OpenGL applications via a direct-rendering X Server and support nearly all NVIDIA graphics chips. TwinView, TV-Out and flat panel displays are also supported. - This package contains the HTML documentation. %prep %setup -q -c -n %{name}-%{version} -T + +%global __provides_exclude ^(libGL\\.so.*|libEGL\\.so.*|libGLESv1_CM\\.so.*|libGLESv2\\.so.*|libOpenCL\\.so.*)$ +#% global __requires_exclude ^(libGLX.so.0.*|libGLdispatch.)$ + # # unpack NVIDIA files # -%if "%{_target_cpu}" == "x86_64" - sh %{SOURCE1} --extract-only - ln -sf NVIDIA-Linux-x86_64-%{nvidia_current_ver} current -%else - sh %{SOURCE0} --extract-only - ln -sf NVIDIA-Linux-x86-%{nvidia_current_ver} current -%endif +sh %{SOURCE0} --extract-only +ln -sf NVIDIA-Linux-x86_64-%{nvidia_current_ver} current sed -i "s|__UTILS_PATH__|%{_bindir}|;s|__PIXMAP_PATH__|%{_datadir}/pixmaps|" \ current/nvidia-settings.desktop @@ -124,6 +101,7 @@ sed -i "s|__UTILS_PATH__|%{_bindir}|;s|__PIXMAP_PATH__|%{_datadir}/pixmaps|" \ cd current #%patch0 -p1 #%patch1 -p1 +tar xf nvidia-persistenced-init.tar.bz2 cd .. %build @@ -132,96 +110,136 @@ cd .. [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" pushd current -install -D -m 0755 libnvidia-wfb.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/xorg/modules/libnvidia-wfb.so.%{nvidia_current_libver} +# From Arch Linux +# X driver +install -D -m755 nvidia_drv.so %{buildroot}%{_libdir}/xorg/modules/drivers/nvidia_drv.so -install -D -m 0755 libcuda.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libcuda.so.%{nvidia_current_libver} +# firmware +install -D -m644 firmware/gsp.bin %{buildroot}/lib/firmware/nvidia/%{version}/gsp.bin -install -D -m 0755 libGL.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libGL_so.%{nvidia_current_libver} -ln -s libGL_so.%{nvidia_current_libver} %{buildroot}%{_libdir}/libGL_current_so.1 +# GLX extension module for X +install -D -m755 libglxserver_nvidia.so.%{version} %{buildroot}%{_libdir}/nvidia/xorg/libglxserver_nvidia.so.%{version} -install -D -m 0755 libglx.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/xorg/modules/extensions/libglx_so.%{nvidia_current_libver} -ln -s libglx_so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/xorg/modules/extensions/libglx_current_so +# Ensure that X finds glx +ln -s libglxserver_nvidia.so.%{version} %{buildroot}%{_libdir}/nvidia/xorg/libglxserver_nvidia.so.1 +ln -s libglxserver_nvidia.so.%{version} %{buildroot}%{_libdir}/nvidia/xorg/libglxserver_nvidia.so -install -D -m 0755 libnvcuvid.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvcuvid.%{nvidia_current_libver} +install -D -m755 libGLX_nvidia.so.%{version} %{buildroot}%{_libdir}/libGLX_nvidia.so.%{version} -install -D -m 0755 libnvidia-cfg.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-cfg_so.%{nvidia_current_libver} -ln -s libnvidia-cfg_so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-cfg_current_so +# OpenGL libraries +install -D -m755 libEGL_nvidia.so.%{version} %{buildroot}%{_libdir}/libEGL_nvidia.so.%{version} +install -D -m755 libGLESv1_CM_nvidia.so.%{version} %{buildroot}%{_libdir}/libGLESv1_CM_nvidia.so.%{version} +install -D -m755 libGLESv2_nvidia.so.%{version} %{buildroot}%{_libdir}/libGLESv2_nvidia.so.%{version} +install -D -m644 10_nvidia.json %{buildroot}%{_datadir}/glvnd/egl_vendor.d/10_nvidia.json -install -D -m 0755 libnvidia-compiler.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-compiler.%{nvidia_current_libver} +# OpenGL core library +install -D -m755 libnvidia-glcore.so.%{version} %{buildroot}%{_libdir}/libnvidia-glcore.so.%{version} +install -D -m755 libnvidia-eglcore.so.%{version} %{buildroot}%{_libdir}/libnvidia-eglcore.so.%{version} +install -D -m755 libnvidia-glsi.so.%{version} %{buildroot}%{_libdir}/libnvidia-glsi.so.%{version} -install -D -m 0755 libnvidia-encode.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-encode.%{nvidia_current_libver} +# OpenCL +install -D -m644 nvidia.icd %{buildroot}%{_sysconfdir}/OpenCL/vendors/nvidia.icd +install -D -m755 libnvidia-compiler.so.%{version} %{buildroot}%{_libdir}/libnvidia-compiler.so.%{version} +install -D -m755 libnvidia-opencl.so.%{version} %{buildroot}%{_libdir}/libnvidia-opencl.so.%{version} -install -D -m 0755 libnvidia-glcore.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-glcore.so.%{nvidia_current_libver} +# misc +install -D -m755 libnvidia-ifr.so.%{version} %{buildroot}%{_libdir}/libnvidia-ifr.so.%{version} +install -D -m755 libnvidia-fbc.so.%{version} %{buildroot}%{_libdir}/libnvidia-fbc.so.%{version} +install -D -m755 libnvidia-encode.so.%{version} %{buildroot}%{_libdir}/libnvidia-encode.so.%{version} +install -D -m755 libnvidia-cfg.so.%{version} %{buildroot}%{_libdir}/libnvidia-cfg.so.%{version} +install -D -m755 libnvidia-ml.so.%{version} %{buildroot}%{_libdir}/libnvidia-ml.so.%{version} +install -D -m755 libnvidia-ngx.so.%{version} %{buildroot}%{_libdir}/libnvidia-ngx.so.%{version} +install -D -m755 libnvidia-glvkspirv.so.%{version} %{buildroot}%{_libdir}/libnvidia-glvkspirv.so.%{version} -install -D -m 0755 libnvidia-ml.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-ml.so.%{nvidia_current_libver} -ln -s libnvidia-ml.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-ml.so.1 +# Vulkan ICD +install -D -m644 nvidia_icd.json %{buildroot}%{_datadir}/vulkan/icd.d/nvidia_icd.json +install -D -m644 nvidia_layers.json %{buildroot}%{_datadir}/vulkan/implicit_layer.d/nvidia_layers.json -install -D -m 0755 libnvidia-opencl.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-opencl.so.%{nvidia_current_libver} +# VDPAU +install -D -m755 libvdpau_nvidia.so.%{version} %{buildroot}%{_libdir}/vdpau/libvdpau_nvidia.so.%{version} -install -D -m 0755 tls/libnvidia-tls.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/tls/libnvidia-tls.so.%{nvidia_current_libver} +# nvidia-tls library +install -D -m755 libnvidia-tls.so.%{version} %{buildroot}%{_libdir}/libnvidia-tls.so.%{version} -install -D -m 0755 libnvidia-tls.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-tls.so.%{nvidia_current_libver} +# CUDA +install -D -m755 libcuda.so.%{version} %{buildroot}%{_libdir}/libcuda.so.%{version} +install -D -m755 libnvcuvid.so.%{version} %{buildroot}%{_libdir}/libnvcuvid.so.%{version} -install -D -m 0755 libnvidia-wfb.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/libnvidia-wfb.so.%{nvidia_current_libver} +# PTX JIT Compiler (Parallel Thread Execution (PTX) is a pseudo-assembly language for CUDA) +install -D -m755 libnvidia-ptxjitcompiler.so.%{version} %{buildroot}%{_libdir}/libnvidia-ptxjitcompiler.so.%{version} -install -D -m755 libOpenCL.so.1.0.0 \ - %{buildroot}%{_libdir}/libOpenCL_nvidia_so.1.0.0 +# raytracing +install -D -m755 libnvoptix.so.%{version} %{buildroot}%{_libdir}/libnvoptix.so.%{version} +install -D -m755 libnvidia-rtcore.so.%{version} %{buildroot}%{_libdir}/libnvidia-rtcore.so.%{version} +install -D -m755 libnvidia-cbl.so.%{version} %{buildroot}%{_libdir}/libnvidia-cbl.so.%{version} -install -D -m755 libvdpau_nvidia.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/vdpau/libvdpau_nvidia.so.%{nvidia_current_libver} -ln -s libvdpau_nvidia.so.%{nvidia_current_libver} \ - %{buildroot}%{_libdir}/vdpau/libvdpau_nvidia.so +# Optical flow +install -D -m755 libnvidia-opticalflow.so.%{version} %{buildroot}%{_libdir}/libnvidia-opticalflow.so.%{version} -install -D -m 0755 nvidia_drv.so \ - %{buildroot}%{_libdir}/xorg/modules/drivers/nvidia_current_drv_so +# DEBUG +install -D -m755 nvidia-debugdump %{buildroot}%{_bindir}/nvidia-debugdump -install -d %{buildroot}%{_sbindir} -cat > %{buildroot}%{_sbindir}/update-alternatives-set-nvidia << _EOF -#!/bin/sh -#update-alternatives --set nvidia_\$(uname -r)_%{kernel_ver_u}.ko \ -#/lib/modules/\$(uname -r)/kernel/drivers/video/nvidia_current_ko -update-alternatives --set libglx.so %{_libdir}/xorg/modules/extensions/libglx_current_so -update-alternatives --set nvidia_drv.so %{_libdir}/xorg/modules/drivers/nvidia_current_drv_so -update-alternatives --set libGL.so.1 %{_libdir}/libGL_current_so.1 -update-alternatives --set libXvMCNVIDIA_dynamic.so %{_libdir}/libXvMCNVIDIA_current_so -update-alternatives --set libnvidia-cfg.so %{_libdir}/libnvidia-cfg_current_so -update-alternatives --set libOpenCL.so.1 %{_libdir}/libOpenCL_nvidia_so.1.0.0 -#update-alternatives --set libnvidia-tls.so.1.lib %{_libdir}/libnvidia-tls_current_so.1 -#update-alternatives --set libnvidia-tls.so.1 %{_libdir}/tls/libnvidia-tls_current_so.1 -_EOF +# nvidia-xconfig +install -D -m755 nvidia-xconfig %{buildroot}%{_bindir}/nvidia-xconfig +install -D -m644 nvidia-xconfig.1.gz %{buildroot}%{_mandir}/man1/nvidia-xconfig.1.gz + +# nvidia-settings +install -D -m755 nvidia-settings %{buildroot}%{_bindir}/nvidia-settings +install -D -m644 nvidia-settings.1.gz %{buildroot}%{_mandir}/man1/nvidia-settings.1.gz +install -D -m644 nvidia-settings.desktop %{buildroot}%{_datadir}/applications/nvidia-settings.desktop +install -D -m644 nvidia-settings.png %{buildroot}%{_datadir}/pixmaps/nvidia-settings.png +sed -e 's:__UTILS_PATH__:/usr/bin:' -e 's:__PIXMAP_PATH__:/usr/share/pixmaps:' -i %{buildroot}%{_datadir}/applications/nvidia-settings.desktop + +# nvidia-bug-report +install -D -m755 nvidia-bug-report.sh %{buildroot}%{_bindir}/nvidia-bug-report.sh + +# nvidia-smi +install -D -m755 nvidia-smi %{buildroot}%{_bindir}/nvidia-smi +install -D -m644 nvidia-smi.1.gz %{buildroot}%{_mandir}/man1/nvidia-smi.1.gz + +# nvidia-cuda-mps +install -D -m755 nvidia-cuda-mps-server %{buildroot}%{_bindir}/nvidia-cuda-mps-server +install -D -m755 nvidia-cuda-mps-control %{buildroot}%{_bindir}/nvidia-cuda-mps-control +install -D -m644 nvidia-cuda-mps-control.1.gz %{buildroot}%{_mandir}/man1/nvidia-cuda-mps-control.1.gz + +# nvidia-modprobe +# This should be removed if nvidia fixed their uvm module! +install -D -m4755 nvidia-modprobe %{buildroot}%{_bindir}/nvidia-modprobe +install -D -m644 nvidia-modprobe.1.gz %{buildroot}%{_mandir}/man1/nvidia-modprobe.1.gz + +# nvidia-persistenced +install -D -m755 nvidia-persistenced %{buildroot}%{_bindir}/nvidia-persistenced +install -D -m644 nvidia-persistenced.1.gz %{buildroot}%{_mandir}/man1/nvidia-persistenced.1.gz +install -D -m644 nvidia-persistenced-init/systemd/nvidia-persistenced.service.template %{buildroot}%{_unitdir}/nvidia-persistenced.service +sed -i 's/__USER__/nvidia-persistenced/' %{buildroot}%{_unitdir}/nvidia-persistenced.service + +# application profiles +install -D -m644 nvidia-application-profiles-%{version}-rc %{buildroot}%{_datadir}/nvidia/nvidia-application-profiles-%{version}-rc +install -D -m644 nvidia-application-profiles-%{version}-key-documentation %{buildroot}%{_datadir}/nvidia/nvidia-application-profiles-%{version}-key-documentation + +# new power management support +install -D -m644 systemd/system/nvidia-suspend.service %{buildroot}%{_unitdir}/nvidia-suspend.service +install -D -m644 systemd/system/nvidia-hibernate.service %{buildroot}%{_unitdir}/nvidia-hibernate.service +install -D -m644 systemd/system/nvidia-resume.service %{buildroot}%{_unitdir}/system/nvidia-resume.service +install -D -m755 systemd/system-sleep/nvidia %{buildroot}%{_systemd_util_dir}/system-sleep/nvidia +install -D -m755 systemd/nvidia-sleep.sh %{buildroot}%{_bindir}/nvidia-sleep.sh + +# distro specific files must be installed in /usr/share/X11/xorg.conf.d +install -D -m644 %{SOURCE2} %{buildroot}%{_datadir}/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf + +install -Dm644 %{SOURCE1} %{buildroot}%{_sysusersdir}/nvidia.conf -for f in nvidia-xconfig nvidia-settings nvidia-smi; do - install -D -m 775 ${f} %{buildroot}%{_bindir}/${f} - install -D -m 644 ${f}.1.gz %{buildroot}%{_mandir}/man1/${f}.1.gz -done install -D -m 644 nvidia-settings.desktop \ %{buildroot}%{_datadir}/applications/nvidia-settings.desktop install -D -m 644 nvidia-settings.png \ %{buildroot}%{_datadir}/pixmaps/nvidia-settings.png -# Clutter workaround (http://blog.sukimashita.com/2015/04/13/gnome-3-16-and-nvidia-binary-driver-crash-with-totem-gnome-maps-cheese-and-others/) -mkdir -p %{buildroot}%{_sysconfdir}/profile.d/ -cat > %{buildroot}%{_sysconfdir}/profile.d/nvidia-clutter.sh << _EOF -export CLUTTER_BACKEND=x11 -_EOF -chmod +x %{buildroot}%{_sysconfdir}/profile.d/nvidia-clutter.sh +## Clutter workaround (http://blog.sukimashita.com/2015/04/13/gnome-3-16-and-nvidia-binary-driver-crash-with-totem-gnome-maps-cheese-and-others/) +#mkdir -p %{buildroot}%{_sysconfdir}/profile.d/ +#cat > %{buildroot}%{_sysconfdir}/profile.d/nvidia-clutter.sh << _EOF +#export CLUTTER_BACKEND=x11 +#_EOF +#chmod +x %{buildroot}%{_sysconfdir}/profile.d/nvidia-clutter.sh # dkms install -d -m0755 %{buildroot}%{_prefix}/src/%{name}-%{version} @@ -272,169 +290,114 @@ nvidia-uvm \ %clean [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" -%post -n xorg-drv-video-nvidia +%post -n xorg-drv-video-%{name} # new install -update-alternatives --remove libnvidia-tls.so %{_libdir}/libnvidia-tls_current.so 2>/dev/null - if [ $1 -ge 1 ]; then # clean any legacy alternatives symlink find /lib/modules/*/kernel/drivers/video/ -name nvidia.ko -type l -exec rm -f {} \; dkms add -q -m %{name} -v %{version} dkms install -q -m %{name} -v %{version} -# update-alternatives \ -# --install %{_libdir}/libXvMCNVIDIA_dynamic.so libXvMCNVIDIA_dynamic.so \ -# %{_libdir}/libXvMCNVIDIA_current_so 50 - update-alternatives \ - --install %{_libdir}/libnvidia-cfg.so libnvidia-cfg.so \ - %{_libdir}/libnvidia-cfg_current_so 50 -# update-alternatives \ -# --install %{_libdir}/libnvidia-tls.so.1 libnvidia-tls.so.1.lib \ -# %{_libdir}/libnvidia-tls_current_so.1 50 -# update-alternatives \ -# --install %{_libdir}/tls/libnvidia-tls.so.1 libnvidia-tls.so.1 \ -# %{_libdir}/tls/libnvidia-tls_current_so.1 50 - - [ -e %{_libdir}/xorg/modules/drivers/nvidia_drv.so ] && \ - rm -f %{_libdir}/xorg/modules/drivers/nvidia_drv.so - - update-alternatives \ - --install %{_libdir}/xorg/modules/drivers/nvidia_drv.so nvidia_drv.so \ - %{_libdir}/xorg/modules/drivers/nvidia_current_drv_so 50 - - update-alternatives \ - --install %{_libdir}/libOpenCL.so.1 libOpenCL.so.1 \ - %{_libdir}/libOpenCL_nvidia_so.1.0.0 20 fi -if [ $1 -eq 1 -a -n "`grep nv /etc/X11/xorg.conf 2>/dev/null`" ]; then - sed -i "s|\"nv\"|\"nvidia\"|" /etc/X11/xorg.conf - sed -i "s|Load \"dri\"||" /etc/X11/xorg.conf -fi /sbin/ldconfig /sbin/depmod -a -F /boot/System.map-%{kernel_ver}%{?KERNEL_TARGET} \ %{kernel_ver}%{?KERNEL_TARGET} &>/dev/null -exit 0 +: -%preun -n xorg-drv-video-nvidia +%preun -n xorg-drv-video-%{name} # erase if [ $1 -eq 0 ]; then dkms remove -q -m nvidia -v %{version} --all - update-alternatives \ - --remove libXvMCNVIDIA_dynamic.so %{_libdir}/libXvMCNVIDIA_current_so - update-alternatives \ - --remove libnvidia-cfg.so %{_libdir}/libnvidia-cfg_current_so - update-alternatives \ - --remove libnvidia-tls.so.1.lib %{_libdir}/libnvidia-tls_current_so.1 - update-alternatives \ - --remove libnvidia-tls.so.1 %{_libdir}/tls/libnvidia-tls_current_so.1 - [ ! -L %{_libdir}/xorg/modules/drivers/nvidia_drv.so ] && \ - rm -f %{_libdir}/xorg/modules/drivers/nvidia_drv.so - - update-alternatives \ - --remove nvidia_drv.so %{_libdir}/xorg/modules/drivers/nvidia_current_drv_so - - update-alternatives \ - --remove libOpenCL.so.1 %{_libdir}/libOpenCL_nvidia_so.1.0.0 - - [ -w /etc/X11/xorg.conf ] && \ - sed -i "s|\"nvidia\"|\"nv\"|" /etc/X11/xorg.conf /sbin/ldconfig /sbin/depmod -a -F /boot/System.map-`uname -r` \ `uname -r` &>/dev/null fi -exit 0 +: -%post -n xorg-ext-libglx-nvidia -update-alternatives --remove libglx.so %{_libdir}/libglx_current.so 2>/dev/null -/usr/sbin/update-alternatives \ - --install %{_libdir}/xorg/modules/extensions/libglx.so libglx.so \ - %{_libdir}/xorg/modules/extensions/libglx_current_so 20 -exit 0 - -%preun -n xorg-ext-libglx-nvidia -if [ $1 -eq 0 ]; then - /usr/sbin/update-alternatives --remove libglx.so \ - %{_libdir}/xorg/modules/extensions/libglx_current_so -fi -exit 0 - -%post -n libGL-nvidia-X11 -update-alternatives --remove libGL.so.1 %{_libdir}/libGL_current.so.1 2>/dev/null -/usr/sbin/update-alternatives \ - --install %{_libdir}/libGL.so.1 libGL.so.1 \ - %{_libdir}/libGL_current_so.1 20 -/sbin/ldconfig -exit 0 - -%preun -n libGL-nvidia-X11 -if [ $1 -eq 0 ]; then - /usr/sbin/update-alternatives --remove libGL.so.1 \ - %{_libdir}/libGL_current_so.1 -fi -/sbin/ldconfig -exit 0 - -%files -n libGL-nvidia-X11 +%files -n xorg-drv-video-%{name} %defattr(-,root,root) -%{_libdir}/libGL_so.%{nvidia_current_libver} -%{_libdir}/libGL_current_so.1 - -%files -n xorg-ext-libglx-nvidia -%defattr(-,root,root) -%{_libdir}/xorg/modules/extensions/libglx_current_so -%{_libdir}/xorg/modules/extensions/libglx_so.%{nvidia_current_libver} - -%files -n xorg-drv-video-nvidia -%defattr(-,root,root) -%{_sysconfdir}/profile.d/nvidia-clutter.sh +#%{_sysconfdir}/profile.d/nvidia-clutter.sh +%{_sysconfdir}/OpenCL/vendors/nvidia.icd %dir %{_prefix}/src/%{name}-%{version} %{_prefix}/src/%{name}-%{version}/* -%attr(0755,root,root) %{_sbindir}/update-alternatives-set-nvidia -%{_libdir}/libnvidia-glcore.so.%{nvidia_current_libver} -#%{_libdir}/libXvMCNVIDIA.a -#%{_libdir}/libXvMCNVIDIA_so.%{nvidia_current_libver} -#%{_libdir}/libXvMCNVIDIA_current_so -%{_libdir}/xorg/modules/drivers/nvidia_current_drv_so -%{_libdir}/xorg/modules/libnvidia-wfb.so.%{nvidia_current_libver} -#%{_libdir}/xorg/modules/libwfb.so -%{_libdir}/libnvidia-cfg_so.%{nvidia_current_libver} -%{_libdir}/libnvidia-cfg_current_so -%{_libdir}/libnvidia-tls.so.%{nvidia_current_libver} -#%{_libdir}/libnvidia-tls_current_so.1 -#%{_libdir}/tls/libnvidia-tls_current_so.1 -%{_libdir}/libnvidia-ml.so.1 -%{_libdir}/libnvidia-ml.so.%{nvidia_current_libver} -%{_libdir}/tls/libnvidia-tls.so.%{nvidia_current_libver} -%{_libdir}/libcuda.so.%{nvidia_current_libver} -%{_libdir}/libnvcuvid.%{nvidia_current_libver} -%{_libdir}/libnvidia-compiler.%{nvidia_current_libver} -%{_libdir}/libnvidia-encode.%{nvidia_current_libver} -%{_libdir}/libnvidia-opencl.so.%{nvidia_current_libver} -%{_libdir}/libnvidia-wfb.so.%{nvidia_current_libver} -%{_libdir}/libOpenCL_nvidia_so.1.0.0 -%{_libdir}/vdpau/libvdpau_nvidia.so -%{_libdir}/vdpau/libvdpau_nvidia.so.%{nvidia_current_libver} +/lib/firmware/nvidia/%{version}/gsp.bin +%{_bindir}/nvidia-* +%{_systemd_util_dir}/system-sleep/nvidia +%{_unitdir}/nvidia-hibernate.service +%{_unitdir}/nvidia-persistenced.service +%{_unitdir}/nvidia-suspend.service +%{_unitdir}/system/nvidia-resume.service +%{_sysusersdir}/nvidia.conf +%{_libdir}/libEGL_nvidia.so.* +%{_libdir}/libGLESv1_CM_nvidia.so.* +%{_libdir}/libGLESv2_nvidia.so.* +%{_libdir}/libGLX_nvidia.so.* +%{_libdir}/libcuda.so.* +%{_libdir}/libnvcuvid.so.* +%{_libdir}/libnvidia-*.so.* +%{_libdir}/libnvoptix.so.* +%dir %{_libdir}/nvidia +%dir %{_libdir}/nvidia/xorg +%{_libdir}/nvidia/xorg/libglxserver_nvidia.so +%{_libdir}/nvidia/xorg/libglxserver_nvidia.so.* +%{_libdir}/vdpau/libvdpau_nvidia.so.* +%{_libdir}/xorg/modules/drivers/nvidia_drv.so +%{_datadir}/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf +%{_datadir}/applications/nvidia-settings.desktop +%{_datadir}/glvnd/egl_vendor.d/10_nvidia.json +%{_datadir}/nvidia/nvidia-application-profiles-%{version}-key-documentation +%{_datadir}/nvidia/nvidia-application-profiles-%{version}-rc +%{_datadir}/pixmaps/nvidia-settings.png +%{_datadir}/vulkan/icd.d/nvidia_icd.json +%{_datadir}/vulkan/implicit_layer.d/nvidia_layers.json +%{_mandir}/man1/nvidia-*.1* %doc current/LICENSE -%files -n xorg-apps-nvidia +%files -n xorg-drv-video-%{name}-doc %defattr(-,root,root) -%{_bindir}/nvidia-settings -%{_bindir}/nvidia-xconfig -%{_bindir}/nvidia-smi -%{_datadir}/applications/nvidia-settings.desktop -%{_datadir}/pixmaps/nvidia-settings.png -%{_mandir}/man1/nvidia-settings.* -%{_mandir}/man1/nvidia-smi.* -%{_mandir}/man1/nvidia-xconfig.* - -%files -n xorg-drv-video-nvidia-doc -%defattr(-,root,root) -%doc current/{LICENSE,NVIDIA_Changelog,README.txt} current/html +%doc current/{NVIDIA_Changelog,README.txt} current/html %changelog -* Fri Aug 21 2020 Silvan Calarco 390.138-2mamba -- dkms: add IGNORE_CC_MISMATCH=1 before make command to fix build with gcc 10.1+ +* Fri Apr 23 2021 Silvan Calarco 465.24.02-2mamba +- rebuilt with libglvnd and libmesa + +* Thu Apr 15 2021 Automatic Build System 465.24.02-1mamba +- automatic version update by autodist + +* Thu Apr 15 2021 Silvan Calarco 460.73.01-1mamba +- update to 460.73.01 + +* Thu Apr 15 2021 Silvan Calarco 460.39-2mamba +- renamed from nvidia_450 + +* Wed Jan 27 2021 Automatic Build System 460.39-1mamba +- automatic version update by autodist + +* Fri Jan 08 2021 Automatic Build System 460.32.03-1mamba +- automatic version update by autodist + +* Thu Nov 19 2020 Automatic Build System 455.45.01-1mamba +- automatic version update by autodist + +* Thu Oct 08 2020 Automatic Build System 455.28-1mamba +- automatic version update by autodist + +* Thu Oct 01 2020 Automatic Build System 450.80.02-1mamba +- automatic version update by autodist + +* Mon Aug 31 2020 Silvan Calarco 450.66-3mamba +- fix removing provides for conflicting libraries + +* Sun Aug 30 2020 Silvan Calarco 450.66-2mamba +- remove provide for conflicting libraries + +* Fri Aug 21 2020 Silvan Calarco 450.66-1mamba +- update to 450.66 +- dkms: added IGNORE_CC_MISMATCH=1 before make command to support gcc 10.1+ + +* Sun Aug 09 2020 Silvan Calarco 450.57-1mamba +- update to 450.57 * Fri Jul 24 2020 Silvan Calarco 390.138-1mamba - update to 390.138 diff --git a/nvidia.sysusers b/nvidia.sysusers new file mode 100644 index 0000000..71c0608 --- /dev/null +++ b/nvidia.sysusers @@ -0,0 +1 @@ +u nvidia-persistenced 143 'NVIDIA Persistence Daemon'