c587c4404e12cfa748249dd9554eb0d9eae917cd
[gentoo.git] / x11-libs / libdesktop-agnostic / libdesktop-agnostic-0.3.92-r1.ebuild
1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=5
5
6 PYTHON_COMPAT=( python2_7 )
7 PYTHON_REQ_USE="threads(+)"
8 VALA_USE_DEPEND="vapigen"
9
10 inherit python-single-r1 waf-utils vala
11
12 DESCRIPTION="A desktop-agnostic library for GLib-based projects"
13 HOMEPAGE="https://launchpad.net/libdesktop-agnostic"
14 SRC_URI="https://launchpad.net/${PN}/0.4/${PV}/+download/${P}.tar.gz"
15
16 LICENSE="GPL-2 LGPL-2.1"
17 SLOT="0"
18 KEYWORDS="amd64 x86"
19 IUSE="debug +gconf glade gnome +introspection"
20
21 RDEPEND=">=dev-libs/glib-2
22         dev-python/pygobject:2[${PYTHON_USEDEP}]
23         dev-python/pygtk:2[${PYTHON_USEDEP}]
24         x11-libs/gtk+:2
25         gconf? ( gnome-base/gconf:2 )
26         glade? ( gnome-base/libglade:2.0 )
27         gnome? ( gnome-base/gnome-desktop:2 )
28         ${PYTHON_DEPS}"
29 DEPEND="${RDEPEND}
30         $(vala_depend)
31         dev-libs/gobject-introspection
32         introspection? ( x11-libs/gtk+:2[introspection] )"
33
34 REQUIRED_USE=${PYTHON_REQUIRED_USE}
35
36 src_configure() {
37         local cfg="keyfile" fdo="glib" myconf=""
38
39         use gconf && cfg="gconf,${cfg}"
40         use gnome && fdo="${fdo},gnome"
41         use debug && myconf="${myconf} --enable-debug"
42         use glade && myconf="${myconf} --with-glade"
43         use introspection || myconf="${myconf} --disable-gi"
44
45         waf-utils_src_configure \
46                 --sysconfdir="${EPREFIX}"/etc \
47                 --config-backends=${cfg} \
48                 --desktop-entry-backends=${fdo} \
49                 --vfs-backends=gio \
50                 ${myconf}
51 }