Commit 0ccf314b authored by Phil's avatar Phil

linux-lts extra modules: bump to 3.0

parent 42d3bbfd
diff -uNr cat11.3/common/lib/modules/fglrx/build_mod/drmP.h build_mod2/drmP.h
--- cat11.3/common/lib/modules/fglrx/build_mod/drmP.h 2011-03-24 17:00:28.000000000 +0100
+++ cat11.3/common/lib/modules/fglrx/build_mod2/drmP.h 2011-03-30 04:23:15.000000000 +0200
@@ -57,7 +57,6 @@
#include <linux/pci.h>
#include <linux/version.h>
#include <linux/sched.h>
-#include <linux/smp_lock.h> /* For (un)lock_kernel */
#include <linux/mm.h>
#include <linux/pagemap.h>
#if defined(__alpha__) || defined(__powerpc__)
diff -uNr cat11.3/common/lib/modules/fglrx/build_mod/firegl_public.c build_mod2/firegl_public.c
--- cat11.3/common/lib/modules/fglrx/build_mod/firegl_public.c 2011-03-24 17:00:28.000000000 +0100
+++ cat11.3/common/lib/modules/fglrx/build_mod2/firegl_public.c 2011-03-30 04:32:59.773179890 +0200
@@ -114,7 +114,6 @@
#include <linux/pci.h>
#include <linux/wait.h>
#include <linux/miscdevice.h>
-#include <linux/smp_lock.h>
// newer SuSE kernels need this
#include <linux/highmem.h>
@@ -1042,9 +1041,6 @@
dev->pubdev.signature = FGL_DEVICE_SIGNATURE;
- for (i = 0; i < __KE_MAX_SPINLOCKS; i++)
- dev->spinlock[i] = SPIN_LOCK_UNLOCKED;
-
for (i=0; i < __KE_MAX_SEMAPHORES; i++)
sema_init(&dev->struct_sem[i], 1);
......@@ -4,33 +4,29 @@
# maintainer (i686): Phil Miller <philm[at]chakra-project[dog]org>
# maintainer (x86_64): Manuel Tortosa <manutortosa[at]chakra-project[dot]org>
# use ../makepkg -d
_kernver="2.6.35-CHAKRA-LTS"
# Find the kernel name inside the chroot
_extramodules=extramodules-`pacman -Q linux-lts | cut -c11-13 | sed 's/linux-lts //g'`-CHAKRA-LTS
_kver="$(cat /lib/modules/${_extramodules}/version)"
pkgname=catalyst-lts
pkgver=11.11
pkgrel=1
pkgdesc="AMD/ATI Catalyst drivers for kernel26. fglrx kernel module only"
pkgrel=2
pkgdesc="AMD/ATI Catalyst drivers for linux. fglrx kernel module only"
arch=('i686' 'x86_64')
url="http://www.ati.amd.com"
license=('custom')
depends=('linux-lts>=2.6.35' 'linux-lts<2.6.36' 'catalyst-utils')
makedepends=('gcc-libs' 'gcc>4.0.0' 'make' 'linux-lts-headers>=2.6.35' 'linux-lts-headers<2.6.36')
conflicts=('catalyst-test' 'nvidia' 'xf86-video-ati' 'xf86-video-radeonhd' 'ati-dri')
depends=('linux-lts>=3.0' 'linux-lts<3.1' 'catalyst-utils')
makedepends=('gcc-libs' 'gcc>4.0.0' 'make' 'linux-headers')
conflicts=('catalyst-test' 'nvidia-lts' 'xf86-video-ati' 'xf86-video-radeonhd' 'ati-dri')
install=catalyst.install
source=(http://www2.ati.com/drivers/linux/ati-driver-installer-${pkgver/./-}-x86.x86_64.run
ati_make.sh
makefile_compat.patch)
#no_bkl.patch
#2.6.39_bkl.patch)
md5sums=('7196077aacfbaf7234a705f5352a1111'
'660396540b0ceaff71d6155c986734de'
'3e1b82bd69774ea808da69c983d6a43b')
#'6a6b2133aa6ef3bcd377731b19c0553a'
#'eb24250f8e537273bae9dbd79a022d61')
......@@ -49,6 +45,7 @@ build() {
if [ "${CARCH}" = "x86_64" ]; then
BUILDARCH=x86_64
_archdir=x86_64
sed -i -e s'~COMPAT_ALLOC_USER_SPACE~arch_compat_alloc_user_space~' ${srcdir}/archive_files/common/lib/modules/fglrx/build_mod//kcl_ioctl.c
fi
if [ "${CARCH}" = "i686" ]; then
BUILDARCH=i386
......@@ -57,45 +54,36 @@ build() {
cd "${srcdir}/archive_files/"
msg "Applying patch(es) ..."
## makefile patch to choose arch_compat_alloc_user_space or older compat_alloc_user_space
## works only in combination with ati_make.sh script
patch -Np1 -i ../makefile_compat.patch || return 1
# if [[ ${_kernver:0:6} < "2.6.39" ]] && [[ `cat /lib/modules/${_kernver}/build/.config | grep -c CONFIG_BKL=y` = 0 ]]; then
# patch -Np1 -i ../no_bkl.patch || return 1
# fi
patch -Np1 -i ../makefile_compat.patch
# if [[ ${_kernver:0:6} == "2.6.39" ]] || [[ ${_kernver:0:6} > "2.6.39" ]]; then
# patch -Np1 -i ../no_bkl.patch || return 1
# #patch -Np1 -i ../2.6.39_bkl.patch || return 1
# fi
# if [[ ${_kernver:0:6} == "2.6.37" ]] || [[ ${_kernver:0:6} > "2.6.37" ]]; then
# patch -Np1 -i ../sema_init.patch || return 1
# fi
#if [[ ${_kver:0:6} < "2.6.39" ]] && [[ `cat /lib/modules/${_kver}/build/.config | grep -c CONFIG_BKL=y` = 0 ]]; then
# patch -Np1 -i ../no_bkl.patch
#fi
cd "${srcdir}/archive_files/common/lib/modules/fglrx/build_mod"
cp "${srcdir}/archive_files/arch/${_archdir}/lib/modules/fglrx/build_mod/libfglrx_ip.a" . || return 1
cp 2.6.x/Makefile . || return 1
cp "${srcdir}/archive_files/arch/${_archdir}/lib/modules/fglrx/build_mod/libfglrx_ip.a" .
cp 2.6.x/Makefile .
msg "Compiling fglrx module ..."
## Compile module using _ati_check variables
make -C /lib/modules/${_kernver}/build SUBDIRS="`pwd`" ARCH=${BUILDARCH} \
make -C /lib/modules/${_kver}/build SUBDIRS="`pwd`" ARCH=${BUILDARCH} \
MODFLAGS="-DMODULE -DATI -DFGL -DPAGE_ATTR_FIX=$PAGE_ATTR_FIX -DCOMPAT_ALLOC_USER_SPACE=$COMPAT_ALLOC_USER_SPACE $def_smp $def_modversions" \
PAGE_ATTR_FIX=$PAGE_ATTR_FIX COMPAT_ALLOC_USER_SPACE=$COMPAT_ALLOC_USER_SPACE modules || return 1
PAGE_ATTR_FIX=$PAGE_ATTR_FIX COMPAT_ALLOC_USER_SPACE=$COMPAT_ALLOC_USER_SPACE modules
}
package() {
cd "${srcdir}/archive_files/common/lib/modules/fglrx/build_mod"
install -m755 -d "${pkgdir}/lib/modules/${_kernver}/video/" || return 1
install -m644 fglrx.ko "${pkgdir}/lib/modules/${_kernver}/video/" || return 1
install -m755 -d "${pkgdir}/lib/modules/${_extramodules}"
install -m644 fglrx.ko "${pkgdir}/lib/modules/${_extramodules}"
gzip "${pkgdir}/lib/modules/${_extramodules}/fglrx.ko"
## License
## License
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
install -m644 "${srcdir}/archive_files/LICENSE.TXT" "${pkgdir}/usr/share/licenses/${pkgname}/" || return 1
install -m644 "${srcdir}/archive_files/LICENSE.TXT" "${pkgdir}/usr/share/licenses/${pkgname}/"
sed -i -e "s/KERNEL_VERSION=.*/KERNEL_VERSION=${_kernver}/" $startdir/*.install
}
\ No newline at end of file
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" ${startdir}/*.install
}
KERNEL_VERSION=2.6.35-CHAKRA-LTS
whisperer(){
echo "----------------------------------------------------------------"
echo "For more info and more troubleshooting visit:"
echo "http://wiki.archlinux.org/index.php/ATI_Catalyst"
echo "----------------------------------------------------------------"
echo ""
echo "--------------------------- == * == ----------------------------"
echo "catalyst package has been splited between:"
echo "- catalyst (module for stock kernel)"
echo "- catalyst-utils (libs and stuff)"
echo ""
echo "and optional:"
echo "- catalyst-hook (auto rebuilding script and source files)"
echo "- catalyst-daemon (auto rebuilding script and source files)"
echo "- catalyst-generator (generator of catalyst-{kernver} packages)"
echo "----------------------------------------------------------------"
}
remove_hook(){
##removing hook's entries
# remove hook fglrx
sed '/^HOOKS/s/ *fglrx//' -i etc/mkinitcpio.conf
# remove heads
sed '/^SyncFirst/s/ *kernel26-headers//' -i etc/pacman.conf
sed '/^SyncFirst/s/ *linux-lts-headers//' -i etc/pacman.conf
}
post_install() {
depmod $KERNEL_VERSION
whisperer
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
post_upgrade() {
remove_hook
depmod $KERNEL_VERSION
whisperer
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
post_remove() {
depmod $KERNEL_VERSION
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
echo "----------------------------------------------------------------"
echo "Don't forget to remove fglrx from MODULES array of /etc/rc.conf"
echo "----------------------------------------------------------------"
}
......@@ -4,41 +4,56 @@
# maintainer (i686): Phil Miller <philm[at]chakra-project[dog]org>
# maintainer (x86_64): Manuel Tortosa <manutortosa[at]chakra-project[dot]org>
# use ../makepkg
_kernver="2.6.35-CHAKRA-LTS"
# include global config
source ../_buildscripts/${current_repo}-${_arch}-cfg.conf
# Find the kernel name inside the chroot
_extramodules=extramodules-`pacman -Q linux-lts | cut -c11-13 | sed 's/linux-lts //g'`-CHAKRA-LTS
_kver="$(cat /lib/modules/${_extramodules}/version)"
pkgname=madwifi-lts
pkgver=0.9.4.4173
_ver=0.9.4-r4173-20111008
pkgrel=1
pkgdesc="Madwifi drivers for Atheros wireless chipsets. For kernel26"
pkgrel=2
pkgdesc="Madwifi drivers for Atheros wireless chipsets"
arch=(i686 x86_64)
license=('GPL')
url="http://madwifi-project.org"
depends=('madwifi-utils' 'kernel26-lts>=2.6.35' 'kernel26-lts<2.6.36')
makedepends=('kernel26-lts-headers>=2.6.35' 'kernel26-lts-headers<2.6.36' 'sharutils')
depends=('madwifi-utils' 'linux-lts>=3.0' 'linux-lts<3.1')
makedepends=('linux-lts-headers' 'sharutils')
install=madwifi-ng.install
# subversion source: svn checkout http:/madwifi-project.org/svn/madwifi/trunk madwifi
source=(http://chakra.sourceforge.net/sources/madwifi/madwifi-${pkgver}.tar.gz
#http://downloads.sourceforge.net/madwifi/madwifi-${pkgver}.tar.gz
)
groups=("kernel26-lts-modules")
build() {
[ "${CARCH}" = "i686" ] && export ARCH=i386
#cd $startdir/src/madwifi-$pkgver
cd $startdir/src/madwifi-$_ver
sed -i -e 's/-Werror//g' Makefile.inc
make KERNELPATH=/lib/modules/$_kernver/build KERNELRELEASE=$_kernver modules|| return 1
make KERNELPATH=/lib/modules/$_kernver/build KERNELRELEASE=$_kernver modules \
DESTDIR=$startdir/pkg KERNELRELEASE=$_kernver install-modules
sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='${_kernver}'/" $startdir/*.install
# install to wireless kernel directory
mkdir -p $startdir/pkg/lib/modules/$_kernver/kernel/drivers/net/wireless/madwifi
mv $startdir/pkg/lib/modules/$_kernver/net/* $startdir/pkg/lib/modules/$_kernver/kernel/drivers/net/wireless/madwifi
rm -r $startdir/pkg/lib/modules/$_kernver/net/
groups=("linux-lts-modules")
conflicts=("madwifi")
replaces=("madwifi")
build()
{
cd madwifi-$_ver
# kernel 3.2 abi change
sed -i -e "s/.ndo_set_multicast_list/.ndo_set_rx_mode/" ath/if_ath.c
sed -i -e "s/ieee80211_set_multicast_list/ieee80211_set_rx_mode/" net80211/ieee80211.c
sed -i -e "s/ndo_set_multicast_list/ndo_set_rx_mode/" net80211/ieee80211.c
sed -i 's/-Werror//' Makefile.inc
sed -i 's/\[4-9\]\\\./[0-9]-/' Makefile
make KERNELPATH=/lib/modules/${_kver}/build KERNELRELEASE=${_kver} modules
}
package()
{
cd madwifi-$_ver
make KERNELPATH=/lib/modules/${_kver}/build KERNELRELEASE=${_kver} modules \
DESTDIR="${pkgdir}" KERNELRELEASE=${_kver} install-modules
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" ${startdir}/*.install
mkdir -p "${pkgdir}/lib/modules/$_extramodules"
mv "${pkgdir}"/lib/modules/${_kver}/net/* "${pkgdir}/lib/modules/$_extramodules"
rm -r "${pkgdir}"/lib/modules/${_kver}
find "${pkgdir}" -name '*.ko' -exec gzip -9 {} \;
}
md5sums=('18cd1c574e0fa66eb4396f92f0700a7e')
--- ath/if_athvar.h~ 2009-06-13 09:38:53.000000000 +0200
+++ ath/if_athvar.h 2009-06-13 09:38:53.000000000 +0200
@@ -103,11 +103,6 @@
/*
* Guess how the interrupt handler should work.
*/
-#if !defined(IRQ_NONE)
-typedef void irqreturn_t;
-#define IRQ_NONE
-#define IRQ_HANDLED
-#endif /* !defined(IRQ_NONE) */
#ifndef SET_MODULE_OWNER
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,23)
post_install() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod -ae $KERNEL_VERSION > /dev/null 2>&1
post_install()
{
post_upgrade
}
post_upgrade() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod -ae $KERNEL_VERSION > /dev/null 2>&1
post_upgrade()
{
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
post_remove() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod -ae $KERNEL_VERSION > /dev/null 2>&1
post_remove()
{
post_upgrade
}
--- nv.c.orig 2010-10-23 10:41:00.433000009 +0200
+++ nv.c 2010-10-23 10:43:54.983000023 +0200
@@ -249,7 +249,11 @@ static struct pci_driver nv_pci_driver =
static struct file_operations nv_fops = {
.owner = THIS_MODULE,
.poll = nv_kern_poll,
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36)
+ .unlocked_ioctl = nv_kern_unlocked_ioctl,
+#else
.ioctl = nv_kern_ioctl,
+#endif
#if defined(HAVE_UNLOCKED_IOCTL)
.unlocked_ioctl = nv_kern_unlocked_ioctl,
#endif
......@@ -4,20 +4,20 @@
# maintainer (i686): Phil Miller <philm[at]chakra-project[dog]org>
# maintainer (x86_64): Manuel Tortosa <manutortosa[at]chakra-project[dot]org>
# use ../makepkg -d
_kernver="2.6.35-CHAKRA-LTS"
# Find the kernel name inside the chroot
_extramodules=extramodules-`pacman -Q linux-lts | cut -c11-13 | sed 's/linux-lts //g'`-CHAKRA-LTS
_kver="$(cat /lib/modules/${_extramodules}/version)"
pkgname=nvidia-173xx-lts
pkgver=173.14.31
pkgrel=1
pkgdesc="NVIDIA drivers for kernel26, 173xx branch."
pkgrel=2
arch=('i686' 'x86_64')
[ "$CARCH" = "i686" ] && ARCH=x86
[ "$CARCH" = "x86_64" ] && ARCH=x86_64
url="http://www.nvidia.com/"
depends=('kernel26-lts' 'nvidia-173xx-utils')
makedepends=('kernel26-lts-headers')
conflicts=('nvidia-96xx' 'nvidia' 'nvidia-173xx')
depends=('linux-lts>=3.0' 'linux-lts<3.1' 'nvidia-173xx-utils')
makedepends=('linux-lts-headers')
conflicts=('nvidia-96xx-lts' 'nvidia-lts')
license=('custom')
install=nvidia.install
source=("http://download.nvidia.com/XFree86/Linux-$ARCH/${pkgver}/NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run")
......@@ -25,20 +25,18 @@ md5sums=('01cd3b91196cd4495f56c34494f310b5')
[ "$CARCH" = "x86_64" ] && md5sums=('d53e8faf8ac90ad98b8998f25f121535')
build() {
cd $srcdir
sh NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run --extract-only
cd NVIDIA-Linux-$ARCH-${pkgver}-pkg0
cd usr/src/nv/
ln -s Makefile.kbuild Makefile
make SYSSRC=/lib/modules/${_kernver}/build module || return 1
sh "NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run" --extract-only
cd "NVIDIA-Linux-$ARCH-${pkgver}-pkg0/usr/src/nv/"
ln -s Makefile.kbuild Makefile
make SYSSRC=/lib/modules/${_kver}/build module || return 1
}
package() {
cd $srcdir/NVIDIA-Linux-$ARCH-${pkgver}-pkg0/usr/src/nv/
mkdir -p $pkgdir/lib/modules/${_kernver}/kernel/drivers/video/
install -m644 nvidia.ko $pkgdir/lib/modules/${_kernver}/kernel/drivers/video/
mkdir -p $pkgdir/etc/modprobe.d
echo "blacklist nouveau" >> $pkgdir/etc/modprobe.d/nouveau_blacklist.conf || return 1
sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='${_kernver}'/" $startdir/nvidia.install
cd "NVIDIA-Linux-$ARCH-${pkgver}-pkg0/usr/src/nv/"
mkdir -p $pkgdir//lib/modules/${_extramodules}
install -m644 nvidia.ko $pkgdir/lib/modules/${_extramodules}
install -d -m755 "${pkgdir}/etc/modprobe.d"
echo "blacklist nouveau" >> "${pkgdir}/etc/modprobe.d/nouveau_blacklist.conf"
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
gzip "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"
}
post_install() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod $KERNEL_VERSION
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
echo 'In order to use nvidia module, reboot the system.'
}
post_upgrade() {
post_install
rmmod nvidia || echo 'In order to use the new nvidia module, exit Xserver and unload it manually.'
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
post_remove() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod $KERNEL_VERSION
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
......@@ -4,22 +4,20 @@
# maintainer (i686): Phil Miller <philm[at]chakra-project[dog]org>
# maintainer (x86_64): Manuel Tortosa <manutortosa[at]chakra-project[dot]org>
# include global config
source ../_buildscripts/${current_repo}-${_arch}-cfg.conf
# use ../makepkg -d
_kernver="2.6.35-CHAKRA-LTS"
# Find the kernel name inside the chroot
_extramodules=extramodules-`pacman -Q linux-lts | cut -c11-13 | sed 's/linux-lts //g'`-CHAKRA-LTS
_kver="$(cat /lib/modules/${_extramodules}/version)"
pkgname=nvidia-96xx-lts
pkgver=96.43.20
pkgrel=1
pkgrel=2
pkgdesc="NVIDIA drivers for kernel26, 96xx branch."
arch=('i686' 'x86_64')
[ "$CARCH" = "i686" ] && ARCH=x86
[ "$CARCH" = "x86_64" ] && ARCH=x86_64
url="http://www.nvidia.com/"
depends=('kernel26-lts>=2.6.35' 'kernel26-lts<2.6.36' 'nvidia-96xx-utils')
makedepends=('kernel26-lts-headers>=2.6.35' 'kernel26-lts-headers<2.6.36')
depends=('linux-lts>=3.0' 'linux-lts<3.1' 'nvidia-96xx-utils')
makedepends=('linux-lts-headers')
conflicts=('nvidia-lts' 'nvidia-173xx-lts')
license=('custom')
install=nvidia.install
......@@ -28,15 +26,18 @@ md5sums=('875cc011385ea26ab5edd54a9b65a003')
[ "$CARCH" = "x86_64" ] && md5sums=('df3c87005487bdf54a6c5b783ff373db')
build() {
cd $srcdir
sh NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run --extract-only
cd NVIDIA-Linux-$ARCH-${pkgver}-pkg0
cd usr/src/nv/
ln -s Makefile.kbuild Makefile
make SYSSRC=/lib/modules/${_kernver}/build module || return 1
mkdir -p $pkgdir/lib/modules/${_kernver}/kernel/drivers/video/
install -m644 nvidia.ko $pkgdir/lib/modules/${_kernver}/kernel/drivers/video/
sh "NVIDIA-Linux-$ARCH-${pkgver}-pkg0.run" --extract-only
cd "NVIDIA-Linux-$ARCH-${pkgver}-pkg0/usr/src/nv/"
ln -s Makefile.kbuild Makefile
make SYSSRC=/lib/modules/${_kver}/build module
}
sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='${_kernver}'/" $startdir/nvidia.install
package() {
cd "NVIDIA-Linux-$ARCH-${pkgver}-pkg0/usr/src/nv/"
mkdir -p $pkgdir//lib/modules/${_extramodules}
install -m644 nvidia.ko $pkgdir/lib/modules/${_extramodules}
install -d -m755 "${pkgdir}/etc/modprobe.d"
echo "blacklist nouveau" >> "${pkgdir}/etc/modprobe.d/nouveau_blacklist.conf"
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
gzip "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"
}
post_install() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod $KERNEL_VERSION
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
echo 'In order to use nvidia module, reboot the system.'
}
post_upgrade() {
post_install
rmmod nvidia || echo 'In order to use the new nvidia module, exit Xserver and unload it manually.'
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
post_remove() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod $KERNEL_VERSION
}
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
\ No newline at end of file
......@@ -4,17 +4,18 @@
# maintainer (i686): Phil Miller <philm[at]chakra-project[dog]org>
# maintainer (x86_64): Manuel Tortosa <manutortosa[at]chakra-project[dot]org>
# use ../makepkg -d
_kernver="2.6.35-CHAKRA-LTS"
# Find the kernel name inside the chroot
_extramodules=extramodules-`pacman -Q linux-lts | cut -c11-13 | sed 's/linux-lts //g'`-CHAKRA-LTS
_kver="$(cat /lib/modules/${_extramodules}/version)"
pkgname=nvidia-lts
pkgver=295.20
pkgrel=1
pkgdesc="NVIDIA drivers for kernel26."
pkgrel=2
pkgdesc="NVIDIA drivers for linux."
arch=('i686' 'x86_64')
url="http://www.nvidia.com/"
depends=('kernel26-lts>=2.6.35' 'kernel26-lts<2.6.36' "nvidia-utils=${pkgver}")
makedepends=('kernel26-lts-headers>=2.6.35' 'kernel26-lts-headers<2.6.36')
depends=('linux-lts>=3.0' 'linux-lts<3.1' "nvidia-utils=${pkgver}")
makedepends=('linux-lts-headers')
conflicts=('nvidia-96xx-lts' 'nvidia-173xx-lts')
license=('custom')
install=nvidia.install
......@@ -32,15 +33,17 @@ elif [ "$CARCH" = "x86_64" ]; then
fi
build() {
cd $srcdir
sh ${_pkg}.run --extract-only
cd ${_pkg}/kernel
make SYSSRC=/lib/modules/${_kernver}/build module
cd "${srcdir}"
sh "${_pkg}.run" --extract-only
cd "${_pkg}/kernel"
make SYSSRC=/lib/modules/"${_kver}/build" module
}
package() {
install -D -m644 $srcdir/${_pkg}/kernel/nvidia.ko \
$pkgdir/lib/modules/${_kernver}/kernel/drivers/video/nvidia.ko
install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
"${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"
install -d -m755 "${pkgdir}/etc/modprobe.d"
echo "blacklist nouveau" >> "${pkgdir}/etc/modprobe.d/nouveau_blacklist.conf"
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
gzip "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"
}
post_install() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod $KERNEL_VERSION
mkdir -p /etc/modprobe.d
echo "blacklist nouveau" > /etc/modprobe.d/nouveau_blacklist.conf
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
echo 'In order to use nvidia module, reboot the system.'
}
post_upgrade() {
post_install
rmmod nvidia || echo 'In order to use the new nvidia module, exit Xserver and unload it manually.'
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
post_remove() {
KERNEL_VERSION='2.6.35-CHAKRA-LTS'
depmod $KERNEL_VERSION
EXTRAMODULES='extramodules-3.0-CHAKRA-LTS'
depmod $(cat /lib/modules/$EXTRAMODULES/version)
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment