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

EAPI=5

AUTOTOOLS_AUTORECONF="1"

inherit autotools-utils flag-o-matic git-2

DESCRIPTION="Stereoscopic and multi-display media player"
HOMEPAGE="http://bino3d.org/"
EGIT_REPO_URI="git://git.savannah.nongnu.org/bino.git"
EGIT_PROJECT="${PN}"
EGIT_BRANCH="master"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="debug doc libav lirc"

IUSE_VIDEO_CARDS="
	video_cards_nvidia"
IUSE+="${IUSE_VIDEO_CARDS}"

LANGS="en bg de fr ru zh_CN"
for X in ${LANGS} ; do
	IUSE+=" linguas_${X}"
done

RDEPEND=">=media-libs/glew-1.6.0
	>=media-libs/openal-1.15.1
	dev-qt/qtgui:4
	dev-qt/qtcore:4
	dev-qt/qtopengl:4
	>=media-libs/libass-0.9.9
	libav? ( >=media-video/libav-0.7:0= )
	!libav? ( >=media-video/ffmpeg-0.7:0= )
	lirc? ( app-misc/lirc )
	video_cards_nvidia? ( media-video/nvidia-settings )
	virtual/libintl"

DEPEND="${RDEPEND}
	sys-devel/gettext
	virtual/pkgconfig"

DOCS=( AUTHORS ChangeLog NEWS README README.Linux )

PATCHES=(
	"${FILESDIR}/${PN}-1.4.2-lirc-detect.patch" # detect lirc
)

src_configure() {
	local myeconfargs=(
		$(use_with video_cards_nvidia xnvctrl)
		$(use_with lirc liblircclient)
		$(use_enable debug)
		--without-equalizer
		--htmldir=/usr/share/doc/${PF}/html
	)

	use video_cards_nvidia && append-cppflags "-I/usr/include/NVCtrl" \
		&& append-ldflags "-L/usr/$(get_libdir)/opengl/nvidia/lib \
		-L/usr/$(get_libdir)" && append-libs "Xext"
	use lirc && append-cppflags "-I/usr/include/lirc" \
		&& append-libs "lirc_client"

	# Fix a compilation error because of a multiple definitions in glew
	append-ldflags "-zmuldefs"

	autotools-utils_src_configure
}

src_install() {
	autotools-utils_src_install

	use doc || ( rm -rf "${D}"/usr/share/doc/${PF}/html && dohtml "${FILESDIR}/${PN}.html" )
}