087bc0875c1dab773bcc726f1334199ba198e4e4
[gentoo.git] / media-video / pitivi / pitivi-0.97.1.ebuild
1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5 GNOME2_LA_PUNT="yes"
6 PYTHON_COMPAT=( python3_5 )
7 PYTHON_REQ_USE="sqlite"
8
9 inherit gnome2 python-single-r1 virtualx
10
11 DESCRIPTION="A non-linear video editor using the GStreamer multimedia framework"
12 HOMEPAGE="http://www.pitivi.org"
13
14 LICENSE="LGPL-2.1"
15 SLOT="0"
16 KEYWORDS="amd64 x86"
17
18 IUSE="v4l test"
19 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
20
21 # XXX: recommends gst-plugins-libav and frei0r-plugins
22
23 # Do not forget to check pitivi/check.py for dependencies!!!
24 # pycanberra, gnome-desktop, libav, libnotify and liwnck are optional
25 GST_VER="1.8.2"
26
27 COMMON_DEPEND="
28         ${PYTHON_DEPS}
29         >=dev-python/pycairo-1.10[${PYTHON_USEDEP}]
30         >=x11-libs/cairo-1.10
31
32         >=media-libs/gstreamer-${GST_VER}:1.0[introspection]
33         >=media-plugins/gst-transcoder-1.8.2-r1
34 "
35 RDEPEND="${COMMON_DEPEND}
36         >=dev-libs/glib-2.30.0:2
37
38         >=dev-libs/gobject-introspection-1.34:=
39         dev-python/dbus-python[${PYTHON_USEDEP}]
40         >=dev-python/gst-python-1.4:1.0[${PYTHON_USEDEP}]
41         dev-python/matplotlib[${PYTHON_USEDEP}]
42         dev-python/numpy[${PYTHON_USEDEP}]
43         dev-python/pycanberra[${PYTHON_USEDEP}]
44         >=dev-python/pygobject-3.8:3[${PYTHON_USEDEP}]
45
46         gnome-base/librsvg:=
47         gnome-base/gnome-desktop:3=[introspection]
48
49         >=media-libs/gstreamer-editing-services-${GST_VER}:1.0[introspection]
50         >=media-libs/gst-plugins-base-${GST_VER}:1.0[introspection]
51         >=media-libs/gst-plugins-bad-${GST_VER}:1.0[gtk]
52         >=media-libs/gst-plugins-good-${GST_VER}:1.0
53         >=media-plugins/gst-plugins-libav-${GST_VER}:1.0
54
55         x11-libs/libnotify[introspection]
56         x11-libs/libwnck:3[introspection]
57         >=x11-libs/gtk+-3.20.0:3[introspection]
58
59         v4l? ( >=media-plugins/gst-plugins-v4l2-${GST_VER}:1.0 )
60 "
61 DEPEND="${RDEPEND}
62         app-text/yelp-tools
63         dev-python/setuptools
64         >=dev-util/intltool-0.35.5
65         >=dev-util/meson-0.28.0
66         dev-util/itstool
67         sys-devel/gettext
68         virtual/pkgconfig
69         test? ( dev-python/nose[${PYTHON_USEDEP}] )
70 "
71
72 PATCHES=(
73         # Make tests optional, bug #594096
74         "${FILESDIR}"/${P}-optional-tests.patch
75 )
76
77 src_configure() {
78         # Not a normal configure
79         # --buildtype=plain needed for honoring CFLAGS/CXXFLAGS and not
80         # defaulting to debug
81         ./configure \
82                 --prefix="${EPREFIX}/usr" \
83                 --buildtype=plain \
84                 --libdir="$(get_libdir)" \
85                 -Denable-tests=$(usex test true false) \
86                 || die
87 }
88
89 src_compile() {
90         # We cannot use 'make' as it won't allow us to build verbosely
91         cd mesonbuild && ninja -v
92 }
93
94 src_test() {
95         export PITIVI_TOP_LEVEL_DIR="${S}"
96         virtx emake check
97 }
98
99 src_install() {
100         gnome2_src_install
101         python_fix_shebang "${D}"
102 }