Version bump, this should fix bug #157009.
authorTimothy Redaelli <drizzt@gentoo.org>
Tue, 19 Dec 2006 09:36:30 +0000 (09:36 +0000)
committerTimothy Redaelli <drizzt@gentoo.org>
Tue, 19 Dec 2006 09:36:30 +0000 (09:36 +0000)
Package-Manager: portage-2.1.2_rc2-r5

net-misc/zaptel/ChangeLog
net-misc/zaptel/Manifest
net-misc/zaptel/files/digest-zaptel-1.2.11-r1
net-misc/zaptel/files/digest-zaptel-1.2.12 [new file with mode: 0644]
net-misc/zaptel/files/digest-zaptel-1.2.9.1-r1
net-misc/zaptel/files/zaptel-1.2.12-gentoo.diff [new file with mode: 0644]
net-misc/zaptel/zaptel-1.2.12.ebuild [new file with mode: 0644]

index d7127ccd6ff09e0643952ef576fb2eeec9b62149..1fa81e4c891a8a3107d6b4a1da2f7674dbfc488f 100644 (file)
@@ -1,6 +1,12 @@
 # ChangeLog for net-misc/zaptel
 # Copyright 2000-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/zaptel/ChangeLog,v 1.87 2006/11/27 14:59:50 gustavoz Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/zaptel/ChangeLog,v 1.88 2006/12/19 09:36:30 drizzt Exp $
+
+*zaptel-1.2.12 (19 Dec 2006)
+
+  19 Dec 2006; Timothy Redaelli <drizzt@gentoo.org>
+  +files/zaptel-1.2.12-gentoo.diff, +zaptel-1.2.12.ebuild:
+  Version bump, this should fix bug #157009.
 
   27 Nov 2006; Gustavo Zacarias <gustavoz@gentoo.org>
   zaptel-1.2.11-r1.ebuild:
index 0715adb03322be7e686b26345429787b72f43fc5..88ed5f9610f7b15342a4b7a9a8e2dc0bbf5cc844 100644 (file)
@@ -37,6 +37,10 @@ AUX zaptel-1.2.11-gentoo.diff 5090 RMD160 1a3b1b2b0d1f06ee05f0212a76e3a78a9963f0
 MD5 b5b5c88abb3d8b1efabdd1d34935c052 files/zaptel-1.2.11-gentoo.diff 5090
 RMD160 1a3b1b2b0d1f06ee05f0212a76e3a78a9963f011 files/zaptel-1.2.11-gentoo.diff 5090
 SHA256 ed70a2f784f191a9c9cb47bcca90209e6f29b3fda6bee649f361a7ae4fb0cf80 files/zaptel-1.2.11-gentoo.diff 5090
+AUX zaptel-1.2.12-gentoo.diff 5088 RMD160 ebf8bd689f7b9e051f3476a2cad429d95458dafc SHA1 2123b41246258dbeae8be069e0b8d0c1ec832c69 SHA256 797226ee1ee56d13829ac9a027d9176503c850777beed6442299935953bcb198
+MD5 e7764f8ac5e6d6cc9a787c427f089f6f files/zaptel-1.2.12-gentoo.diff 5088
+RMD160 ebf8bd689f7b9e051f3476a2cad429d95458dafc files/zaptel-1.2.12-gentoo.diff 5088
+SHA256 797226ee1ee56d13829ac9a027d9176503c850777beed6442299935953bcb198 files/zaptel-1.2.12-gentoo.diff 5088
 AUX zaptel-1.2.9.1-ar.patch 924 RMD160 24eac6e9c5a9576b04df1e595fa6a2e2487772fe SHA1 fdf329d360508d8e629d196d4f0e6ccfabf24dff SHA256 8a8374b2689ed70108d10eb704bb6d3b35550f33a183e039e7efd69c7a681485
 MD5 235d2550fd9a0bde64929e27a6a2343d files/zaptel-1.2.9.1-ar.patch 924
 RMD160 24eac6e9c5a9576b04df1e595fa6a2e2487772fe files/zaptel-1.2.9.1-ar.patch 924
@@ -75,6 +79,7 @@ DIST bristuff-0.3.0-PRE-1v.tar.gz 267644 RMD160 5c5f034d29f4156351a495f40c9c4b17
 DIST zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736 RMD160 b95d2301402e1108bc480ce0e66e87e3062eccf8 SHA1 f8ab2f312c6a2b2f607b9e7f3ccbcca0858c53a7 SHA256 04a8dd22d581b5d28d46a589d695f6eb634bf2bf355347a637fe2d560a63528c
 DIST zaptel-1.0.10.tar.gz 327832 RMD160 a797bb36f35e50c51d30705ad1d628f5728d87ed SHA1 98544260fca2afbcd304f7354b62a56138e15a09 SHA256 7978f3c56a95033bf2bc2cb8d0cb2830c5371aae21e0021503c6dbf2361795d1
 DIST zaptel-1.2.11.tar.gz 1425625 RMD160 6ae43a2f5801dab17216912f976e67371d8e51d2 SHA1 30a2001449ff50b5a47970b76a77500986602211 SHA256 3641c8ef684862b3cc9fd3c3341d25095909a9c2f901d31b7cc9394210cb50e8
