Advertisement
Guest User

Untitled

a guest
Oct 30th, 2019
159
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Based on the file created for Arch Linux by:
  2. # Maintainer : Thomas Baechler <thomas@archlinux.org>
  3.  
  4. # Maintainer: Philip M端ller <philm@manjaro.org>
  5.  
  6. _linuxprefix=linux-lqx
  7. _extramodules=extramodules-lqx
  8. _kver=53
  9. _prevkver=52
  10. pkgname=nvidia-390xx-$_linuxprefix-$_kver
  11. _pkgname=nvidia
  12. pkgver=390.129
  13. _pkgver=390.129
  14. pkgrel=7.3
  15. provides=("$_pkgname=$pkgver")
  16. groups=("$_linuxprefix-extramodules")
  17. pkgdesc="NVIDIA drivers for linux."
  18. arch=('i686' 'x86_64')
  19. url="http://www.nvidia.com/"
  20. depends=("$_linuxprefix" "nvidia-390xx-utils=${pkgver}")
  21. makedepends=("$_linuxprefix-headers")
  22. conflicts=('nvidia-96xx' 'nvidia-183xx' 'nvidia-340xx-lqx' 'nvidia-304xx-lqx' 'nvidia-lqx' "nvidia-390xx-$_linuxprefix-$_prevkver" "nvidia-390xx-$_linuxprefix")
  23. license=('custom')
  24. install=nvidia-lqx.install
  25. options=(!strip)
  26. durl="http://us.download.nvidia.com/XFree86/Linux-x86"
  27. source_i686=("${durl}/${pkgver}/NVIDIA-Linux-x86-${pkgver}.run")
  28. source_x86_64=("${durl}_64/${pkgver}/NVIDIA-Linux-x86_64-${pkgver}-no-compat32.run")
  29. #source=('kernel-4.16.patch' 'kernel-5.1.patch' 'kernel-5.2.patch')
  30. #sha256sums=('622ac792ec200b2239cb663c0010392118b78c9904973d82cd261165c16d6385' 'd92899d4f7a40e2c3cad92d067f2f53c3a18c49b34e62e707a93b125aa37640f' '9d94f30662d64400ee43bb7745544b72e1c6216a30ae2907a744c7ae0aa6e384')
  31. sha256sums_i686=('5854268c26f112a16c6fd7ded0031bf95cc8f4dab617ac5d701090fec19d6f36')
  32. sha256sums_x86_64=('a7925a327cab828d1eb9e74f8943623c5dbc9a5e376a4c0184065d4a319696c1')
  33.  
  34. [[ "$CARCH" = "i686" ]] && _pkg="NVIDIA-Linux-x86-${pkgver}"
  35. [[ "$CARCH" = "x86_64" ]] && _pkg="NVIDIA-Linux-x86_64-${pkgver}-no-compat32"
  36.  
  37. prepare() {
  38. sh "${_pkg}.run" --extract-only
  39. cd "${_pkg}"
  40. # patches here
  41.  
  42. # Restore phys_to_dma support (still needed for 396.18)
  43. # https://bugs.archlinux.org/task/58074
  44. #patch -Np1 -i ../kernel-4.16.patch
  45.  
  46. #patch -Np1 -i ../kernel-5.1.patch
  47. #patch -Np1 -i ../kernel-5.2.patch
  48. }
  49.  
  50. build() {
  51. _kernver="$(cat /usr/lib/modules/${_extramodules}/version)"
  52. cd "${_pkg}"/kernel
  53. make SYSSRC=/usr/lib/modules/"${_kernver}/build" module
  54. }
  55.  
  56. package() {
  57. install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
  58. "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia.ko"
  59. install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia-modeset.ko" \
  60. "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia-modeset.ko"
  61. install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia-drm.ko" \
  62. "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia-drm.ko"
  63. if [[ "$CARCH" = "x86_64" ]]; then
  64. install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia-uvm.ko" \
  65. "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia-uvm.ko"
  66. fi
  67. gzip "${pkgdir}/usr/lib/modules/${_extramodules}/"*.ko
  68. sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia-lqx.install"
  69. }
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement