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

EAPI="4"
PYTHON_DEPEND="python? *"

inherit autotools eutils python

MY_PN=openchange
MY_P=${MY_PN}-${PV}-BORG

DESCRIPTION="Portable open-source implementations of Exchange protocols"
HOMEPAGE="http://www.openchange.org/"
SRC_URI="http://tracker.openchange.org/attachments/download/180/${MY_P}.tar.gz"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64"
IUSE="python"

RDEPEND=">=net-fs/samba-4.0.0_rc2
	dev-libs/boost
	python? ( dev-lang/python )"

DEPEND="${RDEPEND}"

S=${WORKDIR}/${MY_P}

src_prepare() {
	epatch "${FILESDIR}"/"${MY_P}"-python-location-fix.patch
	epatch "${FILESDIR}"/"${MY_P}"-fix-soname-QA.patch
	eaclocal
	eautoconf
}
src_configure() {
	ECONF="--disable-coverage
		$(use_enable python pymapi)"

	econf ${ECONF}
}

src_compile() {
	emake libmapi libmapixx || die "libmapi compilation failed"
}

src_install() {
	emake DESTDIR="${D}" libmapi-install libmapixx-install || die "libmapi install failed"

	if use python ; then
		emake DESTDIR="${D}" python-install || die "pymapi install failed"
	fi
}