summaryrefslogtreecommitdiff
blob: c7ec7098d461dec3d6cba8fa2695f2a6f765ea1b (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
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI="2"

inherit autotools eutils

DESCRIPTION="An object-oriented library which represents simple XML-RPC solution for client and server side."
HOMEPAGE="http://libiqxmlrpc.wikidot.com/"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"

LICENSE="LGPL-2"
SLOT="0"
KEYWORDS="~x86 ~amd64"
IUSE="doc debug"

RDEPEND="=dev-cpp/libxmlpp-1*
	dev-libs/libxml2
	>=dev-libs/boost-1.35.0-r5
	dev-libs/openssl"
DEPEND="${RDEPEND}
	doc? ( app-doc/doxygen )"

src_prepare() {
	epatch "${FILESDIR}/${PV}-boost_test_framework_detection.patch"
	AT_M4DIR="m4"
	eautoreconf
}

src_configure() {
	econf \
		$(use_enable doc docs) \
		$(use_enable debug) \
		--with-boost-unit-test-framework
}

src_compile() {
	# otherwise the package ignores them
	emake CXXFLAGS="${CXXFLAGS}" LDFLAGS="${LDFLAGS}" || die "emake failed"
}

src_install() {
	# We install the docs manually, because: i) sandbox violations ii) wrong location
	emake DESTDIR="${D}" MKDOC=no install || die "emake install failed"
	dodoc ChangeLog README NEWS
	use doc && dohtml doc/libiqxmlrpc.html/*
}