+DIST zaptel-1.2.12.tar.gz 1487021 RMD160 4cbf2627a8bbbad65ec43578c1c89e79f1682bdb SHA1 733dcc3f90a7485808ff2e76832d6e78dca5728c SHA256 ab1e87645ceaae9269493f4e448596045732389197a9bb8c21bd5be88533e48f
 DIST zaptel-1.2.9.1.tar.gz 1255412 RMD160 caf2ad931e2ae439500805a6ca4376dc8083de5a SHA1 6145301bb47107c0910a098e26b4ca5cdb2377ab SHA256 7def44c259352397af2ad80f3c0eb103ff640ffbc7c95f37c3802fee75c10ede
 EBUILD zaptel-1.0.10-r2.ebuild 7200 RMD160 b2c3dc3d5a3df8926e9fafd7051a831ca64c3ec1 SHA1 48e6fa1749f31e9054ff3baf00568debccd436f5 SHA256 3f387be5cb5604e11953f6cfef79e3544357774616396c1325b8e407f3cfea94
 MD5 c7680ee19e6e9fb426a1fff90fa32829 zaptel-1.0.10-r2.ebuild 7200
@@ -84,14 +89,18 @@ EBUILD zaptel-1.2.11-r1.ebuild 9023 RMD160 a85a0f5225e67234ff5c1bda1c12b63b354e5
 MD5 e902c0a9128595c5a1bf2405fb0c16ae zaptel-1.2.11-r1.ebuild 9023
 RMD160 a85a0f5225e67234ff5c1bda1c12b63b354e5a10 zaptel-1.2.11-r1.ebuild 9023
 SHA256 3c719f62712fe3ed83389c28dc94ab1cbe2ee2022187db225dc3183cd1c4d584 zaptel-1.2.11-r1.ebuild 9023
+EBUILD zaptel-1.2.12.ebuild 9018 RMD160 98db97e401944feff969a6bdd884fe21cb53b0c6 SHA1 6b3dfd2e1f5afd9ff539ba6d230b8475cba8a333 SHA256 350fab1289b413a6714a4965a3caefdd1c457f2b362d9f1537729f1a424de0a2
+MD5 49c53ac3b0bf4842511db0ef2becdc88 zaptel-1.2.12.ebuild 9018
+RMD160 98db97e401944feff969a6bdd884fe21cb53b0c6 zaptel-1.2.12.ebuild 9018
+SHA256 350fab1289b413a6714a4965a3caefdd1c457f2b362d9f1537729f1a424de0a2 zaptel-1.2.12.ebuild 9018
 EBUILD zaptel-1.2.9.1-r1.ebuild 8577 RMD160 b487dfe2f52b91b5cd5a75667a2c702bb65397c5 SHA1 b304a51b4e762ca281a54ddac822f3e2deabc4b7 SHA256 36b1e47f352425665c6ed1c77ba9a53374b5bb04e8aaabd8b9483b4c377df8bd
 MD5 3137e2eae66b020b7ac2d239b8d4008b zaptel-1.2.9.1-r1.ebuild 8577
 RMD160 b487dfe2f52b91b5cd5a75667a2c702bb65397c5 zaptel-1.2.9.1-r1.ebuild 8577
 SHA256 36b1e47f352425665c6ed1c77ba9a53374b5bb04e8aaabd8b9483b4c377df8bd zaptel-1.2.9.1-r1.ebuild 8577
-MISC ChangeLog 17334 RMD160 702f3c3b8e7069c7bfbd24b868941dc1b1eadb1f SHA1 4468957eb4fde9f7e0795f8311d9c0a2d87e85d0 SHA256 91856046d20c92cd4e4b8625231d4ddf971c1d1b69c30a991f48b9ef8a8ebaf5
-MD5 6c91ffeb10512231c1aa9115a9ba0931 ChangeLog 17334
-RMD160 702f3c3b8e7069c7bfbd24b868941dc1b1eadb1f ChangeLog 17334
-SHA256 91856046d20c92cd4e4b8625231d4ddf971c1d1b69c30a991f48b9ef8a8ebaf5 ChangeLog 17334
+MISC ChangeLog 17519 RMD160 173c1935fce9766e290c29c9a238db297744f4f6 SHA1 6887f7afa4469fe6376c3103206d05c451e5b9de SHA256 e4a9f2ccc861d37417b8dbc0e1b3725e282929c142516291c514a0cff98f781f
+MD5 51c19bf51615180ea54724bde633a1f4 ChangeLog 17519
+RMD160 173c1935fce9766e290c29c9a238db297744f4f6 ChangeLog 17519
+SHA256 e4a9f2ccc861d37417b8dbc0e1b3725e282929c142516291c514a0cff98f781f ChangeLog 17519
 MISC metadata.xml 382 RMD160 315172442a4bfaa87b855d4c421b22a2527e97b2 SHA1 7b95f41def10946742929592db1d76b7e3bb0a19 SHA256 f79d5cd273e9ecc2181e60ea226a7cb0128011d877fc7531b2df30bd5fd9ae20
 MD5 f3d5d5b8a638e7a9a83fe0eb0d94282c metadata.xml 382
 RMD160 315172442a4bfaa87b855d4c421b22a2527e97b2 metadata.xml 382
