Created
September 20, 2013 22:27
-
-
Save freshhawk/6644767 to your computer and use it in GitHub Desktop.
Working PKGBUILD for nvidia-aufs_friendly with 3.11 kernel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Contributor : Thomas Baechler <thomas@archlinux.org> | |
# Maintainer : Daniel YC Lin <dlin.tw at gmail> | |
pkgname=nvidia-aufs_friendly | |
pkgver=325.15 | |
pkgrel=2 | |
_goodkver=3.11 | |
_badkver=3.12 | |
_extramodules=extramodules-${_goodkver}-aufs_friendly | |
pkgdesc="NVIDIA drivers for linux-aufs_friendly" | |
arch=('i686' 'x86_64') | |
url="http://www.nvidia.com/" | |
depends=("linux-aufs_friendly>=${_goodkver}" "linux-aufs_friendly<${_badkver}" "nvidia-libgl" "nvidia-utils=${pkgver}") | |
makedepends=("linux-aufs_friendly-headers>=${_goodkver}" "linux-aufs_friendly-headers<${_badkver}") | |
conflicts=('nvidia-96xx' 'nvidia-173xx' 'nvidia-304xx-aufs_friendly') | |
license=('custom') | |
install=nvidia.install | |
options=(!strip) | |
source=('nvidia-linux-3.11.patch') | |
md5sums=('6615840da025708edefb44a98c68f6f7') | |
if [ "$CARCH" = "i686" ]; then | |
_arch='x86' | |
_pkg="NVIDIA-Linux-${_arch}-${pkgver}" | |
source+=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run") | |
md5sums+=('528fc538584de6446384b9cec3099d6c') | |
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+=('63b2caa0cb128efa1a7808d7bddb2074') | |
fi | |
build() { | |
_kernver="$(cat /usr/lib/modules/${_extramodules}/version)" | |
cd "${srcdir}" | |
sh "${_pkg}.run" --extract-only | |
cd "${_pkg}/kernel" | |
patch -i "${srcdir}/nvidia-linux-3.11.patch" | |
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-aufs_friendly.conf" | |
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install" | |
gzip "${pkgdir}/usr/lib/modules/${_extramodules}/nvidia.ko" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment