net-misc/youtube-dl: Version 2019.03.09
[gentoo.git] / net-misc / dahdi-tools / dahdi-tools-2.10.2.ebuild
1 # Copyright 1999-2017 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=5
5
6 inherit base
7
8 DESCRIPTION="Userspace tools to configure the kernel modules from net-misc/dahdi"
9 HOMEPAGE="http://www.asterisk.org"
10 SRC_URI="http://downloads.asterisk.org/pub/telephony/${PN}/releases/${P}.tar.gz
11         mirror://gentoo/gentoo-${PN}-patchset-0.4.tar.bz2"
12
13 LICENSE="LGPL-2.1"
14 SLOT="0"
15 KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
16 IUSE="ppp"
17
18 DEPEND="dev-libs/newt
19         ppp? ( net-dialup/ppp )
20         >=net-misc/dahdi-2.5.0
21         !net-misc/zaptel
22         >=sys-kernel/linux-headers-2.6.35
23         virtual/libusb:0"
24 RDEPEND="${DEPEND}"
25
26 EPATCH_SUFFIX="diff"
27 PATCHES=( "${WORKDIR}/${PN}-patchset" )
28
29 src_prepare() {
30         base_src_prepare
31         sed -i \
32                 -e 's:-Werror::' \
33                 Makefile xpp/Makefile || die
34 }
35
36 src_compile() {
37         default_src_compile
38         emake tests
39         use ppp && emake -C ppp
40 }
41
42 src_install() {
43         emake DESTDIR="${D}" install
44         use ppp && emake DESTDIR="${D}" -C ppp install
45         emake DESTDIR="${D}" config
46
47         dosbin patgen pattest patlooptest hdlcstress hdlctest hdlcgen hdlcverify timertest
48
49         # install init scripts
50         newinitd "${FILESDIR}"/dahdi.init2 dahdi
51         newinitd "${FILESDIR}"/dahdi-autoconf.init2 dahdi-autoconf
52         newconfd "${FILESDIR}"/dahdi-autoconf.conf2 dahdi-autoconf
53 }