@@ -99,16 +108,19 @@ SHA256 f79d5cd273e9ecc2181e60ea226a7cb0128011d877fc7531b2df30bd5fd9ae20 metadata
 MD5 b50b5a655448b6b066496c55efe49458 files/digest-zaptel-1.0.10-r2 364
 RMD160 92b40cf655af41ba56cc1e22ae17e891a2758fe4 files/digest-zaptel-1.0.10-r2 364
 SHA256 13a19426a8ee67a67ad505257a3a6d4fa5a43d0b6d1283d8ef5f4572aea135ec files/digest-zaptel-1.0.10-r2 364
-MD5 5924ac42ced63aabf6f839164183216d files/digest-zaptel-1.2.11-r1 649
-RMD160 679a654f51dd71da4784fe69b78a7a0b24e9bbfb files/digest-zaptel-1.2.11-r1 649
-SHA256 33b255bec4486254bf2d806409519cf084a8854c9d993fc2f6ab36a0417c539e files/digest-zaptel-1.2.11-r1 649
-MD5 b7ece6e3cffa6e1eba97ff9e4c4705df files/digest-zaptel-1.2.9.1-r1 578
-RMD160 bae9a9beddbf3e456f02c7581d851179664706cd files/digest-zaptel-1.2.9.1-r1 578
-SHA256 b27a3e6b2c72741af2faf684df42f2785563f728624bf105b4a0899edcd07781 files/digest-zaptel-1.2.9.1-r1 578
+MD5 5be62fb2c9ceb80dd67e273749b36f5b files/digest-zaptel-1.2.11-r1 795
+RMD160 f548947b52714f039cb62714ae2baef8049098f0 files/digest-zaptel-1.2.11-r1 795
+SHA256 f25c5f1b434635c05e59971a2061b49113e3ad69290169f5fb0d7a5c83364311 files/digest-zaptel-1.2.11-r1 795
+MD5 3fd6340ada34c7c0f0b1df11e3b80338 files/digest-zaptel-1.2.12 795
+RMD160 5bb91c092f28aab3ca6618b0117d50a6bc045b80 files/digest-zaptel-1.2.12 795
+SHA256 65df7b2070133e6588ce57412a539fc6dbf9e0ad58207ae7f2434c8fc2af46b8 files/digest-zaptel-1.2.12 795
+MD5 4f0bce568656b2bd56047db290089c5e files/digest-zaptel-1.2.9.1-r1 658
+RMD160 fed5eacf2bbc84ace2c5fdd4a4375d04312a761f files/digest-zaptel-1.2.9.1-r1 658
+SHA256 9322dafee7f351be55a54eec5d617e1ee98b3a32aa5cb25546bd9631ac34487f files/digest-zaptel-1.2.9.1-r1 658
 -----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.5-ecc0.1.6 (GNU/Linux)
+Version: GnuPG v1.4.5 (GNU/Linux)
 
-iD8DBQFFav1tKRy60XGEcJIRAgT2AJ9sy+Wl0q0qWUaFjzW1GwTLTX7WIwCgpAxI
-tHkG235OUC8roPVCulXzmq0=
-=oZTu
+iD8DBQFFh7KlGDyatLGpTbYRArWQAJ90ulBZU6WpDkq8m3nHlnMmrVNOtQCdEDz4
+81UOd3xQJqK1JUah0SzY8b4=
+=lCS+
 -----END PGP SIGNATURE-----
index c6fd17317bc39077f62a1ccd8b628d8139bd7102..fdeb525e2e3b0dd0ed3a1dbc3fb1596a118d89b1 100644 (file)
@@ -1,7 +1,9 @@
 MD5 9da38a78556eb09749d1f789a8a2631c bristuff-0.3.0-PRE-1v.tar.gz 267644
 RMD160 5c5f034d29f4156351a495f40c9c4b176f65e06e bristuff-0.3.0-PRE-1v.tar.gz 267644
 SHA256 91254dd6c71b74a5990df622b523d06c2f0399c6e47630e5155392c1598fd39e bristuff-0.3.0-PRE-1v.tar.gz 267644
+MD5 541b0a5910843d3c0b6a9de9467b9401 zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
 RMD160 b95d2301402e1108bc480ce0e66e87e3062eccf8 zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
 SHA256 04a8dd22d581b5d28d46a589d695f6eb634bf2bf355347a637fe2d560a63528c zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
+MD5 f61f77ec35ccf2e5518e23ac315f67b1 zaptel-1.2.11.tar.gz 1425625
 RMD160 6ae43a2f5801dab17216912f976e67371d8e51d2 zaptel-1.2.11.tar.gz 1425625
 SHA256 3641c8ef684862b3cc9fd3c3341d25095909a9c2f901d31b7cc9394210cb50e8 zaptel-1.2.11.tar.gz 1425625
