diff options
author | Matt Housh <jaeger@crux.ninja> | 2018-08-11 13:46:07 -0500 |
---|---|---|
committer | Matt Housh <jaeger@crux.ninja> | 2018-08-11 13:46:07 -0500 |
commit | 35881809c26f86243888b58fc66fc12d0d359c0a (patch) | |
tree | 3e3007ceb6fa219032d6c8bd3864368d95d0802f /nvidia-sl/Pkgfile | |
parent | cb363308adfe57040b8c235b5fdd22ca85cf9d27 (diff) | |
download | opt-35881809c26f86243888b58fc66fc12d0d359c0a.tar.gz opt-35881809c26f86243888b58fc66fc12d0d359c0a.tar.xz |
nvidia-sl: converted to GLVND
Diffstat (limited to 'nvidia-sl/Pkgfile')
-rw-r--r-- | nvidia-sl/Pkgfile | 197 |
1 files changed, 118 insertions, 79 deletions
diff --git a/nvidia-sl/Pkgfile b/nvidia-sl/Pkgfile index 2bb8867c6..d9f27137d 100644 --- a/nvidia-sl/Pkgfile +++ b/nvidia-sl/Pkgfile @@ -1,88 +1,127 @@ -# Description: nVIDIA Linux Display Driver (short lived branch version) +# Description: NVIDIA Linux Display Driver (short lived branch) # URL: http://www.nvidia.com/ # Maintainer: Matt Housh, jaeger at crux dot ninja -# Depends on: gtk gl-select +# Depends on: gtk gtk3 libglvnd name=nvidia-sl version=396.51 -release=1 +release=2 source=(http://us.download.nvidia.com/XFree86/Linux-x86_64/$version/NVIDIA-Linux-x86_64-$version.run \ - 90-nvidia-uvm.rules) + 90-nvidia-uvm.rules 10-nvidia-drm-outputclass.conf) build() { - sh NVIDIA-Linux-x86_64-$version.run --extract-only - cd NVIDIA-Linux-x86_64-$version - - # libraries - install -d $PKG/usr/lib/{tls,vdpau} - install -m 0755 libGL.so.$version $PKG/usr/lib - install -m 0755 libOpenCL.so.1.0.0 $PKG/usr/lib - install -m 0755 libcuda.so.$version $PKG/usr/lib - install -m 0755 libnvidia-cfg.so.$version $PKG/usr/lib - install -m 0755 libnvidia-compiler.so.$version $PKG/usr/lib - install -m 0755 libnvidia-encode.so.$version $PKG/usr/lib - install -m 0755 libnvidia-fbc.so.$version $PKG/usr/lib - install -m 0755 libnvidia-glcore.so.$version $PKG/usr/lib - install -m 0755 libnvidia-gtk2.so.$version $PKG/usr/lib - install -m 0755 libnvidia-gtk3.so.$version $PKG/usr/lib - install -m 0755 libnvidia-ifr.so.$version $PKG/usr/lib - install -m 0755 libnvidia-ml.so.$version $PKG/usr/lib - install -m 0755 libnvidia-opencl.so.$version $PKG/usr/lib - install -m 0755 libnvidia-tls.so.$version $PKG/usr/lib - install -m 0755 libnvcuvid.so.$version $PKG/usr/lib - install -m 0755 tls/libnvidia-tls.so.$version $PKG/usr/lib/tls - install -m 0755 libvdpau_nvidia.so.$version $PKG/usr/lib/vdpau - install -m 0755 libnvidia-fatbinaryloader.so.$version $PKG/usr/lib - install -m 0755 libnvidia-glvkspirv.so.$version $PKG/usr/lib - - ln -s libvdpau_nvidia.so.$version $PKG/usr/lib/vdpau/libvdpau_nvidia.so.1 - ln -s libvdpau_nvidia.so.$version $PKG/usr/lib/vdpau/libvdpau_nvidia.so - - ln -s libnvcuvid.so.$version $PKG/usr/lib/libnvcuvid.so.1 - ln -s libnvcuvid.so.$version $PKG/usr/lib/libnvcuvid.so - - ln -s libnvidia-ml.so.$version $PKG/usr/lib/libnvidia-ml.so.1 - ln -s libnvidia-ml.so.$version $PKG/usr/lib/libnvidia-ml.so - - ln -s libOpenCL.so.1.0.0 $PKG/usr/lib/libOpenCL.so - - # xorg driver/extensions - install -d $PKG/usr/lib/xorg/modules/{drivers,extensions} - install -m 0755 nvidia_drv.so $PKG/usr/lib/xorg/modules/drivers - install -m 0755 libglx.so.$version $PKG/usr/lib/xorg/modules/extensions - install -m 0755 libnvidia-wfb.so.$version $PKG/usr/lib/xorg/modules - - # nvidia programs amd man-pages - install -d $PKG/usr/{bin,share/man/man1} - install -m 0755 nvidia-{debugdump,persistenced,settings,smi,xconfig} \ - $PKG/usr/bin - install -m 0644 nvidia-{persistenced,settings,smi,xconfig}.1.gz \ - $PKG/usr/share/man/man1 - - # desktop file and icon - install -d $PKG/usr/share/{applications,pixmaps} - sed -i 's:__UTILS_PATH__:/usr/bin: ; s:__PIXMAP_PATH__:/usr/share/pixmaps:' nvidia-settings.desktop - install -m 0644 nvidia-settings.desktop $PKG/usr/share/applications - install -m 0644 nvidia-settings.png $PKG/usr/share/pixmaps - - # additional symlinks required by gl-select - ln -s libGL.so.$version $PKG/usr/lib/libGL_so_1_2_nvidia - ln -s libglx.so.$version $PKG/usr/lib/xorg/modules/extensions/libglx_so_nvidia - - # opencl icd file - install -m 0644 -D nvidia.icd $PKG/etc/OpenCL/vendors/nvidia.icd - - # nvidia-uvm module udev rule - install -d $PKG/lib/udev/rules.d - install -m 0644 $SRC/90-nvidia-uvm.rules $PKG/lib/udev/rules.d/90-nvidia-uvm.rules - - # nvidia-settings registry key file - install -D -m 0644 nvidia-application-profiles-$version-key-documentation \ - $PKG/usr/share/nvidia/nvidia-application-profiles-$version-key-documentation - - # kernel modules - cd kernel - IGNORE_CC_MISMATCH=1 make module - install -d -m 0755 $PKG/lib/modules/`uname -r`/extra - install -m 0644 *.ko $PKG/lib/modules/`uname -r`/extra/ + sh NVIDIA-Linux-x86_64-$version.run --extract-only + cd NVIDIA-Linux-x86_64-$version + + # X driver and GLX extension + install -d $PKG/usr/lib/xorg/modules/{drivers,extensions} + install -m 0755 nvidia_drv.so $PKG/usr/lib/xorg/modules/drivers/ + install -d -m 0755 $PKG/usr/lib/nvidia/xorg + install -m 0755 libglx.so.$version $PKG/usr/lib/nvidia/xorg/ + ln -s libglx.so.$version $PKG/usr/lib/nvidia/xorg/libglx.so + ln -s libglx.so.$version $PKG/usr/lib/nvidia/xorg/libglx.so.1 + + # EGL and OpenGL ES libraries and config + install -d $PKG/usr/lib + install -m 0755 libGLESv1_CM_nvidia.so.$version $PKG/usr/lib/ + ln -s libGLESv1_CM_nvidia.so.$version $PKG/usr/lib/libGLESv1_CM_nvidia.so.1 + install -m 0755 libGLESv2_nvidia.so.$version $PKG/usr/lib/ + ln -s libGLESv2_nvidia.so.$version $PKG/usr/lib/libGLESv2_nvidia.so.2 + install -D -m 0644 10_nvidia.json $PKG/usr/share/glvnd/egl_vendor.d/10_nvidia.json + + # wayland EGL library and config + #install -d $PKG/usr/share/egl/egl_external_platform.d + #install -m 0755 libnvidia-egl-wayland.so.1.0.2 $PKG/usr/lib/ + #install -m 0644 10_nvidia_wayland.json $PKG/usr/share/egl/egl_external_platform.d/ + + # GLVND vendor implementation libraries + install -m 0755 libGLX_nvidia.so.$version $PKG/usr/lib/ + ln -s libGLX_nvidia.so.$version $PKG/usr/lib/libGLX_nvidia.so.0 + install -m 0755 libEGL_nvidia.so.$version $PKG/usr/lib/ + ln -s libEGL_nvidia.so.$verison $PKG/usr/lib/libEGL_nvidia.so.0 + + # vulkan ICD config + install -d $PKG/etc/vulkan/icd.d + sed -i -e 's,__NV_VK_ICD__,libGLX_nvidia.so.0,g' nvidia_icd.json.template + install -m 0644 nvidia_icd.json.template $PKG/etc/vulkan/icd.d/nvidia_icd.json + + # driver component libraries + install -m 0755 libnvidia-cfg.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-compiler.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-eglcore.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-glcore.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-glsi.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-glvkspirv.so.$version $PKG/usr/lib/ + + # vendor VDPAU library + install -D -m 0755 libvdpau_nvidia.so.$version $PKG/usr/lib/vdpau/libvdpau_nvidia.so.$version + ln -s libvdpau_nvidia.so.$version $PKG/usr/lib/vdpau/libvdpau_nvidia.so.1 + ln -s libvdpau_nvidia.so.$version $PKG/usr/lib/vdpau/libvdpau_nvidia.so + + # CUDA libraries + install -m 0755 libcuda.so.$version $PKG/usr/lib/ + ln -s libcuda.so.$version $PKG/usr/lib/libcuda.so.1 + ln -s libcuda.so.$version $PKG/usr/lib/libcuda.so + install -m 0755 libnvidia-fatbinaryloader.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-ptxjitcompiler.so.$version $PKG/usr/lib/ + ln -s libnvidia-ptxjitcompiler.so.$version $PKG/usr/lib/libnvidia-ptxjitcompiler.so.1 + ln -s libnvidia-ptxjitcompiler.so.$version $PKG/usr/lib/libnvidia-ptxjitcompiler.so + + # OpenCL libraries and config + install -m 0755 libOpenCL.so.1.0.0 $PKG/usr/lib/ + install -m 0755 libnvidia-opencl.so.$version $PKG/usr/lib/ + ln -s libnvidia-opencl.so.$version $PKG/usr/lib/libnvidia-opencl.so.1 + ln -s libnvidia-opencl.so.$version $PKG/usr/lib/libnvidia-opencl.so + install -D -m 0644 nvidia.icd $PKG/etc/OpenCL/vendors/nvidia.icd + + # CUDA MPI applications + install -d $PKG/usr/bin + install -m 0755 nvidia-cuda-mps-control $PKG/usr/bin/ + install -m 0755 nvidia-cuda-mps-server $PKG/usr/bin/ + + # TLS libraries + install -m 0755 libnvidia-tls.so.$version $PKG/usr/lib/ + install -d $PKG/usr/lib/tls + install -m 0755 tls/libnvidia-tls.so.$version $PKG/usr/lib/tls/ + + # monitoring and management API library + install -m 0755 libnvidia-ml.so.$version $PKG/usr/lib/ + + # applications + install -m 4755 nvidia-modprobe $PKG/usr/bin/ + install -m 0755 nvidia-{xconfig,settings,smi,debugdump,persistenced} \ + $PKG/usr/bin/ + + # nvidia-settings UI libraries + install -m 0755 libnvidia-gtk{2,3}.so.$version $PKG/usr/lib/ + + # encoding/decoding libraries + install -m 0755 libnvcuvid.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-encode.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-ifr.so.$version $PKG/usr/lib/ + install -m 0755 libnvidia-fbc.so.$version $PKG/usr/lib/ + + # X driver config + install -D -m 0644 $SRC/10-nvidia-drm-outputclass.conf \ + $PKG/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf + + # application profile keys and documentation + install -d -m 0755 $PKG/usr/share/nvidia + install -m 0644 nvidia-application-profiles-$version-rc $PKG/usr/share/nvidia/ + install -m 0644 nvidia-application-profiles-$version-key-documentation $PKG/usr/share/nvidia/ + + # desktop file and icon + install -d $PKG/usr/share/{applications,pixmaps} + sed -i -e 's,__UTILS_PATH__,/usr/bin,' -e 's,__PIXMAP_PATH__,/usr/share/pixmaps,' nvidia-settings.desktop + install -m 0644 nvidia-settings.desktop $PKG/usr/share/applications/ + install -m 0644 nvidia-settings.png $PKG/usr/share/pixmaps/ + + # nvidia-uvm udev rules file + install -D -m 0644 $SRC/90-nvidia-uvm.rules $PKG/lib/udev/rules.d/90-nvidia-uvm.rules + + # kernel modules + cd kernel + IGNORE_CC_MISMATCH=1 make module + install -d $PKG/lib/modules/$(uname -r)/extra + install -m 0644 *.ko $PKG/lib/modules/$(uname -r)/extra/ } |