diff options
author | 2016-03-10 12:01:57 +0100 | |
---|---|---|
committer | 2016-03-15 21:32:05 +0800 | |
commit | fe2742014af5a4a1f306cc3f1ee5d3e5be7ed64c (patch) | |
tree | 4e10d44877f6d34f6ecc79b5092a293e6e854033 /media-libs/libopenshot/libopenshot-0.1.0.ebuild | |
parent | media-libs/libopenshot-audio: new ebuild, version 0.0.6 (diff) | |
download | gentoo-fe2742014af5a4a1f306cc3f1ee5d3e5be7ed64c.tar.gz gentoo-fe2742014af5a4a1f306cc3f1ee5d3e5be7ed64c.tar.bz2 gentoo-fe2742014af5a4a1f306cc3f1ee5d3e5be7ed64c.zip |
media-libs/libopenshot: new ebuild, version 0.1.0
Needed for media-video/openshot-2.0.6
Package-Manager: portage-2.2.27
Closes: https://github.com/gentoo/gentoo/pull/1023
Diffstat (limited to 'media-libs/libopenshot/libopenshot-0.1.0.ebuild')
-rw-r--r-- | media-libs/libopenshot/libopenshot-0.1.0.ebuild | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/media-libs/libopenshot/libopenshot-0.1.0.ebuild b/media-libs/libopenshot/libopenshot-0.1.0.ebuild new file mode 100644 index 000000000000..b7907a9f0eee --- /dev/null +++ b/media-libs/libopenshot/libopenshot-0.1.0.ebuild @@ -0,0 +1,76 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +PYTHON_COMPAT=( python3_{4,5} ) + +inherit cmake-utils python-single-r1 + +DESCRIPTION="Video editing library used by OpenShot" +HOMEPAGE="http://www.openshotvideo.com/" +SRC_URI="https://launchpad.net/${PN}/$(get_version_component_range 1-2)/${PV}/+download/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="libav +python test" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +RDEPEND=" + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtmultimedia:5[widgets] + media-gfx/imagemagick + media-libs/libopenshot-audio + libav? ( media-video/libav:=[encode,x264,xvid,vpx,mp3,theora] ) + !libav? ( media-video/ffmpeg:0=[encode,x264,xvid,vpx,mp3,theora] ) + python? ( ${PYTHON_DEPS} ) +" +DEPEND=" + ${RDEPEND} + python? ( dev-lang/swig ) + test? ( dev-libs/unittest++ ) +" + +# https://github.com/OpenShot/libopenshot/pull/19 +PATCHES=( "${FILESDIR}/${P}-fix-tests-exit-code.patch" ) + +S="${WORKDIR}" + +pkg_setup() { + use python && python-single-r1_pkg_setup +} + +src_prepare() { + use test || cmake_comment_add_subdirectory tests + pushd src > /dev/null || die + if use python; then + pushd bindings > /dev/null || die + cmake_comment_add_subdirectory ruby # TODO: support ruby + popd > /dev/null || die + else + cmake_comment_add_subdirectory bindings + fi + popd > /dev/null || die + cmake-utils_src_prepare +} + +src_configure() { + if use python; then + local mycmakeargs=( + -DPYTHON_EXECUTABLE="${PYTHON}" + -DPYTHON_INCLUDE_DIR="$(python_get_includedir)" + -DPYTHON_LIBRARY="$(python_get_library_path)" + ) + fi + cmake-utils_src_configure +} + +src_test() { + pushd "${BUILD_DIR}/tests" > /dev/null || die + ./openshot-test || die "Tests failed" + popd > /dev/null || die +} |