diff options
author | Kalin KOZHUHAROV <me.kalin@gmail.com> | 2019-01-10 11:49:38 +0100 |
---|---|---|
committer | Craig Andrews <candrews@gentoo.org> | 2019-01-10 20:28:03 -0500 |
commit | 077738eb8a9905827e615ddb1ac2e788337b1291 (patch) | |
tree | 2ab14d8359be13113aeeb2bc96c70b5537c07e97 /media-libs/vidstab/vidstab-9999.ebuild | |
parent | app-office/scribus: 1.5.5_pre20181227 snapshot bump (no keywords) (diff) | |
download | gentoo-077738eb8a9905827e615ddb1ac2e788337b1291.tar.gz gentoo-077738eb8a9905827e615ddb1ac2e788337b1291.tar.bz2 gentoo-077738eb8a9905827e615ddb1ac2e788337b1291.zip |
media-libs/vidstab: Video stabilization library
Closes: https://bugs.gentoo.org/517892
Signed-off-by: Kalin KOZHUHAROV <kalin@thinrope.net>
Signed-off-by: Craig Andrews <candrews@gentoo.org>
Diffstat (limited to 'media-libs/vidstab/vidstab-9999.ebuild')
-rw-r--r-- | media-libs/vidstab/vidstab-9999.ebuild | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/media-libs/vidstab/vidstab-9999.ebuild b/media-libs/vidstab/vidstab-9999.ebuild new file mode 100644 index 000000000000..08bf38d39555 --- /dev/null +++ b/media-libs/vidstab/vidstab-9999.ebuild @@ -0,0 +1,54 @@ +# Copyright 2018-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit cmake-utils toolchain-funcs + +DESCRIPTION="Video stabilization library" +HOMEPAGE="http://public.hronopik.de/vid.stab/" + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://github.com/georgmartius/vid.stab.git" + inherit git-r3 +else + SRC_URI="https://github.com/georgmartius/vid.stab/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" + S="${WORKDIR}/vid.stab-${PV}" +fi + +LICENSE="GPL-2+" +SLOT="0" +IUSE="openmp cpu_flags_x86_sse2" + +src_prepare() { + # USE=cpu_flags_x86_sse2 instead + sed -E 's#include (FindSSE)##' -i CMakeLists.txt + # strip some CFLAGS + for FILE_TO_PATCH in {,transcode/,tests/}CMakeLists.txt; do + sed -E 's#(add_definitions.* )-g #\1#' -i ${FILE_TO_PATCH} + sed -E 's#(add_definitions.* )-O3 #\1#' -i ${FILE_TO_PATCH} + done + cmake-utils_src_prepare +} + +src_configure() { + use openmp && tc-check-openmp + local mycmakeargs=( + -DUSE_OMP="$(usex openmp)" + -DSSE2_FOUND="$(usex cpu_flags_x86_sse2)" + ) + cmake-utils_src_configure +} + +src_test() { + cd tests || die + local mycmakeargs=( + -DUSE_OMP="$(usex openmp)" + ) + local CMAKE_USE_DIR="${CMAKE_USE_DIR}/tests" + local BUILD_DIR="${BUILD_DIR}/tests" + cmake-utils_src_configure + cmake-utils_src_make + "${BUILD_DIR}"/tests || die +} |