summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlin Năstac <mrness@gentoo.org>2006-09-09 15:27:37 +0000
committerAlin Năstac <mrness@gentoo.org>2006-09-09 15:27:37 +0000
commit04f13bc6d86230a60a21eaa2f884c7e927b3a367 (patch)
tree83b191569ff4e0ec52ccc2bbda809a7b51127d03 /net-dialup/slmodem
parentStable on amd64 wrt Bug #145885. (diff)
downloadhistorical-04f13bc6d86230a60a21eaa2f884c7e927b3a367.tar.gz
historical-04f13bc6d86230a60a21eaa2f884c7e927b3a367.tar.bz2
historical-04f13bc6d86230a60a21eaa2f884c7e927b3a367.zip
Fix compilation errors when build against kernels >= 2.6.18 (#140723). Correct udev rules (#144841).
Package-Manager: portage-2.1-r2
Diffstat (limited to 'net-dialup/slmodem')
-rw-r--r--net-dialup/slmodem/ChangeLog10
-rw-r--r--net-dialup/slmodem/Manifest33
-rw-r--r--net-dialup/slmodem/files/digest-slmodem-2.9.11_pre20051101-r16
-rw-r--r--net-dialup/slmodem/files/slmodem-2.9.11-devfs.patch36
-rw-r--r--net-dialup/slmodem/files/slmodem-2.9.11-makefile.patch33
-rw-r--r--net-dialup/slmodem/slmodem-2.9.11_pre20051101-r1.ebuild153
6 files changed, 266 insertions, 5 deletions
diff --git a/net-dialup/slmodem/ChangeLog b/net-dialup/slmodem/ChangeLog
index 124901b84e14..f0ff25dd6439 100644
--- a/net-dialup/slmodem/ChangeLog
+++ b/net-dialup/slmodem/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for net-dialup/slmodem
# Copyright 2000-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-dialup/slmodem/ChangeLog,v 1.67 2006/08/22 12:13:54 genstef Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-dialup/slmodem/ChangeLog,v 1.68 2006/09/09 15:27:36 mrness Exp $
+
+*slmodem-2.9.11_pre20051101-r1 (09 Sep 2006)
+
+ 09 Sep 2006; Alin Nastac <mrness@gentoo.org>
+ +files/slmodem-2.9.11-devfs.patch, +files/slmodem-2.9.11-makefile.patch,
+ +slmodem-2.9.11_pre20051101-r1.ebuild:
+ Fix compilation errors when build against kernels >= 2.6.18 (#140723).
+ Correct udev rules (#144841).
22 Aug 2006; Stefan Schweizer <genstef@gentoo.org>
+files/slmodem-2.9.11-modem-cc-makefile.patch,
diff --git a/net-dialup/slmodem/Manifest b/net-dialup/slmodem/Manifest
index 917634a070c8..8e11646149a1 100644
--- a/net-dialup/slmodem/Manifest
+++ b/net-dialup/slmodem/Manifest
@@ -1,3 +1,14 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+AUX slmodem-2.9.11-devfs.patch 1259 RMD160 091b9b84f8368237d945fe9a800eaf53d1f347f0 SHA1 274717599314406139a2378fbf83be0e744f6152 SHA256 1c072b12c54c723d342307d40b1d4d87965af3d2c8e0bd21969fe5f26f7c2ab0
+MD5 1c6bdfc7fae87a4b1f5e019442cfbda8 files/slmodem-2.9.11-devfs.patch 1259
+RMD160 091b9b84f8368237d945fe9a800eaf53d1f347f0 files/slmodem-2.9.11-devfs.patch 1259
+SHA256 1c072b12c54c723d342307d40b1d4d87965af3d2c8e0bd21969fe5f26f7c2ab0 files/slmodem-2.9.11-devfs.patch 1259
+AUX slmodem-2.9.11-makefile.patch 872 RMD160 2e0c60d8bdf9d9c936c20d7941030fe3fc439402 SHA1 3c8d191a0e7983247a64e54ca70551fe4b83d046 SHA256 56518c7fa8ce442613ff9f23d87cbabe83ddb1fc21d10ae11dc8e7fd57610189
+MD5 ead92ab897f69fd1b9fc97c4c0e305e1 files/slmodem-2.9.11-makefile.patch 872
+RMD160 2e0c60d8bdf9d9c936c20d7941030fe3fc439402 files/slmodem-2.9.11-makefile.patch 872
+SHA256 56518c7fa8ce442613ff9f23d87cbabe83ddb1fc21d10ae11dc8e7fd57610189 files/slmodem-2.9.11-makefile.patch 872
AUX slmodem-2.9.11-modem-cc-makefile.patch 350 RMD160 64b97f6d4f340369e499c2d26423fea9544c0bed SHA1 69ce8083aa33ba941831e55e8c5941f9d5ad61b3 SHA256 0b8d803f8bc4363be32d6fc318e1764ae8df3679d7dbf7242e980053b9ec1524
MD5 61167b597b6d73eb3fea346ecfef4996 files/slmodem-2.9.11-modem-cc-makefile.patch 350
RMD160 64b97f6d4f340369e499c2d26423fea9544c0bed files/slmodem-2.9.11-modem-cc-makefile.patch 350
@@ -28,14 +39,18 @@ RMD160 6ccb14b19191da17b0352525399ec8560eb89c04 files/slusb.hotplug 262
SHA256 1806e732086915be8ca3c43d0abaf73bdde945eb1e11bd24a12c7309be4cdfed files/slusb.hotplug 262
DIST slmodem-2.9.11-20051101.tar.gz 833644 RMD160 044dd97f763c68ff5c5609cb925146c5302bfb61 SHA1 bacd94800a83c86cc872c6afa75dfb3c90828815 SHA256 d5c456b1bab05a1606f7deaf4d5f1b9151d23377e7eb421b81082f9285de5172
DIST ungrab-winmodem.tar.gz 1872 RMD160 c7058f884ddf6345ddcd15c984364f4741464fbf SHA1 d8c48969fd840b4f7b15f9d6b269470a44e4eed0 SHA256 b9d966fa13b05876c2921f4bd030dfb151e6810958202010fab661d1689e4e11
+EBUILD slmodem-2.9.11_pre20051101-r1.ebuild 4594 RMD160 59bef22ccfbeeeb4ae38141ec18b7228558b3aed SHA1 f695f07b1827c35d3a63a51db91bba4ffbcfff15 SHA256 7ccfafc0b48694db5d521c99bf1bf979d3e78a84cf1ce2b7c1963bc0a5c78a6b
+MD5 265e4a9877b3bb12b00c3f6518c20105 slmodem-2.9.11_pre20051101-r1.ebuild 4594
+RMD160 59bef22ccfbeeeb4ae38141ec18b7228558b3aed slmodem-2.9.11_pre20051101-r1.ebuild 4594
+SHA256 7ccfafc0b48694db5d521c99bf1bf979d3e78a84cf1ce2b7c1963bc0a5c78a6b slmodem-2.9.11_pre20051101-r1.ebuild 4594
EBUILD slmodem-2.9.11_pre20051101.ebuild 4619 RMD160 cfed55daf1c5d6fdd7607d2b5c28736fc4ceed49 SHA1 85d4c940fc793b0cbbdb25d814cdd60de7ed76e5 SHA256 71c708a1b978333292b311f357f08b44b6e4c434c755859f615757e873964813
MD5 efea4cd18104c7257dd76d8b7830a418 slmodem-2.9.11_pre20051101.ebuild 4619
RMD160 cfed55daf1c5d6fdd7607d2b5c28736fc4ceed49 slmodem-2.9.11_pre20051101.ebuild 4619
SHA256 71c708a1b978333292b311f357f08b44b6e4c434c755859f615757e873964813 slmodem-2.9.11_pre20051101.ebuild 4619
-MISC ChangeLog 14620 RMD160 ded96bd05ffce87e24784ba7f79e4969b16926af SHA1 c0ee47bf55fd0eb31ffda6048a6cc6fad8f7fd5f SHA256 a86902958704dad32a0f58422a2acd5aa44944961f31c090c8ce7e45521bf4ab
-MD5 fa1ba1f1cc80362360261f5892acaa82 ChangeLog 14620
-RMD160 ded96bd05ffce87e24784ba7f79e4969b16926af ChangeLog 14620
-SHA256 a86902958704dad32a0f58422a2acd5aa44944961f31c090c8ce7e45521bf4ab ChangeLog 14620
+MISC ChangeLog 14934 RMD160 1b9dd5914c160842e4bb6d4de75d8d39dda47c29 SHA1 54012e5c37cc07a6f1717a82b32c6fc079b2f986 SHA256 e0cffe6c459068ebfc591a901fafcaf899f37e176db43b968655ddc61fc9099c
+MD5 a18d8f03f5797032a54d88f5f8180332 ChangeLog 14934
+RMD160 1b9dd5914c160842e4bb6d4de75d8d39dda47c29 ChangeLog 14934
+SHA256 e0cffe6c459068ebfc591a901fafcaf899f37e176db43b968655ddc61fc9099c ChangeLog 14934
MISC metadata.xml 163 RMD160 df94c60cc0bb7abe5913b464a33966b142b2fe1e SHA1 d8332605fd22c32f15438bbdf24aa622c3d2738a SHA256 1137a0fd866641cf719b0c2e9e77ca9fa4541a42f2cc851fe4659cf2677acca3
MD5 ec2f84816306825d125d0c01bd86758d metadata.xml 163
RMD160 df94c60cc0bb7abe5913b464a33966b142b2fe1e metadata.xml 163
@@ -43,3 +58,13 @@ SHA256 1137a0fd866641cf719b0c2e9e77ca9fa4541a42f2cc851fe4659cf2677acca3 metadata
MD5 bd3432246edbc20a20719bef640eb9ca files/digest-slmodem-2.9.11_pre20051101 512
RMD160 13e9984479cbd18a496255c6cc317da7cfd48e47 files/digest-slmodem-2.9.11_pre20051101 512
SHA256 005100f76c5a3ffccbdfcbcc0b6569ed2ed5661a67124f1b74babd3cf026fbdf files/digest-slmodem-2.9.11_pre20051101 512
+MD5 bd3432246edbc20a20719bef640eb9ca files/digest-slmodem-2.9.11_pre20051101-r1 512
+RMD160 13e9984479cbd18a496255c6cc317da7cfd48e47 files/digest-slmodem-2.9.11_pre20051101-r1 512
+SHA256 005100f76c5a3ffccbdfcbcc0b6569ed2ed5661a67124f1b74babd3cf026fbdf files/digest-slmodem-2.9.11_pre20051101-r1 512
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.5 (GNU/Linux)
+
+iD8DBQFFAt173sf9c6kjmR8RAoBcAJ98C1OpcWA0NN87TTzyjRfqJi/EKwCfdT48
+j3OQrIgr5GZpd6x7U4H7Wlg=
+=eDXg
+-----END PGP SIGNATURE-----
diff --git a/net-dialup/slmodem/files/digest-slmodem-2.9.11_pre20051101-r1 b/net-dialup/slmodem/files/digest-slmodem-2.9.11_pre20051101-r1
new file mode 100644
index 000000000000..047a97ea184a
--- /dev/null
+++ b/net-dialup/slmodem/files/digest-slmodem-2.9.11_pre20051101-r1
@@ -0,0 +1,6 @@
+MD5 56bb1ddf621b2fe26caf746aed0ac26f slmodem-2.9.11-20051101.tar.gz 833644
+RMD160 044dd97f763c68ff5c5609cb925146c5302bfb61 slmodem-2.9.11-20051101.tar.gz 833644
+SHA256 d5c456b1bab05a1606f7deaf4d5f1b9151d23377e7eb421b81082f9285de5172 slmodem-2.9.11-20051101.tar.gz 833644
+MD5 a23326976632fe7774e110cbc0636f70 ungrab-winmodem.tar.gz 1872
+RMD160 c7058f884ddf6345ddcd15c984364f4741464fbf ungrab-winmodem.tar.gz 1872
+SHA256 b9d966fa13b05876c2921f4bd030dfb151e6810958202010fab661d1689e4e11 ungrab-winmodem.tar.gz 1872
diff --git a/net-dialup/slmodem/files/slmodem-2.9.11-devfs.patch b/net-dialup/slmodem/files/slmodem-2.9.11-devfs.patch
new file mode 100644
index 000000000000..226fc3f00618
--- /dev/null
+++ b/net-dialup/slmodem/files/slmodem-2.9.11-devfs.patch
@@ -0,0 +1,36 @@
+diff -Nru slmodem-2.9.11-20051101.orig/drivers/amrmo_init.c slmodem-2.9.11-20051101/drivers/amrmo_init.c
+--- slmodem-2.9.11-20051101.orig/drivers/amrmo_init.c 2005-10-10 00:14:13.000000000 +0300
++++ slmodem-2.9.11-20051101/drivers/amrmo_init.c 2006-09-09 18:13:47.219081000 +0300
+@@ -53,7 +53,13 @@
+ #include <linux/poll.h>
+ #include <linux/fs.h>
+ #include <asm/uaccess.h>
+-#include <linux/devfs_fs_kernel.h>
++
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18)
++# include <linux/devfs_fs_kernel.h>
++#else
++# define devfs_mk_cdev(dev, mode, fmt, i)
++# define devfs_remove(fmt, i)
++#endif
+
+ #if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
+ #define OLD_KERNEL 1
+diff -Nru slmodem-2.9.11-20051101.orig/drivers/st7554.c slmodem-2.9.11-20051101/drivers/st7554.c
+--- slmodem-2.9.11-20051101.orig/drivers/st7554.c 2005-11-01 17:31:45.000000000 +0200
++++ slmodem-2.9.11-20051101/drivers/st7554.c 2006-09-09 18:14:36.910186500 +0300
+@@ -55,7 +55,13 @@
+ #include <linux/poll.h>
+ #include <linux/usb.h>
+ #include <linux/device.h>
+-#include <linux/devfs_fs_kernel.h>
++
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18)
++# include <linux/devfs_fs_kernel.h>
++#else
++# define devfs_mk_cdev(dev, mode, fmt, i)
++# define devfs_remove(fmt, i)
++#endif
+
+ #include <modem_defs.h>
+
diff --git a/net-dialup/slmodem/files/slmodem-2.9.11-makefile.patch b/net-dialup/slmodem/files/slmodem-2.9.11-makefile.patch
new file mode 100644
index 000000000000..7bc568ddaf8b
--- /dev/null
+++ b/net-dialup/slmodem/files/slmodem-2.9.11-makefile.patch
@@ -0,0 +1,33 @@
+diff -Nru slmodem-2.9.11-20051101.orig/modem/Makefile slmodem-2.9.11-20051101/modem/Makefile
+--- slmodem-2.9.11-20051101.orig/modem/Makefile 2005-11-01 17:33:34.000000000 +0200
++++ slmodem-2.9.11-20051101/modem/Makefile 2006-09-09 18:04:39.680862000 +0300
+@@ -13,10 +13,10 @@
+ #
+ ###########################################################################
+
+-CC:= gcc
++CC?= gcc
+ RM:= rm -f
+
+-CFLAGS+= -Wall -g -O -I. -DCONFIG_DEBUG_MODEM
++CFLAGS+= -Wall -finline -I. -DCONFIG_DEBUG_MODEM
+
+
+ modem-objs:= \
+@@ -33,13 +33,13 @@
+
+ #SUPPORT_ALSA:=1
+ ifdef SUPPORT_ALSA
+-slmodemd: -lasound
++
+ CFLAGS+= -DSUPPORT_ALSA=1
+-LFLAGS+= -lasound
++LDLIBS+= -lasound
+ endif
+
+ slmodemd modem_test:
+- $(CC) $(LFLAGS) -o $@ $^
++ $(CC) $(LDFLAGS) -o $@ $^ $(LDLIBS)
+
+ clean:
+ $(RM) slmodemd modem_test modem_main.o modem_cmdline.o modem_test.o $(modem-objs) $(dp-objs) $(sysdep-objs)
diff --git a/net-dialup/slmodem/slmodem-2.9.11_pre20051101-r1.ebuild b/net-dialup/slmodem/slmodem-2.9.11_pre20051101-r1.ebuild
new file mode 100644
index 000000000000..211d9fdf65b8
--- /dev/null
+++ b/net-dialup/slmodem/slmodem-2.9.11_pre20051101-r1.ebuild
@@ -0,0 +1,153 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-dialup/slmodem/slmodem-2.9.11_pre20051101-r1.ebuild,v 1.1 2006/09/09 15:27:37 mrness Exp $
+
+inherit eutils linux-mod multilib
+
+DESCRIPTION="Driver for Smart Link modem"
+HOMEPAGE="http://linmodems.technion.ac.il/packages/smartlink/"
+SRC_URI="http://linmodems.technion.ac.il/packages/smartlink/${P/_pre/-}.tar.gz
+ http://linmodems.technion.ac.il/packages/smartlink/ungrab-winmodem.tar.gz"
+
+LICENSE="Smart-Link"
+SLOT="0"
+KEYWORDS="-* ~amd64 ~x86"
+IUSE="alsa usb"
+
+DEPEND="alsa? ( media-libs/alsa-lib )
+ amd64? ( app-emulation/emul-linux-x86-soundlibs )"
+
+S=${WORKDIR}/${P/_pre/-}
+
+pkg_setup() {
+ use amd64 && multilib_toolchain_setup x86
+
+ MODULE_NAMES="ungrab-winmodem(:${WORKDIR}/ungrab-winmodem)"
+ if ! use amd64; then
+ MODULE_NAMES="${MODULE_NAMES} slamr(net:${S}/drivers)"
+ if use usb; then
+ MODULE_NAMES="${MODULE_NAMES} slusb(net:${S}/drivers)"
+ CONFIG_CHECK="USB"
+ fi
+ fi
+ BUILD_TARGETS="all"
+ linux-mod_pkg_setup
+ BUILD_PARAMS="KERNEL_DIR=${KV_DIR}"
+}
+
+src_unpack() {
+ unpack ${A}
+ sed -i "s:SUBDIRS=\$(shell pwd):SUBDIRS=${WORKDIR}/ungrab-winmodem:" \
+ "${WORKDIR}/ungrab-winmodem/Makefile"
+ convert_to_m "${WORKDIR}/ungrab-winmodem/Makefile"
+
+ cd "${S}"
+ epatch "${FILESDIR}/${P%%_*}-makefile.patch"
+ epatch "${FILESDIR}/${P%%_*}-devfs.patch"
+ cd drivers
+ sed -i "s:SUBDIRS=\$(shell pwd):SUBDIRS=${S}/drivers:" Makefile
+ convert_to_m Makefile
+ sed -i "s:.*=[ \t]*THIS_MODULE.*::" st7554.c amrmo_init.c old_st7554.c
+ sed -i 's:MODULE_PARM(\([^,]*\),"i");:module_param(\1, int, 0);:' st7554.c \
+ amrmo_init.c old_st7554.c
+}
+
+src_compile() {
+ local MAKE_PARAMS=""
+ if use alsa || use amd64; then
+ MAKE_PARAMS="SUPPORT_ALSA=1"
+ fi
+ emake ${MAKE_PARAMS} modem || die "failed to build modem"
+
+ use amd64 && multilib_toolchain_setup amd64
+ linux-mod_src_compile
+}
+
+src_install() {
+ linux-mod_src_install
+
+ cd "${S}"
+ newsbin modem/modem_test slmodem_test
+ dosbin modem/slmodemd
+ dodir /var/lib/slmodem
+ fowners root:dialout /var/lib/slmodem
+ keepdir /var/lib/slmodem
+
+ newconfd "${FILESDIR}/${PN}-2.9.conf" ${PN}
+ newinitd "${FILESDIR}/${PN}-2.9.11.init" ${PN}
+
+ # configure for alsa - or not for alsa
+ if use alsa; then
+ sed -i -e "s/# MODULE=alsa/MODULE=alsa/" \
+ -e "s/# HW_SLOT=modem:1/HW_SLOT=modem:1/" "${D}/etc/conf.d/slmodem"
+ else
+ sed -i "s/# MODULE=slamr/MODULE=slamr/" "${D}/etc/conf.d/slmodem"
+ fi
+
+
+ # Add module aliases and install hotplug script
+ insinto /etc/modules.d/; newins "${FILESDIR}/${PN}-2.9.11.modules" ${PN}
+ if use usb; then
+ exeinto /etc/hotplug/usb; newexe "${FILESDIR}/slusb.hotplug" slusb
+ fi
+
+ dodir /etc/hotplug/blacklist.d
+ echo -e "slusb\nslamr\nsnd-intel8x0m" >> "${D}/etc/hotplug/blacklist.d/${PN}"
+
+ # Add configuration for devfs, udev
+ if [ -e "${ROOT}/dev/.devfsd" ] ; then
+ insinto /etc/devfs.d/; newins "${FILESDIR}/${PN}-2.9.devfs" ${PN}
+ elif [ -e "${ROOT}/dev/.udev" ] ; then
+ dodir /etc/udev/rules.d/
+ echo 'KERNEL=="slamr", NAME="slamr0" GROUP="dialout"' > \
+ "${D}/etc/udev/rules.d/55-${PN}.rules"
+ if use usb; then
+ echo 'KERNEL=="slusb", NAME="slusb0" GROUP="dialout"' >> \
+ "${D}/etc/udev/rules.d/55-${PN}.rules"
+ fi
+ fi
+
+ dodoc Changes README "${WORKDIR}/ungrab-winmodem/Readme.txt"
+}
+
+pkg_postinst() {
+ linux-mod_pkg_postinst
+
+ # Make some devices if we aren't using devfs or udev
+ if [ -e "${ROOT}/dev/.devfsd" ]; then
+ ebegin "Restarting devfsd to reread devfs rules"
+ killall -HUP devfsd
+ eend $?
+
+ elif [ -e "${ROOT}/dev/.udev" ]; then
+ ebegin "Restarting udev to reread udev rules"
+ udevstart
+ eend $?
+ else
+ cd "${S}/drivers"
+ make DESTDIR="${ROOT}" install-devices
+ fi
+
+ if [ ! -e "${ROOT}/dev/ppp" ]; then
+ mknod "${ROOT}/dev/ppp" c 108 0
+ fi
+
+ ewarn "To avoid problems, slusb/slamr have been added to /etc/hotplug/blacklist"
+ einfo "You must edit /etc/conf.d/${PN} for your configuration"
+ einfo "To add slmodem to your startup - type : rc-update add slmodem default"
+
+ if use alsa; then
+ einfo "I hope you have already added alsa to your startup: "
+ einfo "otherwise type: rc-update add alsasound boot"
+ einfo
+ einfo "If you need to use snd-intel8x0m from the kernel"
+ einfo "compile it as a module and edit /etc/modules.d/alsa"
+ einfo 'to: "alias snd-card-(number) snd-intel8x0m"'
+ fi
+
+ einfo "You need to be in the uucp AND dialout group to make calls as a user."
+ einfo
+ einfo "If you see the following in dmesg:"
+ echo slamr: device 10b9:5457 is grabbed by driver serial
+ einfo "you need to modprobe ungrab-winmodem before slamr"
+}