summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Johanson <latexer@gentoo.org>2004-03-06 23:44:20 +0000
committerPeter Johanson <latexer@gentoo.org>2004-03-06 23:44:20 +0000
commitcb3e4236d5df7b946651e2fdb06c63d8b49fdfd4 (patch)
tree5d28386b5c7e9833e4e263802703821f74c3e749 /net-wireless
parentgcc-2.x patch (diff)
downloadgentoo-2-cb3e4236d5df7b946651e2fdb06c63d8b49fdfd4.tar.gz
gentoo-2-cb3e4236d5df7b946651e2fdb06c63d8b49fdfd4.tar.bz2
gentoo-2-cb3e4236d5df7b946651e2fdb06c63d8b49fdfd4.zip
Adding 0.3 for kernel version < 2.4.23
Diffstat (limited to 'net-wireless')
-rw-r--r--net-wireless/ndiswrapper/ChangeLog7
-rw-r--r--net-wireless/ndiswrapper/Manifest2
-rw-r--r--net-wireless/ndiswrapper/files/digest-ndiswrapper-0.31
-rw-r--r--net-wireless/ndiswrapper/ndiswrapper-0.3.ebuild103
4 files changed, 112 insertions, 1 deletions
diff --git a/net-wireless/ndiswrapper/ChangeLog b/net-wireless/ndiswrapper/ChangeLog
index f60b5bafa694..412855485656 100644
--- a/net-wireless/ndiswrapper/ChangeLog
+++ b/net-wireless/ndiswrapper/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for net-wireless/ndiswrapper
# Copyright 2000-2004 Gentoo Technologies, Inc.; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-wireless/ndiswrapper/ChangeLog,v 1.1 2004/02/29 04:21:59 latexer Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-wireless/ndiswrapper/ChangeLog,v 1.2 2004/03/06 23:44:20 latexer Exp $
+
+*ndiswrapper-0.3 (06 Mar 2004)
+
+ 06 Mar 2004; Peter Johanson <latexer@gentoo.org> ndiswrapper-0.3.ebuild:
+ Adding version 0.3 for older kernels as 0.4 won't work with them.
*ndiswrapper-0.4 (28 Feb 2004)
diff --git a/net-wireless/ndiswrapper/Manifest b/net-wireless/ndiswrapper/Manifest
index b5f442d74805..0aa4c91ed6ad 100644
--- a/net-wireless/ndiswrapper/Manifest
+++ b/net-wireless/ndiswrapper/Manifest
@@ -1,5 +1,7 @@
MD5 49de1b07262dfa906a9225eae866b418 ndiswrapper-0.4.ebuild 2922
+MD5 49150c270cb1157152f7988f1ee07f7b ndiswrapper-0.3.ebuild 2856
MD5 33114f1343dfde1cc3d07c3e7052053f ChangeLog 566
MD5 0dfb45e6e16bf37b171169afca958121 metadata.xml 429
+MD5 d5bd4c071015eef1d33281dd95f668e7 files/digest-ndiswrapper-0.3 66
MD5 922f4572dd8899c80920a0aea4485be9 files/digest-ndiswrapper-0.4 66
MD5 f27b456e9b1d79f449548aa305378312 files/ndiswrapper.modules.d 379
diff --git a/net-wireless/ndiswrapper/files/digest-ndiswrapper-0.3 b/net-wireless/ndiswrapper/files/digest-ndiswrapper-0.3
new file mode 100644
index 000000000000..f7e489e2c78d
--- /dev/null
+++ b/net-wireless/ndiswrapper/files/digest-ndiswrapper-0.3
@@ -0,0 +1 @@
+MD5 7e05371f986f934f9a664a6a645f74ce ndiswrapper-0.3.tar.gz 38364
diff --git a/net-wireless/ndiswrapper/ndiswrapper-0.3.ebuild b/net-wireless/ndiswrapper/ndiswrapper-0.3.ebuild
new file mode 100644
index 000000000000..86e95cbfe6a2
--- /dev/null
+++ b/net-wireless/ndiswrapper/ndiswrapper-0.3.ebuild
@@ -0,0 +1,103 @@
+# Copyright 1999-2004 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-wireless/ndiswrapper/ndiswrapper-0.3.ebuild,v 1.1 2004/03/06 23:44:20 latexer Exp $
+
+inherit kernel-mod
+
+S=${WORKDIR}/${PN}
+DESCRIPTION="Wrapper for using Windows drivers for some wireless cards"
+HOMEPAGE="http://ndiswrapper.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~x86"
+IUSE=""
+DEPEND="sys-devel/flex"
+
+src_unpack() {
+ check_KV
+ kernel-mod_getversion
+ unpack ${A}
+
+ # Fix path to kernel and KVERS
+ sed -i -e "s:^KSRC.*:KSRC=${ROOT}/usr/src/linux:" \
+ -e "s:^KVERS.*:KVERS=${KV_MAJOR}${KV_MINOR}:" \
+ ${S}/driver/Makefile
+}
+
+src_install() {
+ if [ ${KV_MINOR} -gt 4 ]
+ then
+ KV_OBJ="ko"
+ else
+ KV_OBJ="o"
+ fi
+
+ dobin ${S}/utils/loaddriver
+ dodoc ${S}/README ${S}/AUTHORS
+
+ insinto /lib/modules/${KV}/misc
+ doins ${S}/driver/ndiswrapper.${KV_OBJ}
+
+ insinto /etc/modules.d
+ newins ${FILESDIR}/ndiswrapper.modules.d ndiswrapper
+}
+
+pkg_postinst() {
+ kernel-mod_pkg_postinst
+
+ einfo
+ einfo "Part of the ${PN} module configuration can be done by running"
+ einfo "# ebuild /var/db/pkg/net-wiress/${P}/${P}.ebuild config"
+ einfo "Please consult /etc/modules.d/ndiswrapper to finish"
+ einfo "configuring the driver"
+ einfo
+ einfo "In particular, ndiswrapper requires .inf and .sys files from"
+ einfo "a Windows(tm) driver to function. Put these somewhere like"
+ einfo "/usr/lib/hotplug/drivers, edit /etc/modules.d/ndiswrapper to match,"
+ einfo "then run 'update-modules'"
+ einfo
+}
+
+pkg_config() {
+ if [ ! -f "/etc/modules.d/ndiswrapper" ]
+ then
+ eerror "/etc/modules.d/ndiswrapper not found. Please re-emerge"
+ eerror "${PN} to have this file installed, then re-run this script"
+ die "Driver configuration file not found"
+ fi
+
+ if ! egrep "VENDORID" /etc/modules.d/ndiswrapper
+ then
+ eerror "/etc/modules.d/ndiswrapper doesn't appear to be the one"
+ eerror "distributed by the ${PN} ebuild. To use this config script,"
+ eerror "Please re-emerge ${PN} and then re-run this script."
+ die "Driver configuration file not usable"
+ else
+ einfo "Found acceptable config file at /etc/modules.d/ndiswrapper"
+ fi
+
+ if [ `lspci -n | grep 'Class 0280:' | wc -l` -gt 1 ]
+ then
+ eerror "More than one suitable device detected. This script"
+ eerror "will only work with one suitable device present."
+ die "Too many potential devices found"
+ fi
+
+ I=`lspci -n | grep 'Class 0280:' | cut -d' ' -f4`
+
+ if [ -z "${I}" ]
+ then
+ die "No suitable devices found"
+ fi
+
+ VENDOR=`echo $I | cut -d':' -f1`
+ DEVICEID=`echo $I | cut -d':' -f2`
+
+ einfo "Setting the vendor ID to ${VENDOR} and the device ID to ${DEVICEID}"
+ sed -i -e "s:VENDORID:${VENDOR}:" \
+ -e "s:DEVICEID:${DEVICEID}:" \
+ -e "s:loadndisdriver:loaddriver:" \
+ /etc/modules.d/ndiswrapper
+}