summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCraig Andrews <candrews@gentoo.org>2024-02-10 18:37:40 -0500
committerCraig Andrews <candrews@gentoo.org>2024-02-10 18:37:40 -0500
commita0ed84029bc3da98f1173b71c49cc6c6b937afdb (patch)
treefbc827e02e023bd065d90125b3a3cf5097d35f98 /media-libs
parentmedia-libs/vidstab: adding test dependency (diff)
downloadgentoo-a0ed84029bc3da98f1173b71c49cc6c6b937afdb.tar.gz
gentoo-a0ed84029bc3da98f1173b71c49cc6c6b937afdb.tar.bz2
gentoo-a0ed84029bc3da98f1173b71c49cc6c6b937afdb.zip
media-libs/vidstab: fix ~sparc ~ia64 keywords
Signed-off-by: Craig Andrews <candrews@gentoo.org>
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/vidstab/vidstab-1.1.1-r1.ebuild66
-rw-r--r--media-libs/vidstab/vidstab-1.1.1.ebuild5
-rw-r--r--media-libs/vidstab/vidstab-9999.ebuild2
3 files changed, 68 insertions, 5 deletions
diff --git a/media-libs/vidstab/vidstab-1.1.1-r1.ebuild b/media-libs/vidstab/vidstab-1.1.1-r1.ebuild
new file mode 100644
index 000000000000..6df252bff8f9
--- /dev/null
+++ b/media-libs/vidstab/vidstab-1.1.1-r1.ebuild
@@ -0,0 +1,66 @@
+# Copyright 2018-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake-multilib toolchain-funcs flag-o-matic
+
+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="~alpha amd64 arm arm64 ~loong ~mips ppc ppc64 ~riscv ~x86"
+ S="${WORKDIR}/vid.stab-${PV}"
+fi
+
+LICENSE="GPL-2+"
+SLOT="0"
+IUSE="openmp cpu_flags_x86_sse2 test"
+
+RESTRICT="!test? ( test )"
+DEPEND="test? ( dev-lang/orc )"
+
+pkg_pretend() {
+ [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
+}
+
+pkg_setup() {
+ [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
+}
+
+src_prepare() {
+ # USE=cpu_flags_x86_sse2 instead
+ sed -E 's#include (FindSSE)##' -i CMakeLists.txt || die
+ sed -E 's#include (FindSSE)##' -i tests/CMakeLists.txt || die
+ # strip some CFLAGS
+ for FILE_TO_PATCH in {,transcode/,tests/}CMakeLists.txt; do
+ sed -E 's#(add_definitions.* )-g #\1#' -i ${FILE_TO_PATCH} || die
+ sed -E 's#(add_definitions.* )-O3 #\1#' -i ${FILE_TO_PATCH} || die
+ done
+ cmake_src_prepare
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DUSE_OMP="$(usex openmp)"
+ -DSSE2_FOUND="$(usex cpu_flags_x86_sse2)"
+ )
+ cmake-multilib_src_configure
+}
+
+multilib_src_test() {
+ local mycmakeargs=(
+ -DUSE_OMP="$(usex openmp)"
+ -DSSE2_FOUND="$(usex cpu_flags_x86_sse2)"
+ )
+ append-cflags $(test-flags-CC -fopenmp)
+ local CMAKE_USE_DIR="${CMAKE_USE_DIR}/tests"
+ local BUILD_DIR="${BUILD_DIR}/tests"
+ cmake_src_configure
+ cmake_build
+ "${BUILD_DIR}"/tests || die
+}
diff --git a/media-libs/vidstab/vidstab-1.1.1.ebuild b/media-libs/vidstab/vidstab-1.1.1.ebuild
index beb76c153eed..ec0ef0590a9a 100644
--- a/media-libs/vidstab/vidstab-1.1.1.ebuild
+++ b/media-libs/vidstab/vidstab-1.1.1.ebuild
@@ -19,10 +19,7 @@ fi
LICENSE="GPL-2+"
SLOT="0"
-IUSE="openmp cpu_flags_x86_sse2 test"
-
-RESTRICT="!test? ( test )"
-DEPEND="test? ( dev-lang/orc )"
+IUSE="openmp cpu_flags_x86_sse2"
pkg_pretend() {
[[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
diff --git a/media-libs/vidstab/vidstab-9999.ebuild b/media-libs/vidstab/vidstab-9999.ebuild
index 40a765ac64a2..fa73a3e3e1e3 100644
--- a/media-libs/vidstab/vidstab-9999.ebuild
+++ b/media-libs/vidstab/vidstab-9999.ebuild
@@ -13,7 +13,7 @@ if [[ ${PV} == *9999* ]] ; then
inherit git-r3
else
SRC_URI="https://github.com/georgmartius/vid.stab/archive/v${PV}.tar.gz -> ${P}.tar.gz"
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~mips ~ppc ~ppc64 ~sparc ~x86"
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~loong ~mips ~ppc ~ppc64 ~x86"
S="${WORKDIR}/vid.stab-${PV}"
fi