summaryrefslogtreecommitdiff
path: root/media-libs
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-10-09 04:26:33 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-10-09 04:26:33 +0100
commit6ee17dd82a3bcd0e90af4ebfbb3e411d342761be (patch)
tree5ade54018efa76614b79d832bbe15a22021b6d8c /media-libs
parent325837835fc86686829aaa6acace3d3c06c74cea (diff)
gentoo auto-resync : 09:10:2024 - 04:26:32
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/Manifest.gzbin69429 -> 69422 bytes
-rw-r--r--media-libs/fontconfig/Manifest2
-rw-r--r--media-libs/fontconfig/files/fontconfig-2.15.0-aliasing.patch53
-rw-r--r--media-libs/fontconfig/fontconfig-2.15.0-r1.ebuild234
-rw-r--r--media-libs/netpbm/Manifest2
-rw-r--r--media-libs/netpbm/netpbm-11.2.10.ebuild2
-rw-r--r--media-libs/opencv/Manifest14
-rw-r--r--media-libs/opencv/files/opencv-4.8.0-arm64-fp16.patch272
-rw-r--r--media-libs/opencv/files/opencv-4.8.0-fix-cuda-12.2.0.patch40
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-ade-0.1.2a.tar.gz.patch18
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-drop-python2-detection.patch23
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-eliminate-lto-compiler-warnings.patch36
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-libpng16.patch58
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-opencv_test.patch18
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-protobuf-22.patch190
-rw-r--r--media-libs/opencv/files/opencv-4.8.1-python3_12-support.patch25
-rw-r--r--media-libs/opencv/opencv-4.8.1-r2.ebuild794
-rw-r--r--media-libs/opencv/opencv-4.9.0-r1.ebuild1022
-rw-r--r--media-libs/openjpeg/Manifest2
-rw-r--r--media-libs/openjpeg/openjpeg-2.5.2.ebuild2
20 files changed, 293 insertions, 2514 deletions
diff --git a/media-libs/Manifest.gz b/media-libs/Manifest.gz
index c08873d8e878..7ae6a702187c 100644
--- a/media-libs/Manifest.gz
+++ b/media-libs/Manifest.gz
Binary files differ
diff --git a/media-libs/fontconfig/Manifest b/media-libs/fontconfig/Manifest
index 1079b656350c..ad50f1a7f7d9 100644
--- a/media-libs/fontconfig/Manifest
+++ b/media-libs/fontconfig/Manifest
@@ -2,8 +2,10 @@ AUX fontconfig-2.14.0-latin-update.patch 1889 BLAKE2B 42a5faab884bb47e645a8ee6f0
AUX fontconfig-2.14.0-skip-bubblewrap-tests.patch 408 BLAKE2B 911a87e91dcdf49088e9a684a9af753464211f18fd471989410a57363dd71b7cc0940c9a8e61095d901b4d7ee804536262ebc6afb1af3f470d8cd164d2fd2113 SHA512 8302a3ccf5918c8a4c3af3ab3601752c005c0361003281996eba469195127fab0e99c8d225dcb674a1bc198f2c15b982cce49c6bb3234307cf58e47c9206ff5a
AUX fontconfig-2.14.2-fix-sysroot-fc-cache.patch 2007 BLAKE2B 91a43c8aec698a9733020031bfded6871d379b20535f6c1291d0d3fa38faaef9e367f0958f6df2b88003190184988dc99f7fa7f013f6837f24b617b83a0d5546 SHA512 73e41f2f19f61514a271141ddb4b640ed3b6060c4ccdcc79a4eefa6a6b4ece0e718012bee4b4b7312561e39ca02cd9663084298000d9cc9aa210c81a16945572
AUX fontconfig-2.14.2-math-fabs.patch 3159 BLAKE2B e3472ed44efdc2ffff81410864c7c25f6e1403464b6bec98b84662522c760ff7cc372dbc886cea2a0108bada1ca1ed923c6646cede70b050a8eb87a7c28d9eb4 SHA512 4fc401a980ec63ba0de40de044408063fd0949f0022dfa4333e5aaaff78ba03f2c18ea369af16e4cc952703d25a1c3d1821047e194c4776e00bb90f7ec8cbcc1
+AUX fontconfig-2.15.0-aliasing.patch 1667 BLAKE2B a3881ac359d90de1d3738fcc0bb4ebf9a9deaed1ad3d95445e4d1a77a0d077b20f24b1e9e4a1fcf724d21bd02b62b2903d284ace3915f6943416222f23975377 SHA512 00171483e4a0ec5bdb2a191e3fe49b33499dc1bf58f3896d3ab5d1eae8190eee96d3b680756d195ecb50ac4c767fafe15bbd54460ec455173871ae304638ada9
DIST fontconfig-2.14.2.tar.xz 1440844 BLAKE2B 4efeeb7f9a6705d493128d00b60e681a20a47556f4c0d7787a5c7a6d2cbbc22f150cad7988a9836a9e72aeb61e2b6a196c00a071c7042c62283c7720cdbb743d SHA512 23483e0ae6aa7589fd37f9949a4cf951c5bff981739dbb446881e4cea86a208c0ab31e2358666eac724af1dc6a689a42733a7ce91cd3e76d8d91eacedb318085
DIST fontconfig-2.15.0.tar.xz 1447820 BLAKE2B 17c85fddc4ab84111c4f50afb89ecd8792c3aeaa2690b38fd39fca6f6cece69e9ce0cd3af8a2e54968c79ad1f9bee1e444699a13c068d9dfd3dfe1212ff37533 SHA512 754cd5fffa198fc07a39cf7df683e9adfa7f54ab41fdff8c0eacc078fd35d3e01069ba343f2b045e0b40df88d9f1fc1ee0f7565799f9cb194a59cf95b64c4417
EBUILD fontconfig-2.14.2-r3.ebuild 7192 BLAKE2B ac09bacc348d9b612d5e77941c694cb4b3881463cd9e7f0cbebf34669affc3a217158abd672e1aeae5387db106dc7b6004194436f9786039ca8b72654234c1d2 SHA512 253f4a7030c9838e5c005c371d74e3df659ab7ece6a332f8e04d8d5ac9920f79d49fa4475d89e9323e834f37ae27781e2316d4ac33d4068659ecb29a42943d30
+EBUILD fontconfig-2.15.0-r1.ebuild 7226 BLAKE2B 06d0f58416607b7b063044fb179b04944ceb5f5c3e1590206c3f6b185faf489510f3ec543af1eb341a8ae81dbcbb738181fd11464ec279b191a46e6ab349e332 SHA512 f87f1736ee26c54bbfdbe2941b9a77bd4809baadfb9d7820426c88a174ed639a798cd270c77584330b2491840952069b7df94d07d8478f59a16cc4b67a6d3a4c
EBUILD fontconfig-2.15.0.ebuild 7145 BLAKE2B 16aba4bc2a195da5d43084008dff53d06626f07f0dd09c824124f59fef89693cb87ed13dbbd1e9271698c7956d9587a99d04488333545c389f2a5abf2a974614 SHA512 273d3c5350a13c0155eadb084c3830865417feb10fd272fa8738cdb65210054351026e848605ab818eaace7a88a08a571596ef57194363a8ea945880aa898a5e
MISC metadata.xml 672 BLAKE2B d23112b5d408aed97ad68bc9a141a570c22fd6bbf0022e979b7006817ae27bcba21be43558cb42df06f3c280cbed5570c62805bb69be8a64b1f41bd90b200bc0 SHA512 1ff9c1f22b9766127692eec4824ce966f7a7305ddfae0dd1d8b0e5b432926508dd7a898eada6c182e02c985e11c2f9a22f13eac195333ed32952af0e89015e9a
diff --git a/media-libs/fontconfig/files/fontconfig-2.15.0-aliasing.patch b/media-libs/fontconfig/files/fontconfig-2.15.0-aliasing.patch
new file mode 100644
index 000000000000..03709ac2c3a7
--- /dev/null
+++ b/media-libs/fontconfig/files/fontconfig-2.15.0-aliasing.patch
@@ -0,0 +1,53 @@
+https://gitlab.freedesktop.org/fontconfig/fontconfig/-/merge_requests/333
+
+From 8db62f5a77fd53543dd58e12da7bd96082228893 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Tue, 8 Oct 2024 16:48:19 +0100
+Subject: [PATCH] fontconfig: mark _FcPatternIter as may_alias
+
+We had a report of GCC 14 with -O3 -flto causing wrong font
+sizes with fontconfig (showing up in qalculate-gtk).
+
+It turns out to be because _FcPatternIter and _FcPatternPrivateIter
+are punned between which violates strict-aliasing rules, which
+manifested in FcDefaultSubstitute getting a bogus value from
+FcValueCanonicalize for size.
+
+void* isn't allowed to alias anything -- you can pass addresses
+around provided you cast back to the original type, but if you
+access through the wrong type, you've violated aliasing rules.
+
+Bug: https://bugs.gentoo.org/940923
+Signed-off-by: Sam James <sam@gentoo.org>
+--- a/fontconfig/fontconfig.h
++++ b/fontconfig/fontconfig.h
+@@ -32,8 +32,10 @@
+
+ #if defined(__GNUC__) && (__GNUC__ >= 4)
+ #define FC_ATTRIBUTE_SENTINEL(x) __attribute__((__sentinel__(0)))
++#define FC_ATTRIBUTE_MAY_ALIAS __attribute__((may_alias))
+ #else
+ #define FC_ATTRIBUTE_SENTINEL(x)
++#define FC_ATTRIBUTE_MAY_ALIAS
+ #endif
+
+ #ifndef FcPublic
+@@ -253,7 +255,7 @@ typedef enum _FcValueBinding {
+
+ typedef struct _FcPattern FcPattern;
+
+-typedef struct _FcPatternIter {
++typedef struct FC_ATTRIBUTE_MAY_ALIAS _FcPatternIter {
+ void *dummy1;
+ void *dummy2;
+ } FcPatternIter;
+@@ -1160,6 +1162,7 @@ FcConfigParseAndLoadFromMemory (FcConfig *config,
+ _FCFUNCPROTOEND
+
+ #undef FC_ATTRIBUTE_SENTINEL
++#undef FC_ATTRIBUTE_MAY_ALIAS
+
+
+ #ifndef _FCINT_H_
+--
+GitLab
diff --git a/media-libs/fontconfig/fontconfig-2.15.0-r1.ebuild b/media-libs/fontconfig/fontconfig-2.15.0-r1.ebuild
new file mode 100644
index 000000000000..f1472130c4cc
--- /dev/null
+++ b/media-libs/fontconfig/fontconfig-2.15.0-r1.ebuild
@@ -0,0 +1,234 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..13} )
+inherit multilib meson-multilib python-any-r1 readme.gentoo-r1
+
+DESCRIPTION="A library for configuring and customizing font access"
+HOMEPAGE="https://fontconfig.org/"
+SRC_URI="https://fontconfig.org/release/${P}.tar.xz"
+
+LICENSE="MIT"
+SLOT="1.0"
+if ! [[ $(ver_cut 3) -ge 90 ]] ; then
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
+fi
+IUSE="doc nls test"
+RESTRICT="!test? ( test )"
+
+# - Check minimum freetype & other deps on bumps. See
+# https://gitlab.freedesktop.org/fontconfig/fontconfig/-/blob/main/configure.ac#L314.
+# Note that FT versioning is confusing, need to map it using
+# https://git.savannah.gnu.org/cgit/freetype/freetype2.git/tree/docs/VERSIONS.TXT
+# But sometimes it's actually greater than that, e.g. see Fedora's spec file
+# https://src.fedoraproject.org/rpms/fontconfig/blob/rawhide/f/fontconfig.spec#_1
+#
+# - Purposefully dropped the xml USE flag and libxml2 support. Expat is the
+# default and used by every distro. See bug #283191.
+#
+# - There's a test-only dep on json-c.
+# It might become an optional(?) runtime dep in future though. Who knows.
+# Keep an eye on it.
+RDEPEND="
+ >=dev-libs/expat-2.1.0-r3[${MULTILIB_USEDEP}]
+ >=media-libs/freetype-2.9.1[${MULTILIB_USEDEP}]
+ virtual/libintl[${MULTILIB_USEDEP}]
+ !elibc_Darwin? ( !elibc_SunOS? ( sys-apps/util-linux[${MULTILIB_USEDEP}] ) )
+ elibc_Darwin? ( sys-libs/native-uuid )
+ elibc_SunOS? ( sys-libs/libuuid )
+"
+DEPEND="
+ ${RDEPEND}
+ test? ( dev-libs/json-c )
+"
+BDEPEND="
+ ${PYTHON_DEPS}
+ dev-util/gperf
+ virtual/pkgconfig
+ doc? (
+ =app-text/docbook-sgml-dtd-3.1*
+ app-text/docbook-sgml-utils[jadetex]
+ )
+ nls? ( >=sys-devel/gettext-0.19.8 )
+"
+PDEPEND="virtual/ttf-fonts"
+# We need app-eselect/eselect-fontconfig in IDEPEND to update ROOT
+# when cross-compiling.
+IDEPEND="app-eselect/eselect-fontconfig"
+
+PATCHES=(
+ # bug #130466 + make liberation default
+ "${FILESDIR}"/${PN}-2.14.0-latin-update.patch
+ # Avoid test failure (bubblewrap doesn't work within sandbox)
+ "${FILESDIR}"/${PN}-2.14.0-skip-bubblewrap-tests.patch
+ # Fix aliasing (bug #940923)
+ "${FILESDIR}"/${PN}-2.15.0-aliasing.patch
+
+ # Patches from upstream (can usually be removed with next version bump)
+ "${FILESDIR}"/${PN}-2.14.2-math-fabs.patch
+)
+
+DOC_CONTENTS="Please make fontconfig configuration changes using
+\`eselect fontconfig\`. Any changes made to /etc/fonts/fonts.conf will be
+overwritten. If you need to reset your configuration to upstream defaults,
+delete the directory ${EROOT}/etc/fonts/conf.d/ and re-emerge fontconfig."
+
+src_prepare() {
+ default
+
+ # Test needs network access
+ # https://gitlab.freedesktop.org/fontconfig/fontconfig/-/issues/319
+ # On bumps, please check to see if this has been fixed
+ # to allow local access!
+ sed -i -e '/test-crbug1004254/d' test/meson.build || die
+}
+
+multilib_src_configure() {
+ local addfonts=(
+ "${EPREFIX}"/usr/local/share/fonts
+ )
+
+ # Harvest some font locations, such that users can benefit from the
+ # host OS's installed fonts
+ case ${CHOST} in
+ *-darwin*)
+ addfonts+=(
+ /Library/Fonts
+ /System/Library/Fonts
+ )
+ ;;
+
+ *-solaris*)
+ [[ -d /usr/X/lib/X11/fonts/TrueType ]] && \
+ addfonts+=( /usr/X/lib/X11/fonts/TrueType )
+ [[ -d /usr/X/lib/X11/fonts/Type1 ]] &&
+ addfonts+=( /usr/X/lib/X11/fonts/Type1 )
+ ;;
+
+ *-linux-gnu)
+ use prefix && [[ -d /usr/share/fonts ]] && \
+ addfonts+=( /usr/share/fonts )
+ ;;
+ esac
+
+ local emesonargs=(
+ # USE=doc only controls the additional bits like html/pdf
+ # and regeneration of man pages from source. We always install
+ # the prebuilt man pages.
+ $(meson_native_use_feature doc)
+ $(meson_native_use_feature doc doc-txt)
+ $(meson_native_use_feature doc doc-html)
+ $(meson_native_use_feature doc doc-man)
+ $(meson_native_use_feature doc doc-pdf)
+
+ $(meson_native_use_feature nls)
+ $(meson_feature test tests)
+
+ -Dcache-build=disabled
+ -Dcache-dir="${EPREFIX}"/var/cache/fontconfig
+ -Ddefault-fonts-dirs="${EPREFIX}"/usr/share/fonts
+ -Dadditional-fonts-dirs=$(IFS=, ; echo "${addfonts[*]}" )
+ -Dtemplate-dir="${EPREFIX}"/etc/fonts/conf.avail
+
+ # Let users choose via eselect-fontconfig. See bug #900681
+ # and https://gitlab.freedesktop.org/fontconfig/fontconfig/-/issues/356.
+ -Ddefault-sub-pixel-rendering=none
+ )
+
+ meson_src_configure
+}
+
+multilib_src_install() {
+ MULTILIB_CHOST_TOOLS=( /usr/bin/fc-cache$(get_exeext) )
+
+ meson_src_install
+
+ # Avoid calling this multiple times, bug #459210
+ if multilib_is_native_abi; then
+ insinto /etc/fonts
+ doins fonts.conf
+ fi
+}
+
+multilib_src_install_all() {
+ einstalldocs
+
+ # fc-lang directory contains language coverage datafiles
+ # which are needed to test the coverage of fonts.
+ insinto /usr/share/fc-lang
+ doins fc-lang/*.orth
+
+ dodoc doc/fontconfig-user.{txt,pdf}
+
+ if ! use doc ; then
+ find "${S}" -name "*.[[:digit:]]" -type f -exec doman '{}' + || die
+ fi
+
+ if [[ -e ${ED}/usr/share/doc/fontconfig/ ]] ; then
+ mv "${ED}"/usr/share/doc/fontconfig/* "${ED}"/usr/share/doc/${PF} || die
+ rm -rf "${ED}"/usr/share/doc/fontconfig || die
+ fi
+
+ # Changes should be made to /etc/fonts/local.conf, and as we had
+ # too much problems with broken fonts.conf we force update it ...
+ echo 'CONFIG_PROTECT_MASK="/etc/fonts/fonts.conf"' > "${T}"/37fontconfig || die
+ doenvd "${T}"/37fontconfig
+
+ # As of fontconfig 2.7, everything sticks their noses in here.
+ dodir /etc/sandbox.d
+ echo 'SANDBOX_PREDICT="/var/cache/fontconfig"' > "${ED}"/etc/sandbox.d/37fontconfig || die
+
+ readme.gentoo_create_doc
+}
+
+pkg_preinst() {
+ # bug #193476
+ # /etc/fonts/conf.d/ contains symlinks to ../conf.avail/ to include various
+ # config files. If we install as-is, we'll blow away user settings.
+ ebegin "Syncing fontconfig configuration to system"
+ if [[ -e ${EROOT}/etc/fonts/conf.d ]] ; then
+ local file f
+ for file in "${EROOT}"/etc/fonts/conf.avail/* ; do
+ f=${file##*/}
+ if [[ -L ${EROOT}/etc/fonts/conf.d/${f} ]] ; then
+ [[ -f ${ED}/etc/fonts/conf.avail/${f} ]] \
+ && ln -sf ../conf.avail/"${f}" \
+ "${ED}"/etc/fonts/conf.d/ &>/dev/null
+ else
+ [[ -f ${ED}/etc/fonts/conf.avail/${f} ]] \
+ && rm "${ED}"/etc/fonts/conf.d/"${f}" &>/dev/null
+ fi
+ done
+ fi
+ eend $?
+}
+
+pkg_postinst() {
+ einfo "Cleaning broken symlinks in ${EROOT}/etc/fonts/conf.d/"
+ find -L "${EROOT}"/etc/fonts/conf.d/ -type l -delete
+
+ readme.gentoo_print_elog
+
+ local ver
+ for ver in ${REPLACING_VERSIONS} ; do
+ # 2.14.2 and 2.14.2-r1 included the bad 10-sub-pixel-none.conf
+ if ver_test ${ver} -lt 2.14.2-r2 && ver_test ${ver} -ge 2.14.2 ; then
+ if [[ -e "${EROOT}"/etc/fonts/conf.d/10-sub-pixel-none.conf ]] ; then
+ einfo "Deleting 10-sub-pixel-none.conf from bad fontconfig-2.14.2 (bug #900681)"
+ rm "${EROOT}"/etc/fonts/conf.d/10-sub-pixel-none.conf || die
+ fi
+ fi
+ done
+
+ if [[ -z ${ROOT} ]] ; then
+ multilib_pkg_postinst() {
+ ebegin "Creating global font cache for ${ABI}"
+ "${EPREFIX}"/usr/bin/${CHOST}-fc-cache -srf
+ eend $?
+ }
+
+ multilib_parallel_foreach_abi multilib_pkg_postinst
+ fi
+}
diff --git a/media-libs/netpbm/Manifest b/media-libs/netpbm/Manifest
index 608048932c2e..3c2cb720f505 100644
--- a/media-libs/netpbm/Manifest
+++ b/media-libs/netpbm/Manifest
@@ -9,7 +9,7 @@ DIST netpbm-11.2.10.tar.xz 3782160 BLAKE2B 22dab865106f48a83992ff780a3a3cb26e7fd
DIST netpbm-11.2.11.tar.xz 3782252 BLAKE2B 422b9cefee2a54a9c222236935291f0c8d1f13f064f4ebd277d0f92974b9ce3d7e3d9ae6a0410d767553704a03c2de14ca8456996a53fca0f95d61f9ae72605f SHA512 3d94c0c8c25873a16c78af960c964f5756b3e7a29463f001345956acc3bf1378b0b0b4fc0c57d7388dced0979ba4e8cee0def2200092544dd96fc7d04304660b
DIST netpbm-11.2.9.tar.xz 3782172 BLAKE2B b5acec8306c820e7b0ac2dec21ab5df8f2cdbec01d3d59f82b307d90111954e81e1b01ad7d8e25e8fbd0ea7cf61e8b023e3dfaed6d1cab71b51f7e367d792e56 SHA512 02961bb2ac4a4292e028ed5dbd05daf89ac795f50d36d97be67c49a61be0cbd977e954aa9266c4649d9a46de3fbe7c4b2b51c8363cc7bee322926dd4a9af2ab1
DIST netpbm-11.8.0.tar.xz 3804048 BLAKE2B 8f838790a38decca5efdbd8b05c07a9e13f3d10093e118547674b84e053534f2f05ccb7a8c6e9e8a1ba5bb121036b7b1b3a88841ee28bc92a7d06865fd905481 SHA512 f7ce52bda45157d8b8ecac2076e3073b471b02cdeab3fe5e61862c5b79fa247d2109703a419098028eeb335d71441794708985f5f6c31b77da4daba04df23e80
-EBUILD netpbm-11.2.10.ebuild 7108 BLAKE2B 195861b2f76fa05276a1184ddad2bdb684094b8c671d41e833321839a4f8635c2007b9aa1747714ca40da326e8bec46386d837023c5b2dc53ef5cad17de90c31 SHA512 04e5a95f1b24ec6c9af73ecf8a8ec41bf5d34c321a560c7a27bbedfd481438b4358dc42d76a130e0fe0a45198ef3a3a69f6f656fdf409bc177e440819911606d
+EBUILD netpbm-11.2.10.ebuild 7107 BLAKE2B efc401f6f89b3bd481d6a81556248f2209e901ae8cc18f80fcb6fb173a4aa6822c6330fafb8553568df2ae20a462c1bd218712a046a0a5fca75f7fee80f3a862 SHA512 7ce484ef48b7a8489ed973aded2d9c73e13de95ea949b25a4c91770b55c4881647abdcd7702e5aa0c56a6c592d2a37d21e20834eb51a46968a48b72b0f74eb94
EBUILD netpbm-11.2.11.ebuild 7151 BLAKE2B eec411d852a284714ef3497a1db6e7c51b3fcf6bfa9eb4b167bc63665be2c0f1cc34b0dfbeae9fd3c9f93f4ef174ff52a7d8d47b9d39a1bbf0326edaf4084b51 SHA512 ac4c790909c15bafb0d12f1da3175f1714e666a5d775bfb76b632e607e2b193518441afa01473fc9b78da4fbef35b64aa3c123e3c3228f661cc26cebf6cddcf3
EBUILD netpbm-11.2.9-r1.ebuild 7104 BLAKE2B addce69f99b8cb02ebfe5a8459c36b37268dd43f398d82e09818f61971c797c73ab16c5056137e98edcc960fe7d10d1ce7051fe37c87d3d0957a6d2d683abe99 SHA512 8ae6233266f5c82d568fcdf2f463a38aedcf5dc9ae3ecb91fbddb3e23574ac9ef5e0ce278cc9c4e1ba9f177d62f8730f102ada68c072bccc6e1fdf8a19cae85c
EBUILD netpbm-11.8.0.ebuild 6939 BLAKE2B 773de213668f7e8c7c4e4243e4b5b4b38b4c7beba97d09bd4047c8a5b0b5122eb4ebca492f5a28f777555d3ee05891bfb1294c770f1f8b763461906354275194 SHA512 b6131f9c1c808d2cccdaa9476c0a02307e0efbde8991a7ab25f8bbf0f6b04c4fd52936ac013e3f2977171d261019187d9f7c466156c63abc970ee6c3afed1c22
diff --git a/media-libs/netpbm/netpbm-11.2.10.ebuild b/media-libs/netpbm/netpbm-11.2.10.ebuild
index a37e98d8c503..5f495321a8f9 100644
--- a/media-libs/netpbm/netpbm-11.2.10.ebuild
+++ b/media-libs/netpbm/netpbm-11.2.10.ebuild
@@ -19,7 +19,7 @@ SRC_URI="https://dev.gentoo.org/~ceamac/${CATEGORY}/${PN}/${P}.tar.xz"
LICENSE="Artistic BSD GPL-2 IJG LGPL-2.1 MIT public-domain"
SLOT="0/stable"
-KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ppc64 ~riscv ~s390 ~sparc x86 ~amd64-linux ~x86-linux"
+KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 ~sparc x86 ~amd64-linux ~x86-linux"
IUSE="jbig jpeg png postscript rle cpu_flags_x86_sse2 static-libs svga tiff X xml"
# app-text/ghostscript-gpl is really needed for postscript
diff --git a/media-libs/opencv/Manifest b/media-libs/opencv/Manifest
index 9b5b9d5234a8..a503aae64047 100644
--- a/media-libs/opencv/Manifest
+++ b/media-libs/opencv/Manifest
@@ -3,15 +3,6 @@ AUX opencv-3.4.1-cuda-add-relaxed-constexpr.patch 707 BLAKE2B 743a9c259c59fc4e30
AUX opencv-4.1.2-opencl-license.patch 519 BLAKE2B 6dcdf809c3c75a39d0e44f02e157a0c0ee074fd15144565ed51ade7e7849cb313c084100f499cc1240424f4647a2ff73c8d5e61cbdf6d0499846db61b8a30729 SHA512 2874a5140ef5028eb6c64f36325904000edd722560cf876fc49d63b040633bcfea01cae27c156b18191564805cafd2986f26eea322b1376af4f2982d66ed7653
AUX opencv-4.4.0-disable-native-cpuflag-detect.patch 1218 BLAKE2B 06569f6b7d33eccb11cae74624a2cc7d7e1eb788145813509220dc8436d2380892392be8c4af03fec845f3eade74b6277985cf80e38785317b15f17890bcaa4c SHA512 3be60f7ee28e3b001ef0c791e3ce1c849ff6fa9fdb70731716668b2698eed9abb24ee3aead1dbc857ed68fc46a645c70a1e3831e8a3e5a5b1791aa06bd2f9ee1
AUX opencv-4.5.0-link-with-cblas-for-lapack.patch 726 BLAKE2B adbffd961c88229bf810e13fe20705352ff506a653c1d55bb0687c03d8daf9e05aed0f2ba9cd6e306c625837d6ddf64eeb99dc6cbf2b15fae833f4a7eea6aad0 SHA512 4c3108e304721c2cd78eb82f5d7bccc18831db5f47bc628a98ae6a37da389deef30e7e9b6dc5644e3bc0e0fafdd907dc37822a58a25555999698527d2ac364b0
-AUX opencv-4.8.0-arm64-fp16.patch 12222 BLAKE2B 18803d74cb57bbc303c8159ca69d24dcc47d00a314bfdababeadd3b85306d289c8b35a1106011086931396e0ab82d98964434d0c0eaa34c25451c766ca9b9199 SHA512 1d9d42a711a1ae0ec7f1f641a68271d4b36f6b8701997a05d65c633d3531cad75e4edbf71c4f80cc59a9a14baa8ddebf19081dc67b99898dce13da8e3746227e
-AUX opencv-4.8.0-fix-cuda-12.2.0.patch 1920 BLAKE2B c43157c4859666a962fa40ed435aeab6b17ac01b9b67dbba0955fb7c009504b1780f5de2a40ee63db245cadf0da41b40fda0d7e06ad719071b12ba385f693ea2 SHA512 5ab0c15811748307971e8939a40c08c2c9cf3e38d2acafff72a3890f6d7c7133d8c7a087cf1a05b2dbe1907dd88911872c61c10f7638edb46ee679f658b265c6
-AUX opencv-4.8.1-ade-0.1.2a.tar.gz.patch 652 BLAKE2B 91b933513485c5e4a33b3711328f01752ea8f77bf26701744ff9a7d56f899227c1f5899dd68ec7050929c2068e2d5dc805533173543ac0ab5a5db827a6d075c3 SHA512 61267dae88ca1e9f5d99e6d57101c0a0a2df2bc5fc9f646d14953707f8c1f4fc9f58e7861b007f5970603f267f797c43cbc35e29aa66e343fcfa6e568750934e
-AUX opencv-4.8.1-drop-python2-detection.patch 1041 BLAKE2B bd7c4f66b36d04b57a4493df1b00ee6700ed6f28464f2538bde62d2b2a3d29ebb82946a1765540e6977ce6ee111dc2f37c3419ee74536f9c55340ae2e550d48a SHA512 7e5e36fa1fc312a4c791c099618c73b2f4ed5810a66f4de4ead5d0f5917d60c191c55289538bf908bcfa45522939ddfac62505e79fbfb7c3ea046a2027b576ff
-AUX opencv-4.8.1-eliminate-lto-compiler-warnings.patch 1241 BLAKE2B eead5a16616fd9afcced21180e8e336e32ad387ff4010c55e5edcf2f81f09244c4914c98ab0439911f5ab8df1f61527a83ff5f09db65743fc5266748fc8bf969 SHA512 b3907b9d9f96f107fd27189961fe1a15b5706f66524cf21ea342ed04eedfa21c08d7572001d3afb70c54a7bfef56093fd7f8ac7a5dd9ea768f1b0412b5658eec
-AUX opencv-4.8.1-libpng16.patch 2299 BLAKE2B 2aa6e7c2e35106b5c9243ad04b55eff650dc5351d73eafa2d4f703e2a965992c2145ba80f32e5e3c8a35b2370f301cb716387d9366cfc729add455a734243f6d SHA512 35b5441e78e7f62e5965350e1eae3060f258be26ac27d5a8c723b18b14e381327bb202409dfa0915ee81903b4f5ca660abd689967119ee6b3eb3bdb32072be4f
-AUX opencv-4.8.1-opencv_test.patch 724 BLAKE2B 0b56c5a7a9bd86c0d85b740284f00ecddecf2a36319565074cf23966599adf632747d67dac0dd55471a4110b157173849558920fe8cc2fa4b7126542eb546fac SHA512 a1ba01ce63f27fd8f3197860af5153940a4e751bb56cec2cd978ca3c1495da9ee9bac8e70187f1e6ef0a7d3585f8625f79753b10c41500344d35104b4f774795
-AUX opencv-4.8.1-protobuf-22.patch 6895 BLAKE2B 5f4f6d249f523de5722b628cd2233b0bb14ea2cd6fe72d221dfbdb5561a821c592d24a306022900b5efc6b71e8f135e4a537bd96d09756c8d5ccd29fad8b2a55 SHA512 63f43ea4e91726937aaa8b538d79503a3654f9a873d0398667c65e1c706ce1c591d64731970147ef82726fb2646817d439ca12b513616809e03794b57e8486ef
-AUX opencv-4.8.1-python3_12-support.patch 1354 BLAKE2B 6f1e5c7b8c3ddd3bbbe3bc9f4123ef114312155cab5eec34e431574cbc7e564f1ac87152a8adf11af75d386b2701bf4f7c337eb1941a6c699170b400013d5683 SHA512 2638f1cfb638de73e5e8a46b415844961d02ae9f398d9748535ec392c410ece010b3ee8d82a6510a153879f213aa07008f445e1cfa1144e7fd9ffbfe13e94e82
AUX opencv-4.8.1-use-system-flatbuffers.patch 1522 BLAKE2B a9000e3269266cf9e85b6ba247fd977eb1c2e0bf771d0ba1432ba1f56802f72062402e55e7327e91085be870338e452ac08ec8a958d3cf51fdd9a8daf0cfee76 SHA512 50d7ee7de6513ea56974c598641c2d9edb7679f273f6313c1dd7e68ba667688ad50fd61691661702fab75ddfa1165cd96a52ebebd19c8c09116612c90c8b11d3
AUX opencv-4.8.1-use-system-opencl.patch 933 BLAKE2B 557448d74771f6b9fc8b2fa5af79e6287c1dbad9a6c5dabe520080c7481d033002164cbfdd5a767d3b4cc54ec1344423ea8a0bbbd13a873ca955d95787924d10 SHA512 1602b74e829cd8842efbe6535e91a426a88c9ae08280d863bc4150cbe2a9d3ebef02b2abe98ee470f26412bb6fca653529492bf54b87f4d53fe20f242ef03771
AUX opencv-4.9.0-ade-0.1.2d.tar.gz.patch 652 BLAKE2B 80b3d810e31a16413b67a0c0d64991c7fe699240ae67a50ecc7d926af33359eccb6aef52facbba1bea56723698e775f293c8cae57b504e76ec1e287d2c21b810 SHA512 dc88386c96ea882848a18d9336541e525a926d9c9d75c3e9d4dc667e03ea8fe85109f360a310c8ea602c643fcc4e4317b3af81c0f4e50f9057ee0588d433b020
@@ -21,10 +12,7 @@ AUX opencv_contrib-4.8.1-NVIDIAOpticalFlowSDK-2.0.tar.gz.patch 1158 BLAKE2B c4b1
AUX opencv_contrib-4.8.1-rgbd.patch 477 BLAKE2B 0120e631199d7099bae437d459f0c950c3cbd11e5f0a900d687ca5aedf1d7602f7faa3be5ba1a9b3e0758f3fd70574450f97bd7429e447df7440d58326ceb99b SHA512 6fe2ef40bf26d40e4f52d84b17183f6e536b2fe51bf65266be6a59865def0b9c074aa5eff58a60d673afec776a7ba03acaba667c917b78751950b77f68759d96
AUX opencv_contrib-4.9.0-cuda-12.4.patch 2397 BLAKE2B 7333533f0818b04f5ec89b593f9bf7710aba496a2ba7a1688043818d4249d4a3d3e3f17c42456d2e5e0aaae728f0b9726f3943ce732f7307b0126adc68147da0 SHA512 442c97b3fbf48f0b5c1176a10b1bbcf7fccad369070b6be2a0e3e6dd2ccba88f0a7662360b108fc4d55b766d0563d5f7eef5a2fb7afa5212aac8cab73e9ad43c
DIST NVIDIAOpticalFlowSDK-edb50da3cf849840d680249aa6dbef248ebce2ca.tar.gz 8771 BLAKE2B f579960448bdaf57fbefd5e88002d8f6f4dbb828429b0f3a0112916c03039d4e4de65263eb8464a4d62924c1b77f0a61c2d93b7307657439bfbf7d59785f1533 SHA512 85dfdc52260f54f62c980508f4b6ab384e44200bd1c13761c4947f9a898c08f0faed2d734a85a4ba7a46f8788ed58ee89f12f61cee97881b69ba626bbd04f655
-DIST ade-0.1.2a.tar.gz 116737 BLAKE2B 9ac2af2f21aab8cb5d599e0b653bb6126642588e508f55e5fbfe5ce9607267f25e5187fd31ed69349064551c06e15b2ba548319708ed5f70e7761470775cc6e0 SHA512 d3ed210ff25f4c05393b0039cb4a73a6ceb8b42ba3d776e0469da2362899d3f76564cc6a06965b7de91f38517e1cd4ff4b18c00185d2b1a0af5a34ecf0d9dd44
DIST ade-0.1.2d.tar.gz 117027 BLAKE2B c544b769c7b289342a469950ed047fa13719bafba29aa41167b588cf4f24ed6e596159ec19b65e61e09519a461a5e82ac07d63e2ea493279ee182fe658810abb SHA512 46f2feee28d732a6940a5a95944f3283bde1b8c8e05466a8ca1c576623c54d1bed875ce2b24a941111d8976cb0c6ba5a4ac8408f042f5765debf1badf7d43348
-DIST opencv-4.8.1.tar.gz 92006711 BLAKE2B 54728a37e3e8a528bd8d2e6df5963a996820a51160d05ac72b350234ce5372f99c037af96e13c55de1452e517fffb478c2335b9e1cbc07a36c78f99351eabd58 SHA512 b98d89b8e7b8ae8138bce00c5226816b761b53fbeb8f28ca516e08c5d130f216f9388a81785cd6684034530f768e097cbe12f19a9361f362b7d2048bfc427a65
-DIST opencv-4.8.1_contrib.tar.gz 59200293 BLAKE2B 8cf3ee60cb38a9fa2649013b9b4704022abe5cc65c331078dc7ea87028bc99df8b0de12f835905f5bb5c00a811f256754cac018ca8e02739ac5c6fe36aa4346d SHA512 e3df49e6a1411f55eebbc02f4534ddefabff961b4f63c69b21fe06ff3df894773a8643ab0cb123b83c2bdc8fa02698b332d3c243e8546c894e6c6c8ecaa65500
DIST opencv-4.9.0.tar.gz 92788647 BLAKE2B 257478b0f5e19abca5b3676767dacd40765c645eb455080160b8b9dc54e66fba4880200b483829fc9050bc3f9b3e815f8ee784d7b41261877784536778fe3c96 SHA512 1598ae59849e7805b3cbec5260bb501006f26edff452343b366b9262a0f48a6e09f4b2e760209cb677f2a64a7b22f4e70bc6195c104bcea74cc9fe04031d0292
DIST opencv_3rdparty-34e4206aef44d50e6bbcd0ab06354b52e7466d26.tar.gz 397901 BLAKE2B 9adbe14ee3a2c90b890be694aa80d65b67e23a23f47ccabee4564e31eb9857d717b5a751df32004cfa5d6a53a9e1d8ea8d8943b705a0eaea5ca741169e2222f6 SHA512 8a92555aed2ac8752818586ab9762dd96ec128c5465cb87e402f15b15d16f7d371b3de045ef7295526e9ef99ec817766bb685a21d24dba29c650cf44e384a4e3
DIST opencv_3rdparty-8afa57abc8229d611c4937165d20e2a2d9fc5a12.tar.gz 63301261 BLAKE2B 923dc944edfda4c292d42207290bee414bfe21998f6ffe341ea3b38b6f2f581f3a243653e2c1fd3fa86084068ad6e7acd5ca73ab43094aa15f124d379833a5d8 SHA512 68cce870da0846cbd12a093ec7896b510e34590dad2b91699be1df5d4f72d343f9789d54c45c1b801784f7e57e0e80b19ba65dd99855225da99b4193dae97aaa
@@ -33,7 +21,5 @@ DIST opencv_3rdparty-b2bfc75f6aea5b1f834ff0f0b865a7c18ff1459f.tar.gz 10036903 BL
DIST opencv_3rdparty-fccf7cd6a4b12079f73bbfb21745f9babcd4eb1d.tar.gz 1470898 BLAKE2B f1794cc8f8684501f670db3d720c02f35c57ebe91f276cc21dea1f1c1426740d03569143fec74380e941703b5086db5f013ca913fb296eda99559115fd53ca30 SHA512 07118b9d688bf0ff34a6e4ca1548006124d80d11e7b48f08c9e1910b64249b1dad0ace460f50adda0ecb69b90871fc59cc25f451570c63f7c6d6ba2b92d8801c
DIST opencv_contrib-4.9.0.tar.gz 59803362 BLAKE2B e6b90e9bd462f96ef010490d45105d7125622d6c49912653c0d387568ae7109b1cbcac4cc0f52c1f997a45ed75923caea90bf4ad9336e689a56742b029789038 SHA512 ebaee3b88bd7ae246727e65a98d9fbc1d9772a4181a1926f3af742410b78dc87d2386bcd96ac67d7fb1a3020c3717a2cdebdcf9304d6dfd9ea494004791cf043
DIST opencv_extra-4.9.0.tar.gz 502141517 BLAKE2B ed7351f29c6fb80d56d5ef383af68322fa805c7689132f7ca9bb43c9a1319c5876ce6d5c40d583c955eb255dd82b876c94ed42625cd71b13830ec94b2cc75dc2 SHA512 f05c1eaed491d15107c858af5b33d0d5856070dcb6f94491ba33a172b2f0caf34905eb5d1787e1247bc888626478647fce0db7f3ccbc6d6faba0ee43fd6b6bfa
-EBUILD opencv-4.8.1-r2.ebuild 29152 BLAKE2B 26ed0294916f8062548587cc168c944aa178bcba5f2f84ceacf98e5a1380b8af8469fe6b0d201846d3678e4dba4e7647e9ee2efbed7e11a6b24ec0ed9417a06a SHA512 1cfae2b8cf6f2d975745bf4080627c1259a1c4131a688fd06e6f530b4edfa3376170f9486a1fadb1ee15aa932bb9abb27436bdd3a4c357ccf0502a756361fc31
-EBUILD opencv-4.9.0-r1.ebuild 34638 BLAKE2B 695e677013af934cf4920f69f0b0c8e3f60836ea80a39f8dd628a0431b8947f067fdc052b848d6c215511bf5661fbe9177c083815eb661bacdaeffb27a292da9 SHA512 255936aa5da242b54afdf2b8ee12a7038453d528e947fec2b113a72f620feb4f3f967fa57b0fe5c6a166d3cb8452be5a57b965f46cc7886c0fc1e123c9a7aeab
EBUILD opencv-4.9.0-r2.ebuild 35013 BLAKE2B 596d4d9cc5cc9fca76ad546cd63a6e02e1145d8fee02ea1a85686154e5cba3dca1e72724d75872db2df64550d16252a53eb53d5630c731c922bad691dac719fc SHA512 47289e69a3287d9380f0e669eb6d3f7936b32e752eefb7d59a71cb0417602f3e12b9ccde68bb276d6ac947eed64e62de1c5ead5fd3d1b8b8f1c144f6cf423b65
MISC metadata.xml 3718 BLAKE2B 44b00ff4bc94a19f6a1b68cfefb29ce9f1a4ee21ee999b72a258268893ede5274d863d3a6faa325e6f0522c078c6afae53c6de4c46d6ed5a083888e195f34276 SHA512 b6c2f0a27b84afcb576209a3bdc641e81323c01bcac9617086d79821e723ea3c9698e8f3c5db837d46da68e48b6d9d08bdd05977e22d58d6c7ad30fa7b965b52
diff --git a/media-libs/opencv/files/opencv-4.8.0-arm64-fp16.patch b/media-libs/opencv/files/opencv-4.8.0-arm64-fp16.patch
deleted file mode 100644
index 6bf04daf58ae..000000000000
--- a/media-libs/opencv/files/opencv-4.8.0-arm64-fp16.patch
+++ /dev/null
@@ -1,272 +0,0 @@
-https://github.com/opencv/opencv/pull/24203
-
-From 689fa6f372975d58e9f50fd17a0abd105b1815f1 Mon Sep 17 00:00:00 2001
-From: Sam James <sam@gentoo.org>
-Date: Mon, 28 Aug 2023 04:20:58 +0100
-Subject: [PATCH] Fix compilation on arm64 with FP16 when disabled
-
-If building with -mcpu=native or any other setting which implies the current
-CPU has FP16 but with intrinsics disabled, we mistakenly try to use it even
-though convolution.hpp conditionally defines it correctly based on whether
-we should *use it*. convolution.cpp on the other hand was mismatched and
-trying to use it if the CPU supported it, even if not enabled in the build
-system.
-
-Make the guards match.
-
-Bug: https://bugs.gentoo.org/913031
-Signed-off-by: Sam James <sam@gentoo.org>
---- a/modules/dnn/src/layers/cpu_kernels/convolution.cpp
-+++ b/modules/dnn/src/layers/cpu_kernels/convolution.cpp
-@@ -118,7 +118,7 @@ Ptr<FastConv> initFastConv(
- const size_t wstep = weightsMat.step1();
-
- conv->useFP16 = false;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- // TODO: add FP16 support for Winograd.
- if (_useFP16 && (conv->conv_type == CONV_TYPE_GENERIC || conv->conv_type == CONV_TYPE_DEPTHWISE_REMAIN))
- conv->useFP16 = true;
-@@ -137,7 +137,7 @@ Ptr<FastConv> initFastConv(
- int padded_ksize = ((ksize + VEC_ALIGN-1) / VEC_ALIGN) * VEC_ALIGN;
- int nweights = C * padded_ksize;
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (conv->useFP16)
- {
- conv->weightsBuf_FP16.resize(nweights + VEC_ALIGN);
-@@ -190,7 +190,7 @@ Ptr<FastConv> initFastConv(
- #endif
- const int CONV_WINO_NATOMS_F32 = CONV_WINO_AREA / CONV_WINO_ATOM_F32; // for AVX2, it is 8, otherwise, it's 16.
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- // FP 16
- const int CONV_WINO_ATOM_F16 = CONV_WINO_ATOM_F32 * 2;
- const int CONV_WINO_NATOMS_F16 = CONV_WINO_AREA / CONV_WINO_ATOM_F16;
-@@ -208,7 +208,7 @@ Ptr<FastConv> initFastConv(
- size_t nweights = ngroups*Kg_nblocks*Cg*CONV_WINO_KBLOCK*CONV_WINO_AREA;
-
- float* wptrWino = nullptr;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- float16_t* wptrWino_FP16 = nullptr;
- if (conv->useFP16)
- {
-@@ -264,7 +264,7 @@ Ptr<FastConv> initFastConv(
- }
-
- // repack the data.
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (conv->useFP16)
- {
- float16_t* wptr = wptrWino_FP16 + (g*Kg_nblocks + ki) * Cg *CONV_WINO_KBLOCK*CONV_WINO_AREA +
-@@ -308,7 +308,7 @@ Ptr<FastConv> initFastConv(
-
- float* weightsBufPtr = nullptr;
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- int numStripsMR_FP16 = (Kg + CONV_MR_FP16 - 1) / CONV_MR_FP16;
- int Kg_aligned_FP16 = numStripsMR_FP16 * CONV_MR_FP16;
- size_t nweights_FP16 = ngroups * Kg_aligned_FP16 * DkHkWkCg;
-@@ -331,7 +331,7 @@ Ptr<FastConv> initFastConv(
- }
-
- // Pack the weight.
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (conv->useFP16)
- {
- parallel_for_(Range(0, ngroups * numStripsMR_FP16), [&](const Range& r0){
-@@ -415,7 +415,7 @@ static inline void packData8(char*& inpbuf, float*& inptrIn, int& in_w, int& x0,
- char * inpbufC = inpbuf + s0 * esz;
- float* inptrInC = (float* )inptrIn;
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- float16_t* inpbufC_FP16 = (float16_t *)inpbufC;
- if (esz == sizeof(float16_t))
- {
-@@ -521,7 +521,7 @@ static inline void packData2(char *& inpbuf, float*& inptrIn, int& in_w, int& x0
- char* inpbufC = inpbuf + s0 * esz;
- float* inptrInC = inptrIn;
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- float16_t* inpbufC_FP16 = (float16_t *)inpbufC;
- if (esz == sizeof(float16_t))
- {
-@@ -553,7 +553,7 @@ static inline void packData2(char *& inpbuf, float*& inptrIn, int& in_w, int& x0
- in_w += stride_w;
- }
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- // Fast convert float 32 to float16
- static inline void _cvt32f16f( const float* src, float16_t* dst, int len)
- {
-@@ -623,7 +623,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- {
- // Make special branch where memcpy() is called with a constant buffer size.
- // Compilers will likely unroll this loop properly.
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inptr += inp_planesize, inpbuf += CONV_NR_esz)
-@@ -636,7 +636,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- }
- else
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inptr += inp_planesize, inpbuf += CONV_NR_esz)
-@@ -700,7 +700,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- int w0 = std::max(0, (-in_w + dilation_w-1)/dilation_w);
- int w1 = std::min(Wk, (Wi - in_w + dilation_w-1)/dilation_w);
- const float* inptrInC = inptrIn;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- float16_t* inpbufC = (float16_t *)inpbuf + s0;
-@@ -761,7 +761,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- int w1 = std::min(Wk, (Wi - in_w + dilation_w-1)/dilation_w);
-
- const float* inptrInC = inptrIn;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- float16_t* inpbufC = (float16_t *)inpbuf + s0;
-@@ -834,7 +834,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- int w0 = std::max(0, (-in_w + dilation_w-1)/dilation_w);
- int w1 = std::min(Wk, (Wi - in_w + dilation_w-1)/dilation_w);
- const float* inptrInC = inptrIn;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- float16_t* inpbufC = (float16_t* )inpbuf + s0;
-@@ -887,7 +887,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- for (; i < CONV_NR;)
- {
- float* inpbuf_ki = (float* )inpbuf + k * CONV_NR * Cg + i;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- float16_t * inpbuf_ki_FP16 = (float16_t *)inpbuf + k * CONV_NR * Cg + i;
- #endif
-
-@@ -903,7 +903,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- {
- if (stride_w == 1)
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR, inptr_ki += inp_planesize)
-@@ -934,7 +934,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- }
- else if (stride_w == 2)
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR, inptr_ki += inp_planesize)
-@@ -967,7 +967,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- }
- else
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR, inptr_ki += inp_planesize)
-@@ -1006,7 +1006,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- {
- if (stride_w == 1)
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR, inptr_ki += inp_planesize)
-@@ -1029,7 +1029,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- }
- else
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR, inptr_ki += inp_planesize)
-@@ -1057,7 +1057,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- }
- else
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR, inptr_ki += inp_planesize)
-@@ -1073,7 +1073,7 @@ static inline void packInputData(char* inpbuf_task, float* inp, const int* ofsta
- }
- else
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- for (int c = 0; c < Cg; c++, inpbuf_ki_FP16 += CONV_NR)
-@@ -1260,7 +1260,7 @@ void runFastConv(InputArray _input, OutputArray _output, const Ptr<FastConv>& co
- int CONV_MR = CONV_MR_FP32;
- int esz = sizeof(float );
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- // works at FP 16.
-@@ -1433,7 +1433,7 @@ void runFastConv(InputArray _input, OutputArray _output, const Ptr<FastConv>& co
- }
-
- char *weights = nullptr;
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- CV_Assert(!conv->weightsBuf_FP16.empty());
-@@ -1474,7 +1474,7 @@ void runFastConv(InputArray _input, OutputArray _output, const Ptr<FastConv>& co
- #if CV_NEON && CV_NEON_AARCH64
- if (conv->useNEON)
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- opt_NEON::convBlockMR1_FP16(DkHkWkCg, weights, inptr, cptr, biasVal, fusedAdd, minval, maxval, ifMinMaxAct, outLen, CONV_NR);
-@@ -1537,7 +1537,7 @@ void runFastConv(InputArray _input, OutputArray _output, const Ptr<FastConv>& co
- #if CV_NEON
- if (conv->useNEON)
- {
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- opt_NEON::convBlock_FP16(c1 - c0, wptr, inptr, (char *)cptr_f16, ldc, c0 == 0, outLen, CONV_MR, CONV_NR);
-@@ -1567,7 +1567,7 @@ void runFastConv(InputArray _input, OutputArray _output, const Ptr<FastConv>& co
- float biasval = biasptr[k];
- int j = 0;
-
--#ifdef CONV_ARM_FP16
-+#if defined(CONV_ARM_FP16) && CV_FP16
- if (useFP16)
- {
- float32x4_t vbias = vdupq_n_f32(biasval);
diff --git a/media-libs/opencv/files/opencv-4.8.0-fix-cuda-12.2.0.patch b/media-libs/opencv/files/opencv-4.8.0-fix-cuda-12.2.0.patch
deleted file mode 100644
index fd7d12af2644..000000000000
--- a/media-libs/opencv/files/opencv-4.8.0-fix-cuda-12.2.0.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-https://github.com/opencv/opencv/pull/24104
-https://github.com/opencv/opencv/commit/5466fd2606ca6df57bbe43f064d2ae73fe4329eb
-https://bugs.gentoo.org/915775
-
-From ab8cb6f8a9034da2a289b84685c6d959266029be Mon Sep 17 00:00:00 2001
-From: cudawarped <12133430+cudawarped@users.noreply.github.com>
-Date: Tue, 1 Aug 2023 13:02:42 +0300
-Subject: [PATCH] cuda: fix for compatibility with CUDA Toolkit >= 12.2.0
-
----
- modules/dnn/src/cuda4dnn/primitives/normalize_bbox.hpp | 2 +-
- modules/dnn/src/cuda4dnn/primitives/region.hpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/modules/dnn/src/cuda4dnn/primitives/normalize_bbox.hpp b/modules/dnn/src/cuda4dnn/primitives/normalize_bbox.hpp
-index f067dddaa701..91ff33f81718 100644
---- a/modules/dnn/src/cuda4dnn/primitives/normalize_bbox.hpp
-+++ b/modules/dnn/src/cuda4dnn/primitives/normalize_bbox.hpp
-@@ -111,7 +111,7 @@ namespace cv { namespace dnn { namespace cuda4dnn {
- * or there might be several weights
- * or we don't have to scale
- */
-- if (weight != 1.0)
-+ if (weight != static_cast<T>(1.0f))
- {
- kernels::scale1_with_bias1<T>(stream, output, input, weight, 1.0);
- }
-diff --git a/modules/dnn/src/cuda4dnn/primitives/region.hpp b/modules/dnn/src/cuda4dnn/primitives/region.hpp
-index d22d44214e7b..3af05155feea 100644
---- a/modules/dnn/src/cuda4dnn/primitives/region.hpp
-+++ b/modules/dnn/src/cuda4dnn/primitives/region.hpp
-@@ -121,7 +121,7 @@ namespace cv { namespace dnn { namespace cuda4dnn {
- new_coords
- );
-
-- if (nms_iou_threshold > 0) {
-+ if (nms_iou_threshold > static_cast<T>(0.0f)) {
- auto output_mat = output_wrapper->getMutableHostMat();
- CV_Assert(output_mat.type() == CV_32F);
- for (int i = 0; i < input.get_axis_size(0); i++) {
diff --git a/media-libs/opencv/files/opencv-4.8.1-ade-0.1.2a.tar.gz.patch b/media-libs/opencv/files/opencv-4.8.1-ade-0.1.2a.tar.gz.patch
deleted file mode 100644
index 056553695ee2..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-ade-0.1.2a.tar.gz.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-From: Paul Zander <negril.nx+gentoo@gmail.com>
-
-Use tar.gz instead of zip to make CI happy.
-
-diff --git a/modules/gapi/cmake/DownloadADE.cmake b/modules/gapi/cmake/DownloadADE.cmake
-index e22c4f1..fb0c10a 100644
---- a/modules/gapi/cmake/DownloadADE.cmake
-+++ b/modules/gapi/cmake/DownloadADE.cmake
-@@ -1,7 +1,7 @@
- set(ade_src_dir "${OpenCV_BINARY_DIR}/3rdparty/ade")
--set(ade_filename "v0.1.2a.zip")
-+set(ade_filename "v0.1.2a.tar.gz")
- set(ade_subdir "ade-0.1.2a")
--set(ade_md5 "fa4b3e25167319cb0fa9432ef8281945")
-+set(ade_md5 "89fd5f32c2796d3fecf62273c4aa7c4d")
- ocv_download(FILENAME ${ade_filename}
- HASH ${ade_md5}
- URL
diff --git a/media-libs/opencv/files/opencv-4.8.1-drop-python2-detection.patch b/media-libs/opencv/files/opencv-4.8.1-drop-python2-detection.patch
deleted file mode 100644
index 5a3a89f665b4..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-drop-python2-detection.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-From: Paul Zander <negril.nx+gentoo@gmail.com>
-
-Python2 is long gone. So don't try finding it.
-
-diff --git a/cmake/OpenCVDetectPython.cmake b/cmake/OpenCVDetectPython.cmake
-index 599b2eb..345e3ef 100644
---- a/cmake/OpenCVDetectPython.cmake
-+++ b/cmake/OpenCVDetectPython.cmake
-@@ -268,14 +268,6 @@ if(OPENCV_PYTHON_SKIP_DETECTION)
- return()
- endif()
-
--find_python("" "${MIN_VER_PYTHON2}" PYTHON2_LIBRARY PYTHON2_INCLUDE_DIR
-- PYTHON2INTERP_FOUND PYTHON2_EXECUTABLE PYTHON2_VERSION_STRING
-- PYTHON2_VERSION_MAJOR PYTHON2_VERSION_MINOR PYTHON2LIBS_FOUND
-- PYTHON2LIBS_VERSION_STRING PYTHON2_LIBRARIES PYTHON2_LIBRARY
-- PYTHON2_DEBUG_LIBRARIES PYTHON2_LIBRARY_DEBUG PYTHON2_INCLUDE_PATH
-- PYTHON2_INCLUDE_DIR PYTHON2_INCLUDE_DIR2 PYTHON2_PACKAGES_PATH
-- PYTHON2_NUMPY_INCLUDE_DIRS PYTHON2_NUMPY_VERSION)
--
- option(OPENCV_PYTHON3_VERSION "Python3 version" "")
- find_python("${OPENCV_PYTHON3_VERSION}" "${MIN_VER_PYTHON3}" PYTHON3_LIBRARY PYTHON3_INCLUDE_DIR
- PYTHON3INTERP_FOUND PYTHON3_EXECUTABLE PYTHON3_VERSION_STRING
diff --git a/media-libs/opencv/files/opencv-4.8.1-eliminate-lto-compiler-warnings.patch b/media-libs/opencv/files/opencv-4.8.1-eliminate-lto-compiler-warnings.patch
deleted file mode 100644
index 7d6a5456a63f..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-eliminate-lto-compiler-warnings.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-https://github.com/opencv/opencv/pull/23991
-
-From 4ee0f212cc19f7e77483d34d4cf8378945e3da31 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?=E4=B8=8D=E9=B1=BC=E5=84=BF?=
- <36976072+buyuer@users.noreply.github.com>
-Date: Fri, 14 Jul 2023 08:45:14 +0000
-Subject: [PATCH] Eliminating compilation warnings when using lto in gcc12 and
- later versions
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-use -flto=auto when use gcc12 or later
-
-Signed-off-by: 不鱼儿 <36976072+buyuer@users.noreply.github.com>
----
- cmake/OpenCVCompilerOptions.cmake | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/cmake/OpenCVCompilerOptions.cmake b/cmake/OpenCVCompilerOptions.cmake
-index d4600943fb0d..8bd86681303e 100644
---- a/cmake/OpenCVCompilerOptions.cmake
-+++ b/cmake/OpenCVCompilerOptions.cmake
-@@ -261,7 +261,11 @@ if(CV_GCC OR CV_CLANG)
- endif()
-
- if(ENABLE_LTO)
-- add_extra_compiler_option(-flto)
-+ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 12)
-+ add_extra_compiler_option(-flto=auto)
-+ else()
-+ add_extra_compiler_option(-flto)
-+ endif()
- endif()
- if(ENABLE_THIN_LTO)
- add_extra_compiler_option(-flto=thin)
diff --git a/media-libs/opencv/files/opencv-4.8.1-libpng16.patch b/media-libs/opencv/files/opencv-4.8.1-libpng16.patch
deleted file mode 100644
index a5b2aedb063a..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-libpng16.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From: Paul Zander <negril.nx+gentoo@gmail.com>
-
-Gentoo installs libpng as libpng16, so adjust the detection.
-
-diff --git a/cmake/OpenCVFindLibsGrfmt.cmake b/cmake/OpenCVFindLibsGrfmt.cmake
-index 46b5108..0ff88ea 100644
---- a/cmake/OpenCVFindLibsGrfmt.cmake
-+++ b/cmake/OpenCVFindLibsGrfmt.cmake
-@@ -245,9 +245,9 @@ if(NOT HAVE_SPNG AND WITH_PNG)
- include(FindPNG)
- if(PNG_FOUND)
- include(CheckIncludeFile)
-- check_include_file("${PNG_PNG_INCLUDE_DIR}/libpng/png.h" HAVE_LIBPNG_PNG_H)
-- if(HAVE_LIBPNG_PNG_H)
-- ocv_parse_header("${PNG_PNG_INCLUDE_DIR}/libpng/png.h" PNG_VERSION_LINES PNG_LIBPNG_VER_MAJOR PNG_LIBPNG_VER_MINOR PNG_LIBPNG_VER_RELEASE)
-+ check_include_file("${PNG_PNG_INCLUDE_DIR}/libpng16/png.h" HAVE_LIBPNG16_PNG_H)
-+ if(HAVE_LIBPNG16_PNG_H)
-+ ocv_parse_header("${PNG_PNG_INCLUDE_DIR}/libpng16/png.h" PNG_VERSION_LINES PNG_LIBPNG_VER_MAJOR PNG_LIBPNG_VER_MINOR PNG_LIBPNG_VER_RELEASE)
- else()
- ocv_parse_header("${PNG_PNG_INCLUDE_DIR}/png.h" PNG_VERSION_LINES PNG_LIBPNG_VER_MAJOR PNG_LIBPNG_VER_MINOR PNG_LIBPNG_VER_RELEASE)
- endif()
-@@ -255,7 +255,7 @@ if(NOT HAVE_SPNG AND WITH_PNG)
- endif()
-
- if(NOT PNG_FOUND)
-- ocv_clear_vars(PNG_LIBRARY PNG_LIBRARIES PNG_INCLUDE_DIR PNG_PNG_INCLUDE_DIR HAVE_LIBPNG_PNG_H PNG_DEFINITIONS)
-+ ocv_clear_vars(PNG_LIBRARY PNG_LIBRARIES PNG_INCLUDE_DIR PNG_PNG_INCLUDE_DIR HAVE_LIBPNG16_PNG_H PNG_DEFINITIONS)
-
- set(PNG_LIBRARY libpng CACHE INTERNAL "")
- set(PNG_LIBRARIES ${PNG_LIBRARY})
-diff --git a/cmake/templates/cvconfig.h.in b/cmake/templates/cvconfig.h.in
-index d6c7875..005e9b3 100644
---- a/cmake/templates/cvconfig.h.in
-+++ b/cmake/templates/cvconfig.h.in
-@@ -79,7 +79,7 @@
- #cmakedefine HAVE_JPEG
-
- /* libpng/png.h needs to be included */
--#cmakedefine HAVE_LIBPNG_PNG_H
-+#cmakedefine HAVE_LIBPNG16_PNG_H
-
- /* GDCM DICOM codec */
- #cmakedefine HAVE_GDCM
-diff --git a/modules/imgcodecs/src/grfmt_png.cpp b/modules/imgcodecs/src/grfmt_png.cpp
-index 388a3fc..4dde181 100644
---- a/modules/imgcodecs/src/grfmt_png.cpp
-+++ b/modules/imgcodecs/src/grfmt_png.cpp
-@@ -58,8 +58,8 @@
- # define _FILE_OFFSET_BITS 0
- #endif
-
--#ifdef HAVE_LIBPNG_PNG_H
--#include <libpng/png.h>
-+#ifdef HAVE_LIBPNG16_PNG_H
-+#include <libpng16/png.h>
- #else
- #include <png.h>
- #endif
diff --git a/media-libs/opencv/files/opencv-4.8.1-opencv_test.patch b/media-libs/opencv/files/opencv-4.8.1-opencv_test.patch
deleted file mode 100644
index 2bdc2d830570..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-opencv_test.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-From: Paul Zander <negril.nx+gentoo@gmail.com>
-
-We don't package quirc, so the misplaced #ifdef breaks compilation.
-
-diff --git a/modules/objdetect/test/test_qrcode.cpp b/modules/objdetect/test/test_qrcode.cpp
-index 5e6ec6f..6dc14cc 100644
---- a/modules/objdetect/test/test_qrcode.cpp
-+++ b/modules/objdetect/test/test_qrcode.cpp
-@@ -374,8 +374,8 @@ TEST_P(Objdetect_QRCode_Multi, regression)
- qrcode = QRCodeDetectorAruco();
- }
- std::vector<Point> corners;
--#ifdef HAVE_QUIRC
- std::vector<cv::String> decoded_info;
-+#ifdef HAVE_QUIRC
- std::vector<Mat> straight_barcode;
- EXPECT_TRUE(qrcode.detectAndDecodeMulti(src, decoded_info, corners, straight_barcode));
- ASSERT_FALSE(corners.empty());
diff --git a/media-libs/opencv/files/opencv-4.8.1-protobuf-22.patch b/media-libs/opencv/files/opencv-4.8.1-protobuf-22.patch
deleted file mode 100644
index 1e8a369777a5..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-protobuf-22.patch
+++ /dev/null
@@ -1,190 +0,0 @@
-From 6f3dde396f6eed53afcd5cc882402e18ff7c1ca8 Mon Sep 17 00:00:00 2001
-From: Kumataro <Kumataro@users.noreply.github.com>
-Date: Sat, 7 Oct 2023 10:11:25 +0900
-Subject: [PATCH] 3rdparty: supporting protobuf v22 and later
-
-subsumes:
-
-- dnn: disable some tests for external protobuf
-- use GREATER instead of GREATER_EQUAL and remove new blank line at EOF
-- fix for BUILD_TESTS=OFF
-- Use Config mode in CMake.
-
-(cleaning up review noise)
-
----
- cmake/OpenCVFindProtobuf.cmake | 35 +++++++++++++++++++++++++++-----
- modules/dnn/CMakeLists.txt | 6 ++++++
- modules/dnn/test/test_layers.cpp | 24 ++++++++++++++++++----
- 3 files changed, 56 insertions(+), 9 deletions(-)
-
-diff --git a/cmake/OpenCVFindProtobuf.cmake b/cmake/OpenCVFindProtobuf.cmake
-index 8835347..5b1e175 100644
---- a/cmake/OpenCVFindProtobuf.cmake
-+++ b/cmake/OpenCVFindProtobuf.cmake
-@@ -30,8 +30,14 @@ if(BUILD_PROTOBUF)
- set(Protobuf_LIBRARIES "libprotobuf")
- set(HAVE_PROTOBUF TRUE)
- else()
-+ # we still need this for command PROTOBUF_GENERATE_CPP.
-+ set(protobuf_MODULE_COMPATIBLE ON)
-+
- unset(Protobuf_VERSION CACHE)
-- find_package(Protobuf QUIET)
-+ find_package(Protobuf QUIET CONFIG)
-+ if(NOT Protobuf_FOUND)
-+ find_package(Protobuf QUIET)
-+ endif()
-
- # Backwards compatibility
- # Define camel case versions of input variables
-@@ -67,6 +73,20 @@ else()
- endif()
- endif()
-
-+# See https://github.com/opencv/opencv/issues/24369
-+# In Protocol Buffers v22.0 and later drops C++11 support and depends abseil-cpp.
-+# Details: https://protobuf.dev/news/2022-08-03/
-+# And if std::text_view is in abseil-cpp requests C++17 and later.
-+
-+if(HAVE_PROTOBUF)
-+ if(NOT (Protobuf_VERSION VERSION_LESS 22))
-+ if((CMAKE_CXX_STANDARD EQUAL 98) OR (CMAKE_CXX_STANDARD LESS 17))
-+ message(STATUS "CMAKE_CXX_STANDARD=${CMAKE_CXX_STANDARD} is too old to support protobuf(${Protobuf_VERSION}) and/or abseil-cpp. Use C++17 or later. Turning HAVE_PROTOBUF off")
-+ set(HAVE_PROTOBUF FALSE)
-+ endif()
-+ endif()
-+endif()
-+
- if(HAVE_PROTOBUF AND PROTOBUF_UPDATE_FILES AND NOT COMMAND PROTOBUF_GENERATE_CPP)
- message(FATAL_ERROR "Can't configure protobuf dependency (BUILD_PROTOBUF=${BUILD_PROTOBUF} PROTOBUF_UPDATE_FILES=${PROTOBUF_UPDATE_FILES})")
- endif()
-@@ -74,15 +94,20 @@ endif()
- if(HAVE_PROTOBUF)
- list(APPEND CUSTOM_STATUS protobuf)
- if(NOT BUILD_PROTOBUF)
-+ unset( __location)
- if(TARGET "${Protobuf_LIBRARIES}")
- get_target_property(__location "${Protobuf_LIBRARIES}" IMPORTED_LOCATION_RELEASE)
- if(NOT __location)
- get_target_property(__location "${Protobuf_LIBRARIES}" IMPORTED_LOCATION)
- endif()
-- elseif(Protobuf_LIBRARY)
-- set(__location "${Protobuf_LIBRARY}")
-- else()
-- set(__location "${Protobuf_LIBRARIES}")
-+ endif()
-+
-+ if(NOT __location)
-+ if(Protobuf_LIBRARY)
-+ set(__location "${Protobuf_LIBRARY}")
-+ else()
-+ set(__location "${Protobuf_LIBRARIES}")
-+ endif()
- endif()
- endif()
- list(APPEND CUSTOM_STATUS_protobuf " Protobuf:"
-diff --git a/modules/dnn/CMakeLists.txt b/modules/dnn/CMakeLists.txt
-index 804b78e..9fcc460 100644
---- a/modules/dnn/CMakeLists.txt
-+++ b/modules/dnn/CMakeLists.txt
-@@ -245,6 +245,12 @@ ocv_create_module(${libs} ${dnn_runtime_libs})
- ocv_add_samples()
- ocv_add_accuracy_tests(${dnn_runtime_libs})
-
-+if(NOT BUILD_PROTOBUF)
-+ if(TARGET opencv_test_dnn)
-+ ocv_target_compile_definitions(opencv_test_dnn PRIVATE "OPENCV_DNN_EXTERNAL_PROTOBUF=1")
-+ endif()
-+endif()
-+
- set(perf_path "${CMAKE_CURRENT_LIST_DIR}/perf")
- file(GLOB_RECURSE perf_srcs "${perf_path}/*.cpp")
- file(GLOB_RECURSE perf_hdrs "${perf_path}/*.hpp" "${perf_path}/*.h")
-diff --git a/modules/dnn/test/test_layers.cpp b/modules/dnn/test/test_layers.cpp
-index 763d94b..6cb6d54 100644
---- a/modules/dnn/test/test_layers.cpp
-+++ b/modules/dnn/test/test_layers.cpp
-@@ -756,11 +756,15 @@ TEST_F(Layer_RNN_Test, get_set_test)
-
- TEST_P(Test_Caffe_layers, Accum)
- {
-+#ifdef OPENCV_DNN_EXTERNAL_PROTOBUF
-+ throw SkipTestException("Requires patched protobuf");
-+#else
- if (backend == DNN_BACKEND_OPENCV && target != DNN_TARGET_CPU)
- applyTestTag(CV_TEST_TAG_DNN_SKIP_OPENCL, CV_TEST_TAG_DNN_SKIP_OPENCL_FP16);
-
- testLayerUsingCaffeModels("accum", false, false, 0.0, 0.0, 2);
- testLayerUsingCaffeModels("accum_ref", false, false, 0.0, 0.0, 2);
-+#endif
- }
-
- TEST_P(Test_Caffe_layers, FlowWarp)
-@@ -780,27 +784,39 @@ TEST_P(Test_Caffe_layers, ChannelNorm)
-
- TEST_P(Test_Caffe_layers, DataAugmentation)
- {
-+#ifdef OPENCV_DNN_EXTERNAL_PROTOBUF
-+ throw SkipTestException("Requires patched protobuf");
-+#else
- if (backend == DNN_BACKEND_OPENCV && target == DNN_TARGET_OPENCL_FP16)
- applyTestTag(CV_TEST_TAG_DNN_SKIP_OPENCL_FP16);
- testLayerUsingCaffeModels("data_augmentation", true, false);
- testLayerUsingCaffeModels("data_augmentation_2x1", true, false);
- testLayerUsingCaffeModels("data_augmentation_8x6", true, false);
-+#endif
- }
-
- TEST_P(Test_Caffe_layers, Resample)
- {
-+#ifdef OPENCV_DNN_EXTERNAL_PROTOBUF
-+ throw SkipTestException("Requires patched protobuf");
-+#else
- if (backend != DNN_BACKEND_OPENCV)
- applyTestTag(CV_TEST_TAG_DNN_SKIP_IE_NN_BUILDER, CV_TEST_TAG_DNN_SKIP_IE_NGRAPH);
- testLayerUsingCaffeModels("nearest_2inps", false, false, 0.0, 0.0, 2);
- testLayerUsingCaffeModels("nearest", false, false);
-+#endif
- }
-
- TEST_P(Test_Caffe_layers, Correlation)
- {
-+#ifdef OPENCV_DNN_EXTERNAL_PROTOBUF
-+ throw SkipTestException("Requires patched protobuf");
-+#else
- if (backend == DNN_BACKEND_OPENCV && target == DNN_TARGET_OPENCL_FP16)
- applyTestTag(CV_TEST_TAG_DNN_SKIP_IE_NGRAPH, CV_TEST_TAG_DNN_SKIP_IE_NN_BUILDER,
- CV_TEST_TAG_DNN_SKIP_OPENCL, CV_TEST_TAG_DNN_SKIP_OPENCL_FP16);
- testLayerUsingCaffeModels("correlation", false, false, 0.0, 0.0, 2);
-+#endif
- }
-
- TEST_P(Test_Caffe_layers, Convolution2Inputs)
-@@ -1641,12 +1657,11 @@ private:
- int outWidth, outHeight, zoomFactor;
- };
-
--#ifndef OPENCV_DNN_EXTERNAL_PROTOBUF
- TEST_P(Test_Caffe_layers, Interp)
--#else
--TEST_P(Test_Caffe_layers, DISABLED_Interp) // requires patched protobuf (available in OpenCV source tree only)
--#endif
- {
-+#ifdef OPENCV_DNN_EXTERNAL_PROTOBUF
-+ throw SkipTestException("Requires patched protobuf");
-+#else
- #if defined(INF_ENGINE_RELEASE) && INF_ENGINE_VER_MAJOR_EQ(2021030000)
- if (backend == DNN_BACKEND_INFERENCE_ENGINE_NGRAPH && target == DNN_TARGET_MYRIAD)
- applyTestTag(CV_TEST_TAG_DNN_SKIP_IE_MYRIAD, CV_TEST_TAG_DNN_SKIP_IE_NGRAPH); // exception
-@@ -1670,6 +1685,7 @@ TEST_P(Test_Caffe_layers, DISABLED_Interp) // requires patched protobuf (availa
-
- // Test an implemented layer.
- testLayerUsingCaffeModels("layer_interp", false, false);
-+#endif
- }
-
- INSTANTIATE_TEST_CASE_P(/*nothing*/, Test_Caffe_layers, dnnBackendsAndTargets());
---
-2.43.0
-
diff --git a/media-libs/opencv/files/opencv-4.8.1-python3_12-support.patch b/media-libs/opencv/files/opencv-4.8.1-python3_12-support.patch
deleted file mode 100644
index 7eae8a180ce6..000000000000
--- a/media-libs/opencv/files/opencv-4.8.1-python3_12-support.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-https://github.com/opencv/opencv/pull/23991
-
-From 00ca8f455e6a5588d905e3a0b268f18ee3fda5dd Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Sun, 1 Oct 2023 16:12:25 +0100
-Subject: [PATCH] `numpy.distutils` is removed in numpy 1.26 on Python 3.12.
-
-so we don't use numpy.distutils to get includes dirs of python-numpy
----
- cmake/OpenCVDetectPython.cmake | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/cmake/OpenCVDetectPython.cmake b/cmake/OpenCVDetectPython.cmake
-index 88a434185622..d4098ce8e60d 100644
---- a/cmake/OpenCVDetectPython.cmake
-+++ b/cmake/OpenCVDetectPython.cmake
-@@ -216,7 +216,7 @@ if(NOT ${found})
- message(STATUS " PYTHON3_NUMPY_INCLUDE_DIRS")
- else()
- # Attempt to discover the NumPy include directory. If this succeeds, then build python API with NumPy
-- execute_process(COMMAND "${_executable}" -c "import os; os.environ['DISTUTILS_USE_SDK']='1'; import numpy.distutils; print(os.pathsep.join(numpy.distutils.misc_util.get_numpy_include_dirs()))"
-+ execute_process(COMMAND "${_executable}" -c "import numpy; print(numpy.get_include())"
- RESULT_VARIABLE _numpy_process
- OUTPUT_VARIABLE _numpy_include_dirs
- OUTPUT_STRIP_TRAILING_WHITESPACE)
diff --git a/media-libs/opencv/opencv-4.8.1-r2.ebuild b/media-libs/opencv/opencv-4.8.1-r2.ebuild
deleted file mode 100644
index bb6a1ae807ab..000000000000
--- a/media-libs/opencv/opencv-4.8.1-r2.ebuild
+++ /dev/null
@@ -1,794 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{10..12} )
-inherit cuda java-pkg-opt-2 java-ant-2 cmake-multilib flag-o-matic python-r1 toolchain-funcs
-
-DESCRIPTION="A collection of algorithms and sample code for various computer vision problems"
-HOMEPAGE="https://opencv.org"
-
-ADE_PV="0.1.2a" # branch master
-QRCODE_COMMIT="a8b69ccc738421293254aec5ddb38bd523503252" # branch wechat_qrcode_20210119
-DNN_SAMPLES_FACE_DETECTOR_COMMIT="b2bfc75f6aea5b1f834ff0f0b865a7c18ff1459f" # branch dnn_samples_face_detector_20170830
-XFEATURES2D_BOOSTDESC_COMMIT="34e4206aef44d50e6bbcd0ab06354b52e7466d26" # branch contrib_xfeatures2d_boostdesc_20161012
-XFEATURES2D_VGG_COMMIT="fccf7cd6a4b12079f73bbfb21745f9babcd4eb1d" # branch contrib_xfeatures2d_vgg_20160317
-FACE_ALIGNMENT_COMMIT="8afa57abc8229d611c4937165d20e2a2d9fc5a12" # branch contrib_face_alignment_20170818
-NVIDIA_OPTICAL_FLOW_COMMIT="edb50da3cf849840d680249aa6dbef248ebce2ca" # branch nvof_2_0_bsd
-
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz
- https://github.com/opencv/ade/archive/v${ADE_PV}.tar.gz -> ade-${ADE_PV}.tar.gz
- contrib? (
- https://github.com/${PN}/${PN}_contrib/archive/${PV}.tar.gz -> ${P}_contrib.tar.gz
- dnnsamples? (
- https://github.com/${PN}/${PN}_3rdparty/archive/${QRCODE_COMMIT}.tar.gz -> ${PN}_3rdparty-${QRCODE_COMMIT}.tar.gz
- https://github.com/${PN}/${PN}_3rdparty/archive/${DNN_SAMPLES_FACE_DETECTOR_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${DNN_SAMPLES_FACE_DETECTOR_COMMIT}.tar.gz
- )
- contribxfeatures2d? (
- https://github.com/${PN}/${PN}_3rdparty/archive/${XFEATURES2D_BOOSTDESC_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}.tar.gz
- https://github.com/${PN}/${PN}_3rdparty/archive/${XFEATURES2D_VGG_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}.tar.gz
- )
- contribdnn? (
- https://github.com/${PN}/${PN}_3rdparty/archive/${FACE_ALIGNMENT_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}.tar.gz
- )
- cuda? (
- https://github.com/NVIDIA/NVIDIAOpticalFlowSDK/archive/${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz
- -> NVIDIAOpticalFlowSDK-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz
- )
- )
-"
-
-LICENSE="Apache-2.0"
-SLOT="0/${PV}" # subslot = libopencv* soname version
-KEYWORDS="amd64 ~arm arm64 ~loong ~ppc ~ppc64 ~riscv x86"
-IUSE="contrib contribcvv contribdnn contribfreetype contribhdf contribovis contribsfm contribxfeatures2d cuda cudnn debug dnnsamples +eigen examples +features2d ffmpeg gdal gflags glog gphoto2 gstreamer gtk3 ieee1394 jpeg jpeg2k lapack non-free opencl openexr opengl openmp opencvapps png +python qt5 qt6 tesseract testprograms tbb tiff vaapi v4l vtk webp xine video_cards_intel"
-
-# The following lines are shamelessly stolen from ffmpeg-9999.ebuild with modifications
-ARM_CPU_FEATURES=(
- cpu_flags_arm_neon:NEON
- cpu_flags_arm_vfpv3:VFPV3
-)
-PPC_CPU_FEATURES=(
- cpu_flags_ppc_vsx:VSX
- cpu_flags_ppc_vsx3:VSX3
-)
-X86_CPU_FEATURES_RAW=(
- sse:SSE
- sse2:SSE2
- sse3:SSE3
- ssse3:SSSE3
- sse4_1:SSE4_1
- popcnt:POPCNT
- sse4_2:SSE4_2
- f16c:FP16
- fma3:FMA3
- avx:AVX
- avx2:AVX2
- avx512f:AVX_512F
-)
-X86_CPU_FEATURES=( ${X86_CPU_FEATURES_RAW[@]/#/cpu_flags_x86_} )
-CPU_FEATURES_MAP=(
- ${ARM_CPU_FEATURES[@]}
- ${PPC_CPU_FEATURES[@]}
- ${X86_CPU_FEATURES[@]}
-)
-IUSE="${IUSE} ${CPU_FEATURES_MAP[@]%:*}"
-
-# OpenGL needs gtk or Qt installed to activate, otherwise build system
-# will silently disable it without the user knowing, which defeats the
-# purpose of the opengl use flag.
-# cuda needs contrib, bug #701712
-REQUIRED_USE="
- cpu_flags_x86_avx2? ( cpu_flags_x86_f16c )
- cpu_flags_x86_f16c? ( cpu_flags_x86_avx )
- cuda? (
- contrib
- tesseract? ( opencl )
- )
- cudnn? ( cuda )
- dnnsamples? ( examples )
- gflags? ( contrib )
- glog? ( contrib )
- contribcvv? ( contrib || ( qt5 qt6 ) )
- contribdnn? ( contrib )
- contribfreetype? ( contrib )
- contribhdf? ( contrib )
- contribovis? ( contrib )
- contribsfm? ( contrib eigen gflags glog )
- contribxfeatures2d? ( contrib )
- java? ( python )
- opengl? ( || ( qt5 qt6 ) )
- python? ( ${PYTHON_REQUIRED_USE} )
- tesseract? ( contrib )
- ?? ( gtk3 || ( qt5 qt6 ) )
- ?? ( cuda gdal )
- ?? ( cuda openexr )
- ?? ( cuda tbb )
-"
-
-# The following logic is intrinsic in the build system, but we do not enforce
-# it on the useflags since this just blocks emerging pointlessly:
-# openmp? ( !tbb )
-
-RDEPEND="
- app-arch/bzip2[${MULTILIB_USEDEP}]
- dev-libs/protobuf:=[${MULTILIB_USEDEP}]
- sys-libs/zlib[${MULTILIB_USEDEP}]
- cuda? ( <dev-util/nvidia-cuda-toolkit-12.4:0= )
- cudnn? ( dev-libs/cudnn:= )
- contribdnn? ( dev-libs/flatbuffers:= )
- contribhdf? ( sci-libs/hdf5:= )
- contribfreetype? (
- media-libs/freetype:2[${MULTILIB_USEDEP}]
- media-libs/harfbuzz:=[${MULTILIB_USEDEP}]
- )
- contribovis? ( >=dev-games/ogre-1.12:= )
- ffmpeg? ( media-video/ffmpeg:0=[${MULTILIB_USEDEP}] )
- gdal? ( sci-libs/gdal:= )
- gflags? ( dev-cpp/gflags:=[${MULTILIB_USEDEP}] )
- glog? ( dev-cpp/glog:=[${MULTILIB_USEDEP}] )
- gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
- gstreamer? (
- media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
- media-libs/gst-plugins-base:1.0[${MULTILIB_USEDEP}]
- )
- gtk3? (
- dev-libs/glib:2[${MULTILIB_USEDEP}]
- x11-libs/gtk+:3[${MULTILIB_USEDEP}]
- )
- ieee1394? (
- media-libs/libdc1394:=[${MULTILIB_USEDEP}]
- sys-libs/libraw1394[${MULTILIB_USEDEP}]
- )
- java? ( >=virtual/jre-1.8:* )
- jpeg? ( media-libs/libjpeg-turbo:=[${MULTILIB_USEDEP}] )
- jpeg2k? ( media-libs/openjpeg:2=[${MULTILIB_USEDEP}] )
- lapack? (
- virtual/cblas
- >=virtual/lapack-3.10
- virtual/lapacke
- )
- opencl? (
- virtual/opencl[${MULTILIB_USEDEP}]
- dev-util/opencl-headers
- )
- openexr? (
- dev-libs/imath:=
- media-libs/openexr:=
- )
- opengl? (
- virtual/opengl[${MULTILIB_USEDEP}]
- virtual/glu[${MULTILIB_USEDEP}]
- )
- png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
- python? (
- ${PYTHON_DEPS}
- dev-python/numpy:=[${PYTHON_USEDEP}]
- )
- qt5? (
- dev-qt/qtgui:5
- dev-qt/qtwidgets:5
- dev-qt/qttest:5
- dev-qt/qtconcurrent:5
- opengl? ( dev-qt/qtopengl:5 )
- )
- !qt5? (
- qt6? (
- dev-qt/qtbase:6[gui,widgets,concurrent,opengl?]
- )
- )
- tesseract? ( app-text/tesseract[opencl=,${MULTILIB_USEDEP}] )
- tbb? ( dev-cpp/tbb:=[${MULTILIB_USEDEP}] )
- tiff? ( media-libs/tiff:=[${MULTILIB_USEDEP}] )
- v4l? ( >=media-libs/libv4l-0.8.3[${MULTILIB_USEDEP}] )
- vaapi? ( media-libs/libva[${MULTILIB_USEDEP}] )
- vtk? ( sci-libs/vtk:=[rendering,cuda=] )
- webp? ( media-libs/libwebp:=[${MULTILIB_USEDEP}] )
- xine? ( media-libs/xine-lib )"
-DEPEND="${RDEPEND}
- eigen? ( >=dev-cpp/eigen-3.3.8-r1:3 )
- java? ( >=virtual/jdk-1.8:* )"
-BDEPEND="virtual/pkgconfig"
-
-PATCHES=(
- "${FILESDIR}/${PN}-3.4.0-disable-download.patch"
- "${FILESDIR}/${PN}-3.4.1-cuda-add-relaxed-constexpr.patch"
- "${FILESDIR}/${PN}-4.1.2-opencl-license.patch"
- "${FILESDIR}/${PN}-4.4.0-disable-native-cpuflag-detect.patch"
- "${FILESDIR}/${PN}-4.5.0-link-with-cblas-for-lapack.patch"
- "${FILESDIR}/${PN}-4.8.0-arm64-fp16.patch"
- "${FILESDIR}/${PN}-4.8.0-fix-cuda-12.2.0.patch"
-
- "${FILESDIR}/${PN}-4.8.1-use-system-flatbuffers.patch"
- "${FILESDIR}/${PN}-4.8.1-eliminate-lto-compiler-warnings.patch"
- "${FILESDIR}/${PN}-4.8.1-python3_12-support.patch"
-
- "${FILESDIR}/${PN}-4.8.1-use-system-opencl.patch"
- "${FILESDIR}/${PN}-4.8.1-opencv_test.patch"
- "${FILESDIR}/${PN}-4.8.1-drop-python2-detection.patch"
- "${FILESDIR}/${PN}-4.8.1-libpng16.patch"
- "${FILESDIR}/${PN}-4.8.1-ade-0.1.2a.tar.gz.patch"
-
- "${FILESDIR}/${PN}-4.8.1-protobuf-22.patch" # bug 909087, in 4.9.0
-
- # TODO applied in src_prepare
- # "${FILESDIR}/${PN}_contrib-${PV}-rgbd.patch"
- # "${FILESDIR}/${PN}_contrib-4.8.1-NVIDIAOpticalFlowSDK-2.0.tar.gz.patch"
-)
-
-pkg_pretend() {
- if use cuda && [[ -z "${CUDA_GENERATION}" ]] && [[ -z "${CUDA_ARCH_BIN}" ]]; then
- einfo "The target CUDA architecture can be set via one of:"
- einfo " - CUDA_GENERATION set to one of Maxwell, Pascal, Volta, Turing, Ampere, Lovelace, Hopper, Auto"
- einfo " - CUDA_ARCH_BIN, (and optionally CUDA_ARCH_PTX) in the form of x.y tuples."
- einfo " You can specify multiple tuple separated by \";\"."
- einfo ""
- einfo "The CUDA architecture tuple for your device can be found at https://developer.nvidia.com/cuda-gpus."
- fi
-
- if use cuda && [[ ${MERGE_TYPE} == "buildonly" ]] && [[ -n "${CUDA_GENERATION}" || -n "${CUDA_ARCH_BIN}" ]]; then
- local info_message="When building a binary package it's recommended to unset CUDA_GENERATION and CUDA_ARCH_BIN"
- einfo "$info_message so all available architectures are build."
- fi
-
- [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
-}
-
-pkg_setup() {
- [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
- use java && java-pkg-opt-2_pkg_setup
-}
-
-src_prepare() {
- if use cuda; then
- export CUDA_VERBOSE="$(usex debug "true" "false")"
- cuda_src_prepare
- fi
-
- cmake_src_prepare
-
- # remove bundled stuff
- rm -r 3rdparty || die "Removing 3rd party components failed"
- sed -e '/add_subdirectory(.*3rdparty.*)/ d' \
- -i CMakeLists.txt cmake/*cmake || die
-
- if use contrib; then
- cd "${WORKDIR}/${PN}_contrib-${PV}" || die
- eapply "${FILESDIR}/${PN}_contrib-${PV}-rgbd.patch"
- eapply "${FILESDIR}/${PN}_contrib-4.8.1-NVIDIAOpticalFlowSDK-2.0.tar.gz.patch"
- cd "${S}" || die
-
- ! use contribcvv && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/cvv" || die; }
- # ! use contribdnn && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/dnn" || die; }
- ! use contribfreetype && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/freetype" || die; }
- ! use contribhdf && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/hdf" || die; }
- ! use contribovis && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/ovis" || die; }
- ! use contribsfm && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/sfm" || die; }
- ! use contribxfeatures2d && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/xfeatures2d" || die; }
- fi
-
- mkdir -p "${S}/.cache/ade" || die
- cp \
- "${DISTDIR}/ade-${ADE_PV}.tar.gz" \
- "${S}/.cache/ade/$(md5sum "${DISTDIR}/ade-${ADE_PV}.tar.gz" | cut -f 1 -d " ")-v${ADE_PV}.tar.gz" || die
-
- if use dnnsamples; then
- mkdir -p "${S}/.cache/wechat_qrcode" || die
- for file in "detect.caffemodel" "detect.prototxt" "sr.prototxt" "sr.caffemodel"; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${QRCODE_COMMIT}/${file}" \
- "${S}/.cache/wechat_qrcode/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${QRCODE_COMMIT}/${file}" | cut -f 1 -d " " \
- )-${file}" || die
- done
-
- mv \
- "${WORKDIR}/${PN}_3rdparty-${DNN_SAMPLES_FACE_DETECTOR_COMMIT}/res10_300x300_ssd_iter_140000.caffemodel" \
- "${S}/samples/dnn/" || die
- fi
-
- if use contribxfeatures2d; then
- cp \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/"*.i \
- "${WORKDIR}/${PN}_contrib-${PV}"/modules/xfeatures2d/src/ || die
- mkdir -p "${S}/.cache/xfeatures2d/boostdesc" || die
- for file in "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/"*.i; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/$(basename "${file}")" \
- "${S}/.cache/xfeatures2d/boostdesc/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/$(basename "${file}")" | cut -f 1 -d " " \
- )-$(basename "${file}")" || die
- done
-
- cp \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/"*.i \
- "${WORKDIR}/${PN}_contrib-${PV}"/modules/xfeatures2d/src/ || die
- mkdir -p "${S}/.cache/xfeatures2d/vgg" || die
- for file in "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/"*.i; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/$(basename "${file}")" \
- "${S}/.cache/xfeatures2d/vgg/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/$(basename "${file}")" | cut -f 1 -d " " \
- )-$(basename "${file}")" || die
- done
- fi
-
- if use contribdnn; then
- mkdir -p "${S}/.cache/data" || die
- for file in "face_landmark_model.dat"; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}/${file}" \
- "${S}/.cache/data/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}/${file}" | cut -f 1 -d " " \
- )-${file}" || die
- done
- fi
-
- if use cuda; then
- mkdir -p "${S}/.cache/nvidia_optical_flow"
- cp \
- "${DISTDIR}/NVIDIAOpticalFlowSDK-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz" \
- "${S}/.cache/nvidia_optical_flow/$( \
- md5sum "${DISTDIR}/NVIDIAOpticalFlowSDK-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz" | cut -f 1 -d " " \
- )-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz" || die
- fi
-
- if use java; then
- java-pkg-opt-2_src_prepare
-
- # this really belongs in src_prepare() too
- JAVA_ANT_ENCODING="iso-8859-1"
- # set encoding so even this cmake build will pick it up.
- export ANT_OPTS+=" -Dfile.encoding=iso-8859-1"
- fi
-}
-
-multilib_src_configure() {
- # bug #919101 and https://github.com/opencv/opencv/issues/19020
- filter-lto
-
- # please dont sort here, order is the same as in CMakeLists.txt
- local mycmakeargs=(
- -DMIN_VER_CMAKE=3.26
-
- -DCMAKE_POLICY_DEFAULT_CMP0146="OLD" # FindCUDA
- -DCMAKE_POLICY_DEFAULT_CMP0148="OLD" # FindPythonInterp
-
- # for protobuf
- -DCMAKE_CXX_STANDARD=14
-
- # Optional 3rd party components
- # ===================================================
- -DENABLE_DOWNLOAD=yes
- -DOPENCV_ENABLE_NONFREE=$(usex non-free)
- -DWITH_QUIRC=OFF # Do not have dependencies
- -DWITH_FLATBUFFERS=$(multilib_native_usex contribdnn)
- -DWITH_1394=$(usex ieee1394)
- # -DWITH_AVFOUNDATION=OFF # IOS
- -DWITH_VTK=$(multilib_native_usex vtk)
- -DWITH_EIGEN=$(usex eigen)
- -DWITH_VFW=OFF # Video windows support
- -DWITH_FFMPEG=$(usex ffmpeg)
- -DWITH_GSTREAMER=$(usex gstreamer)
- -DWITH_GSTREAMER_0_10=OFF # Don't want this
- -DWITH_GTK=$(usex gtk3)
- -DWITH_GTK_2_X=OFF # only want gtk3 nowadays
- -DWITH_IPP=OFF
- # Jasper was removed from tree because of security problems.
- # Upstream were/are making progress. We use openjpeg instead.
- # bug 734284
- -DWITH_JASPER=OFF
- -DWITH_JPEG=$(usex jpeg)
- -DWITH_OPENJPEG=$(usex jpeg2k)
- -DWITH_WEBP=$(usex webp)
- -DWITH_OPENEXR=$(multilib_native_usex openexr)
- -DWITH_OPENGL=$(usex opengl)
- -DOpenGL_GL_PREFERENCE="GLVND"
- -DWITH_OPENVX=OFF
- -DWITH_OPENNI=OFF # Not packaged
- -DWITH_OPENNI2=OFF # Not packaged
- -DWITH_PNG=$(usex png)
- -DWITH_GDCM=OFF
- -DWITH_PVAPI=OFF
- -DWITH_GIGEAPI=OFF
- -DWITH_ARAVIS=OFF
- -DWITH_WIN32UI=OFF # Windows only
- # -DWITH_QUICKTIME=OFF
- # -DWITH_QTKIT=OFF
- -DWITH_TBB=$(usex tbb)
- -DWITH_OPENMP=$(usex !tbb $(usex openmp))
- -DWITH_CSTRIPES=OFF
- -DWITH_PTHREADS_PF=ON
- -DWITH_TIFF=$(usex tiff)
- -DWITH_UNICAP=OFF # Not packaged
- -DWITH_V4L=$(usex v4l)
- -DWITH_LIBV4L=$(usex v4l)
- # -DWITH_DSHOW=ON # direct show supp
- -DWITH_MSMF=OFF
- -DWITH_XIMEA=OFF # Windows only
- -DWITH_XINE=$(multilib_native_usex xine)
- -DWITH_CLP=OFF
- -DWITH_OPENCL=$(usex opencl)
- -DWITH_OPENCL_SVM=OFF
- -DWITH_OPENCLAMDFFT=$(usex opencl)
- -DWITH_OPENCLAMDBLAS=$(usex opencl)
- -DWITH_DIRECTX=OFF
- -DWITH_INTELPERC=OFF
- -DWITH_IPP_A=OFF
- -DWITH_MATLAB=OFF
- -DWITH_VA=$(usex vaapi)
- -DWITH_VA_INTEL=$(usex vaapi $(usex video_cards_intel))
- -DWITH_GDAL=$(multilib_native_usex gdal)
- -DWITH_GPHOTO2=$(usex gphoto2)
- -DWITH_LAPACK=$(multilib_native_usex lapack)
- -DWITH_ITT=OFF # 3dparty libs itt_notify
- # ===================================================
- # CUDA build components: nvidia-cuda-toolkit
- # ===================================================
- -DWITH_CUDA=$(multilib_native_usex cuda)
- -DWITH_CUBLAS=$(multilib_native_usex cuda)
- -DWITH_CUFFT=$(multilib_native_usex cuda)
- -DWITH_CUDNN=$(multilib_native_usex cudnn)
- -DWITH_NVCUVID="no"
- -DCUDA_NPP_LIBRARY_ROOT_DIR=$(usex cuda "${EPREFIX}/opt/cuda" "")
- # ===================================================
- # OpenCV build components
- # ===================================================
- -DBUILD_SHARED_LIBS=ON
- -DBUILD_JAVA=$(multilib_native_usex java) # Ant needed, no compile flag
- -DBUILD_ANDROID_EXAMPLES=OFF
- -DBUILD_opencv_apps=$(usex opencvapps ON OFF)
- -DBUILD_DOCS=OFF # Doesn't install anyways.
- -DBUILD_EXAMPLES=$(multilib_native_usex examples)
- -DBUILD_PERF_TESTS=OFF
- -DBUILD_TESTS=$(multilib_native_usex testprograms)
- -DBUILD_WITH_DEBUG_INFO=$(usex debug)
- -DOPENCV_ENABLE_MEMORY_SANITIZER=$(usex debug)
- # -DBUILD_WITH_STATIC_CRT=OFF
- -DBUILD_WITH_DYNAMIC_IPP=OFF
- -DBUILD_FAT_JAVA_LIB=OFF
- # -DBUILD_ANDROID_SERVICE=OFF
- -DBUILD_CUDA_STUBS=$(multilib_native_usex cuda)
- -DOPENCV_EXTRA_MODULES_PATH=$(usex contrib "${WORKDIR}/${PN}_contrib-${PV}/modules" "")
- # ===================================================
- # OpenCV installation options
- # ===================================================
- -DINSTALL_CREATE_DISTRIB=OFF
- -DINSTALL_C_EXAMPLES=$(multilib_native_usex examples)
- -DINSTALL_TESTS=$(multilib_native_usex testprograms)
- -DINSTALL_PYTHON_EXAMPLES=$(multilib_native_usex examples)
- # -DINSTALL_ANDROID_EXAMPLES=OFF
- -DINSTALL_TO_MANGLED_PATHS=OFF
- -DOPENCV_GENERATE_PKGCONFIG=ON
- # opencv uses both ${CMAKE_INSTALL_LIBDIR} and ${LIB_SUFFIX}
- # to set its destination libdir
- -DLIB_SUFFIX=
- # ===================================================
- # OpenCV build options
- # ===================================================
- -DENABLE_CCACHE=OFF
- # bug 733796, but PCH is a risky game in CMake anyway
- -DENABLE_PRECOMPILED_HEADERS=OFF
- -DENABLE_SOLUTION_FOLDERS=OFF
- -DENABLE_PROFILING=OFF
- -DENABLE_COVERAGE=OFF
-
- -DHAVE_opencv_java=$(multilib_native_usex java YES NO)
- -DENABLE_NOISY_WARNINGS=OFF
- -DOPENCV_WARNINGS_ARE_ERRORS=OFF
- -DENABLE_IMPL_COLLECTION=OFF
- -DENABLE_INSTRUMENTATION=OFF
- -DGENERATE_ABI_DESCRIPTOR=OFF
- -DDOWNLOAD_EXTERNAL_TEST_DATA=OFF
- # ===================================================
- # things we want to be hard off or not yet figured out
- # ===================================================
- -DBUILD_PACKAGE=OFF
- # ===================================================
- # Not building protobuf but update files bug #631418
- # ===================================================
- -DWITH_PROTOBUF=ON
- -DBUILD_PROTOBUF=OFF
- -DPROTOBUF_UPDATE_FILES=ON
- -DProtobuf_MODULE_COMPATIBLE=ON
- # ===================================================
- # things we want to be hard enabled not worth useflag
- # ===================================================
- -DCMAKE_SKIP_RPATH=ON
- -DOPENCV_DOC_INSTALL_PATH=
- -DBUILD_opencv_features2d=$(usex features2d ON OFF)
- )
-
- if use qt5; then
- mycmakeargs+=(
- -DWITH_QT=$(multilib_native_usex qt5 ON OFF)
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON
- )
- elif use qt6; then
- mycmakeargs+=(
- -DWITH_QT=$(multilib_native_usex qt6 ON OFF)
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt5=ON
- )
- else
- mycmakeargs+=(
- -DWITH_QT=OFF
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt5=ON
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON
- )
- fi
-
- # ==================================================
- # cpu flags, should solve 633900
- #===================================================
- local CPU_BASELINE=""
- for i in "${CPU_FEATURES_MAP[@]}" ; do
- if [[ ${ABI} != x86 || ${i%:*} != "cpu_flags_x86_avx2" ]]; then # workaround for Bug 747163
- use ${i%:*} && CPU_BASELINE="${CPU_BASELINE}${i#*:};"
- fi
- done
-
- mycmakeargs+=(
- -DOPENCV_CPU_OPT_IMPLIES_IGNORE=ON
- -DCPU_BASELINE="${CPU_BASELINE}"
- -DCPU_DISPATCH=
- )
-
- # ===================================================
- # OpenCV Contrib Modules
- # ===================================================
- if use contrib; then
- mycmakeargs+=(
- -DBUILD_opencv_dnn=$(multilib_native_usex contribdnn ON OFF)
- -DBUILD_opencv_xfeatures2d=$(usex contribxfeatures2d ON OFF)
- -DBUILD_opencv_cvv=$(usex contribcvv ON OFF)
- -DBUILD_opencv_hdf=$(multilib_native_usex contribhdf ON OFF)
- -DBUILD_opencv_sfm=$(usex contribsfm ON OFF)
- -DBUILD_opencv_freetype=$(usex contribfreetype ON OFF)
- -DBUILD_opencv_ovis=$(usex contribovis ON OFF)
- )
-
- if multilib_is_native_abi; then
- mycmakeargs+=(
- -DCMAKE_DISABLE_FIND_PACKAGE_Tesseract=$(usex !tesseract)
- )
- else
- mycmakeargs+=(
- -DCMAKE_DISABLE_FIND_PACKAGE_Tesseract=ON
- )
- fi
- fi
-
- # workaround for bug 413429
- tc-export CC CXX
-
- if multilib_is_native_abi && use cuda; then
- cuda_add_sandbox -w
- sandbox_write "/proc/self/task"
-
- if [[ -n "${CUDA_GENERATION}" ]]; then
- mycmakeargs+=(
- -DCUDA_GENERATION="${CUDA_GENERATION}"
- )
- fi
-
- if [[ -n "${CUDA_ARCH_BIN}" ]]; then
- mycmakeargs+=(
- -DCUDA_ARCH_BIN="${CUDA_ARCH_BIN}"
- )
-
- if [[ -n "${CUDA_ARCH_PTX}" ]]; then
- mycmakeargs+=(
- -DCUDA_ARCH_PTX="${CUDA_ARCH_PTX}"
- )
- fi
- fi
-
- local NVCCFLAGS_OpenCV="${NVCCFLAGS// /\;}"
- mycmakeargs+=(
- -DOPENCV_CUDA_DETECTION_NVCC_FLAGS="-ccbin=$(cuda_gccdir)"
- -DCUDA_NVCC_FLAGS="-forward-unknown-opts;${NVCCFLAGS_OpenCV//\"/}"
- )
-
- use vtk && mycmakeargs+=(
- -DCMAKE_CUDA_FLAGS="-forward-unknown-opts ${NVCCFLAGS//\;/ }"
- )
- fi
-
- if multilib_is_native_abi && use python; then
- python_configure() {
- # Set all python variables to load the correct Gentoo paths
- local mycmakeargs=(
- "${mycmakeargs[@]}"
- # python_setup alters PATH and sets this as wrapper
- # to the correct interpreter we are building for
- -DPYTHON_DEFAULT_EXECUTABLE="${EPYTHON}"
- -DINSTALL_PYTHON_EXAMPLES="$(usex examples)"
- )
- cmake_src_configure
- use java && java-ant-2_src_configure
- }
-
- python_foreach_impl python_configure
- else
- mycmakeargs+=(
- -DPYTHON_EXECUTABLE=OFF
- -DINSTALL_PYTHON_EXAMPLES=OFF
- -DBUILD_opencv_python2=OFF
- -DBUILD_opencv_python3=OFF
- )
- cmake_src_configure
- use java && java-ant-2_src_configure
- fi
-
-}
-
-multilib_src_compile() {
- if multilib_is_native_abi && use python; then
- python_foreach_impl cmake_src_compile
- else
- cmake_src_compile
- fi
-}
-
-multilib_src_install() {
- if use abi_x86_64 && use abi_x86_32; then
- MULTILIB_WRAPPED_HEADERS=(
- # [opencv4]
- /usr/include/opencv4/opencv2/cvconfig.h
- /usr/include/opencv4/opencv2/opencv_modules.hpp
-
- /usr/include/opencv4/opencv2/core_detect.hpp
-
- /usr/include/opencv4/opencv2/cudaarithm.hpp
- /usr/include/opencv4/opencv2/cudabgsegm.hpp
- /usr/include/opencv4/opencv2/cudacodec.hpp
- /usr/include/opencv4/opencv2/cudafeatures2d.hpp
- /usr/include/opencv4/opencv2/cudafilters.hpp
- /usr/include/opencv4/opencv2/cudaimgproc.hpp
- /usr/include/opencv4/opencv2/cudalegacy.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCV.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCVBroxOpticalFlow.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCVHaarObjectDetection.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCVPyramid.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NPP_staging.hpp
- /usr/include/opencv4/opencv2/cudaobjdetect.hpp
- /usr/include/opencv4/opencv2/cudaoptflow.hpp
- /usr/include/opencv4/opencv2/cudastereo.hpp
- /usr/include/opencv4/opencv2/cudawarping.hpp
- # [cudev]
- /usr/include/opencv4/opencv2/cudev.hpp
- /usr/include/opencv4/opencv2/cudev/block/block.hpp
- /usr/include/opencv4/opencv2/cudev/block/detail/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/block/detail/reduce_key_val.hpp
- /usr/include/opencv4/opencv2/cudev/block/dynamic_smem.hpp
- /usr/include/opencv4/opencv2/cudev/block/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/block/scan.hpp
- /usr/include/opencv4/opencv2/cudev/block/vec_distance.hpp
- /usr/include/opencv4/opencv2/cudev/common.hpp
- /usr/include/opencv4/opencv2/cudev/expr/binary_func.hpp
- /usr/include/opencv4/opencv2/cudev/expr/binary_op.hpp
- /usr/include/opencv4/opencv2/cudev/expr/color.hpp
- /usr/include/opencv4/opencv2/cudev/expr/deriv.hpp
- /usr/include/opencv4/opencv2/cudev/expr/expr.hpp
- /usr/include/opencv4/opencv2/cudev/expr/per_element_func.hpp
- /usr/include/opencv4/opencv2/cudev/expr/reduction.hpp
- /usr/include/opencv4/opencv2/cudev/expr/unary_func.hpp
- /usr/include/opencv4/opencv2/cudev/expr/unary_op.hpp
- /usr/include/opencv4/opencv2/cudev/expr/warping.hpp
- /usr/include/opencv4/opencv2/cudev/functional/color_cvt.hpp
- /usr/include/opencv4/opencv2/cudev/functional/detail/color_cvt.hpp
- /usr/include/opencv4/opencv2/cudev/functional/functional.hpp
- /usr/include/opencv4/opencv2/cudev/functional/tuple_adapter.hpp
- /usr/include/opencv4/opencv2/cudev/grid/copy.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/copy.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/histogram.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/integral.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/minmaxloc.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/pyr_down.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/pyr_up.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/reduce_to_column.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/reduce_to_row.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/split_merge.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/transform.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/transpose.hpp
- /usr/include/opencv4/opencv2/cudev/grid/histogram.hpp
- /usr/include/opencv4/opencv2/cudev/grid/integral.hpp
- /usr/include/opencv4/opencv2/cudev/grid/pyramids.hpp
- /usr/include/opencv4/opencv2/cudev/grid/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/grid/reduce_to_vec.hpp
- /usr/include/opencv4/opencv2/cudev/grid/split_merge.hpp
- /usr/include/opencv4/opencv2/cudev/grid/transform.hpp
- /usr/include/opencv4/opencv2/cudev/grid/transpose.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/constant.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/deriv.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/detail/gpumat.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/extrapolation.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/glob.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/gpumat.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/interpolation.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/lut.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/mask.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/remap.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/resize.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/texture.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/traits.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/transform.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/warping.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/zip.hpp
- /usr/include/opencv4/opencv2/cudev/util/atomic.hpp
- /usr/include/opencv4/opencv2/cudev/util/detail/tuple.hpp
- /usr/include/opencv4/opencv2/cudev/util/detail/type_traits.hpp
- /usr/include/opencv4/opencv2/cudev/util/limits.hpp
- /usr/include/opencv4/opencv2/cudev/util/saturate_cast.hpp
- /usr/include/opencv4/opencv2/cudev/util/simd_functions.hpp
- /usr/include/opencv4/opencv2/cudev/util/tuple.hpp
- /usr/include/opencv4/opencv2/cudev/util/type_traits.hpp
- /usr/include/opencv4/opencv2/cudev/util/vec_math.hpp
- /usr/include/opencv4/opencv2/cudev/util/vec_traits.hpp
- /usr/include/opencv4/opencv2/cudev/warp/detail/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/warp/detail/reduce_key_val.hpp
- /usr/include/opencv4/opencv2/cudev/warp/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/warp/scan.hpp
- /usr/include/opencv4/opencv2/cudev/warp/shuffle.hpp
- /usr/include/opencv4/opencv2/cudev/warp/warp.hpp
- # [contribcvv]
- /usr/include/opencv4/opencv2/cvv.hpp
- /usr/include/opencv4/opencv2/cvv/call_meta_data.hpp
- /usr/include/opencv4/opencv2/cvv/cvv.hpp
- /usr/include/opencv4/opencv2/cvv/debug_mode.hpp
- /usr/include/opencv4/opencv2/cvv/dmatch.hpp
- /usr/include/opencv4/opencv2/cvv/filter.hpp
- /usr/include/opencv4/opencv2/cvv/final_show.hpp
- /usr/include/opencv4/opencv2/cvv/show_image.hpp
- # [contribdnn]
- /usr/include/opencv4/opencv2/dnn.hpp
- /usr/include/opencv4/opencv2/dnn/all_layers.hpp
- /usr/include/opencv4/opencv2/dnn/dict.hpp
- /usr/include/opencv4/opencv2/dnn/dnn.hpp
- /usr/include/opencv4/opencv2/dnn/dnn.inl.hpp
- /usr/include/opencv4/opencv2/dnn/layer.details.hpp
- /usr/include/opencv4/opencv2/dnn/layer.hpp
- /usr/include/opencv4/opencv2/dnn/shape_utils.hpp
- /usr/include/opencv4/opencv2/dnn/utils/debug_utils.hpp
- /usr/include/opencv4/opencv2/dnn/utils/inference_engine.hpp
- /usr/include/opencv4/opencv2/dnn/version.hpp
- /usr/include/opencv4/opencv2/dnn_superres.hpp
- # [contribhdf]
- /usr/include/opencv4/opencv2/hdf.hpp
- /usr/include/opencv4/opencv2/hdf/hdf5.hpp
-
- /usr/include/opencv4/opencv2/mcc.hpp
- /usr/include/opencv4/opencv2/mcc/ccm.hpp
- /usr/include/opencv4/opencv2/mcc/checker_detector.hpp
- /usr/include/opencv4/opencv2/mcc/checker_model.hpp
-
- /usr/include/opencv4/opencv2/text.hpp
- /usr/include/opencv4/opencv2/text/erfilter.hpp
- /usr/include/opencv4/opencv2/text/ocr.hpp
- /usr/include/opencv4/opencv2/text/swt_text_detection.hpp
- /usr/include/opencv4/opencv2/text/textDetector.hpp
-
- # [qt5,qt6]
- /usr/include/opencv4/opencv2/viz.hpp
- /usr/include/opencv4/opencv2/viz/types.hpp
- /usr/include/opencv4/opencv2/viz/viz3d.hpp
- /usr/include/opencv4/opencv2/viz/vizcore.hpp
- /usr/include/opencv4/opencv2/viz/widget_accessor.hpp
- /usr/include/opencv4/opencv2/viz/widgets.hpp
-
- /usr/include/opencv4/opencv2/wechat_qrcode.hpp
- )
- fi
- if multilib_is_native_abi && use python; then
- python_foreach_impl cmake_src_install
- python_foreach_impl python_optimize
- else
- cmake_src_install
- fi
-}
diff --git a/media-libs/opencv/opencv-4.9.0-r1.ebuild b/media-libs/opencv/opencv-4.9.0-r1.ebuild
deleted file mode 100644
index 227ff691acb6..000000000000
--- a/media-libs/opencv/opencv-4.9.0-r1.ebuild
+++ /dev/null
@@ -1,1022 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{10..12} )
-inherit cuda java-pkg-opt-2 java-ant-2 cmake-multilib flag-o-matic python-r1 toolchain-funcs virtualx
-
-DESCRIPTION="A collection of algorithms and sample code for various computer vision problems"
-HOMEPAGE="https://opencv.org"
-
-if [[ ${PV} = *9999* ]] ; then
- inherit git-r3
- EGIT_REPO_URI="https://github.com/${PN}/${PN}.git"
-else
- # branch master
- ADE_PV="0.1.2d"
- # branch wechat_qrcode_20210119
- QRCODE_COMMIT="a8b69ccc738421293254aec5ddb38bd523503252"
- # branch dnn_samples_face_detector_20170830
- DNN_SAMPLES_FACE_DETECTOR_COMMIT="b2bfc75f6aea5b1f834ff0f0b865a7c18ff1459f"
- # branch contrib_xfeatures2d_boostdesc_20161012
- XFEATURES2D_BOOSTDESC_COMMIT="34e4206aef44d50e6bbcd0ab06354b52e7466d26"
- # branch contrib_xfeatures2d_vgg_20160317
- XFEATURES2D_VGG_COMMIT="fccf7cd6a4b12079f73bbfb21745f9babcd4eb1d"
- # branch contrib_face_alignment_20170818
- FACE_ALIGNMENT_COMMIT="8afa57abc8229d611c4937165d20e2a2d9fc5a12"
- # branch nvof_2_0_bsd
- NVIDIA_OPTICAL_FLOW_COMMIT="edb50da3cf849840d680249aa6dbef248ebce2ca"
-
- SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz
- https://github.com/opencv/ade/archive/v${ADE_PV}.tar.gz -> ade-${ADE_PV}.tar.gz
- contrib? (
- https://github.com/${PN}/${PN}_contrib/archive/${PV}.tar.gz -> ${PN}_contrib-${PV}.tar.gz
- dnnsamples? (
- https://github.com/${PN}/${PN}_3rdparty/archive/${QRCODE_COMMIT}.tar.gz -> ${PN}_3rdparty-${QRCODE_COMMIT}.tar.gz
- https://github.com/${PN}/${PN}_3rdparty/archive/${DNN_SAMPLES_FACE_DETECTOR_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${DNN_SAMPLES_FACE_DETECTOR_COMMIT}.tar.gz
- )
- contribxfeatures2d? (
- https://github.com/${PN}/${PN}_3rdparty/archive/${XFEATURES2D_BOOSTDESC_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}.tar.gz
- https://github.com/${PN}/${PN}_3rdparty/archive/${XFEATURES2D_VGG_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}.tar.gz
- )
- contribdnn? (
- https://github.com/${PN}/${PN}_3rdparty/archive/${FACE_ALIGNMENT_COMMIT}.tar.gz
- -> ${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}.tar.gz
- )
- cuda? (
- https://github.com/NVIDIA/NVIDIAOpticalFlowSDK/archive/${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz
- -> NVIDIAOpticalFlowSDK-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz
- )
- )
- test? (
- https://github.com/${PN}/${PN}_extra/archive/refs/tags/${PV}.tar.gz -> ${PN}_extra-${PV}.tar.gz
- )
- "
- KEYWORDS="amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv x86"
-fi
-
-LICENSE="Apache-2.0"
-SLOT="0/${PV}" # subslot = libopencv* soname version
-
-# general options
-IUSE="debug doc +eigen gflags glog java non-free opencvapps +python test testprograms"
-
-# modules
-IUSE+=" contrib contribcvv contribdnn contribfreetype contribhdf contribovis contribsfm contribxfeatures2d dnnsamples examples +features2d"
-# hardware
-IUSE+=" opencl cuda cudnn video_cards_intel"
-# video
-IUSE+=" +ffmpeg gstreamer xine vaapi v4l gphoto2 ieee1394"
-# image
-IUSE+=" gdal jasper jpeg jpeg2k openexr png quirc tesseract tiff webp"
-# gui
-IUSE+=" gtk3 qt5 qt6 opengl vtk"
-# parallel
-IUSE+=" openmp tbb"
-# lapack options
-IUSE+=" atlas lapack mkl"
-
-# TODO make this only relevant for binhost
-CPU_FEATURES_MAP=(
- cpu_flags_arm_neon:NEON
- cpu_flags_arm_vfpv3:VFPV3
-
- cpu_flags_ppc_vsx:VSX # (always available on Power8)
- cpu_flags_ppc_vsx3:VSX3 # (always available on Power9)
-
- cpu_flags_x86_sse:SSE # (always available on 64-bit CPUs)
- cpu_flags_x86_sse2:SSE2 # (always available on 64-bit CPUs)
-
- cpu_flags_x86_sse3:SSE3
- cpu_flags_x86_ssse3:SSSE3
-
- cpu_flags_x86_sse4_1:SSE4_1
- cpu_flags_x86_popcnt:POPCNT
- cpu_flags_x86_sse4_2:SSE4_2
-
- cpu_flags_x86_f16c:FP16
- cpu_flags_x86_fma3:FMA3
- cpu_flags_x86_avx:AVX
- cpu_flags_x86_avx2:AVX2
- cpu_flags_x86_avx512f:AVX_512F
-)
-IUSE+=" ${CPU_FEATURES_MAP[*]%:*}"
-unset ARM_CPU_FEATURES PPC_CPU_FEATURES X86_CPU_FEATURES_RAW X86_CPU_FEATURES
-
-REQUIRED_USE="
- amd64? ( cpu_flags_x86_sse cpu_flags_x86_sse2 )
- cpu_flags_x86_avx2? ( cpu_flags_x86_f16c )
- cpu_flags_x86_f16c? ( cpu_flags_x86_avx )
- cuda? (
- contrib
- tesseract? ( opencl )
- )
- cudnn? ( cuda )
- dnnsamples? ( examples )
- gflags? ( contrib )
- glog? ( contrib )
- contribcvv? ( contrib || ( qt5 qt6 ) )
- contribdnn? ( contrib )
- contribfreetype? ( contrib )
- contribhdf? ( contrib )
- contribovis? ( contrib )
- contribsfm? ( contrib eigen gflags glog )
- contribxfeatures2d? ( contrib )
- java? ( python )
- opengl? ( ?? ( gtk3 || ( qt5 qt6 ) ) )
- python? ( ${PYTHON_REQUIRED_USE} )
- tesseract? ( contrib )
- ?? ( gtk3 || ( qt5 qt6 ) )
- test? ( || ( ffmpeg gstreamer ) jpeg png tiff features2d )
-"
-
-# TODO find a way to compile these with the cuda compiler
-REQUIRED_USE+="
- cuda? ( !gdal !openexr !tbb )
-"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- app-arch/bzip2[${MULTILIB_USEDEP}]
- dev-libs/protobuf:=[${MULTILIB_USEDEP}]
- sys-libs/zlib[${MULTILIB_USEDEP}]
- cuda? ( <dev-util/nvidia-cuda-toolkit-12.4:0= )
- cudnn? ( dev-libs/cudnn:= )
- contribdnn? ( dev-libs/flatbuffers:= )
- contribhdf? ( sci-libs/hdf5:= )
- contribfreetype? (
- media-libs/freetype:2[${MULTILIB_USEDEP}]
- media-libs/harfbuzz:=[${MULTILIB_USEDEP}]
- )
- contribovis? ( >=dev-games/ogre-1.12:= )
- ffmpeg? ( media-video/ffmpeg:0=[${MULTILIB_USEDEP}] )
- gdal? ( sci-libs/gdal:= )
- gflags? ( dev-cpp/gflags:=[${MULTILIB_USEDEP}] )
- glog? ( dev-cpp/glog:=[${MULTILIB_USEDEP}] )
- gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
- gstreamer? (
- media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
- media-libs/gst-plugins-base:1.0[${MULTILIB_USEDEP}]
- )
- gtk3? (
- dev-libs/glib:2[${MULTILIB_USEDEP}]
- x11-libs/gtk+:3[${MULTILIB_USEDEP}]
- )
- ieee1394? (
- media-libs/libdc1394:=[${MULTILIB_USEDEP}]
- sys-libs/libraw1394[${MULTILIB_USEDEP}]
- )
- java? ( >=virtual/jre-1.8:* )
- jpeg? ( media-libs/libjpeg-turbo:=[${MULTILIB_USEDEP}] )
- jpeg2k? (
- jasper? ( media-libs/jasper:= )
- !jasper? ( media-libs/openjpeg:2=[${MULTILIB_USEDEP}] )
- )
- lapack? (
- atlas? ( sci-libs/atlas )
- mkl? ( sci-libs/mkl )
- !atlas? (
- !mkl? (
- virtual/cblas
- >=virtual/lapack-3.10
- virtual/lapacke
- )
- )
- )
- opencl? (
- virtual/opencl[${MULTILIB_USEDEP}]
- dev-util/opencl-headers
- )
- openexr? (
- dev-libs/imath:=
- media-libs/openexr:=
- )
- opengl? (
- virtual/opengl[${MULTILIB_USEDEP}]
- virtual/glu[${MULTILIB_USEDEP}]
- )
- png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
- python? (
- ${PYTHON_DEPS}
- dev-python/numpy:=[${PYTHON_USEDEP}]
- )
- qt5? (
- dev-qt/qtgui:5
- dev-qt/qtwidgets:5
- dev-qt/qttest:5
- dev-qt/qtconcurrent:5
- opengl? ( dev-qt/qtopengl:5 )
- )
- !qt5? (
- qt6? (
- dev-qt/qtbase:6[gui,widgets,concurrent,opengl?]
- )
- )
- quirc? ( media-libs/quirc )
- tesseract? ( app-text/tesseract[opencl=,${MULTILIB_USEDEP}] )
- tbb? ( dev-cpp/tbb:=[${MULTILIB_USEDEP}] )
- tiff? ( media-libs/tiff:=[${MULTILIB_USEDEP}] )
- v4l? ( >=media-libs/libv4l-0.8.3[${MULTILIB_USEDEP}] )
- vaapi? ( media-libs/libva[${MULTILIB_USEDEP}] )
- vtk? ( sci-libs/vtk:=[rendering,cuda=] )
- webp? ( media-libs/libwebp:=[${MULTILIB_USEDEP}] )
- xine? ( media-libs/xine-lib )
-"
-DEPEND="
- ${RDEPEND}
- eigen? ( >=dev-cpp/eigen-3.3.8-r1:3 )
- java? ( >=virtual/jdk-1.8:* )
-"
-# TODO gstreamer dependencies
-DEPEND+="
- test? (
- gstreamer? (
- media-plugins/gst-plugins-jpeg[${MULTILIB_USEDEP}]
- media-plugins/gst-plugins-x264[${MULTILIB_USEDEP}]
- )
- )
-"
-BDEPEND="
- virtual/pkgconfig
- cuda? ( dev-util/nvidia-cuda-toolkit:0= )
- doc? (
- app-text/doxygen[dot]
- python? (
- dev-python/beautifulsoup4[${PYTHON_USEDEP}]
- )
- )
-"
-
-PATCHES=(
- "${FILESDIR}/${PN}-3.4.0-disable-download.patch"
- "${FILESDIR}/${PN}-3.4.1-cuda-add-relaxed-constexpr.patch"
- "${FILESDIR}/${PN}-4.1.2-opencl-license.patch"
- "${FILESDIR}/${PN}-4.4.0-disable-native-cpuflag-detect.patch"
- "${FILESDIR}/${PN}-4.5.0-link-with-cblas-for-lapack.patch"
-
- "${FILESDIR}/${PN}-4.8.1-use-system-flatbuffers.patch"
- "${FILESDIR}/${PN}-4.8.1-use-system-opencl.patch"
- "${FILESDIR}/${PN}-4.9.0-drop-python2-detection.patch"
- "${FILESDIR}/${PN}-4.9.0-ade-0.1.2d.tar.gz.patch"
- "${FILESDIR}/${PN}-4.9.0-cmake-cleanup.patch"
-
- # TODO applied in src_prepare
- # "${FILESDIR}/${PN}_contrib-${PV}-rgbd.patch"
- # "${FILESDIR}/${PN}_contrib-4.8.1-NVIDIAOpticalFlowSDK-2.0.tar.gz.patch"
-)
-
-cuda_get_cuda_compiler() {
- local compiler
- tc-is-gcc && compiler="gcc"
- tc-is-clang && compiler="clang"
- [[ -z "$compiler" ]] && die "no compiler specified"
-
- local package="sys-devel/${compiler}"
- local version="${package}"
- local CUDAHOSTCXX_test
- while
- local CUDAHOSTCXX="${CUDAHOSTCXX_test}"
- version=$(best_version "${version}")
- if [[ -z "${version}" ]]; then
- if [[ -z "${CUDAHOSTCXX}" ]]; then
- die "could not find supported version of ${package}"
- fi
- break
- fi
- CUDAHOSTCXX_test="$(
- dirname "$(
- realpath "$(
- which "${compiler}-$(echo "${version}" | grep -oP "(?<=${package}-)[0-9]*")"
- )"
- )"
- )"
- version="<${version}"
- do ! echo "int main(){}" | nvcc "-ccbin ${CUDAHOSTCXX_test}" - -x cu &>/dev/null; done
-
- echo "${CUDAHOSTCXX}"
-}
-
-cuda_get_host_native_arch() {
- : "${CUDAARCHS:=$(__nvcc_device_query)}"
- echo "${CUDAARCHS}"
-}
-
-pkg_pretend() {
- if use cuda && [[ -z "${CUDA_GENERATION}" ]] && [[ -z "${CUDA_ARCH_BIN}" ]]; then # TODO CUDAARCHS
- einfo "The target CUDA architecture can be set via one of:"
- einfo " - CUDA_GENERATION set to one of Maxwell, Pascal, Volta, Turing, Ampere, Lovelace, Hopper, Auto"
- einfo " - CUDA_ARCH_BIN, (and optionally CUDA_ARCH_PTX) in the form of x.y tuples."
- einfo " You can specify multiple tuple separated by \";\"."
- einfo ""
- einfo "The CUDA architecture tuple for your device can be found at https://developer.nvidia.com/cuda-gpus."
- fi
-
- if use cuda && [[ ${MERGE_TYPE} == "buildonly" ]] && [[ -n "${CUDA_GENERATION}" || -n "${CUDA_ARCH_BIN}" ]]; then
- local info_message="When building a binary package it's recommended to unset CUDA_GENERATION and CUDA_ARCH_BIN"
- einfo "$info_message so all available architectures are build."
- fi
-
- [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
-}
-
-pkg_setup() {
- [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
- use java && java-pkg-opt-2_pkg_setup
-}
-
-src_prepare() {
- cmake_src_prepare
-
- # remove bundled stuff
- rm -r 3rdparty || die "Removing 3rd party components failed"
- sed -e '/add_subdirectory(.*3rdparty.*)/ d' \
- -i CMakeLists.txt cmake/*cmake || die
-
- if use contrib; then
- cd "${WORKDIR}/${PN}_contrib-${PV}" || die
- eapply "${FILESDIR}/${PN}_contrib-4.8.1-rgbd.patch"
- eapply "${FILESDIR}/${PN}_contrib-4.8.1-NVIDIAOpticalFlowSDK-2.0.tar.gz.patch"
- if has_version ">=dev-util/nvidia-cuda-toolkit-12.4" && use cuda; then
- # TODO https://github.com/NVIDIA/cccl/pull/1522
- eapply "${FILESDIR}/${PN}_contrib-4.9.0-cuda-12.4.patch"
- fi
- cd "${S}" || die
-
- ! use contribcvv && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/cvv" || die; }
- # ! use contribdnn && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/dnn" || die; }
- ! use contribfreetype && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/freetype" || die; }
- ! use contribhdf && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/hdf" || die; }
- ! use contribovis && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/ovis" || die; }
- ! use contribsfm && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/sfm" || die; }
- ! use contribxfeatures2d && { rm -R "${WORKDIR}/${PN}_contrib-${PV}/modules/xfeatures2d" || die; }
- fi
-
- mkdir -p "${S}/.cache/ade" || die
- cp \
- "${DISTDIR}/ade-${ADE_PV}.tar.gz" \
- "${S}/.cache/ade/$(md5sum "${DISTDIR}/ade-${ADE_PV}.tar.gz" | cut -f 1 -d " ")-v${ADE_PV}.tar.gz" || die
-
- if use dnnsamples; then
- mkdir -p "${S}/.cache/wechat_qrcode" || die
- for file in "detect.caffemodel" "detect.prototxt" "sr.prototxt" "sr.caffemodel"; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${QRCODE_COMMIT}/${file}" \
- "${S}/.cache/wechat_qrcode/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${QRCODE_COMMIT}/${file}" | cut -f 1 -d " " \
- )-${file}" || die
- done
-
- mv \
- "${WORKDIR}/${PN}_3rdparty-${DNN_SAMPLES_FACE_DETECTOR_COMMIT}/res10_300x300_ssd_iter_140000.caffemodel" \
- "${S}/samples/dnn/" || die
- fi
-
- if use contribxfeatures2d; then
- cp \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/"*.i \
- "${WORKDIR}/${PN}_contrib-${PV}"/modules/xfeatures2d/src/ || die
- mkdir -p "${S}/.cache/xfeatures2d/boostdesc" || die
- for file in "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/"*.i; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/$(basename "${file}")" \
- "${S}/.cache/xfeatures2d/boostdesc/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_BOOSTDESC_COMMIT}/$(basename "${file}")" | cut -f 1 -d " " \
- )-$(basename "${file}")" || die
- done
-
- cp \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/"*.i \
- "${WORKDIR}/${PN}_contrib-${PV}"/modules/xfeatures2d/src/ || die
- mkdir -p "${S}/.cache/xfeatures2d/vgg" || die
- for file in "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/"*.i; do
- mv \
- "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/$(basename "${file}")" \
- "${S}/.cache/xfeatures2d/vgg/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${XFEATURES2D_VGG_COMMIT}/$(basename "${file}")" | cut -f 1 -d " " \
- )-$(basename "${file}")" || die
- done
- fi
-
- if use contribdnn; then
- mkdir -p "${S}/.cache/data" || die
- mkdir -p "${WORKDIR}/${PN}_extra-${PV}/testdata/cv/face/" || die
- file="face_landmark_model.dat"
- cp \
- "${WORKDIR}/${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}/${file}" \
- "${WORKDIR}/${PN}_extra-${PV}/testdata/cv/face/" \
- || die
- mv \
- "${WORKDIR}/${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}/${file}" \
- "${S}/.cache/data/$( \
- md5sum "${WORKDIR}/${PN}_3rdparty-${FACE_ALIGNMENT_COMMIT}/${file}" | cut -f 1 -d " " \
- )-${file}" || die
- fi
-
- if use cuda; then
- mkdir -p "${S}/.cache/nvidia_optical_flow"
- cp \
- "${DISTDIR}/NVIDIAOpticalFlowSDK-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz" \
- "${S}/.cache/nvidia_optical_flow/$( \
- md5sum "${DISTDIR}/NVIDIAOpticalFlowSDK-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz" | cut -f 1 -d " " \
- )-${NVIDIA_OPTICAL_FLOW_COMMIT}.tar.gz" || die
- fi
-
- if use java; then
- java-pkg-opt-2_src_prepare
-
- JAVA_ANT_ENCODING="iso-8859-1"
- # set encoding so even this cmake build will pick it up.
- export ANT_OPTS+=" -Dfile.encoding=iso-8859-1"
- fi
-}
-
-multilib_src_configure() {
- # bug #919101 and https://github.com/opencv/opencv/issues/19020
- filter-lto
-
- # please don't sort here, order is the same as in CMakeLists.txt
- local mycmakeargs=(
- -DMIN_VER_CMAKE=3.26
-
- -DCMAKE_POLICY_DEFAULT_CMP0148="OLD" # FindPythonInterp
-
- # for protobuf
- -DCMAKE_CXX_STANDARD=17
-
- # Optional 3rd party components
- # ===================================================
- -DENABLE_DOWNLOAD=yes
- -DOPENCV_ENABLE_NONFREE="$(usex non-free)"
- -DWITH_QUIRC="$(usex quirc)"
- -DWITH_FLATBUFFERS="$(multilib_native_usex contribdnn)"
- -DWITH_1394="$(usex ieee1394)"
- # -DWITH_AVFOUNDATION="no" # IOS
- -DWITH_VTK="$(multilib_native_usex vtk)"
- -DWITH_EIGEN="$(usex eigen)"
- -DWITH_VFW="no" # Video windows support
- -DWITH_FFMPEG="$(usex ffmpeg)"
- -DWITH_GSTREAMER="$(usex gstreamer)"
- -DWITH_GTK="$(usex gtk3)"
- -DWITH_GTK_2_X="no" # only want gtk3 nowadays
- -DWITH_IPP="no"
- -DWITH_JASPER="$(multilib_native_usex jasper)"
- -DWITH_JPEG="$(usex jpeg)"
- -DWITH_OPENJPEG="$(usex jpeg2k)"
- -DWITH_WEBP="$(usex webp)"
- -DWITH_OPENEXR="$(multilib_native_usex openexr)"
- -DWITH_OPENGL="$(usex opengl)"
- -DOpenGL_GL_PREFERENCE="GLVND"
- -DWITH_OPENVX="no"
- -DWITH_OPENNI="no" # Not packaged
- -DWITH_OPENNI2="no" # Not packaged
- -DWITH_PNG="$(usex png)"
- -DWITH_GDCM="no"
- -DWITH_PVAPI="no"
- -DWITH_GIGEAPI="no"
- -DWITH_ARAVIS="no"
- -DWITH_WIN32UI="no" # Windows only
- # -DWITH_QUICKTIME="no"
- # -DWITH_QTKIT="no"
- -DWITH_TBB="$(usex tbb)"
- -DWITH_OPENMP="$(usex !tbb "$(usex openmp)")"
- -DWITH_PTHREADS_PF="yes"
- -DWITH_TIFF="$(usex tiff)"
- -DWITH_UNICAP="no" # Not packaged
- -DWITH_V4L="$(usex v4l)"
- -DWITH_LIBV4L="$(usex v4l)"
- # -DWITH_DSHOW="yes" # direct show supp
- -DWITH_MSMF="no"
- -DWITH_XIMEA="no" # Windows only
- -DWITH_XINE="$(multilib_native_usex xine)"
- -DWITH_CLP="no"
- -DWITH_OPENCL="$(usex opencl)"
- -DWITH_OPENCL_SVM="no" # "$(usex opencl)"
- -DWITH_DIRECTX="no"
- -DWITH_INTELPERC="no"
- -DWITH_IPP_A="no"
- -DWITH_MATLAB="no"
- -DWITH_VA="$(usex vaapi)"
- -DWITH_VA_INTEL="$(usex vaapi "$(usex video_cards_intel)")"
- -DWITH_GDAL="$(multilib_native_usex gdal)"
- -DWITH_GPHOTO2="$(usex gphoto2)"
- -DWITH_LAPACK="$(multilib_native_usex lapack)"
- -DWITH_ITT="no" # 3dparty libs itt_notify
- # ===================================================
- # CUDA build components: nvidia-cuda-toolkit
- # ===================================================
- -DWITH_CUDA="$(multilib_native_usex cuda)"
- -DWITH_CUBLAS="$(multilib_native_usex cuda)"
- -DWITH_CUFFT="$(multilib_native_usex cuda)"
- -DWITH_CUDNN="$(multilib_native_usex cudnn)"
- # NOTE set this via MYCMAKEARGS if needed
- -DWITH_NVCUVID="no" # TODO needs NVIDIA Video Codec SDK
- -DWITH_NVCUVENC="no" # TODO needs NVIDIA Video Codec SDK
- -DCUDA_NPP_LIBRARY_ROOT_DIR="$(usex cuda "${EPREFIX}/opt/cuda" "")"
- # ===================================================
- # OpenCV build components
- # ===================================================
- -DBUILD_SHARED_LIBS="yes"
- -DBUILD_JAVA="$(multilib_native_usex java)" # Ant needed, no compile flag
- -DBUILD_ANDROID_EXAMPLES="no"
- -DBUILD_opencv_apps="$(usex opencvapps)"
- -DBUILD_DOCS="$(usex doc)" # Doesn't install anyways.
- -DBUILD_EXAMPLES="$(multilib_native_usex examples)"
- -DBUILD_TESTS="$(multilib_native_usex test)"
- -DBUILD_PERF_TESTS="no"
-
- # -DBUILD_WITH_STATIC_CRT="no"
- -DBUILD_WITH_DYNAMIC_IPP="no"
- -DBUILD_FAT_JAVA_LIB="no"
- # -DBUILD_ANDROID_SERVICE="no"
- -DBUILD_CUDA_STUBS="$(multilib_native_usex cuda)"
- -DOPENCV_EXTRA_MODULES_PATH="$(usex contrib "${WORKDIR}/${PN}_contrib-${PV}/modules" "")"
- # ===================================================
- # OpenCV installation options
- # ===================================================
- -DINSTALL_CREATE_DISTRIB="no"
- -DINSTALL_BIN_EXAMPLES="$(multilib_native_usex examples)"
- -DINSTALL_C_EXAMPLES="$(multilib_native_usex examples)"
- -DINSTALL_TESTS="$(multilib_native_usex testprograms)"
- # -DINSTALL_ANDROID_EXAMPLES="no"
- -DINSTALL_TO_MANGLED_PATHS="no"
- -DOPENCV_GENERATE_PKGCONFIG="yes"
- # opencv uses both ${CMAKE_INSTALL_LIBDIR} and ${LIB_SUFFIX}
- # to set its destination libdir
- -DLIB_SUFFIX=
- # ===================================================
- # OpenCV build options
- # ===================================================
- # -DENABLE_CCACHE="no"
- # bug 733796, but PCH is a risky game in CMake anyway
- -DBUILD_USE_SYMLINKS="yes"
- -DENABLE_PRECOMPILED_HEADERS="no"
- -DENABLE_SOLUTION_FOLDERS="no"
- -DENABLE_PROFILING="no"
- -DENABLE_COVERAGE="no"
- -DOPENCV_DOWNLOAD_TRIES_LIST="0"
-
- -DHAVE_opencv_java="$(multilib_native_usex java)"
-
- -DBUILD_WITH_DEBUG_INFO="$(usex debug)"
- -DOPENCV_ENABLE_MEMORY_SANITIZER="$(usex debug)"
- -DCV_TRACE="$(usex debug)"
- -DENABLE_NOISY_WARNINGS="$(usex debug)"
- -DOPENCV_WARNINGS_ARE_ERRORS="no"
- -DENABLE_IMPL_COLLECTION="no"
- -DENABLE_INSTRUMENTATION="no"
- -DGENERATE_ABI_DESCRIPTOR="no"
- # ===================================================
- # things we want to be hard off or not yet figured out
- # ===================================================
- -DBUILD_PACKAGE="no"
- # ===================================================
- # Not building protobuf but update files bug #631418
- # ===================================================
- -DWITH_PROTOBUF="yes"
- -DBUILD_PROTOBUF="no"
- -DPROTOBUF_UPDATE_FILES="yes"
- -DProtobuf_MODULE_COMPATIBLE="yes"
- # ===================================================
- # things we want to be hard enabled not worth useflag
- # ===================================================
- -DOPENCV_DOC_INSTALL_PATH="share/doc/${P}"
- # NOTE do this so testprograms do not fail TODO adjust path in code
- -DOPENCV_TEST_DATA_INSTALL_PATH="share/${PN}$(ver_cut 1)/testdata"
- -DOPENCV_TEST_INSTALL_PATH="libexec/${PN}/bin/test"
- -DOPENCV_SAMPLES_BIN_INSTALL_PATH="libexec/${PN}/bin/samples"
-
- -DBUILD_IPP_IW="no"
- -DBUILD_ITT="no"
-
- # ===================================================
- # configure modules to be build
- # ===================================================
- -DBUILD_opencv_gapi="$(usex ffmpeg yes "$(usex gstreamer)")"
- -DBUILD_opencv_features2d="$(usex features2d)"
- -DBUILD_opencv_java_bindings_generator="$(usex java)"
- -DBUILD_opencv_js="no"
- -DBUILD_opencv_js_bindings_generator="no"
- -DBUILD_opencv_objc_bindings_generator="no"
- -DBUILD_opencv_python2="no"
- -DBUILD_opencv_ts="$(usex test)"
- -DBUILD_opencv_video="$(usex ffmpeg yes "$(usex gstreamer)")"
- -DBUILD_opencv_videoio="$(usex ffmpeg yes "$(usex gstreamer)")"
-
- -DBUILD_opencv_cudalegacy="no"
-
- # -DBUILD_opencv_world="yes"
-
- -DDNN_PLUGIN_LIST="all"
- -DHIGHGUI_PLUGIN_LIST="all"
- -DVIDEOIO_PLUGIN_LIST="all"
-
- )
-
- if use qt5; then
- mycmakeargs+=(
- -DWITH_QT="$(multilib_native_usex qt5)"
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt6="yes"
- )
- elif use qt6; then
- mycmakeargs+=(
- -DWITH_QT="$(multilib_native_usex qt6)"
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt5="yes"
- )
- else
- mycmakeargs+=(
- -DWITH_QT="no"
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt5="yes"
- -DCMAKE_DISABLE_FIND_PACKAGE_Qt6="yes"
- )
- fi
-
- # ==================================================
- # cpu flags, should solve 633900
- #===================================================
- # TODO binhost https://github.com/opencv/opencv/wiki/CPU-optimizations-build-options
-
- local CPU_BASELINE=""
- for i in "${CPU_FEATURES_MAP[@]}" ; do
- if [[ ${ABI} != x86 || ${i%:*} != "cpu_flags_x86_avx2" ]]; then # workaround for Bug 747163
- use "${i%:*}" && CPU_BASELINE="${CPU_BASELINE}${i#*:};"
- fi
- done
- unset CPU_FEATURES_MAP
-
- mycmakeargs+=(
- -DCPU_BASELINE="${CPU_BASELINE}"
- )
- if [[ ${MERGE_TYPE} != "buildonly" ]]; then
- mycmakeargs+=(
- -DOPENCV_CPU_OPT_IMPLIES_IGNORE="yes"
- -DCPU_DISPATCH=
- )
- fi
-
- # ===================================================
- # OpenCV Contrib Modules
- # ===================================================
- if use contrib; then
- mycmakeargs+=(
- -DBUILD_opencv_cvv="$(usex contribcvv)"
- -DBUILD_opencv_dnn="$(usex contribdnn)"
- -DBUILD_opencv_freetype="$(usex contribfreetype)"
- -DBUILD_opencv_hdf="$(multilib_native_usex contribhdf)"
- -DBUILD_opencv_ovis="$(usex contribovis)"
- -DBUILD_opencv_sfm="$(usex contribsfm)"
- -DBUILD_opencv_xfeatures2d="$(usex contribxfeatures2d)"
- )
-
- if multilib_is_native_abi && use !tesseract; then
- mycmakeargs+=(
- -DCMAKE_DISABLE_FIND_PACKAGE_Tesseract="yes"
- )
- fi
- fi
-
- # workaround for bug 413429
- tc-export CC CXX
-
- if multilib_is_native_abi && use cuda; then
- cuda_add_sandbox -w
- sandbox_write "/proc/self/task"
- CUDAHOSTCXX="$(cuda_get_cuda_compiler)"
- CUDAARCHS="$(cuda_get_host_native_arch)"
- export CUDAHOSTCXX
- export CUDAARCHS
- mycmakeargs+=(
- -DENABLE_CUDA_FIRST_CLASS_LANGUAGE="yes"
- )
- fi
-
- if use ffmpeg; then
- mycmakeargs+=(
- -DOPENCV_GAPI_GSTREAMER="no"
- )
- fi
-
- if use mkl; then
- mycmakeargs+=(
- -DLAPACK_IMPL="MKL"
- -DMKL_WITH_OPENMP="$(usex !tbb "$(usex openmp)")"
- -DMKL_WITH_TBB="$(usex tbb)"
- )
- fi
-
- # NOTE set this via MYCMAKEARGS if needed
- if use opencl; then
- if has_version sci-libs/clfft; then
- mycmakeargs+=( -DWITH_OPENCLAMDFFT="yes" )
- else
- mycmakeargs+=( -DWITH_OPENCLAMDFFT="no" )
- fi
- if has_version sci-libs/clblas; then
- mycmakeargs+=( -DWITH_OPENCLAMDBLAS="yes" )
- else
- mycmakeargs+=( -DWITH_OPENCLAMDBLAS="no" )
- fi
- else
- mycmakeargs+=(
- -DWITH_OPENCLAMDFFT="no"
- -DWITH_OPENCLAMDBLAS="no"
- )
- fi
-
- if use test; then
- # opencv tests assume to be build in Release mode
- CMAKE_BUILD_TYPE="Release"
- mycmakeargs+=(
- -DOPENCV_TEST_DATA_PATH="${WORKDIR}/${PN}_extra-${PV}/testdata"
- )
- if use vtk; then
- mycmakeargs+=(
- -DVTK_MPI_NUMPROCS="$(nproc)" # TODO
- )
- fi
- fi
-
- if multilib_is_native_abi && use python; then
- python_configure() {
- # Set all python variables to load the correct Gentoo paths
- local mycmakeargs=(
- "${mycmakeargs[@]}"
- # python_setup alters PATH and sets this as wrapper
- # to the correct interpreter we are building for
- -DBUILD_opencv_python3="yes"
- -DBUILD_opencv_python_bindings_generator="yes"
- -DBUILD_opencv_python_tests="$(usex test)"
- -DPYTHON_DEFAULT_EXECUTABLE="${EPYTHON}"
- -DINSTALL_PYTHON_EXAMPLES="$(usex examples)"
- )
- cmake_src_configure
- }
-
- python_foreach_impl python_configure
- else
- mycmakeargs+=(
- -DPYTHON_EXECUTABLE="no"
- -DINSTALL_PYTHON_EXAMPLES="no"
- -DBUILD_opencv_python3="no"
- -DBUILD_opencv_python_bindings_generator="no"
- -DBUILD_opencv_python_tests="no"
- )
- cmake_src_configure
- fi
- use java && java-ant-2_src_configure
-}
-
-multilib_src_compile() {
- opencv_compile() {
- cmake_src_compile
- }
- if multilib_is_native_abi && use python; then
- python_foreach_impl opencv_compile
- else
- opencv_compile
- fi
-}
-
-multilib_src_test() {
- CMAKE_SKIP_TESTS=(
- 'Test_ONNX_layers.LSTM_cell_forward/0'
- 'Test_ONNX_layers.LSTM_cell_bidirectional/0'
- 'Test_TensorFlow_layers.Convolution3D/1'
- 'Test_TensorFlow_layers.concat_3d/1'
-
- 'AsyncAPICancelation/cancel*basic'
- )
-
- if ! use gtk && ! use qt5 && ! use qt6; then
- CMAKE_SKIP_TESTS+=(
- # these fail with parallism
- '^Highgui_*'
- )
- fi
-
- if multilib_is_native_abi && use cuda; then
- CMAKE_SKIP_TESTS+=(
- 'CUDA_OptFlow/BroxOpticalFlow.Regression/0'
- 'CUDA_OptFlow/BroxOpticalFlow.OpticalFlowNan/0'
- 'CUDA_OptFlow/NvidiaOpticalFlow_1_0.Regression/0'
- 'CUDA_OptFlow/NvidiaOpticalFlow_2_0.Regression/0'
- )
- fi
-
- if use opengl; then
- CMAKE_SKIP_TESTS+=(
- 'OpenGL/Buffer.MapDevice/*'
- 'OpenGL/*Gpu*'
- )
- fi
-
- if use opencl; then
- CMAKE_SKIP_TESTS+=(
- 'OCL_Arithm/InRange.Mat/\(CV_32S,*'
- )
- fi
-
- local myctestargs=(
- --test-timeout 180
- )
-
- if multilib_is_native_abi && use cuda; then
- cuda_add_sandbox -w
- export OPENCV_PARALLEL_BACKEND="threads"
- export DNN_BACKEND_OPENCV="cuda"
- fi
-
- opencv_test() {
- export OPENCV_CORE_PLUGIN_PATH="${BUILD_DIR}/lib"
- export OPENCV_DNN_PLUGIN_PATH="${BUILD_DIR}/lib"
- export OPENCV_VIDEOIO_PLUGIN_PATH="${BUILD_DIR}/lib"
-
- export OPENCV_TEST_DATA_PATH="${WORKDIR}/${PN}_extra-${PV}/testdata"
-
- # Work around zink warnings
- export LIBGL_ALWAYS_SOFTWARE=true
- results=()
- for test in "${BUILD_DIR}/bin/opencv_test_"*; do
- echo "${test}"
- if ! "${test}" --gtest_color=yes --gtest_filter="-$(IFS=: ; echo "${CMAKE_SKIP_TESTS[*]}")"; then
-
- results+=( "$(basename ${test})" )
-
- if [[ -z "${OPENCV_TEST_CONTINUE_ON_FAIL}" ]]; then
- eerror "${results[*]} failed"
- die
- fi
- fi
- done
-
- echo -e "${results[*]}"
- }
-
- if multilib_is_native_abi && use python; then
- python_foreach_impl virtx opencv_test
- else
- virtx opencv_test
- fi
-}
-
-multilib_src_install() {
- if use abi_x86_64 && use abi_x86_32; then
- MULTILIB_WRAPPED_HEADERS=( # {{{
- # [opencv4]
- /usr/include/opencv4/opencv2/cvconfig.h
- /usr/include/opencv4/opencv2/opencv_modules.hpp
-
- /usr/include/opencv4/opencv2/core_detect.hpp
-
- /usr/include/opencv4/opencv2/cudaarithm.hpp
- /usr/include/opencv4/opencv2/cudabgsegm.hpp
- /usr/include/opencv4/opencv2/cudacodec.hpp
- /usr/include/opencv4/opencv2/cudafeatures2d.hpp
- /usr/include/opencv4/opencv2/cudafilters.hpp
- /usr/include/opencv4/opencv2/cudaimgproc.hpp
- /usr/include/opencv4/opencv2/cudalegacy.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCV.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCVBroxOpticalFlow.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCVHaarObjectDetection.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NCVPyramid.hpp
- /usr/include/opencv4/opencv2/cudalegacy/NPP_staging.hpp
- /usr/include/opencv4/opencv2/cudaobjdetect.hpp
- /usr/include/opencv4/opencv2/cudaoptflow.hpp
- /usr/include/opencv4/opencv2/cudastereo.hpp
- /usr/include/opencv4/opencv2/cudawarping.hpp
- # [cudev]
- /usr/include/opencv4/opencv2/cudev.hpp
- /usr/include/opencv4/opencv2/cudev/block/block.hpp
- /usr/include/opencv4/opencv2/cudev/block/detail/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/block/detail/reduce_key_val.hpp
- /usr/include/opencv4/opencv2/cudev/block/dynamic_smem.hpp
- /usr/include/opencv4/opencv2/cudev/block/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/block/scan.hpp
- /usr/include/opencv4/opencv2/cudev/block/vec_distance.hpp
- /usr/include/opencv4/opencv2/cudev/common.hpp
- /usr/include/opencv4/opencv2/cudev/expr/binary_func.hpp
- /usr/include/opencv4/opencv2/cudev/expr/binary_op.hpp
- /usr/include/opencv4/opencv2/cudev/expr/color.hpp
- /usr/include/opencv4/opencv2/cudev/expr/deriv.hpp
- /usr/include/opencv4/opencv2/cudev/expr/expr.hpp
- /usr/include/opencv4/opencv2/cudev/expr/per_element_func.hpp
- /usr/include/opencv4/opencv2/cudev/expr/reduction.hpp
- /usr/include/opencv4/opencv2/cudev/expr/unary_func.hpp
- /usr/include/opencv4/opencv2/cudev/expr/unary_op.hpp
- /usr/include/opencv4/opencv2/cudev/expr/warping.hpp
- /usr/include/opencv4/opencv2/cudev/functional/color_cvt.hpp
- /usr/include/opencv4/opencv2/cudev/functional/detail/color_cvt.hpp
- /usr/include/opencv4/opencv2/cudev/functional/functional.hpp
- /usr/include/opencv4/opencv2/cudev/functional/tuple_adapter.hpp
- /usr/include/opencv4/opencv2/cudev/grid/copy.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/copy.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/histogram.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/integral.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/minmaxloc.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/pyr_down.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/pyr_up.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/reduce_to_column.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/reduce_to_row.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/split_merge.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/transform.hpp
- /usr/include/opencv4/opencv2/cudev/grid/detail/transpose.hpp
- /usr/include/opencv4/opencv2/cudev/grid/histogram.hpp
- /usr/include/opencv4/opencv2/cudev/grid/integral.hpp
- /usr/include/opencv4/opencv2/cudev/grid/pyramids.hpp
- /usr/include/opencv4/opencv2/cudev/grid/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/grid/reduce_to_vec.hpp
- /usr/include/opencv4/opencv2/cudev/grid/split_merge.hpp
- /usr/include/opencv4/opencv2/cudev/grid/transform.hpp
- /usr/include/opencv4/opencv2/cudev/grid/transpose.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/constant.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/deriv.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/detail/gpumat.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/extrapolation.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/glob.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/gpumat.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/interpolation.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/lut.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/mask.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/remap.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/resize.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/texture.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/traits.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/transform.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/warping.hpp
- /usr/include/opencv4/opencv2/cudev/ptr2d/zip.hpp
- /usr/include/opencv4/opencv2/cudev/util/atomic.hpp
- /usr/include/opencv4/opencv2/cudev/util/detail/tuple.hpp
- /usr/include/opencv4/opencv2/cudev/util/detail/type_traits.hpp
- /usr/include/opencv4/opencv2/cudev/util/limits.hpp
- /usr/include/opencv4/opencv2/cudev/util/saturate_cast.hpp
- /usr/include/opencv4/opencv2/cudev/util/simd_functions.hpp
- /usr/include/opencv4/opencv2/cudev/util/tuple.hpp
- /usr/include/opencv4/opencv2/cudev/util/type_traits.hpp
- /usr/include/opencv4/opencv2/cudev/util/vec_math.hpp
- /usr/include/opencv4/opencv2/cudev/util/vec_traits.hpp
- /usr/include/opencv4/opencv2/cudev/warp/detail/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/warp/detail/reduce_key_val.hpp
- /usr/include/opencv4/opencv2/cudev/warp/reduce.hpp
- /usr/include/opencv4/opencv2/cudev/warp/scan.hpp
- /usr/include/opencv4/opencv2/cudev/warp/shuffle.hpp
- /usr/include/opencv4/opencv2/cudev/warp/warp.hpp
- # [contribcvv]
- /usr/include/opencv4/opencv2/cvv.hpp
- /usr/include/opencv4/opencv2/cvv/call_meta_data.hpp
- /usr/include/opencv4/opencv2/cvv/cvv.hpp
- /usr/include/opencv4/opencv2/cvv/debug_mode.hpp
- /usr/include/opencv4/opencv2/cvv/dmatch.hpp
- /usr/include/opencv4/opencv2/cvv/filter.hpp
- /usr/include/opencv4/opencv2/cvv/final_show.hpp
- /usr/include/opencv4/opencv2/cvv/show_image.hpp
- # [contribdnn]
- /usr/include/opencv4/opencv2/dnn.hpp
- /usr/include/opencv4/opencv2/dnn/all_layers.hpp
- /usr/include/opencv4/opencv2/dnn/dict.hpp
- /usr/include/opencv4/opencv2/dnn/dnn.hpp
- /usr/include/opencv4/opencv2/dnn/dnn.inl.hpp
- /usr/include/opencv4/opencv2/dnn/layer.details.hpp
- /usr/include/opencv4/opencv2/dnn/layer.hpp
- /usr/include/opencv4/opencv2/dnn/shape_utils.hpp
- /usr/include/opencv4/opencv2/dnn/utils/debug_utils.hpp
- /usr/include/opencv4/opencv2/dnn/utils/inference_engine.hpp
- /usr/include/opencv4/opencv2/dnn/version.hpp
- /usr/include/opencv4/opencv2/dnn_superres.hpp
- # [contribhdf]
- /usr/include/opencv4/opencv2/hdf.hpp
- /usr/include/opencv4/opencv2/hdf/hdf5.hpp
-
- /usr/include/opencv4/opencv2/mcc.hpp
- /usr/include/opencv4/opencv2/mcc/ccm.hpp
- /usr/include/opencv4/opencv2/mcc/checker_detector.hpp
- /usr/include/opencv4/opencv2/mcc/checker_model.hpp
-
- /usr/include/opencv4/opencv2/text.hpp
- /usr/include/opencv4/opencv2/text/erfilter.hpp
- /usr/include/opencv4/opencv2/text/ocr.hpp
- /usr/include/opencv4/opencv2/text/swt_text_detection.hpp
- /usr/include/opencv4/opencv2/text/textDetector.hpp
-
- # [qt5,qt6]
- /usr/include/opencv4/opencv2/viz.hpp
- /usr/include/opencv4/opencv2/viz/types.hpp
- /usr/include/opencv4/opencv2/viz/viz3d.hpp
- /usr/include/opencv4/opencv2/viz/vizcore.hpp
- /usr/include/opencv4/opencv2/viz/widget_accessor.hpp
- /usr/include/opencv4/opencv2/viz/widgets.hpp
-
- /usr/include/opencv4/opencv2/wechat_qrcode.hpp
- ) # }}}
- fi
- if multilib_is_native_abi && use python; then
- python_foreach_impl cmake_src_install
- python_foreach_impl python_optimize
- else
- cmake_src_install
- fi
-}
diff --git a/media-libs/openjpeg/Manifest b/media-libs/openjpeg/Manifest
index 108d3863b875..69e2c89bf6e6 100644
--- a/media-libs/openjpeg/Manifest
+++ b/media-libs/openjpeg/Manifest
@@ -6,5 +6,5 @@ DIST openjpeg-data_20210926.tar.gz 498600110 BLAKE2B 34a1c39379d9f8f4caad6c8263a
DIST openjpeg-data_20230923.tar.gz 498600318 BLAKE2B cf595b9f8690ad0b9616f080c3bfdaf553802912cd41015f86766085c0bd021cead294372bd9925c2a569fabbd9a0f1684bcf6eb1b5ecdc14d64231a76401a3b SHA512 3e1e3bb489eac6047671395fbf92bbfb2ad7c7c0206c1a233c215ba3d5b5263a6ce65d523f98fdaa4949e28eaa179716264f89eebf73b44c71373a9c86313cc1
EBUILD openjpeg-2.5.0-r5.ebuild 3016 BLAKE2B 58ccde41f1a927a062a7cc9600ff8e7a1224dc1fa2af44d4ed76e88bf03d85429dd2e2f3a56fc45377b779e0aa5fb246be88f645485d17b5c6bd6f27bb6c59ed SHA512 6cf06915de4bb0ca9b96ded1560322673ca98a82c5ad67e8f2b437f83d8b7819efa5a5cee6b9cd41e00e0bb0cbfa17b10d0cd707fb564c2d9d7e6f950c4aafcc
EBUILD openjpeg-2.5.0-r6.ebuild 3019 BLAKE2B 390894e12a72f321302e6cffa4c77bd9ea6d2305968af8b5298d3066b7f4d97fa16da127afc5a0ed1637ed9bb834696d1da6023adaeab4ba395661d3672e8880 SHA512 7e21b4d51c87892ca5e1aff7da50db28285c5d298b324fe250c9cc162e0c7d21922668b4397d509dc0954654614fefe7834e888e6ebd109057f61ab2e29161b5
-EBUILD openjpeg-2.5.2.ebuild 2869 BLAKE2B 8caf7069021c8e4ddab46442095640c8a18e12b1f5a9c53bed6a1fde04a5c94ee63fdc34532e9994d3da6a7a22fad46daef91d8ef1c95318ebf870f829492feb SHA512 2398f08825cb2c6403a66bd9853d9c5c22da6a37584b49964c2dce7d45e493fc913973bd9aa7f01dc7b46b2f815f1f73efa819b489ad7c5413adf3b203a5ab12
+EBUILD openjpeg-2.5.2.ebuild 2868 BLAKE2B f96d6dd0cf58d628a97695109d75c181ca257628913553f0f628316d6694280aaf05d693cd494bd351431c1a591583f3a440a44ba49d0e42642f0912e1b8acaa SHA512 31b7f72d4d277c8e9ca1d705e7a5884f321dba42a164ca19f6186457753893234ed81a8997808e45c7ac273852f90e64bb56830c16a201f1dbedd11af2e8731e
MISC metadata.xml 612 BLAKE2B ecbdd9706b1975ad5a9f5ba9957ee7e1cc7cf42e7dfcb3e8b8f9e1f9851b035ac3d997ec9515a181b52be5112dfa44e9d2f98eeb532b21bf353afedcee035181 SHA512 243f4e9e4bc1d851c97167ab8f19ac240ea12d1e53ea59e6709b6da7a810edeb8aa287d92e0334b6b09d2df7660cc64de2dd9af739b2f3daa6ff19dcc304fa8d
diff --git a/media-libs/openjpeg/openjpeg-2.5.2.ebuild b/media-libs/openjpeg/openjpeg-2.5.2.ebuild
index c71da8a16783..cdd476b7fcc7 100644
--- a/media-libs/openjpeg/openjpeg-2.5.2.ebuild
+++ b/media-libs/openjpeg/openjpeg-2.5.2.ebuild
@@ -20,7 +20,7 @@ SRC_URI="https://github.com/uclouvain/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
LICENSE="BSD-2"
SLOT="2/7" # based on SONAME
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
IUSE="doc test"
RESTRICT="!test? ( test )"