blob: 45760874ebe45a28cfef8faea5ff8c22c41f75ab (
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
|
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-irc/mistbot/mistbot-0.9.ebuild,v 1.5 2007/10/30 22:04:44 angelos Exp $
inherit eutils multilib toolchain-funcs
DESCRIPTION="A modular IRC-Bot written in C++"
HOMEPAGE="http://kuja.in/mistbot/"
SRC_URI="http://znc.in/~psychon/mistbot/downloads/${P}.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~sparc ~x86"
IUSE="doc xml nls debug ssl"
RDEPEND="virtual/libc
dev-libs/confuse
net-dns/c-ares
xml? ( dev-libs/libxml2 )"
DEPEND="${RDEPEND}
doc? ( app-doc/doxygen
app-text/xmlto )"
src_compile() {
ebegin "Change build.conf to fit needs"
if ! use xml; then
sed -e '/^MODS\ +=\ rss$/d' -i build.conf || die "sed failed"
fi
if ! use nls; then
sed -e '/^NLS\ =\ nls$/d' -i build.conf || die "sed failed"
fi
if ! use debug; then
sed -e '/^DEBUG\ =\ debug$/d' -i build.conf || die "sed failed"
fi
if ! use ssl; then
sed -e '/^SSL\ =\ ssl$/d' -i build.conf || die "sed failed"
fi
sed -e 's/^#ONCE\ =\ yes$/ONCE\ =\ yes/' -i build.conf || die "sed failed"
sed -re "/(PC|MOD|SCRIPT)DIR/s/lib/$(get_libdir)/" -i Makefile || die "sed failed"
echo "CXXFLAGS=${CXXFLAGS}" >> build.conf
echo "CXX=$(tc-getCXX)" >> build.conf
echo "LDFLAGS=${LDFLAGS}" >> build.conf
echo "PREFIX=/usr" >> build.conf
ebegin "compiling source"
emake all-oneGo || die "emake failed"
if use doc; then
ebegin "generate documentation"
emake doc || die "make doc failed"
fi
}
src_install() {
emake DESTDIR="${D}" install
dodoc AUTHORS mistbot.conf
dosym ${P} /usr/bin/${PN}
if use doc; then
dodoc doc/userdoc.html
insinto /usr/share/doc/${PF}/api
doins doc/api/* || die "install API docs failed"
fi
}
|