diff --git a/net-misc/zaptel/files/digest-zaptel-1.2.12 b/net-misc/zaptel/files/digest-zaptel-1.2.12
new file mode 100644 (file)
index 0000000..42cc873
--- /dev/null
@@ -0,0 +1,9 @@
+MD5 9da38a78556eb09749d1f789a8a2631c bristuff-0.3.0-PRE-1v.tar.gz 267644
+RMD160 5c5f034d29f4156351a495f40c9c4b176f65e06e bristuff-0.3.0-PRE-1v.tar.gz 267644
+SHA256 91254dd6c71b74a5990df622b523d06c2f0399c6e47630e5155392c1598fd39e bristuff-0.3.0-PRE-1v.tar.gz 267644
+MD5 541b0a5910843d3c0b6a9de9467b9401 zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
+RMD160 b95d2301402e1108bc480ce0e66e87e3062eccf8 zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
+SHA256 04a8dd22d581b5d28d46a589d695f6eb634bf2bf355347a637fe2d560a63528c zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
+MD5 99b9f86556b903a32607b2751f920513 zaptel-1.2.12.tar.gz 1487021
+RMD160 4cbf2627a8bbbad65ec43578c1c89e79f1682bdb zaptel-1.2.12.tar.gz 1487021
+SHA256 ab1e87645ceaae9269493f4e448596045732389197a9bb8c21bd5be88533e48f zaptel-1.2.12.tar.gz 1487021
index 9e151a944149eef495ad7f154b515f780d5345b2..f8f8dd692e84e747444ec6c756a0937966b61667 100644 (file)
@@ -1,5 +1,6 @@
 RMD160 8d3abdbbae4c376d52225395c72f4538e1f84a94 bristuff-0.3.0-PRE-1s.tar.gz 265953
 SHA256 30adea4f070ed44d1952163e850c177f976857b96965e18844ccd492ccef968d bristuff-0.3.0-PRE-1s.tar.gz 265953
+MD5 541b0a5910843d3c0b6a9de9467b9401 zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
 RMD160 b95d2301402e1108bc480ce0e66e87e3062eccf8 zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
 SHA256 04a8dd22d581b5d28d46a589d695f6eb634bf2bf355347a637fe2d560a63528c zaphfc_0.3.0-PRE-1o_florz-12.diff.gz 10736
 RMD160 caf2ad931e2ae439500805a6ca4376dc8083de5a zaptel-1.2.9.1.tar.gz 1255412
