forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
kmplayer-0.12.0b.ebuild
85 lines (74 loc) · 2.03 KB
/
kmplayer-0.12.0b.ebuild
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-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
EGIT_BRANCH="0.12"
KDE_HANDBOOK="true"
inherit kde5
DESCRIPTION="Video player plugin for Konqueror and basic MPlayer frontend"
HOMEPAGE="https://kmplayer.kde.org"
SRC_URI="mirror://kde/stable/${PN}/${EGIT_BRANCH}/${P}.tar.bz2"
LICENSE="GPL-2 FDL-1.2 LGPL-2.1"
KEYWORDS="amd64 x86"
IUSE="cairo npp"
CDEPEND="
$(add_frameworks_dep kbookmarks)
$(add_frameworks_dep kcompletion)
$(add_frameworks_dep kconfig)
$(add_frameworks_dep kconfigwidgets)
$(add_frameworks_dep kcoreaddons)
$(add_frameworks_dep kdelibs4support)
$(add_frameworks_dep ki18n)
$(add_frameworks_dep kiconthemes)
$(add_frameworks_dep kio)
$(add_frameworks_dep kmediaplayer)
$(add_frameworks_dep kparts)
$(add_frameworks_dep ktextwidgets)
$(add_frameworks_dep kwidgetsaddons)
$(add_frameworks_dep kxmlgui)
$(add_qt_dep qtdbus)
$(add_qt_dep qtgui)
$(add_qt_dep qtsvg)
$(add_qt_dep qtwidgets)
$(add_qt_dep qtx11extras)
$(add_qt_dep qtxml)
media-libs/phonon[qt5(+)]
x11-libs/libX11
x11-libs/libxcb
cairo? ( x11-libs/cairo[xcb] )
npp? (
dev-libs/dbus-glib
dev-libs/glib:2
www-plugins/adobe-flash:*
>=x11-libs/gtk+-2.10.14:2
)
"
DEPEND="${CDEPEND}
sys-devel/gettext
"
RDEPEND="${CDEPEND}
media-video/mplayer
!media-video/kmplayer:4
"
src_prepare() {
if use npp; then
sed -i src/kmplayer_part.desktop \
-e ":^MimeType: s:=:=application/x-shockwave-flash;:" || die
fi
kde5_src_prepare
}
src_configure() {
# 0.12: expat build broken, check in later releases
local mycmakeargs=(
-DKMPLAYER_BUILT_WITH_EXPAT=OFF
-DKMPLAYER_BUILT_WITH_CAIRO=$(usex cairo)
-DKMPLAYER_BUILT_WITH_NPP=$(usex npp)
)
kde5_src_configure
}
src_install() {
kde5_src_install
if use npp; then
kwriteconfig5 --file "${ED}/usr/share/config/kmplayerrc" --group "application/x-shockwave-flash" --key player npp
kwriteconfig5 --file "${ED}/usr/share/config/kmplayerrc" --group "application/x-shockwave-flash" --key plugin /usr/lib/nsbrowser/plugins/libflashplayer.so
fi
}