Gentoo Archives: gentoo-commits

From: "Stefan Schweizer (genstef)" <genstef@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-dialup/misdn: ChangeLog misdn-1.1.6.ebuild
Date: Mon, 22 Oct 2007 19:03:07
Message-Id: E1Ik2YH-0005G0-OP@stork.gentoo.org
1 genstef 07/10/22 19:03:01
2
3 Modified: ChangeLog
4 Added: misdn-1.1.6.ebuild
5 Log:
6 version bump
7 (Portage version: 2.1.3.15)
8
9 Revision Changes Path
10 1.25 net-dialup/misdn/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-dialup/misdn/ChangeLog?rev=1.25&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-dialup/misdn/ChangeLog?rev=1.25&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-dialup/misdn/ChangeLog?r1=1.24&r2=1.25
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/net-dialup/misdn/ChangeLog,v
19 retrieving revision 1.24
20 retrieving revision 1.25
21 diff -u -r1.24 -r1.25
22 --- ChangeLog 7 Jul 2007 10:21:39 -0000 1.24
23 +++ ChangeLog 22 Oct 2007 19:03:01 -0000 1.25
24 @@ -1,6 +1,12 @@
25 # ChangeLog for net-dialup/misdn
26 # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/net-dialup/misdn/ChangeLog,v 1.24 2007/07/07 10:21:39 genstef Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/net-dialup/misdn/ChangeLog,v 1.25 2007/10/22 19:03:01 genstef Exp $
29 +
30 +*misdn-1.1.6 (22 Oct 2007)
31 +
32 + 22 Oct 2007; Stefan Schweizer <genstef@g.o>
33 + +files/misdn-2.6.23.diff, +misdn-1.1.6.ebuild:
34 + version bump
35
36 *misdn-1.1.5 (07 Jul 2007)
37
38
39
40
41 1.1 net-dialup/misdn/misdn-1.1.6.ebuild
42
43 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-dialup/misdn/misdn-1.1.6.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-dialup/misdn/misdn-1.1.6.ebuild?rev=1.1&content-type=text/plain
45
46 Index: misdn-1.1.6.ebuild
47 ===================================================================
48 # Copyright 1999-2007 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/net-dialup/misdn/misdn-1.1.6.ebuild,v 1.1 2007/10/22 19:03:01 genstef Exp $
51
52 inherit eutils linux-mod
53
54 MY_P=mISDN-${PV//./_}
55 DESCRIPTION="mISDN is the new ISDN stack of the linux kernel 2.6."
56 HOMEPAGE="http://www.misdn.org/"
57 SRC_URI="http://www.misdn.org/downloads/releases/${MY_P}.tar.gz"
58
59 LICENSE="GPL-2"
60 SLOT="0"
61 KEYWORDS="~x86 ~amd64 ~ppc"
62
63 # list of echo canceller use flags,
64 # first active in this list is selected (=order does matter)
65 MISDN_EC_FLAGS="ecmg2 eckb1 ecmark2"
66
67 # list of card modules
68 MISDN_MODULES=("avmfritz" "hfcpci" "hfcmulti" "hfcsusb" "hfcsmini" "xhfc" "sedlfax" "w6692pci" "netjetpci")
69 MISDN_KCONFIG=("AVM_FRITZ" "HFCPCI" "HFCMULTI" "HFCUSB" "HFCMINI" "XHFC" "SPEEDFAX" "W6692" "NETJET")
70
71 IUSE="ecaggressive ${MISDN_EC_FLAGS}"
72 for i in ${MISDN_MODULES[@]}; do IUSE="${IUSE} misdn_cards_${i}"; done
73
74 RDEPEND=">=net-dialup/capi4k-utils-20050718
75 sys-devel/bc"
76
77 S=${WORKDIR}/${MY_P}/drivers/isdn/hardware/mISDN
78
79 ### Begin: Helper functions
80
81 select_echo_cancel() {
82 local myEC=""
83 for x in ${MISDN_EC_FLAGS}; do
84 if use ${x}; then
85 myEC=$(echo "${x}" | sed -e "s:^ec\(.*\):\U\1\E:")
86 break;
87 fi
88 done
89 echo ${myEC}
90 }
91
92 dsp_enable() {
93 local i
94 for i in "${@}"; do
95 sed -i -e "s:.*\(#include.*dsp_${i}\):\1:m" dsp.h
96 done
97 }
98
99 dsp_disable() {
100 local i
101 for i in "${@}"; do
102 sed -i -e "s:.*\(#include.*dsp_${i}\)://\1:m" dsp.h
103 done
104 }
105
106 ### End: Helper functions
107
108 pkg_setup() {
109 local numec=0
110
111 CONFIG_CHECK="ISDN_CAPI ISDN_CAPI_CAPI20 ISDN_CAPI_CAPIFS_BOOL"
112 linux-mod_pkg_setup
113 MODULE_NAMES="mISDN_capi(net:) mISDN_dtmf(net:) mISDN_l1(net:)
114 mISDN_x25dte(net:) l3udss1(net:) mISDN_core(net:) mISDN_isac(net:)
115 mISDN_l2(net:) mISDN_dsp(net:)"
116 BUILD_PARAMS="-C ${KV_DIR} SUBDIRS=${S} MINCLUDES=${WORKDIR}/${MY_P}/include CONFIG_MISDN_DRV=m CONFIG_MISDN_DSP=y"
117 BUILD_TARGETS="modules"
118 #I4LmISDN(net:) does not compile :( CONFIG_I4L_CAPI_LAYER=m
119 # the i4l->capi simulation seems to be only for kernel 2.4
120
121 # check if multiple echo cancellers have been selected
122 for x in ${MISDN_EC_FLAGS}; do
123 use ${x} && : $((numec++))
124 done
125 if [[ ${numec} -gt 1 ]]; then
126 # multiple flags are active, only the first in the ZAP_EC_FLAGS list
127 # will be used, make sure the user knows about this
128 ewarn
129 ewarn "Multiple echo canceller flags are active but only one will be used!"
130 ewarn "Selected: $(select_echo_cancel)"
131 fi
132
133 # Check existence of user selected cards
134 if [ -n "${MISDN_CARDS}" ]; then
135 for USERCARD in ${MISDN_CARDS} ; do
136 for ((CARD=0; CARD < ${#MISDN_MODULES[*]}; CARD++)); do
137 if [ "${USERCARD}" = "${MISDN_MODULES[CARD]}" ]; then
138 MODULE_NAMES="${MODULE_NAMES} ${MISDN_MODULES[CARD]}(net:)"
139 #[ "sedlfax" = "${MISDN_MODULES[CARD]}" ] && MODULE_NAMES="${MODULE_NAMES} faxl3(net:)"
140 BUILD_PARAMS="${BUILD_PARAMS} CONFIG_MISDN_${MISDN_KCONFIG[CARD]}=y"
141 continue 2
142 fi
143 done
144 die "Module ${USERCARD} not present in ${P}"
145 done
146 else
147 elog
148 elog "You can control the modules which are built with the variable"
149 elog "MISDN_CARDS which should contain a blank separated list"
150 elog "of a selection from the following cards:"
151 elog " ${MISDN_MODULES[*]}"
152 elog
153 ewarn "I give you the chance of hitting Ctrl-C and make the necessary"
154 ewarn "adjustments in /etc/make.conf."
155
156 # enable everything
157 for ((CARD=0; CARD < ${#MISDN_MODULES[*]}; CARD++)); do
158 MODULE_NAMES="${MODULE_NAMES} ${MISDN_MODULES[CARD]}(net:)"
159 #[ "sedlfax" = "${MISDN_MODULES[CARD]}" ] && MODULE_NAMES="${MODULE_NAMES} faxl3(net:)"
160 BUILD_PARAMS="${BUILD_PARAMS} CONFIG_MISDN_${MISDN_KCONFIG[CARD]}=y"
161 done
162 fi
163 }
164
165 src_unpack() {
166 unpack ${A}
167
168 cd "${S}"
169 kernel_is ge 2 6 23 && epatch ${FILESDIR}/misdn-2.6.23.diff
170
171 if use ecaggressive; then
172 sed -i -e "s:.*#define \(AGGRESSIVE_SUPPRESSOR\):#define \1:m" dsp.h
173 fi
174
175 case "$(select_echo_cancel)" in
176 MG2)
177 dsp_enable mg2ec
178 dsp_disable kb1ec mec2
179 ;;
180 KB1)
181 dsp_enable kb1ec
182 dsp_disable mg2ec mec2
183 ;;
184 MARK2)
185 dsp_enable mec2
186 dsp_disable mg2ec kb1ec
187 ;;
188 esac
189 }
190
191 src_install() {
192 linux-mod_src_install
193
194 insinto /usr/include/linux
195 doins "${WORKDIR}/${MY_P}/"include/linux/*.h
196
197 dodir /etc/udev/rules.d
198 echo 'KERNEL=="obj-*", NAME="mISDN", GROUP="dialout", MODE="0660"' \
199 > "${D}/etc/udev/rules.d/53-${PN}.rules"
200
201 insinto /etc/modules.d
202 newins "${WORKDIR}/${MY_P}/"mISDN.modprobe.d ${PN}
203
204 sed -i -e "s:USER=.*:USER=root:" \
205 -e "s:GROUP=.*:GROUP=dialout:" "${WORKDIR}/${MY_P}/"misdn-init
206 dosbin "${WORKDIR}/${MY_P}/"misdn-init
207
208 dodoc Kconfig.v2.6
209 dodoc "${FILESDIR}/README.hfcmulti" "${WORKDIR}/${MY_P}/"README.misdn-init
210 }
211
212 pkg_preinst() {
213 if [ -e "${ROOT}"/etc/misdn-init.conf ]; then
214 cp "${ROOT}"/etc/misdn-init.conf "${D}"/etc
215 else
216 sed -i -e "s:/etc/misdn-init.conf:${D}\0:" "${D}"/usr/sbin/misdn-init
217 "${D}"/usr/sbin/misdn-init config
218 sed -i -e "s:${D}/etc/misdn-init.conf:/etc/misdn-init.conf:" "${D}"/usr/sbin/misdn-init
219 fi
220 }
221
222 pkg_postinst() {
223 linux-mod_pkg_postinst
224
225 ewarn
226 ewarn "This driver is still under heavy development"
227 ewarn "Please report ebuild related bugs / wishes to http://bugs.gentoo.org"
228 ewarn "Please report driver bugs to the mISDN mailing-list:"
229 ewarn " https://www.isdn4linux.de/mailman/listinfo/isdn4linux"
230 }
231
232
233
234 --
235 gentoo-commits@g.o mailing list