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

EAPI=6

PYTHON_COMPAT=( python2_7 )
inherit multilib-minimal python-single-r1

DESCRIPTION="Codec for karaoke and text encapsulation for Ogg"
HOMEPAGE="https://code.google.com/p/libkate/"
SRC_URI="https://libkate.googlecode.com/files/${P}.tar.gz"

LICENSE="BSD"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc x86 ~amd64-fbsd ~x86-fbsd"

IUSE="debug doc wxwidgets"
REQUIRED_USE="wxwidgets? ( ${PYTHON_REQUIRED_USE} )"

COMMON_DEPEND="
	media-libs/libogg:=[${MULTILIB_USEDEP}]
	media-libs/libpng:0=[${MULTILIB_USEDEP}]
"
DEPEND="${COMMON_DEPEND}
	virtual/pkgconfig[${MULTILIB_USEDEP}]
	sys-devel/flex[${MULTILIB_USEDEP}]
	sys-devel/bison
	doc? ( app-doc/doxygen )
"
RDEPEND="${COMMON_DEPEND}
	wxwidgets? (
		${PYTHON_DEPS}
		dev-python/wxpython:3.0[${PYTHON_USEDEP}]
		media-libs/liboggz )
"

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

multilib_src_configure() {
	local ECONF_SOURCE=${S}
	econf \
		--disable-static \
		$(use_enable debug) \
		$(multilib_native_use_enable doc) \
		$(multilib_native_usex wxwidgets '' 'PYTHON=:')
}

multilib_src_install_all() {
	einstalldocs
	find "${D}" -name '*.la' -delete || die
	use wxwidgets && python_fix_shebang "${D}"
}