diff options
author | Martin Schlemmer <azarah@gentoo.org> | 2003-05-26 20:13:39 +0000 |
---|---|---|
committer | Martin Schlemmer <azarah@gentoo.org> | 2003-05-26 20:13:39 +0000 |
commit | 79a5c05785c03bbb25876f4952a13e857fdc7233 (patch) | |
tree | f742c9e306a2348400a0a36171a04a1ff7fb0de3 /media-video | |
parent | 2.5 patch (diff) | |
download | gentoo-2-79a5c05785c03bbb25876f4952a13e857fdc7233.tar.gz gentoo-2-79a5c05785c03bbb25876f4952a13e857fdc7233.tar.bz2 gentoo-2-79a5c05785c03bbb25876f4952a13e857fdc7233.zip |
2.5 patch
Diffstat (limited to 'media-video')
5 files changed, 210 insertions, 3 deletions
diff --git a/media-video/nvidia-kernel/ChangeLog b/media-video/nvidia-kernel/ChangeLog index 76221ed7cd81..790c07ba5a85 100644 --- a/media-video/nvidia-kernel/ChangeLog +++ b/media-video/nvidia-kernel/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for media-video/nvidia-kernel # Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/nvidia-kernel/ChangeLog,v 1.32 2003/05/13 20:53:38 azarah Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-video/nvidia-kernel/ChangeLog,v 1.33 2003/05/26 20:11:32 azarah Exp $ + +*nvidia-kernel-1.0.4363-r2 (26 May 2003) + + 26 May 2003; Martin Schlemmer <azarah@gentoo.org> + nvidia-kernel-1.0.4363-r2.ebuild, + files/1.0.4363/NVIDIA_kernel-1.0-4363-2.5.69-agp.diff: + Another patch for 2.5 kernels. *nvidia-kernel-1.0.4363-r1 (13 May 2003) diff --git a/media-video/nvidia-kernel/Manifest b/media-video/nvidia-kernel/Manifest index 8fc1de81d090..a20c3b335f1d 100644 --- a/media-video/nvidia-kernel/Manifest +++ b/media-video/nvidia-kernel/Manifest @@ -1,4 +1,4 @@ -MD5 61ba695d5ddcca227d668659b886cb1c ChangeLog 6634 +MD5 72b5c30956287e008e275335251c3854 ChangeLog 6855 MD5 04b1f361d40708ab81631bea5e46a632 nvidia-kernel-1.0.2880-r1.ebuild 1970 MD5 5177ed76121fb4bc1aa220c62319d196 nvidia-kernel-1.0.2960-r1.ebuild 2081 MD5 16a9003f79bea31eeec6f03ae64cd8ef nvidia-kernel-1.0.3123-r2.ebuild 3229 @@ -7,7 +7,8 @@ MD5 e64884b31959fdf80e8abc6016f63e34 nvidia-kernel-1.0.4349-r1.ebuild 4219 MD5 0646bd1f1f1109063862d1475aaccab4 nvidia-kernel-1.0.4349-r2.ebuild 3702 MD5 10e07a6ec08e11dab21341ae06788e78 nvidia-kernel-1.0.4349.ebuild 4201 MD5 60d9b36f0373c43f7942c7dcc942350b nvidia-kernel-1.0.4363.ebuild 4104 -MD5 627b40fb7eac1e0f41a60d8ebbb63976 nvidia-kernel-1.0.4363-r2.ebuild 4600 +MD5 639f1a1337e47fa10bc02eabf32404ef nvidia-kernel-1.0.4363-r2.ebuild 4600 +MD5 fb0098fb2f158b1633237ad1e18bdb8f nvidia-kernel-1.0.4363-r1.ebuild 4364 MD5 441b29e8f10b6620c4dd4fc01528f172 files/NVIDIA_kernel-1.0-3123-2.5-module.diff 5569 MD5 4057597a09dd795c93ce8088d6f023bb files/NVIDIA_kernel-1.0-3123-2.5-tl-pa.diff 11858 MD5 059b3ddf8944dce6c9184d11d15abd71 files/NVIDIA_kernel-1.0-3123-2.5-tl.diff 31614 diff --git a/media-video/nvidia-kernel/files/1.0.4363/NVIDIA_kernel-1.0-4363-2.5.69-agp.diff b/media-video/nvidia-kernel/files/1.0.4363/NVIDIA_kernel-1.0-4363-2.5.69-agp.diff new file mode 100644 index 000000000000..5a2aa0dbe9e8 --- /dev/null +++ b/media-video/nvidia-kernel/files/1.0.4363/NVIDIA_kernel-1.0-4363-2.5.69-agp.diff @@ -0,0 +1,48 @@ +diff -urN NVIDIA_kernel-1.0-4363.orig/os-agp.c NVIDIA_kernel-1.0-4363/os-agp.c +--- NVIDIA_kernel-1.0-4363.orig/os-agp.c 2003-05-26 20:03:59.000000000 +0200 ++++ NVIDIA_kernel-1.0-4363/os-agp.c 2003-05-26 20:03:25.000000000 +0200 +@@ -28,7 +28,7 @@ + #ifdef AGPGART + + typedef struct { +- agp_memory *ptr; ++ struct agp_memory *ptr; + int num_pages; + int offset; + #if defined(NVCPU_IA64) +@@ -45,7 +45,7 @@ + int ready; + } agp_gart; + +-agp_kern_info agpinfo; ++struct agp_kern_info agpinfo; + agp_gart gart; + const drm_agp_t *drm_agp_p; + +@@ -260,7 +260,7 @@ + *pAddress = (void*) 0; + return RM_ERROR; + #else +- agp_memory *ptr; ++ struct agp_memory *ptr; + int err; + agp_priv_data *data; + RM_STATUS status; +@@ -388,7 +388,7 @@ + #else + struct vm_area_struct *vma = (struct vm_area_struct *) pvma; + agp_priv_data *agp_data = (agp_priv_data *) priv_data; +- agp_memory *agp_memory_ptr = agp_data->ptr; ++ struct agp_memory *agp_memory_ptr = agp_data->ptr; + struct page *page_ptr; + unsigned long phys_addr; + int idx; +@@ -431,7 +431,7 @@ + #ifndef AGPGART + return RM_OK; + #else +- agp_memory *ptr; ++ struct agp_memory *ptr; + agp_priv_data *data = priv_data; + + #if defined(NVCPU_IA64) && (LINUX_VERSION_CODE < KERNEL_VERSION(2, 4, 9)) diff --git a/media-video/nvidia-kernel/files/digest-nvidia-kernel-1.0.4363-r2 b/media-video/nvidia-kernel/files/digest-nvidia-kernel-1.0.4363-r2 new file mode 100644 index 000000000000..b1f93afc2136 --- /dev/null +++ b/media-video/nvidia-kernel/files/digest-nvidia-kernel-1.0.4363-r2 @@ -0,0 +1 @@ +MD5 29b4cfcff63f502787fd2f0ac7a105fd NVIDIA_kernel-1.0-4363.tar.gz 661447 diff --git a/media-video/nvidia-kernel/nvidia-kernel-1.0.4363-r2.ebuild b/media-video/nvidia-kernel/nvidia-kernel-1.0.4363-r2.ebuild new file mode 100644 index 000000000000..777503044966 --- /dev/null +++ b/media-video/nvidia-kernel/nvidia-kernel-1.0.4363-r2.ebuild @@ -0,0 +1,150 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-video/nvidia-kernel/nvidia-kernel-1.0.4363-r2.ebuild,v 1.1 2003/05/26 20:11:32 azarah Exp $ + +inherit eutils + +# Make sure Portage does _NOT_ strip symbols. Need both lines for +# Portage 1.8.9+ +DEBUGBUILD="yes" +RESTRICT="nostrip" + +NV_V="${PV/1.0./1.0-}" +NV_PACKAGE="NVIDIA_kernel-${NV_V}" +S="${WORKDIR}/${NV_PACKAGE}" +DESCRIPTION="Linux kernel module for the NVIDIA's X driver" +SRC_URI="ftp://download.nvidia.com/XFree86/Linux-x86/${NV_V}/${NV_PACKAGE}.tar.gz" +HOMEPAGE="http://www.nvidia.com/" + +# The slow needs to be set to $KV to prevent unmerges of +# modules for other kernels. +LICENSE="NVIDIA" +SLOT="${KV}" +KEYWORDS="~x86 -ppc -sparc -alpha -hppa -mips -arm" + +DEPEND="virtual/linux-sources + >=sys-apps/portage-1.9.10" +RDEPEND=${DEPEND} +IUSE="" + +pkg_setup() { + if [ ! -f /proc/mtrr ] + then + eerror "This version needs MTRR support for most chipsets!" + eerror "Please enable MTRR support in your kernel config, found at:" + eerror + eerror " Processor type and features -> [*] MTRR (Memory Type Range Register) support" + eerror + eerror "and recompile your kernel ..." + die "MTRR support not detected!" + fi + + if [ ! -f "${ROOT}/usr/src/linux/include/linux/version.h" ] + then + eerror "Please verify that your /usr/src/linux symlink is pointing" + eerror "to your current kernel sources, and that you did run:" + eerror + eerror " # make dep" + die "/usr/src/linux symlink not setup!" + fi +} + +src_unpack() { + unpack ${A} + + # Next section applies patches for linux-2.5 kernel, and/or + # bugfixes for linux-2.4. All these are from: + # + # http://www.minion.de/nvidia/ + # + # Many thanks to Christian Zander <zander@minion.de> for bringing + # these to us, and being so helpful to select which to use. + + # Get the kernel version of sources in /usr/src/linux ... + local KV_full="$(awk '/UTS_RELEASE/ { gsub("\"", "", $3); print $3 }' \ + "${ROOT}/usr/src/linux/include/linux/version.h")" + local KV_major="$(echo "${KV_full}" | cut -d. -f1)" + local KV_minor="$(echo "${KV_full}" | cut -d. -f2)" + local KV_micro="$(echo "${KV_full}" | cut -d. -f3 | sed -e 's:[^0-9].*::')" + + cd ${S} + einfo "Linux kernel ${KV_major}.${KV_minor}.${KV_micro}" + if [ "${KV_major}" -eq 2 -a "${KV_minor}" -eq 5 ] + then + EPATCH_SINGLE_MSG="Applying tasklet patch for kernel 2.5..." \ + epatch ${FILESDIR}/${PV}/${NV_PACKAGE}-2.5-20030424.diff + + if [ "${KV_micro}" -ge 68 ] && \ + [ -n "`grep irqreturn_t /usr/src/linux/include/linux/interrupt.h`" ] + then + EPATCH_SINGLE_MSG="Applying patch for devfs/irq changes in 2.5.68+..." \ + epatch ${FILESDIR}/${PV}/${NV_PACKAGE}-2.5.68.diff + fi + + if [ "${KV_micro}" -ge 69 ] + then + if [ -z "`grep devfs_handle_t /usr/src/linux/include/linux/devfs_fs_kernel.h`" ] + then + EPATCH_SINGLE_MSG="Applying patch for devfs changes in 2.5.69+..." \ + epatch ${FILESDIR}/${PV}/${NV_PACKAGE}-2.5.69.diff + fi + if [ -n "`grep "struct agp_memory" /usr/src/linux/drivers/char/agp/agp.h`" ] + then + EPATCH_SINGLE_MSG="Applying patch for agp changes in 2.5.69+..." \ + epatch ${FILESDIR}/${PV}/${NV_PACKAGE}-2.5.69-agp.diff + fi + fi + + # Some problems with kbuild one .. + ln -s Makefile.nvidia Makefile + fi +} + +src_compile() { + # Portage should determine the version of the kernel sources + check_KV + # IGNORE_CC_MISMATCH disables a sanity check that's needed when gcc has been + # updated but the running kernel is still compiled with an older gcc. This is + # needed for chrooted building, where the sanity check detects the gcc of the + # kernel outside the chroot rather than within. + make IGNORE_CC_MISMATCH="yes" KERNDIR="/usr/src/linux" \ + clean nvidia.o || die +} + +src_install() { + # The driver goes into the standard modules location + insinto /lib/modules/${KV}/video + doins nvidia.o + + # Add the aliases + insinto /etc/modules.d + newins ${FILESDIR}/nvidia-1.1 nvidia + + # Docs + dodoc ${S}/README + + # The device creation script + into / + newsbin ${S}/makedevices.sh NVmakedevices.sh +} + +pkg_postinst() { + if [ "${ROOT}" = "/" ] + then + # Update module dependency + [ -x /usr/sbin/update-modules ] && /usr/sbin/update-modules + if [ ! -e /dev/.devfsd ] && [ -x /sbin/NVmakedevices.sh ] + then + /sbin/NVmakedevices.sh >/dev/null 2>&1 + fi + fi + + echo + einfo "If you are not using devfs, loading the module automatically at" + einfo "boot up, you need to add \"nvidia\" to your /etc/modules.autoload." + echo + ewarn "Please note that the driver name changed from \"NVdriver\"" + ewarn "to \"nvidia.o\"." + echo +} + |