blob: a7ee1699590bcc72f0ec08a4f077a91f2611e42c (
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
|
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit eutils subversion
DESCRIPTION="YATE - Yet Another Telephony Engine"
HOMEPAGE="http://yate.null.ro/"
SRC_URI=""
EAPI="1"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="doc gsm gtk h323 ilbc mysql postgres pri qt4 spandsp speex wanpipe zaptel"
COMMONDEPEND="gsm? ( media-sound/gsm )
gtk? ( >=x11-libs/gtk+-2.6.8 )
h323? ( dev-libs/pwlib >=net-libs/openh323-1.15.3 )
mysql? ( dev-db/mysql )
postgres? ( dev-db/postgresql )
pri? ( net-libs/libpri )
qt4? ( x11-libs/qt:4 )
spandsp? ( media-libs/spandsp )
speex? ( media-libs/speex )
wanpipe? ( net-misc/wanpipe )
zaptel? ( net-misc/zaptel )"
DEPEND="${COMMONDEPEND}
media-sound/sox
doc? ( || ( app-doc/doxygen >=dev-util/kdoc-2.0_alpha54 ) )"
RDEPEND="${COMMONDEPEND}"
ESVN_REPO_URI="http://yate.null.ro/svn/yate/trunk"
ESVN_BOOTSTRAP="./autogen.sh"
pkg_setup() {
if use qt4 && ! built_with_use x11-libs/qt:4 accessibility; then
eerror "Please make sure x11-libs/qt:4 is built with:"
eerror "\taccessibility"
die "Package dependencies not set up correctly"
fi
}
src_compile() {
local extraopts
# Figure out which doc generators are available.
if use doc && has_version app-doc/doxygen; then
extraopts+=" --with-doxygen"
else
extraopts+=" --without-doxygen"
fi
if use doc && has_version dev-util/kdoc; then
extraopts+=" --with-kdoc"
else
extraopts+=" --without-kdoc"
fi
econf \
$(use_enable ilbc) \
$(use_enable wanpipe) \
$(use_with gsm libgsm) \
$(use_with gtk libgtk2) \
$(use_with h323 openh323 /usr) \
$(use_with h323 pwlib /usr) \
$(use_with mysql mysql /usr) \
$(use_with postgres libpq /usr) \
$(use_with pri libpri) \
$(use_with qt4 libqt4) \
$(use_with spandsp) \
$(use_with speex libspeex) \
$(use_with wanpipe wphwec /usr/include/wanpipe) \
${extraopts} \
|| die "Configure failed"
emake DEBUG="-DNDEBUG" all || die "Building all failed"
if use doc; then
emake apidocs || die "Building API docs failed"
fi
}
src_install() {
emake DESTDIR=${D} install-noapi || die "emake install-noapi failed"
if use doc; then
emake DESTDIR=${D} install-api || die "emake install-api failed"
fi
newinitd ${FILESDIR}/yate.initd yate
newconfd ${FILESDIR}/yate.confd yate
if [ "${P}" != "${PF}" ]; then
cd ${D}/usr/share/doc
mv ${P} ${PF}
fi
insinto /usr/share/doc/${PF}/scripts
cp -a ${S}/share/scripts/* ${D}/usr/share/doc/${PF}/scripts/
rm -fr ${D}/usr/share/doc/${PF}/scripts/{Makefile*,.cvsignore}
find ${D}/usr/share/doc/${PF}/scripts/ -depth -delete -name ".svn" -a -type d
}
|