[arch-commits] Commit in nvidia-304xx/repos (8 files)
Thomas Bächler
thomas at nymeria.archlinux.org
Sun Jan 26 12:19:59 UTC 2014
Date: Sunday, January 26, 2014 @ 13:19:58
Author: thomas
Revision: 204763
archrelease: copy trunk to testing-i686
Added:
nvidia-304xx/repos/testing-i686/
nvidia-304xx/repos/testing-i686/PKGBUILD
(from rev 204742, nvidia-304xx/trunk/PKGBUILD)
nvidia-304xx/repos/testing-i686/nvidia.install
(from rev 204742, nvidia-304xx/trunk/nvidia.install)
nvidia-304xx/repos/testing-i686/nvidia_3.13_kernel.patch
(from rev 204742, nvidia-304xx/trunk/nvidia_3.13_kernel.patch)
nvidia-304xx/repos/testing-x86_64/
nvidia-304xx/repos/testing-x86_64/PKGBUILD
(from rev 204742, nvidia-304xx/trunk/PKGBUILD)
nvidia-304xx/repos/testing-x86_64/nvidia.install
(from rev 204742, nvidia-304xx/trunk/nvidia.install)
nvidia-304xx/repos/testing-x86_64/nvidia_3.13_kernel.patch
(from rev 204742, nvidia-304xx/trunk/nvidia_3.13_kernel.patch)
-----------------------------------------+
testing-i686/PKGBUILD | 55 ++++++++++++++++++++++++++++++
testing-i686/nvidia.install | 15 ++++++++
testing-i686/nvidia_3.13_kernel.patch | 25 +++++++++++++
testing-x86_64/PKGBUILD | 55 ++++++++++++++++++++++++++++++
testing-x86_64/nvidia.install | 15 ++++++++
testing-x86_64/nvidia_3.13_kernel.patch | 25 +++++++++++++
6 files changed, 190 insertions(+)
Copied: nvidia-304xx/repos/testing-i686/PKGBUILD (from rev 204742, nvidia-304xx/trunk/PKGBUILD)
===================================================================
--- testing-i686/PKGBUILD (rev 0)
+++ testing-i686/PKGBUILD 2014-01-26 12:19:58 UTC (rev 204763)
@@ -0,0 +1,55 @@
+# $Id$
+# Maintainer : Thomas Baechler <thomas at archlinux.org>
+
+pkgname=nvidia-304xx
+pkgver=304.117
+_extramodules=extramodules-3.13-ARCH
+pkgrel=5
+pkgdesc="NVIDIA drivers for linux, 304xx legacy branch"
+arch=('i686' 'x86_64')
+url="http://www.nvidia.com/"
+depends=('linux>=3.13' 'linux<3.14' "nvidia-304xx-utils=${pkgver}")
+makedepends=('linux-headers>=3.13' 'linux-headers<3.14')
+conflicts=('nvidia' 'nvidia-96xx' 'nvidia-173xx')
+license=('custom')
+install=nvidia.install
+options=(!strip)
+source=('nvidia_3.13_kernel.patch')
+md5sums=('f1569a1ce7f9293b876c2b72f3fd7c9e')
+
+if [ "$CARCH" = "i686" ]; then
+ _arch='x86'
+ _pkg="NVIDIA-Linux-${_arch}-${pkgver}"
+ source+=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
+ md5sums+=('023eb03da304a1842fc503c81e3c5694')
+elif [ "$CARCH" = "x86_64" ]; then
+ _arch='x86_64'
+ _pkg="NVIDIA-Linux-${_arch}-${pkgver}-no-compat32"
+ source+=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
+ md5sums+=('8ee9f672028971c6d36118894d0e2c59')
+fi
+
+
+prepare() {
+ cd "${srcdir}"
+ sh "${_pkg}.run" --extract-only
+ cd "${_pkg}"
+ patch -p1 -i "${srcdir}"/nvidia_3.13_kernel.patch
+}
+
+build() {
+ _kernver="$(cat /usr/lib/modules/${_extramodules}/version)"
+ cd "${_pkg}/kernel"
+ make SYSSRC=/usr/lib/modules/"${_kernver}/build" module
+}
+
+package() {
+ install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
+ "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia.ko"
+ install -d -m755 "${pkgdir}/usr/lib/modprobe.d"
+ echo "blacklist nouveau" >> "${pkgdir}/usr/lib/modprobe.d/nvidia.conf"
+ sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
+ gzip "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia.ko"
+
+ # the license file is part of nvidia-304xx-utils - the module depends on it, so we don't ship it another time.
+}
Copied: nvidia-304xx/repos/testing-i686/nvidia.install (from rev 204742, nvidia-304xx/trunk/nvidia.install)
===================================================================
--- testing-i686/nvidia.install (rev 0)
+++ testing-i686/nvidia.install 2014-01-26 12:19:58 UTC (rev 204763)
@@ -0,0 +1,15 @@
+post_install() {
+ EXTRAMODULES='extramodules-3.12-ARCH'
+ depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
+ echo 'In order to use nvidia module, reboot the system.'
+}
+
+post_upgrade() {
+ EXTRAMODULES='extramodules-3.12-ARCH'
+ depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
+}
+
+post_remove() {
+ EXTRAMODULES='extramodules-3.12-ARCH'
+ depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
+}
Copied: nvidia-304xx/repos/testing-i686/nvidia_3.13_kernel.patch (from rev 204742, nvidia-304xx/trunk/nvidia_3.13_kernel.patch)
===================================================================
--- testing-i686/nvidia_3.13_kernel.patch (rev 0)
+++ testing-i686/nvidia_3.13_kernel.patch 2014-01-26 12:19:58 UTC (rev 204763)
@@ -0,0 +1,25 @@
+diff -Nur NVIDIA-Linux-x86_64-304.117-no-compat32.orig/kernel/nv-acpi.c NVIDIA-Linux-x86_64-304.117-no-compat32/kernel/nv-acpi.c
+--- NVIDIA-Linux-x86_64-304.117-no-compat32.orig/kernel/nv-acpi.c 2013-11-27 06:25:42.000000000 +0100
++++ NVIDIA-Linux-x86_64-304.117-no-compat32/kernel/nv-acpi.c 2014-01-26 12:25:06.443610357 +0100
+@@ -15,6 +15,10 @@
+ #include "nv-linux.h"
+ #include "nv-reg.h"
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 13, 0) && defined(ACPI_HANDLE)
++#define DEVICE_ACPI_HANDLE(a) ACPI_HANDLE(a)
++#endif
++
+ #if defined(NV_LINUX_ACPI_EVENTS_SUPPORTED)
+
+ static int nv_acpi_add (struct acpi_device *);
+@@ -299,7 +303,10 @@
+
+ if (pNvAcpiObject->notify_handler_installed)
+ {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
++ /* beginning with 3.13, acpi_remove_notify_handler() waits for events to finish */
+ NV_ACPI_OS_WAIT_EVENTS_COMPLETE();
++#endif
+
+ // remove event notifier
+ status = acpi_remove_notify_handler(device->handle, ACPI_DEVICE_NOTIFY, nv_acpi_event);
Copied: nvidia-304xx/repos/testing-x86_64/PKGBUILD (from rev 204742, nvidia-304xx/trunk/PKGBUILD)
===================================================================
--- testing-x86_64/PKGBUILD (rev 0)
+++ testing-x86_64/PKGBUILD 2014-01-26 12:19:58 UTC (rev 204763)
@@ -0,0 +1,55 @@
+# $Id$
+# Maintainer : Thomas Baechler <thomas at archlinux.org>
+
+pkgname=nvidia-304xx
+pkgver=304.117
+_extramodules=extramodules-3.13-ARCH
+pkgrel=5
+pkgdesc="NVIDIA drivers for linux, 304xx legacy branch"
+arch=('i686' 'x86_64')
+url="http://www.nvidia.com/"
+depends=('linux>=3.13' 'linux<3.14' "nvidia-304xx-utils=${pkgver}")
+makedepends=('linux-headers>=3.13' 'linux-headers<3.14')
+conflicts=('nvidia' 'nvidia-96xx' 'nvidia-173xx')
+license=('custom')
+install=nvidia.install
+options=(!strip)
+source=('nvidia_3.13_kernel.patch')
+md5sums=('f1569a1ce7f9293b876c2b72f3fd7c9e')
+
+if [ "$CARCH" = "i686" ]; then
+ _arch='x86'
+ _pkg="NVIDIA-Linux-${_arch}-${pkgver}"
+ source+=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
+ md5sums+=('023eb03da304a1842fc503c81e3c5694')
+elif [ "$CARCH" = "x86_64" ]; then
+ _arch='x86_64'
+ _pkg="NVIDIA-Linux-${_arch}-${pkgver}-no-compat32"
+ source+=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
+ md5sums+=('8ee9f672028971c6d36118894d0e2c59')
+fi
+
+
+prepare() {
+ cd "${srcdir}"
+ sh "${_pkg}.run" --extract-only
+ cd "${_pkg}"
+ patch -p1 -i "${srcdir}"/nvidia_3.13_kernel.patch
+}
+
+build() {
+ _kernver="$(cat /usr/lib/modules/${_extramodules}/version)"
+ cd "${_pkg}/kernel"
+ make SYSSRC=/usr/lib/modules/"${_kernver}/build" module
+}
+
+package() {
+ install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
+ "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia.ko"
+ install -d -m755 "${pkgdir}/usr/lib/modprobe.d"
+ echo "blacklist nouveau" >> "${pkgdir}/usr/lib/modprobe.d/nvidia.conf"
+ sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
+ gzip "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia.ko"
+
+ # the license file is part of nvidia-304xx-utils - the module depends on it, so we don't ship it another time.
+}
Copied: nvidia-304xx/repos/testing-x86_64/nvidia.install (from rev 204742, nvidia-304xx/trunk/nvidia.install)
===================================================================
--- testing-x86_64/nvidia.install (rev 0)
+++ testing-x86_64/nvidia.install 2014-01-26 12:19:58 UTC (rev 204763)
@@ -0,0 +1,15 @@
+post_install() {
+ EXTRAMODULES='extramodules-3.12-ARCH'
+ depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
+ echo 'In order to use nvidia module, reboot the system.'
+}
+
+post_upgrade() {
+ EXTRAMODULES='extramodules-3.12-ARCH'
+ depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
+}
+
+post_remove() {
+ EXTRAMODULES='extramodules-3.12-ARCH'
+ depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
+}
Copied: nvidia-304xx/repos/testing-x86_64/nvidia_3.13_kernel.patch (from rev 204742, nvidia-304xx/trunk/nvidia_3.13_kernel.patch)
===================================================================
--- testing-x86_64/nvidia_3.13_kernel.patch (rev 0)
+++ testing-x86_64/nvidia_3.13_kernel.patch 2014-01-26 12:19:58 UTC (rev 204763)
@@ -0,0 +1,25 @@
+diff -Nur NVIDIA-Linux-x86_64-304.117-no-compat32.orig/kernel/nv-acpi.c NVIDIA-Linux-x86_64-304.117-no-compat32/kernel/nv-acpi.c
+--- NVIDIA-Linux-x86_64-304.117-no-compat32.orig/kernel/nv-acpi.c 2013-11-27 06:25:42.000000000 +0100
++++ NVIDIA-Linux-x86_64-304.117-no-compat32/kernel/nv-acpi.c 2014-01-26 12:25:06.443610357 +0100
+@@ -15,6 +15,10 @@
+ #include "nv-linux.h"
+ #include "nv-reg.h"
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 13, 0) && defined(ACPI_HANDLE)
++#define DEVICE_ACPI_HANDLE(a) ACPI_HANDLE(a)
++#endif
++
+ #if defined(NV_LINUX_ACPI_EVENTS_SUPPORTED)
+
+ static int nv_acpi_add (struct acpi_device *);
+@@ -299,7 +303,10 @@
+
+ if (pNvAcpiObject->notify_handler_installed)
+ {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
++ /* beginning with 3.13, acpi_remove_notify_handler() waits for events to finish */
+ NV_ACPI_OS_WAIT_EVENTS_COMPLETE();
++#endif
+
+ // remove event notifier
+ status = acpi_remove_notify_handler(device->handle, ACPI_DEVICE_NOTIFY, nv_acpi_event);
More information about the arch-commits
mailing list