summaryrefslogtreecommitdiff
blob: 988ddf73b0fb6ba6d9e99faa54d1873a3549a7db (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
74
75
76
77
78
79
80
81
82
83
84
85
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI="5"
GCONF_DEBUG="no"
PYTHON_COMPAT=( python{3_3,3_4} )
VALA_API_MIN_VERSION="0.20"

inherit gnome2 python-single-r1 vala

DESCRIPTION="Code assistance services for various programming languages"
HOMEPAGE="https://wiki.gnome.org/Projects/CodeAssistance"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64"
IUSE="c css javascript json python vala xml"

REQUIRED_IUSE="
	python? ( ${PYTHON_REQUIRED_USE} )
	c? ( python )
	sh? ( python )
	xml? ( python )
"

RDEPEND="
	c? (
		sys-devel/llvm
	)
	css? (
		|| (
			dev-lang/ruby:2.0
			dev-lang/ruby:1.9
		)
		dev-ruby/sass
	)
	javascript? ( dev-libs/gjs )
	json? (
		${PYTHON_DEPS}
		dev-python/simplejson[${PYTHON_USEDEP}]
	)
	python? (
		${PYTHON_DEPS}
		dev-libs/gobject-introspection
		dev-python/dbus-python[${PYTHON_USEDEP}]
		>=dev-python/pygobject-3.8:3[${PYTHON_USEDEP}]
	)
	vala? (
		$(vala_depend)
		>=dev-libs/glib-2.36:2
		dev-libs/libgee:0.8[introspection]
	)
	xml? ( ${PYTHON_DEPS} )
"
# ruby supports needs ruby-rdbus
# go support with dev-lang/go
DEPEND="${RDEPEND}
"

pkg_setup() {
	use python && python-single-r1_pkg_setup
}

src_prepare() {
	vala_src_prepare
	gnome2_src_prepare
}

# FIXME: automagic for ruby interpreter
src_configure() {
	python_export_best
	gnome2_src_configure \
		$(use_enable c) \
		$(use_enable css) \
		--disable-go \
		$(use_enable javascript js) \
		$(use_enable json) \
		$(use_enable python) \
		--disable-ruby \
		--enable-sh \
		$(use_enable vala) \
		$(use_enable xml) \
		PYTHON=${PYTHON}
}