summaryrefslogtreecommitdiff
blob: 4d6130f8fd87fa0501adea003cebef7d634480c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-dialup/ltmodem/ltmodem-8.26_alpha9-r2.ebuild,v 1.1 2003/12/09 14:41:39 lanius Exp $

MY_P="${P/_alpha/a}"
DESCRIPTION="Winmodems with Lucent Apollo (ISA) and Mars (PCI) chipsets"
HOMEPAGE="http://www.heby.de/ltmodem/"
SRC_URI="http://www.physcip.uni-stuttgart.de/heby/ltmodem/${MY_P}.tar.gz
	http://www.sfu.ca/~cth/ltmodem/${MY_P}.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86"

DEPEND="virtual/linux-sources"

S=${WORKDIR}/${MY_P}

src_compile() {
	cp build_module{,.orig}
	sed -e 's:make -e:make:' \
	 -e 's:read -p:echo:' \
		build_module.orig > build_module
	FAST="1" ./build_module ${KV} --with-force || die
}

src_install() {
	dohtml DOCs/*.html
	rm -rf DOCs/*.html DOCs/Installers

	dodoc 1ST-READ BLDrecord.txt Utility_version_tests.txt DOCs/*

	mv utils/fixscript utils/ltfixscript
	mv utils/noisefix utils/ltnoisefix
	mv utils/unloading utils/ltunloading
	dobin utils/lt*

	cd source
	make install ROOTDIR=${D} || die

	insinto /etc/devfs.d
	newins debian/etc_devfs_conf.d_ltmodem ltmodem
	insinto /etc/modules.d
	newins debian/modules ltmodem
}

pkg_postinst() {
	[ -x /usr/sbin/update-modules ] && /usr/sbin/update-modules
	einfo "Use /dev/modem to access modem"
	einfo "If you have problems, read this doc:"
	einfo "/usr/share/doc/${PF}/html/post-install.html"
	echo
	einfo "Also, if you wish to access the modem through"
	einfo "/dev/modem without rebooting, run this:"
	einfo "killall -HUP devfsd"
}