blob: 934331c7a09a7e440c6973a8921374fbb2759627 (
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
|
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-libs/libnih/libnih-1.0.3.ebuild,v 1.1 2011/10/19 17:27:02 vapier Exp $
EAPI="2"
inherit versionator eutils autotools
DESCRIPTION="Light-weight 'standard library' of C functions"
HOMEPAGE="https://launchpad.net/libnih"
SRC_URI="http://launchpad.net/${PN}/$(get_version_component_range 1-2)/${PV}/+download/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~arm ~x86"
IUSE="dbus nls static-libs test +threads"
RDEPEND="dbus? ( dev-libs/expat >=sys-apps/dbus-1.2.16 )"
DEPEND="${RDEPEND}
sys-devel/gettext
dev-util/pkgconfig
test? ( dev-util/valgrind )"
src_prepare() {
epatch "${FILESDIR}"/${PN}-1.0.3-optional-dbus.patch
epatch "${FILESDIR}"/${PN}-1.0.3-pkg-config.patch
eautoreconf
}
src_configure() {
econf \
$(use_with dbus) \
$(use_enable nls) \
$(use_enable static-libs static) \
$(use_enable threads) \
$(use_enable threads threading)
}
src_install() {
emake DESTDIR="${D}" install || die
# we need to be in / because upstart needs libnih
gen_usr_ldscript -a nih nih-dbus
use static-libs || rm "${D}"/usr/lib*/*.la
dodoc AUTHORS ChangeLog HACKING NEWS README TODO
}
|