diff --git a/net-misc/zaptel/files/zaptel-1.2.12-gentoo.diff b/net-misc/zaptel/files/zaptel-1.2.12-gentoo.diff
new file mode 100644 (file)
index 0000000..d1a2fb6
--- /dev/null
@@ -0,0 +1,103 @@
+diff -Nura zaptel-1.2.11/build_tools/genmodconf zaptel-1.2.11.gentoo/build_tools/genmodconf
+--- zaptel-1.2.11/build_tools/genmodconf       2006-05-23 14:51:00.000000000 -0300
++++ zaptel-1.2.11.gentoo/build_tools/genmodconf        2006-11-14 11:54:53.624386476 -0300
+@@ -79,20 +79,6 @@
+ echo Building ${target}...
+-if [ "${1}" = "linux24" ]; then
+-    for mod in ${3}; do
+-      if ! grep -q "post-install ${mod} " ${target}; then
+-          echo "post-install ${mod} /sbin/ztcfg" >> ${target}
+-      fi
+-    done
+-elif [ "${1}" = "linux26" ]; then
+-    for mod in ${3}; do
+-      if ! grep -q "install ${mod} " ${target}; then
+-          echo "install ${mod} /sbin/modprobe --ignore-install ${mod} ${cmdopts} && /sbin/ztcfg" >> ${target}
+-      fi
+-    done
+-fi
+-
+ if ! grep -q "alias wcfxs" ${target}; then
+     echo "alias wcfxs wctdm" >> ${target};
+ fi;
+diff -Nura zaptel-1.2.11/build_tools/genudevrules zaptel-1.2.11.gentoo/build_tools/genudevrules
+--- zaptel-1.2.11/build_tools/genudevrules     2006-05-17 13:49:46.000000000 -0300
++++ zaptel-1.2.11.gentoo/build_tools/genudevrules      2006-11-14 11:54:53.625386224 -0300
+@@ -22,9 +22,9 @@
+ cat <<EOF
+ # zaptel devices with ownership/permissions for running as non-root
+-KERNEL${match}"zapctl", NAME="zap/ctl", OWNER="asterisk", GROUP="asterisk", MODE="0660"
+-KERNEL${match}"zaptimer", NAME="zap/timer", OWNER="asterisk", GROUP="asterisk", MODE="0660"
+-KERNEL${match}"zapchannel", NAME="zap/channel", OWNER="asterisk", GROUP="asterisk", MODE="0660"
+-KERNEL${match}"zappseudo", NAME="zap/pseudo", OWNER="asterisk", GROUP="asterisk", MODE="0660"
+-KERNEL${match}"zap[0-9]*", NAME="zap/%n", OWNER="asterisk", GROUP="asterisk", MODE="0660"
++KERNEL${match}"zapctl", NAME="zap/ctl", OWNER="root", GROUP="dialout", MODE="0660"
++KERNEL${match}"zaptimer", NAME="zap/timer", OWNER="root", GROUP="dialout", MODE="0660"
++KERNEL${match}"zapchannel", NAME="zap/channel", OWNER="root", GROUP="dialout", MODE="0660"
++KERNEL${match}"zappseudo", NAME="zap/pseudo", OWNER="root", GROUP="dialout", MODE="0660"
++KERNEL${match}"zap[0-9]*", NAME="zap/%n", OWNER="root", GROUP="dialout", MODE="0660"
+ EOF
+diff -Nura zaptel-1.2.11/Makefile zaptel-1.2.11.gentoo/Makefile
+--- zaptel-1.2.11/Makefile     2006-10-31 03:25:16.000000000 -0300
++++ zaptel-1.2.11.gentoo/Makefile      2006-11-14 12:00:45.451857178 -0300
+@@ -25,7 +25,7 @@
+ endif
+ KINCLUDES:=$(KSRC)/include
+-CFLAGS+=-I. -O4 -g -Wall -DBUILDING_TONEZONE #-DTONEZONE_DRIVER
++CFLAGS+=-I. -Iinclude -g -Wall -DBUILDING_TONEZONE #-DTONEZONE_DRIVER
+ CFLAGS_PPC:=$(shell if uname -m | grep -q ppc; then echo "-fsigned-char"; fi)
+ CFLAGS_X86-64:=$(shell if uname -m | grep -q x86_64; then echo "-m64"; fi)
+ CFLAGS+=$(CFLAGS_PPC) $(CFLAGS_X86-64)
+@@ -299,7 +299,8 @@
+       done
+ else # DYNFS
+   ifdef UDEVRULES
+-      build_tools/genudevrules > $(INSTALL_PREFIX)/etc/udev/rules.d/zaptel.rules
++      build_tools/genudevrules > zaptel.rules
++      install -D -m 644 zaptel.rules $(INSTALL_PREFIX)/etc/udev/rules.d/10-zaptel.rules
+   else # !UDEVRULES
+       @echo "**** Dynamic filesystem detected -- not creating device nodes"
+   endif
+@@ -314,7 +315,7 @@
+       tar -zxf mISDNuser.tar.gz
+       $(MAKE) -C mISDNuser install
+-install: all devices firmware
++install: devices firmware
+       install -D -m 755 ztcfg $(INSTALL_PREFIX)/sbin/ztcfg
+       if [ -f sethdlc-new ]; then \
+               install -D -m 755 sethdlc-new $(INSTALL_PREFIX)/sbin/sethdlc; \
+@@ -337,24 +338,21 @@
+       fi; \
+       rm -f $(INSTALL_PREFIX)/lib/modules/$(KVERS)/misc/wcfxs.o
+       install -D -m 755 $(LIBTONEZONE_SO) $(INSTALL_PREFIX)/usr/lib/$(LIBTONEZONE_SO).$(LIBTONEZONE_SO_MAJOR_VER).$(LIBTONEZONE_SO_MINOR_VER)
+-      [ `id -u` = 0 ] && /sbin/ldconfig || :
++      [ `id -u` = 0 ] && /sbin/ldconfig -n $(INSTALL_PREFIX)/usr/lib || :
+       rm -f $(INSTALL_PREFIX)/usr/lib/$(LIBTONEZONE_SO)
+       ln -sf $(LIBTONEZONE_SO).$(LIBTONEZONE_SO_MAJOR_VER).$(LIBTONEZONE_SO_MINOR_VER) \
+               $(INSTALL_PREFIX)/usr/lib/$(LIBTONEZONE_SO).$(LIBTONEZONE_SO_MAJOR_VER)
+       ln -sf $(LIBTONEZONE_SO).$(LIBTONEZONE_SO_MAJOR_VER).$(LIBTONEZONE_SO_MINOR_VER) \
+               $(INSTALL_PREFIX)/usr/lib/$(LIBTONEZONE_SO)
+-      if [ -x /usr/sbin/sestatus ] && (/usr/sbin/sestatus | grep "SELinux status:" | grep -q "enabled") ; then restorecon -v $(INSTALL_PREFIX)/usr/lib/$(LIBTONEZONE_SO); fi
+       install -D -m 644 zaptel.h $(INSTALL_PREFIX)/usr/include/linux/zaptel.h
+       install -D -m 644 torisa.h $(INSTALL_PREFIX)/usr/include/linux/torisa.h
+       install -D -m 644 tonezone.h $(INSTALL_PREFIX)/usr/include/tonezone.h
+-      install -m 644 doc/ztcfg.8 $(INSTALL_PREFIX)/usr/share/man/man8
+-      install -m 644 doc/zttool.8 $(INSTALL_PREFIX)/usr/share/man/man8
+-      [ `id -u` = 0 ] && /sbin/depmod -a $(KVERS) || :
++      install -d $(INSTALL_PREFIX)/usr/share/man/man8
++      install -m 644 doc/ztcfg.8 $(INSTALL_PREFIX)/usr/share/man/man8/
++      install -m 644 doc/zttool.8 $(INSTALL_PREFIX)/usr/share/man/man8/
+       [ -f $(CONFIG_FILE) ] || install -D -m 644 zaptel.conf.sample $(CONFIG_FILE)
++      install -d -m 755 $(INSTALL_PREFIX)/etc/modules.d
+       build_tools/genmodconf $(BUILDVER) "$(INSTALL_PREFIX)" "$(filter-out zaptel,$(MODULES))"
+-      @if [ -d /etc/modutils ]; then \
+-              /sbin/update-modules ; \
+-      fi
+ install-udev: devices
diff --git a/net-misc/zaptel/zaptel-1.2.12.ebuild b/net-misc/zaptel/zaptel-1.2.12.ebuild
new file mode 100644 (file)
index 0000000..7ce9d72
--- /dev/null
@@ -0,0 +1,370 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/zaptel/zaptel-1.2.12.ebuild,v 1.1 2006/12/19 09:36:30 drizzt Exp $
+
+inherit toolchain-funcs eutils linux-mod
+
+## NOTE:
+#
+#
+
+BRI_VERSION="0.3.0-PRE-1v"
+FLORZ_VERSION="0.3.0-PRE-1o_florz-12"
+
+IUSE="bri ecmark ecmark2 ecmark3 ecaggressive eckb1 ecmg2 ecsteve ecsteve2 florz rtc ukcid watchdog zapras zapnet"
+
+MY_P="${P/_/-}"
+
+DESCRIPTION="Drivers for Digium and ZapataTelephony cards"
+HOMEPAGE="http://www.asterisk.org"
+SRC_URI="http://ftp.digium.com/pub/zaptel/releases/${MY_P}.tar.gz
+        bri? ( http://www.junghanns.net/downloads/bristuff-${BRI_VERSION}.tar.gz )
+        florz? ( http://www.netdomination.org/pub/asterisk/zaphfc_${FLORZ_VERSION}.diff.gz )"
+
+S="${WORKDIR}/${MY_P}"
+
+S_BRI="${WORKDIR}/bristuff-${BRI_VERSION}"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~ppc ~x86"
+
+DEPEND="virtual/libc
+       virtual/linux-sources
+       dev-libs/libusb
+       >=dev-libs/newt-0.50.0"
+
+# list of echo canceller use flags,
+# first active in this list is selected (=order does matter)
+ZAP_EC_FLAGS="ecmark ecmark2 ecmark3 ecsteve ecsteve2 eckb1 ecmg2"
+
+### Begin: Helper functions
+
+select_echo_cancel() {
+       local myEC=""
+
+       for x in ${ZAP_EC_FLAGS}; do
+               if use $x; then
+                       myEC=$(echo "$x" | sed -e "s:^ec::" | tr '[:lower:]' '[:upper:]')
+                       break;
+               fi
+       done
+
+       echo ${myEC}
+}
+
+zconfig_disable() {
+       if grep -q "${1}" ${S}/zconfig.h; then
+               # match a little more than ${1} so we can use zconfig_disable
+               # to disable all echo cancellers in zconfig.h w/o calling it several times
+               sed -i -e "s:^[ \t]*#define[ \t]\+\(${1}[a-zA-Z0-9_-]*\).*:#undef \1:" \
+                       ${S}/zconfig.h
+       fi
+
+       return $?
+}
+
+zconfig_enable() {
+       if grep -q "${1}" ${S}/zconfig.h; then
+               sed -i  -e "s:^/\*[ \t]*#define[ \t]\+\(${1}\).*:#define \1:" \
+                       -e "s:^[ \t]*#undef[ \t]\+\(${1}\).*:#define \1:" \
+                       ${S}/zconfig.h
+       fi
+
+       return $?
+}
+
+### End: Helper functions
+
+pkg_setup() {
+       local result=0 numec=0
+
+       linux-mod_pkg_setup
+
+       einfo "Running pre-flight checks..."
+
+       # basic zaptel checks
+       if kernel_is 2 4 ; then
+               if ! linux_chkconfig_present CRC32; then
+                       echo
+                       eerror "Your kernel lacks CRC32 support!"
+                       eerror "Enable CONFIG_CRC32!"
+                       result=$((result+1))
+               fi
+       else
+               if ! linux_chkconfig_present CRC_CCITT; then
+                       echo
+                       eerror "Your kernel lacks CRC_CCIT support!"
+                       eerror "Enable CONFIG_CRC_CCIT!"
+                       result=$((result+1))
+               fi
+       fi
+
+       # check if multiple echo cancellers have been selected
+       for x in ${ZAP_EC_FLAGS}; do
+               use $x && numec=$((numec+1))
+       done
+       if [[ $numec -gt 1 ]]; then
+               # multiple flags are active, only the first in the ZAP_EC_FLAGS list
+               # will be used, make sure the user knows about this
+               echo
+               ewarn "Multiple echo canceller flags are active but only one will be used!"
+               ewarn "Selected: $(select_echo_cancel)"
+       fi
+
+       # we need at least HDLC generic support
+       if use zapnet && ! linux_chkconfig_present HDLC; then
+               echo
+               eerror "zapnet: Your kernel lacks HDLC support!"
+               eerror "zapnet: Enable CONFIG_HDLC* to use zaptel network support!"
+               result=$((result+1))
+       fi
+
+       # zapras needs PPP support
+       if use zapras && ! linux_chkconfig_present PPP; then
+               echo
+               eerror "zapras: Your kernel lacks PPP support!"
+               eerror "zapras: Enable CONFIG_PPP* to use zaptel ras support!"
+               result=$((result+1))
+       fi
+
+       # rtc needs linux-2.6 and CONFIG_RTC
+       if use rtc; then
+               if ! kernel_is 2 6; then
+                       echo
+                       eerror "rtc: >=Linux-2.6.0 is needed for rtc support!"
+                       result=$((result+1))
+               fi
+
+               if ! linux_chkconfig_present RTC; then
+                       eerror "rtc: Your kernel lacks RealTime-Clock support!"
+                       result=$((result+1))
+               fi
+       fi
+
+       if [[ $result -gt 0 ]]; then
+               echo
+               ewarn "One or more of the neccessary precondition(s) is/are not met!"
+               ewarn "Look at the messages above, resolve the problem (or disable the use-flag) and try again"
+               echo
+
+               if [[ $result -lt 3 ]]; then
+                       eerror "[$result Error(s)] Zaptel is not happy :("
+               else
+                       eerror "[$result Error(s)] You're making zaptel cry :'("
+               fi
+               die "[$result] Precondition(s) not met"
+       fi
+
+       echo
+       einfo "Zaptel is happy and continues... :)"
+}
+
+src_unpack() {
+       unpack ${A}
+
+       cd ${S}
+       epatch ${FILESDIR}/${P}-gentoo.diff
+       epatch ${FILESDIR}/zaptel-1.2.9.1-gcc411_is_a_retard-kbuild.patch
+       epatch ${FILESDIR}/zaptel-1.2.9.1-ar.patch
+
+       use ukcid && \
+               epatch ${FILESDIR}/${PN}-1.2.0-ukcid.patch
+
+       # try to apply bristuff patch
+       if use bri; then
+               # fix for userpriv
+               chmod -R a=rwX ${S_BRI}
+
+               einfo "Patching zaptel w/ BRI stuff (${BRI_VERSION})"
+               epatch ${S_BRI}/patches/zaptel.patch
+
+               cd ${S_BRI}
+
+               if use florz; then
+                       einfo "Using florz patches (${FLORZ_VERSION}) for zaphfc"
+
+                       # remove as soon as there's a new florz patch available
+                       sed -i -e "s:zaptel-1\.2\.5:zaptel-1.2.6:g" \
+                               ${WORKDIR}/zaphfc_${FLORZ_VERSION}.diff
+
+                       epatch ${WORKDIR}/zaphfc_${FLORZ_VERSION}.diff
+               fi
+
+               # patch includes
+               sed -i  -e "s:^#include.*zaptel\.h.*:#include <zaptel.h>:" \
+                       qozap/qozap.c \
+                       zaphfc/zaphfc.c \
+                       cwain/cwain.c
+
+               # patch makefiles
+               sed -i  -e "s:^ZAP[\t ]*=.*:ZAP=-I${S}:" \
+                       -e "s:^MODCONF=.*:MODCONF=/etc/modules.d/zaptel:" \
+                       -e "s:linux-2.6:linux:g" \
+                       qozap/Makefile \
+                       zaphfc/Makefile \
+                       cwain/Makefile
+
+               sed -i  -e "s:^\(CFLAGS+=-I. \).*:\1 \$(ZAP):" \
+                       zaphfc/Makefile
+
+               cd ${S}
+       fi
+
+### Configuration changes
+       local myEC
+
+       # prepare zconfig.h
+       myEC=$(select_echo_cancel)
+       if [[ -n "${myEC}" ]]; then
+               einfo "Selected echo canceller: ${myEC}"
+               # disable default first, set new selected ec afterwards
+               zconfig_disable ECHO_CAN
+               zconfig_enable ECHO_CAN_${myEC}
+       fi
+
+       # enable rtc support on 2.6
+       if use rtc && linux_chkconfig_present RTC && kernel_is 2 6; then
+               einfo "Enabling ztdummy RTC support"
+               zconfig_enable USE_RTC
+       fi
+
+       # enable agressive echo surpression
+       use ecaggressive && \
+               zconfig_enable AGGRESSIVE_SUPPRESSOR
+
+       # ppp ras support
+       use zapras && \
+               zconfig_enable CONFIG_ZAPATA_PPP
+
+       # frame relay, syncppp...
+       use zapnet && \
+               zconfig_enable CONFIG_ZAPATA_NET
+
+       # zaptel watchdog
+       use watchdog && \
+               zconfig_enable CONFIG_ZAPTEL_WATCHDOG
+}
+
+src_compile() {
+       # build
+       make KVERS=${KV_FULL} \
+            KSRC=${KV_DIR} ARCH=$(tc-arch-kernel) || die
+
+       cd ${S}/xpp/utils
+       make || die "make xpp utils failed"
+
+       if use bri; then
+               cd ${S_BRI}
+               for x in cwain qozap zaphfc; do
+                       einfo "Building ${x}..."
+                       make KVERS=${KV_FULL} \
+                               KSRC=/usr/src/linux \
+                               ARCH=$(tc-arch-kernel) \
+                               -C ${x} || die "make ${x} failed"
+               done
+       fi
+}
+
+src_install() {
+       kernel_is 2 4 && cp /etc/modules.conf ${D}/etc
+       make INSTALL_PREFIX=${D} ARCH=$(tc-arch-kernel) \
+            KVERS=${KV_FULL} KSRC=/usr/src/linux install || die
+
+       dodoc ChangeLog README README.udev README.Linux26 README.fxsusb zaptel.init
+       dodoc zaptel.conf.sample LICENSE zaptel.sysconfig README.fxotune
+
+       # additional tools
+       dobin ztmonitor ztspeed zttest fxotune
+
+       # install all header files, several packages need the complete set
+       # (e.g. sangoma wanpipe)
+       insinto /usr/include/zaptel
+       doins *.h
+
+       if use bri; then
+               einfo "Installing bri"
+               cd ${S_BRI}
+
+               insinto /lib/modules/${KV_FULL}/misc
+               doins qozap/qozap.${KV_OBJ}
+               doins zaphfc/zaphfc.${KV_OBJ}
+               doins cwain/cwain.${KV_OBJ}
+
+               # install example configs for octoBRI and quadBRI
+               insinto /etc
+               doins qozap/zaptel.conf.octoBRI
+               newins qozap/zaptel.conf zaptel.conf.quadBRI
+               newins zaphfc/zaptel.conf zaptel.conf.zaphfc
+
+               insinto /etc/asterisk
+               doins qozap/zapata.conf.octoBRI
+               newins qozap/zapata.conf zapata.conf.quadBRI
+               newins zaphfc/zapata.conf zapata.conf.zaphfc
+
+               docinto bristuff
+               dodoc CHANGES INSTALL
+
+               docinto bristuff/qozap
+               dodoc qozap/LICENSE qozap/TODO qozap/*.conf*
+
+               docinto bristuff/zaphfc
+               dodoc zaphfc/LICENSE zaphfc/*.conf
+
+               docinto bristuff/cwain
+               dodoc cwain/TODO cwain/LICENSE
+
+               cd ${S}
+       fi
+
+       # install init script
+       newinitd ${FILESDIR}/zaptel.rc6 zaptel
+       newconfd ${FILESDIR}/zaptel.confd zaptel
+
+       # install devfsd rule file
+       insinto /etc/devfs.d
+       newins ${FILESDIR}/zaptel.devfsd zaptel
+
+       # install udev rule file
+       insinto /etc/udev/rules.d
+       newins ${FILESDIR}/zaptel.udevd 10-zaptel.rules
+
+       # fix permissions if there's no udev / devfs around
+       if [[ -d ${D}/dev/zap ]]; then
+               chown -R root:dialout   ${D}/dev/zap
+               chmod -R u=rwX,g=rwX,o= ${D}/dev/zap
+       fi
+
+       # install xpp utils
+       cd ${S}/xpp/utils
+       make DESTDIR=${D} install || die "failed xpp utils install"
+}
+
+pkg_postinst() {
+       linux-mod_pkg_postinst
+
+       echo
+       einfo "Use the /etc/init.d/zaptel script to load zaptel.conf settings on startup!"
+       echo
+
+       if use bri; then
+               einfo "Bristuff configs have been merged as:"
+               einfo ""
+               einfo "${ROOT}etc/"
+               einfo "    zaptel.conf.zaphfc"
+               einfo "    zaptel.conf.quadBRI"
+               einfo "    zaptel.conf.octoBRI"
+               einfo ""
+               einfo "${ROOT}etc/asterisk/"
+               einfo "    zapata.conf.zaphfc"
+               einfo "    zapata.conf.quadBRI"
+               einfo "    zapata.conf.octoBRI"
+               echo
+       fi
+
+       # fix permissions if there's no udev / devfs around
+       if [[ -d ${ROOT}dev/zap ]]; then
+               chown -R root:dialout   ${ROOT}dev/zap
+               chmod -R u=rwX,g=rwX,o= ${ROOT}dev/zap
+       fi
+}