From 3b00f2d2f95f5d6ff01e71259eb94fa714a92232 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Fri, 16 Feb 2024 17:36:56 +0000 Subject: gentoo auto-resync : 16:02:2024 - 17:36:56 --- media-libs/Manifest.gz | Bin 69172 -> 69187 bytes media-libs/libffado/Manifest | 2 - media-libs/libffado/libffado-2.4.7.ebuild | 125 ------ media-libs/mesa/Manifest | 2 + media-libs/mesa/mesa-23.3.6.ebuild | 448 +++++++++++++++++++++ media-libs/netpbm/Manifest | 6 +- .../netpbm-11.2.7-fix-pnmcolormap2-test.patch | 213 ++++++++++ .../files/netpbm-11.5.2-fix-tests-musl.patch | 157 ++++++++ media-libs/netpbm/netpbm-11.2.7.ebuild | 6 +- media-libs/netpbm/netpbm-11.5.2.ebuild | 5 + 10 files changed, 834 insertions(+), 130 deletions(-) delete mode 100644 media-libs/libffado/libffado-2.4.7.ebuild create mode 100644 media-libs/mesa/mesa-23.3.6.ebuild create mode 100644 media-libs/netpbm/files/netpbm-11.2.7-fix-pnmcolormap2-test.patch create mode 100644 media-libs/netpbm/files/netpbm-11.5.2-fix-tests-musl.patch (limited to 'media-libs') diff --git a/media-libs/Manifest.gz b/media-libs/Manifest.gz index b4ad88491eea..a637ffea1fc0 100644 Binary files a/media-libs/Manifest.gz and b/media-libs/Manifest.gz differ diff --git a/media-libs/libffado/Manifest b/media-libs/libffado/Manifest index 4f1215c9cf0c..9e2362e99866 100644 --- a/media-libs/libffado/Manifest +++ b/media-libs/libffado/Manifest @@ -1,6 +1,4 @@ AUX libffado-2.4.7-fix-config-load-crash.patch 728 BLAKE2B 066910a52b054d423abfc2656e5b9499be7b03499a74bd8df97b99b83d7c14c68e5728a4608b5082a53bd0f6d174ef645c461139018d0110cdfc2f8ad6111214 SHA512 7fedd5157bd3fae9cb70de02b5883a69caea0c0a2b80a3d86fe66d57743e127c281922afdfdfcb8cc14e492dafcf814a230d70dad8601168c615d9daf719cdd0 -DIST libffado-2.4.7.tgz 1231931 BLAKE2B 3c304011259ddbd35ce8fd725d38a5f50fca962981f9c5af6e377493a14985e4b96c64bcc54ba5a341028ec17dc6f2c42ce527422779f2edc6f9a1a61220cf51 SHA512 424a9ca7ded12e72d77a50d7ddf4e50dc0d55b80d725499df7609ce60d0eac8b24a41d9b8e4e74f78bdefe114b61bd5f1ec09a6d083f4a58475e66d61153f075 DIST libffado-2.4.8.tgz 1237955 BLAKE2B 14b83d55fc9a7b33c888b893c808f8419292fefaa2c2239b4b51c2b84070a584ea72821c8469bb8d965a9a5e6473b6fcfb5e85f4eecd2d424e3167322f8abb81 SHA512 fbbcd30640c55315f2e65fc6c07afc71a77dd2c9d1b6127ee55cd17e76511ad5f0563135e52397dbf113fb0d5925021a38780f231409bdd920da52e6c1ce3acc -EBUILD libffado-2.4.7.ebuild 2910 BLAKE2B 7bc847ab06720a19a14c463b89b65eee94c01f8835a7cfd6ded5a289e59ea5b1f88a5d7588c3cac2a059f063d4d304d56ab7f702b314ca224d72e5b6f1e15561 SHA512 9dfc974c63b9f868ea477722f223732d15343c472e31a753d3a6a9f77382554cfe8bb726a195ba265cb38f1c5867f8cccd7dc7b468a684af05d757af30a7b1ac EBUILD libffado-2.4.8.ebuild 2936 BLAKE2B aabd28bba092188f7bc98d5e979dc587b8c76c434b7f6961d536ca95dc76bb0feb25713f6337e159311ac3c7b29185cda77c87f1ae4cd5ea03368052556e152e SHA512 6318efe5372488eb2fcb19adf7a00fb6865029ef17e3ede59ca7c0f6c736a3066f005fcc6ec0d9f75ab25f383ec30d8461df7578d80aea8abe1db6eedbf73934 MISC metadata.xml 344 BLAKE2B a7d2c27caa7e9fa72716534c406145b94bd8a13eadf57d06ea8e3148339857311bd7e8f0434edbf8a70a5e7bfec1726425e1d16734841b056caeee7754471666 SHA512 30d31f76c73ff218fa34e5f9d442e2366082bf4697038c804c093cac0e22720341691b732bf653466f8e5fc7e734c11b08a02cef7dd2a4bd93635968e2c29447 diff --git a/media-libs/libffado/libffado-2.4.7.ebuild b/media-libs/libffado/libffado-2.4.7.ebuild deleted file mode 100644 index 559b64032697..000000000000 --- a/media-libs/libffado/libffado-2.4.7.ebuild +++ /dev/null @@ -1,125 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -PYTHON_COMPAT=( python3_{9..11} ) - -inherit desktop python-single-r1 scons-utils toolchain-funcs udev multilib-minimal - -DESCRIPTION="Driver for IEEE1394 (Firewire) audio interfaces" -HOMEPAGE="http://www.ffado.org" - -if [[ "${PV}" = "9999" ]]; then - inherit subversion - ESVN_REPO_URI="http://subversion.ffado.org/ffado/trunk/${PN}" -else - SRC_URI="http://www.ffado.org/files/${P}.tgz" - KEYWORDS="~alpha amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv x86" -fi - -LICENSE="GPL-2 GPL-3" -SLOT="0" -IUSE="debug qt5 test-programs" -REQUIRED_USE="${PYTHON_REQUIRED_USE}" - -BDEPEND=" - virtual/pkgconfig -" -CDEPEND="${PYTHON_DEPS} - dev-cpp/libxmlpp:2.6[${MULTILIB_USEDEP}] - >=dev-libs/dbus-c++-0.9.0-r5 - dev-libs/libconfig:=[cxx,${MULTILIB_USEDEP}] - media-libs/alsa-lib - media-libs/libiec61883[${MULTILIB_USEDEP}] - sys-apps/dbus - sys-libs/libavc1394[${MULTILIB_USEDEP}] - sys-libs/libraw1394[${MULTILIB_USEDEP}] - qt5? ( - $(python_gen_cond_dep ' - dev-python/dbus-python[${PYTHON_USEDEP}] - dev-python/PyQt5[dbus,${PYTHON_USEDEP}] - ') - x11-misc/xdg-utils - )" -DEPEND="${CDEPEND}" -RDEPEND="${CDEPEND}" - -PATCHES=( - "${FILESDIR}/libffado-2.4.7-fix-config-load-crash.patch" -) - -myescons() { - local myesconsargs=( - PREFIX="${EPREFIX}/usr" - LIBDIR="${EPREFIX}/usr/$(get_libdir)" - MANDIR="${EPREFIX}/usr/share/man" - UDEVDIR="$(get_udevdir)/rules.d" - CUSTOM_ENV=true - DETECT_USERSPACE_ENV=false - DEBUG=$(usex debug) - PYPKGDIR="$(python_get_sitedir)" - # ENABLE_OPTIMIZATIONS detects cpu type and sets flags accordingly - # -fomit-frame-pointer is added also which can cripple debugging. - # we set flags from portage instead - ENABLE_OPTIMIZATIONS=false - # This only works for JACK1>=0.122.0 or JACK2>=1.9.9. - ENABLE_SETBUFFERSIZE_API_VER=force - ) - if multilib_is_native_abi; then - myesconsargs+=( - BUILD_MIXER=$(usex qt5 true false) - BUILD_TESTS=$(usex test-programs) - ) - else - myesconsargs+=( - BUILD_MIXER=false - BUILD_TESTS=false - ) - fi - escons "${myesconsargs[@]}" "${@}" -} - -src_prepare() { - default - - # Bug #808853 - cp "${BROOT}"/usr/share/gnuconfig/config.guess admin/ || die "Failed to update config.guess" - - # Always use Qt5 - sed -i -e 's/try:/if False:/' -e 's/except.*/else:/' support/mixer-qt4/ffado/import_pyqt.py || die - - # Bugs #658052, #659226 - sed -i -e 's/^CacheDir/#CacheDir/' SConstruct || die - - multilib_copy_sources -} - -multilib_src_compile() { - tc-export CC CXX - myescons -} - -multilib_src_install() { - myescons DESTDIR="${D}" WILL_DEAL_WITH_XDG_MYSELF="True" install -} - -multilib_src_install_all() { - einstalldocs - - python_fix_shebang "${D}" - python_optimize "${D}" - - if use qt5; then - newicon "support/xdg/hi64-apps-ffado.png" "ffado.png" - newmenu "support/xdg/ffado.org-ffadomixer.desktop" "ffado-mixer.desktop" - fi -} - -pkg_postinst() { - udev_reload -} - -pkg_postrm() { - udev_reload -} diff --git a/media-libs/mesa/Manifest b/media-libs/mesa/Manifest index b8369715aa5f..514b0e943789 100644 --- a/media-libs/mesa/Manifest +++ b/media-libs/mesa/Manifest @@ -1,6 +1,8 @@ DIST mesa-23.3.5.tar.xz 19429564 BLAKE2B 69c7434ae9c503c14b5bf9abad9a3a26a1dd402461b098dcdb01b9da7a7e8652f897fd9681c809aa70d3ace77c448289d22400deca3854844a355eb0ac095583 SHA512 1ad29f524caee0000ef51abe58d29d9687de5fbc5168f7e677bb4e69c5e9a94918d5fbf6e10c6757fe7ce6d47bab109e452f0fa2e26aad2e6f8bfb744383b5ea +DIST mesa-23.3.6.tar.xz 19455492 BLAKE2B 1bec42973aa849ab3553942500de253213736eca5a71550f488cf915d65ee4f47d137772af1c59042f5803cfaf8152f278ccbab29c896d104985263a7121a2ba SHA512 b52ee34de90b77cd4f204a0cfeabc72064f30c3a11668b5280ad5d1c59c3c805b14a8d892f33c32db68a8ada330fbe7fe2124edccfd45cc84636ca7605c10048 DIST mesa-24.0.1.tar.xz 19950992 BLAKE2B 05eb98f2fec0d15e63e8da2ca2e563d0b6fb7e29d639e66fc69074b7550939160e6f29121b80f2c64083625f2b13aa728221443b1f5adf2dd0fd92056ed9dc40 SHA512 1eaff5dcff8dd314b2dfe249d25db68d530d3f0fb54e926999768d0a48aa34b67c31ec3587bb2a7d1969845b26e79a4d87aceb7a141fd2e811ae0c47c00b0963 EBUILD mesa-23.3.5.ebuild 12324 BLAKE2B be5c26a776ad3a70154f241c3d7fc4e880f61348cc20411d76bb563617bac9d8fca93738ac286475c7b263304ce4623ab12d5dd52cdd8e81005aab30554d889e SHA512 75451e0253e9bf473dc471e449ecb6e19dda75cbfefa6702fd62adeeba431713af6c576865efedf53dd845deac59b7b2ac03005344bba5925990f991c2dccc22 +EBUILD mesa-23.3.6.ebuild 12331 BLAKE2B cc6bec787020cbda9333823a94aeead4c0390492e4e10485e7bc823735a1e37098066b55f607c9688959936ac81337b2b5a8b1fafd3bb4bb73ccbb1c4b6af8f9 SHA512 71855871d00f4b07c7ccbf1f01d2ee1df3c49efff17460669da7d057ce7af62d761f815e6873a3d8a55859f0125c66e488be74d0d56f712fe4e1ab12f795e621 EBUILD mesa-24.0.1.ebuild 11544 BLAKE2B 219b9c11840684766c0a1b5ea6f9cc61acee4a86878620fce178f8dd69fc652955b82acabedc00f2cc7b287d17e3e06bdf738875c5482086c3d58244ff9ca938 SHA512 bfbd0400e3208016e7e2c7dfbbb8f04296d6616230918c3fee2ffe9efe5a4a1173ad737071f435710ec253ac314f4753620b200b5944da97d497829de6bf3934 EBUILD mesa-9999.ebuild 11457 BLAKE2B cd2f2d1b76a35e376b8a43889ee8c77ed0aa6a020201f19321bee9284dcd5047a28e5015cd3d8c6a3afb156b04ea5b33b1a1179e673991168258aafa3c39e8e5 SHA512 365d861641b8d52b0a4c66e3325c430e6dee48117374da8a578b4bdf9d02007f31bfa0956465cbcf50b43769c26a866ab5580840ff84709557e1ee2fbe3deec1 MISC metadata.xml 1435 BLAKE2B 53690878512b86ce0b8dce38b083684c85ad5c1a655d5a69cb3265e156869845263eb16f271691b66c9f0cd76e97b56908acf7a1792d6abac0ec99447826cbb5 SHA512 842106e5d6eb60ff33c8cae7f0d52983c4f7e104152718b50fc790cbcb2506551a6fc7841fe8e3c7963850c238f77505b0e49b10a3a936baf459e1acaf73e07f diff --git a/media-libs/mesa/mesa-23.3.6.ebuild b/media-libs/mesa/mesa-23.3.6.ebuild new file mode 100644 index 000000000000..015ace3a31c5 --- /dev/null +++ b/media-libs/mesa/mesa-23.3.6.ebuild @@ -0,0 +1,448 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) + +inherit flag-o-matic llvm meson-multilib python-any-r1 linux-info + +MY_P="${P/_/-}" + +DESCRIPTION="OpenGL-like graphic library for Linux" +HOMEPAGE="https://www.mesa3d.org/ https://mesa.freedesktop.org/" + +if [[ ${PV} == 9999 ]]; then + EGIT_REPO_URI="https://gitlab.freedesktop.org/mesa/mesa.git" + inherit git-r3 +else + SRC_URI="https://archive.mesa3d.org/${MY_P}.tar.xz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-solaris" +fi + +LICENSE="MIT SGI-B-2.0" +SLOT="0" +RESTRICT="!test? ( test )" + +RADEON_CARDS="r300 r600 radeon radeonsi" +VIDEO_CARDS="${RADEON_CARDS} d3d12 freedreno intel lavapipe lima nouveau panfrost v3d vc4 virgl vivante vmware" +for card in ${VIDEO_CARDS}; do + IUSE_VIDEO_CARDS+=" video_cards_${card}" +done + +IUSE="${IUSE_VIDEO_CARDS} + cpu_flags_x86_sse2 d3d9 debug gles1 +gles2 +llvm + lm-sensors opencl osmesa +proprietary-codecs selinux + test unwind vaapi valgrind vdpau vulkan + vulkan-overlay wayland +X xa zink +zstd" + +REQUIRED_USE=" + d3d9? ( + || ( + video_cards_intel + video_cards_r300 + video_cards_r600 + video_cards_radeonsi + video_cards_nouveau + video_cards_vmware + ) + ) + vulkan? ( video_cards_radeonsi? ( llvm ) ) + vulkan-overlay? ( vulkan ) + video_cards_lavapipe? ( llvm vulkan ) + video_cards_radeon? ( x86? ( llvm ) amd64? ( llvm ) ) + video_cards_r300? ( x86? ( llvm ) amd64? ( llvm ) ) + video_cards_radeonsi? ( llvm ) + vdpau? ( X ) + xa? ( X ) + zink? ( vulkan ) +" + +LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.110" +RDEPEND=" + >=dev-libs/expat-2.1.0-r3[${MULTILIB_USEDEP}] + >=media-libs/libglvnd-1.3.2[X?,${MULTILIB_USEDEP}] + >=sys-libs/zlib-1.2.8[${MULTILIB_USEDEP}] + unwind? ( sys-libs/libunwind[${MULTILIB_USEDEP}] ) + llvm? ( + video_cards_radeonsi? ( + virtual/libelf:0=[${MULTILIB_USEDEP}] + ) + video_cards_r600? ( + virtual/libelf:0=[${MULTILIB_USEDEP}] + ) + video_cards_radeon? ( + virtual/libelf:0=[${MULTILIB_USEDEP}] + ) + ) + lm-sensors? ( sys-apps/lm-sensors:=[${MULTILIB_USEDEP}] ) + opencl? ( + >=virtual/opencl-3 + dev-libs/libclc[spirv(-)] + >=dev-util/spirv-tools-1.3.231.0 + virtual/libelf:0= + ) + vaapi? ( + >=media-libs/libva-1.7.3:=[${MULTILIB_USEDEP}] + ) + vdpau? ( >=x11-libs/libvdpau-1.1:=[${MULTILIB_USEDEP}] ) + selinux? ( sys-libs/libselinux[${MULTILIB_USEDEP}] ) + wayland? ( >=dev-libs/wayland-1.18.0[${MULTILIB_USEDEP}] ) + ${LIBDRM_DEPSTRING}[video_cards_freedreno?,video_cards_intel?,video_cards_nouveau?,video_cards_vc4?,video_cards_vivante?,video_cards_vmware?,${MULTILIB_USEDEP}] + X? ( + >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}] + >=x11-libs/libxshmfence-1.1[${MULTILIB_USEDEP}] + >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}] + >=x11-libs/libXxf86vm-1.1.3[${MULTILIB_USEDEP}] + >=x11-libs/libxcb-1.13:=[${MULTILIB_USEDEP}] + x11-libs/libXfixes[${MULTILIB_USEDEP}] + x11-libs/xcb-util-keysyms[${MULTILIB_USEDEP}] + ) + zink? ( media-libs/vulkan-loader:=[${MULTILIB_USEDEP}] ) + zstd? ( app-arch/zstd:=[${MULTILIB_USEDEP}] ) +" +for card in ${RADEON_CARDS}; do + RDEPEND="${RDEPEND} + video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] ) + " +done +RDEPEND="${RDEPEND} + video_cards_radeonsi? ( ${LIBDRM_DEPSTRING}[video_cards_amdgpu] ) +" + +# Please keep the LLVM dependency block separate. Since LLVM is slotted, +# we need to *really* make sure we're not pulling one than more slot +# simultaneously. +# +# How to use it: +# 1. Specify LLVM_MAX_SLOT (inclusive), e.g. 17. +# 2. Specify LLVM_MIN_SLOT (inclusive), e.g. 15. +LLVM_MAX_SLOT="17" +LLVM_MIN_SLOT="15" +LLVM_USE_DEPS="llvm_targets_AMDGPU(+),${MULTILIB_USEDEP}" +PER_SLOT_DEPSTR=" + ( + !opencl? ( sys-devel/llvm:@SLOT@[${LLVM_USE_DEPS}] ) + opencl? ( sys-devel/clang:@SLOT@[${LLVM_USE_DEPS}] ) + opencl? ( dev-util/spirv-llvm-translator:@SLOT@ ) + ) +" +LLVM_DEPSTR=" + || ( + $(for ((slot=LLVM_MAX_SLOT; slot>=LLVM_MIN_SLOT; slot--)); do + echo "${PER_SLOT_DEPSTR//@SLOT@/${slot}}" + done) + ) + !opencl? ( =dev-python/mako-0.8.0[\${PYTHON_USEDEP}]") + vulkan? ( + dev-util/glslang + llvm? ( + video_cards_intel? ( + amd64? ( + $(python_gen_any_dep "dev-python/ply[\${PYTHON_USEDEP}]") + ~dev-util/intel_clc-${PV} + dev-libs/libclc[spirv(-)] + ) + ) + ) + ) + wayland? ( dev-util/wayland-scanner ) +" + +S="${WORKDIR}/${MY_P}" +EGIT_CHECKOUT_DIR=${S} + +QA_WX_LOAD=" +x86? ( + usr/lib/libglapi.so.0.0.0 + usr/lib/libOSMesa.so.8.0.0 + usr/lib/libGLX_mesa.so.0.0.0 +)" + +llvm_check_deps() { + if use opencl; then + has_version "sys-devel/clang:${LLVM_SLOT}[${LLVM_USE_DEPS}]" || return 1 + has_version "dev-util/spirv-llvm-translator:${LLVM_SLOT}" || return 1 + fi + has_version "sys-devel/llvm:${LLVM_SLOT}[${LLVM_USE_DEPS}]" +} + +pkg_pretend() { + if use vulkan; then + if ! use video_cards_d3d12 && + ! use video_cards_freedreno && + ! use video_cards_intel && + ! use video_cards_radeonsi && + ! use video_cards_v3d; then + ewarn "Ignoring USE=vulkan since VIDEO_CARDS does not contain d3d12, freedreno, intel, radeonsi, or v3d" + fi + fi + + if use vaapi; then + if ! use video_cards_d3d12 && + ! use video_cards_r600 && + ! use video_cards_radeonsi && + ! use video_cards_nouveau; then + ewarn "Ignoring USE=vaapi since VIDEO_CARDS does not contain d3d12, r600, radeonsi, or nouveau" + fi + fi + + if use vdpau; then + if ! use video_cards_d3d12 && + ! use video_cards_r300 && + ! use video_cards_r600 && + ! use video_cards_radeonsi && + ! use video_cards_nouveau; then + ewarn "Ignoring USE=vdpau since VIDEO_CARDS does not contain d3d12, r300, r600, radeonsi, or nouveau" + fi + fi + + if use xa; then + if ! use video_cards_freedreno && + ! use video_cards_nouveau && + ! use video_cards_vmware; then + ewarn "Ignoring USE=xa since VIDEO_CARDS does not contain freedreno, nouveau, or vmware" + fi + fi + + if ! use llvm; then + use opencl && ewarn "Ignoring USE=opencl since USE does not contain llvm" + fi + + if use osmesa && ! use llvm; then + ewarn "OSMesa will be slow without enabling USE=llvm" + fi +} + +python_check_deps() { + python_has_version -b ">=dev-python/mako-0.8.0[${PYTHON_USEDEP}]" || return 1 + if use llvm && use vulkan && use video_cards_intel && use amd64; then + python_has_version -b "dev-python/ply[${PYTHON_USEDEP}]" || return 1 + fi +} + +pkg_setup() { + # warning message for bug 459306 + if use llvm && has_version sys-devel/llvm[!debug=]; then + ewarn "Mismatch between debug USE flags in media-libs/mesa and sys-devel/llvm" + ewarn "detected! This can cause problems. For details, see bug 459306." + fi + + if use video_cards_intel || + use video_cards_radeonsi; then + if kernel_is -ge 5 11 3; then + CONFIG_CHECK="~KCMP" + elif kernel_is -ge 5 11; then + CONFIG_CHECK="~CHECKPOINT_RESTORE" + elif kernel_is -ge 5 10 20; then + CONFIG_CHECK="~KCMP" + else + CONFIG_CHECK="~CHECKPOINT_RESTORE" + fi + linux-info_pkg_setup + fi + + if use llvm; then + llvm_pkg_setup + fi + python-any-r1_pkg_setup +} + +src_prepare() { + default + sed -i -e "/^PLATFORM_SYMBOLS/a '__gentoo_check_ldflags__'," \ + bin/symbols-check.py || die # bug #830728 +} + +multilib_src_configure() { + local emesonargs=() + + local platforms + use X && platforms+="x11" + use wayland && platforms+=",wayland" + emesonargs+=(-Dplatforms=${platforms#,}) + + if use video_cards_intel || + use video_cards_r300 || + use video_cards_r600 || + use video_cards_radeonsi || + use video_cards_nouveau || + use video_cards_vmware; then + emesonargs+=($(meson_use d3d9 gallium-nine)) + else + emesonargs+=(-Dgallium-nine=false) + fi + + if use video_cards_d3d12 || + use video_cards_r600 || + use video_cards_radeonsi || + use video_cards_nouveau; then + emesonargs+=($(meson_feature vaapi gallium-va)) + use vaapi && emesonargs+=( -Dva-libs-path="${EPREFIX}"/usr/$(get_libdir)/va/drivers ) + else + emesonargs+=(-Dgallium-va=disabled) + fi + + if use video_cards_d3d12; then + emesonargs+=($(meson_feature vaapi gallium-d3d12-video)) + fi + + if use video_cards_d3d12 || + use video_cards_r300 || + use video_cards_r600 || + use video_cards_radeonsi || + use video_cards_nouveau; then + emesonargs+=($(meson_feature vdpau gallium-vdpau)) + else + emesonargs+=(-Dgallium-vdpau=disabled) + fi + + if use video_cards_freedreno || + use video_cards_nouveau || + use video_cards_vmware; then + emesonargs+=($(meson_feature xa gallium-xa)) + else + emesonargs+=(-Dgallium-xa=disabled) + fi + + if use video_cards_freedreno || + use video_cards_lima || + use video_cards_panfrost || + use video_cards_v3d || + use video_cards_vc4 || + use video_cards_vivante; then + gallium_enable -- kmsro + fi + + gallium_enable -- swrast + gallium_enable video_cards_freedreno freedreno + gallium_enable video_cards_intel crocus i915 iris + gallium_enable video_cards_lima lima + gallium_enable video_cards_d3d12 d3d12 + gallium_enable video_cards_nouveau nouveau + gallium_enable video_cards_panfrost panfrost + gallium_enable video_cards_v3d v3d + gallium_enable video_cards_vc4 vc4 + gallium_enable video_cards_virgl virgl + gallium_enable video_cards_vivante etnaviv + gallium_enable video_cards_vmware svga + gallium_enable zink zink + + gallium_enable video_cards_r300 r300 + gallium_enable video_cards_r600 r600 + gallium_enable video_cards_radeonsi radeonsi + if ! use video_cards_r300 && \ + ! use video_cards_r600; then + gallium_enable video_cards_radeon r300 r600 + fi + + if use llvm && use opencl; then + PKG_CONFIG_PATH="$(get_llvm_prefix "${LLVM_MAX_SLOT}")/$(get_libdir)/pkgconfig" + # See https://gitlab.freedesktop.org/mesa/mesa/-/blob/main/docs/rusticl.rst + emesonargs+=( + $(meson_native_true gallium-rusticl) + -Drust_std=2021 + ) + fi + + if use vulkan; then + vulkan_enable video_cards_lavapipe swrast + vulkan_enable video_cards_freedreno freedreno + vulkan_enable video_cards_intel intel intel_hasvk + vulkan_enable video_cards_d3d12 microsoft-experimental + vulkan_enable video_cards_radeonsi amd + vulkan_enable video_cards_v3d broadcom + fi + + driver_list() { + local drivers="$(sort -u <<< "${1// /$'\n'}")" + echo "${drivers//$'\n'/,}" + } + + local vulkan_layers + use vulkan && vulkan_layers+="device-select" + use vulkan-overlay && vulkan_layers+=",overlay" + emesonargs+=(-Dvulkan-layers=${vulkan_layers#,}) + + if use llvm && use vulkan && use video_cards_intel && use amd64; then + emesonargs+=(-Dintel-clc=system) + else + emesonargs+=(-Dintel-clc=disabled) + fi + + # Workaround for bug #914905, can drop w/ > 23.3 + append-ldflags $(test-flags-CCLD -Wl,--undefined-version) + + emesonargs+=( + $(meson_use test build-tests) + -Dglx=$(usex X dri disabled) + -Dshared-glapi=enabled + -Ddri3=enabled + -Degl=enabled + -Dexpat=enabled + -Dgbm=enabled + -Dglvnd=true + $(meson_feature gles1) + $(meson_feature gles2) + $(meson_feature llvm) + $(meson_feature lm-sensors lmsensors) + $(meson_use osmesa) + $(meson_use selinux) + $(meson_feature unwind libunwind) + $(meson_feature zstd) + $(meson_use cpu_flags_x86_sse2 sse2) + -Dvalgrind=$(usex valgrind auto disabled) + -Dvideo-codecs=$(usex proprietary-codecs "h264dec,h264enc,h265dec,h265enc,vc1dec" "") + -Dgallium-drivers=$(driver_list "${GALLIUM_DRIVERS[*]}") + -Dvulkan-drivers=$(driver_list "${VULKAN_DRIVERS[*]}") + --buildtype $(usex debug debug plain) + -Db_ndebug=$(usex debug false true) + ) + meson_src_configure +} + +multilib_src_test() { + meson_src_test -t 100 +} + +# $1 - VIDEO_CARDS flag (check skipped for "--") +# other args - names of DRI drivers to enable +gallium_enable() { + if [[ $1 == -- ]] || use $1; then + shift + GALLIUM_DRIVERS+=("$@") + fi +} + +vulkan_enable() { + if [[ $1 == -- ]] || use $1; then + shift + VULKAN_DRIVERS+=("$@") + fi +} diff --git a/media-libs/netpbm/Manifest b/media-libs/netpbm/Manifest index 25a0e138ea0d..27bc1ad96a72 100644 --- a/media-libs/netpbm/Manifest +++ b/media-libs/netpbm/Manifest @@ -2,8 +2,10 @@ AUX make-tarball.sh 1895 BLAKE2B d6311e862d8b2fb10d88a90263f7187c04bde49ff0ecb78 AUX netpbm-10.86.21-build.patch 2319 BLAKE2B b22150c8683790c9ac31abc00b8f3f5b55cc6e990186f506c67496fce774fdfef1ba23843129fd493f8aa3e4ad5f74cfcf1d2388da95225ac2ef19f0c949f425 SHA512 459c54dac19067f2185a02ef812932e8fcb6a73d6267c32578bd3b7d3b12494052e929b24663407ad919e1e98aa2df58ed8e27be3f18eeb2fbe2402e4ff9e629 AUX netpbm-11.0.0-misc-deps.patch 1446 BLAKE2B 721e926a83d50d04d4a407051ee077db5e5bf8fb1ae9aff1ff1d7859cf1bb0d5f74fa1143681b451d36323f93d5e7fa3876e485d6538958e30779cac081df5b8 SHA512 7135533660b15a113df5a38298725f895e8cbd6ac4695eb5f2d40bd214c43cb9d1c261063e0cea162a6ca6071cda5f4e0380d29eefa6af57e7d67ce319fe2216 AUX netpbm-11.1.0-fix-clang-O2.patch 773 BLAKE2B a8d2bef659d384b0f94560fec847d37731315f5cdb67e5474efb596672d146446c6d545caa816d74f9d4c32fe486ce49f8cb55f38e9706bae6b0ba79c0dbbb5e SHA512 0a0049415d5c252603c47325d69ae582bec76ac15f442682ef0a2ff8c5a8cd19e28543644883bde891f2a376a401f43ed923b184112f49c67d295b9215d519de +AUX netpbm-11.2.7-fix-pnmcolormap2-test.patch 7051 BLAKE2B 741d4943b2e9eab1fb0061d6265271df8e25e458c1eb39f50aed8a392edf8369c9f0f3c43fc6ca0b940dd376166c9419c5039ddeaf10487859a7ea9bec4e6075 SHA512 4c7be95b582db27e3ce542b8f53bfdad2e6882b22ccc383aa7ca480cb5ba2a6aa000724dae3c5107efd1071bb87fac0648061dd46b0b75f1072ef05b7e128a68 +AUX netpbm-11.5.2-fix-tests-musl.patch 4779 BLAKE2B 049b20cecdaf40e77c37ad01cfe4e17b8006c3788f47971319e553bfbab760e7e0bb3a970060e74860a7c3326945f5505680519efe7c2feee5fa6ee08ba45202 SHA512 260f4282dcfd6dd0922b62e4c3f217e33d159ab2df779ec0c1df27f16c8075fb77927ce2aadd34c20475d38b7482506758e38b7571df7c3d5a92de9c5cc496d6 DIST netpbm-11.2.7.tar.xz 3780372 BLAKE2B 8a6a75bd0358acf21faa3defd2b3ca886aacd38a28a1f8b65280a9d6c1667102a47efb734fe2ff2dfae38a5d0995b5efaa4b3ec70138bac7ad07e3e6e79c6063 SHA512 3fb00524b958d97304066749d4117b11ce5e23b7c8e08e68bfb5109575cc40a52dbe0f44559e6c0832a4397298efbea50a8ed0b9d2b57e41a09275729574bace DIST netpbm-11.5.2.tar.xz 3781780 BLAKE2B 8d73e6424709f08687c784af88ccefca1f2f7dde256d69fa132005a56ecd30af13abccd5a3a73edf62ae7d302e52ac36201aa0d2490cd8ed759dd3071e1b052a SHA512 2da209e0dd4bb482cc48828fab0297810b152fde7245666a940b74eab713c082eef8e03aacd9c6cb5770e047d96386ad2dbc88f4bdb6d660e333f5eb4cabda4a -EBUILD netpbm-11.2.7.ebuild 6836 BLAKE2B ee8ce8774917ae49808eb5ee8b70f46289f7feac05e9ef304ffe492474d26bb35b0a5d7413293eb25da15c91645b2b49b2aa2c6a90cc164dc6956e0262bf2f11 SHA512 e405ebd3d0a44c96de0b25f8a99f355a49044740159d977d0734946b4ed9f47a660c4977bfd00b996b37f983f4616ce94d19486a0881cb495c714f128d8ea0e3 -EBUILD netpbm-11.5.2.ebuild 6724 BLAKE2B a1fe436c072b05af84091d2964e321372f363d158c639fd345f497b24e3a993b77c63fcbdd0c07a8960f971d17c1e56f80dd082d4a56deefa185ae6c4e95f374 SHA512 9cd9826b92945ed3d6a67e4a9dceeb35f49acac3d4f7e3a1f9052bce3887bcf6dd475fe78037501d320b3d1ff5ade49c034e31b65c9eab6dc76ab9b358acfa1a +EBUILD netpbm-11.2.7.ebuild 6976 BLAKE2B 18225d4d04fe229802a170d569d297f9231b1c0d46c05239ec4221a10da0e4934b01c6ac294e8d972333e0ab90b8b71c5334ea5a4c85fac006c3fe87060f99f7 SHA512 4da684cb71c45de8b76bae5c7f79269bb25fb4b3fac9cc71cde5707923bdddb7e52e527c1e47755df7185e7fd18c1a19ebbbbc94f9e6a171583415735602de2c +EBUILD netpbm-11.5.2.ebuild 6893 BLAKE2B 51e08ff2753647d36c2bf8bafbbc26ab256e94a3bfe83c4c1690f8ab79ef4eae7246b44fa267abba3393b7617f802598e63ca73a0de6158c668bda1440b8d3d7 SHA512 350e2ceb608be231931cfd4044b8b6f7b570e3c212a45cc27a2c91e6991a977ef3bbbb35b5971a793d260ca11dd28365ef1808dd52b0a6bcc3edf331dcf2f14d MISC metadata.xml 424 BLAKE2B 9ccc907d6c15cb1a7d6cfe4679d6fa9f488642948897ca34958a06b439ebcfb912cfb18fa9d93f15f19573aed4bd7083d277151c477410a59cd64b4c9c0446d4 SHA512 a987be2134a44cc916d5a026068219b8ccaa149e577eaf2a53a7802321793129777cc79b069df95ec9320f15279249a5f9d8a61509452ef02effcb6c66cf9e80 diff --git a/media-libs/netpbm/files/netpbm-11.2.7-fix-pnmcolormap2-test.patch b/media-libs/netpbm/files/netpbm-11.2.7-fix-pnmcolormap2-test.patch new file mode 100644 index 000000000000..a3af51371767 --- /dev/null +++ b/media-libs/netpbm/files/netpbm-11.2.7-fix-pnmcolormap2-test.patch @@ -0,0 +1,213 @@ +Backport pnmcolormap2 test from 11.5.x to 11.2.x + +See also https://bugs.gentoo.org/907295 + +--- a/test/pnmcolormap2.test ++++ b/test/pnmcolormap2.test +@@ -5,51 +5,143 @@ + tmpdir=${tmpdir:-/tmp} + map=${tmpdir}/map.ppm + +-echo "Test. Should print 'match' eight times." +-# Threshold values (targetN=xx.xx) here were produced by calculating +-# the S/N ratio with reduced colors. ++echo "Test. Should print 'match' eighteen times." ++ ++# Threshold values (tgtN=xx.xx) were produced by calculating ++# the S/N ratio when the original image is compared against a ++# reference image with fewer colors than the target output image. + + # colors in following tests / colors for calculating threshold +-# 100 / 90 +-# 200 / 180 +-# 30 / 25 ++# 256 / 224 ++# 128 / 96 -splitspread ++# 128 / 108 other ++# 64 / 44 -center (default) ++# 64 / 48 -splitspread ++# 64 / 56 other ++ ++# -center ++echo pnmcolormap 256 ++tgt1=37.19; tgt2=37.86; tgt3=37.77 ++pnmcolormap 256 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap 128 ++tgt1=34.46; tgt2=35.61; tgt3=34.97 ++pnmcolormap 128 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap 64 ++tgt1=30.30; tgt2=33.10; tgt3=31.74 ++pnmcolormap 64 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -meancolor 256 ++tgt1=38.36; tgt2=38.63; tgt3=38.95 ++pnmcolormap -meancolor 256 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -meancolor 128 ++tgt1=35.86; tgt2=37.17; tgt3=36.65 ++pnmcolormap -meancolor 128 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -meancolor 64 ++tgt1=33.64; tgt2=34.92; tgt3=34.44 ++pnmcolormap -meancolor 64 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -meanpixel 256 ++tgt1=38.40; tgt2=38.65; tgt3=38.90 ++pnmcolormap -meanpixel 256 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -meanpixel 128 ++tgt1=35.75; tgt2=37.13; tgt3=36.69 ++pnmcolormap -meanpixel 128 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -meanpixel 64 ++tgt1=33.75; tgt2=34.79; tgt3=34.53 ++pnmcolormap -meanpixel 64 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} ++ ++echo pnmcolormap -spreadluminosity 256 ++tgt1=36.82; tgt2=36.87; tgt3=37.25 ++pnmcolormap -spreadluminosity 256 testimg.ppm > ${map} ++pnmremap -mapfile=${map} testimg.ppm |\ ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - ++rm ${map} + +-pnmcolormap 100 testimg.ppm > ${map} ++echo pnmcolormap -spreadluminosity 128 ++tgt1=34.61; tgt2=33.40; tgt3=34.66 ++pnmcolormap -spreadluminosity 128 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=33.42 -target2=35.14 -target3=34.35 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap -meancolor 100 testimg.ppm > ${map} ++echo pnmcolormap -spreadluminosity 64 ++tgt1=32.35; tgt2=30.23; tgt3=32.35 ++pnmcolormap -spreadluminosity 64 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=34.91 -target2=36.86 -target3=35.84 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap -meanpixel 100 testimg.ppm > ${map} ++echo pnmcolormap -splitcolorct 256 ++tgt1=37.55; tgt2=38.37; tgt3=38.04 ++pnmcolormap -splitcolorct 256 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=34.95 -target2=36.77 -target3=35.81 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap -spreadluminosity 100 testimg.ppm > ${map} ++echo pnmcolormap -splitcolorct 128 ++tgt1=34.84; tgt2=35.72; tgt3=34.64 ++pnmcolormap -splitcolorct 128 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=33.71 -target2=32.91 -target3=33.93 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap -splitcolorct 100 testimg.ppm > ${map} ++echo pnmcolormap -splitcolorct 64 ++tgt1=31.56; tgt2=33.74; tgt3=32.93 ++pnmcolormap -splitcolorct 64 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=33.97 -target2=35.34 -target3=34.23 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap -splitspread 100 testimg.ppm > ${map} ++echo pnmcolormap -splitspread 256 ++tgt1=35.18; tgt2=37.26; tgt3=36.17 ++pnmcolormap -splitspread 256 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=32.98 -target2=35.06 -target3=33.19 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap 200 testimg.ppm > ${map} ++echo pnmcolormap -splitspread 128 ++tgt1=33.18; tgt2=35.58; tgt3=33.71 ++pnmcolormap -splitspread 128 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=36.14 -target2=36.87 -target3=36.79 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} + +-pnmcolormap 30 testimg.ppm > ${map} ++echo pnmcolormap -splitspread 64 ++tgt1=31.27; tgt2=33.03; tgt3=30.97 ++pnmcolormap -splitspread 64 testimg.ppm > ${map} + pnmremap -mapfile=${map} testimg.ppm |\ +- pnmpsnr -target1=28.53 -target2=31.62 -target3=29.99 testimg.ppm - ++pnmpsnr -target1=${tgt1} -target2=${tgt2} -target3=${tgt3} testimg.ppm - + rm ${map} +--- a/test/pnmcolormap2.ok ++++ b/test/pnmcolormap2.ok +@@ -1,9 +1,37 @@ +-Test. Should print 'match' eight times. ++Test. Should print 'match' eighteen times. ++pnmcolormap 256 + match ++pnmcolormap 128 + match ++pnmcolormap 64 + match ++pnmcolormap -meancolor 256 + match ++pnmcolormap -meancolor 128 + match ++pnmcolormap -meancolor 64 + match ++pnmcolormap -meanpixel 256 + match ++pnmcolormap -meanpixel 128 ++match ++pnmcolormap -meanpixel 64 ++match ++pnmcolormap -spreadluminosity 256 ++match ++pnmcolormap -spreadluminosity 128 ++match ++pnmcolormap -spreadluminosity 64 ++match ++pnmcolormap -splitcolorct 256 ++match ++pnmcolormap -splitcolorct 128 ++match ++pnmcolormap -splitcolorct 64 ++match ++pnmcolormap -splitspread 256 ++match ++pnmcolormap -splitspread 128 ++match ++pnmcolormap -splitspread 64 + match diff --git a/media-libs/netpbm/files/netpbm-11.5.2-fix-tests-musl.patch b/media-libs/netpbm/files/netpbm-11.5.2-fix-tests-musl.patch new file mode 100644 index 000000000000..4d8bd6c3b74d --- /dev/null +++ b/media-libs/netpbm/files/netpbm-11.5.2-fix-tests-musl.patch @@ -0,0 +1,157 @@ +Some tests are broken on musl. + +https://sourceforge.net/p/netpbm/code/4843/ +pnmindex, ppmtomitsu tests that don't use pnmcolormap + +So far, this only fixed ppmtomitsu. + +See also https://bugs.gentoo.org/907295 + +--- a/test/pnmindex.ok ++++ b/test/pnmindex.ok +@@ -7,12 +7,18 @@ + 3099638253 5290 + Test 4. Should print 1397700642 3160 + 1397700642 3160 +-Test 5. Should print 2303488589 28514 +-2303488589 28514 +-Test 6. Should print 1706277976 100455 +-1706277976 100455 +-Test 7. Should print 801388440 100455 ++Test 5. Should print 243472565 28514 ++243472565 28514 ++Test 6. Should print 801388440 100455 + 801388440 100455 ++Test 7. Should print 256 twice ++256 ++256 ++Test 8. Should print 100 twice ++100 ++100 ++Test 9. Should print match ++match + Test Invalid + Expected failure 1 (no output) + Expected failure 2 (no output) +--- a/test/pnmindex.test ++++ b/test/pnmindex.test +@@ -3,6 +3,9 @@ + # Also requires: pamcat pamscale pbmtext pnmcolormap pnmindex + # Also requires: pnminvert pnmquant pnmremap + ++tmpdir=${tmpdir:-/tmp} ++pnmindex256_ppm=${tmpdir}/pnmindex256.ppm ++ + echo "Test 1. Should print 3391481002 889" + pnmindex maze.pbm | cksum + +@@ -17,18 +20,28 @@ + pnmindex -size 20 -across=3 testgrid.pbm testgrid.pbm testgrid.pbm \ + testgrid.pbm testgrid.pbm testgrid.pbm | cksum + +-echo "Test 5. Should print 2303488589 28514" +-pnmindex testimg.ppm | cksum ++echo "Test 5. Should print 243472565 28514" ++pnmindex -noquant testimg.ppm | cksum + +-echo "Test 6. Should print 1706277976 100455" +-pnmindex -size 50 -across=2 testimg.ppm testimg.ppm testimg.ppm \ +- testimg.ppm testimg.ppm testimg.ppm | cksum +- +-echo "Test 7. Should print 801388440 100455" ++echo "Test 6. Should print 801388440 100455" + pnmindex -size 50 -across=2 -noquant testimg.ppm testimg.ppm testimg.ppm \ +- testimg.ppm testimg.ppm testimg.ppm | cksum ++ testimg.ppm testimg.ppm testimg.ppm | tee ${pnmindex256_ppm} | cksum + ++echo "Test 7. Should print 256 twice" ++pnmindex testimg.ppm | ppmhist -nomap -noheader | wc -l ++pnmindex -colors 256 testimg.ppm | ppmhist -nomap -noheader | wc -l + ++echo "Test 8. Should print 100 twice" ++pnmindex -colors 100 testimg.ppm | ppmhist -nomap -noheader | wc -l ++pnmindex -colors 100 testimg.ppm testimg.ppm | ppmhist -nomap -noheader | wc -l ++ ++ ++echo "Test 9. Should print match" ++pnmindex -size 50 -across=2 -quant -colors=256 testimg.ppm testimg.ppm testimg.ppm \ ++ testimg.ppm testimg.ppm testimg.ppm |\ ++ pnmpsnr -rgb -target1=41.31 -target2=40.76 -target3=40.71 ${pnmindex256_ppm} - ++ ++ + echo "Test Invalid" + + . ${srcdir}/test-invalid.inc +--- a/test/ppmtomitsu.ok ++++ b/test/ppmtomitsu.ok +@@ -1,9 +1,9 @@ +-Test 0. Should print 458455366 101484 +-458455366 101484 ++Test 0. Should print 668243897 101532 ++668243897 101532 + Test 1. Should print 3110813682 101562 + 3110813682 101562 +-Test 2. Should print 4168174994 34399 +-4168174994 34399 ++Test 2. Should print 825518840 34209 ++825518840 34209 + Test 3. Should print 3201293405 310 + 3201293405 310 + Test 4. Should print 3354679572 752 +@@ -10,5 +10,5 @@ + 3354679572 752 + Test 5. Should print 3999654426 101549 + 3999654426 101549 +-Test 6. Should print 4201246884 101549 +-4201246884 101549 ++Test 6. Should print 3103038403 101549 ++3103038403 101549 +--- a/test/ppmtomitsu.test ++++ b/test/ppmtomitsu.test +@@ -1,31 +1,31 @@ + #! /bin/sh + # This script tests: ppmtomitsu +-# Also requires: pnmcolormap pnmremap ++# Also requires: pamseq pamdepth + + tmpdir=${tmpdir:-/tmp} +-testimg100_ppm=${tmpdir}/testimg100.ppm ++testimg216_ppm=${tmpdir}/testimg216.ppm + +-echo "Test 0. Should print 458455366 101484" +-# equivalent to: Pnmquant 100 testimg.ppm +-pnmcolormap 100 testimg.ppm | pnmremap -nofloyd -mapfile=- testimg.ppm |\ +- tee ${testimg100_ppm} | cksum ++echo "Test 0. Should print 668243897 101532" + ++pamseq 3 5 -tupletype=RGB | pamdepth 255 | pnmremap -nofloyd -mapfile=- testimg.ppm |\ ++ tee ${testimg216_ppm} | cksum ++ + echo "Test 1. Should print 3110813682 101562" +-ppmtomitsu testimg.ppm | cksum ++ppmtomitsu testimg.ppm | cksum + +-echo "Test 2. Should print 4168174994 34399" +-ppmtomitsu ${testimg100_ppm} | cksum ++echo "Test 2. Should print 825518840 34209" ++ppmtomitsu ${testimg216_ppm} | cksum + + echo "Test 3. Should print 3201293405 310" +-ppmtomitsu testgrid.pbm | cksum ++ppmtomitsu testgrid.pbm | cksum + + echo "Test 4. Should print 3354679572 752" +-ppmtomitsu -tiny testgrid.pbm | cksum ++ppmtomitsu -tiny testgrid.pbm | cksum + + echo "Test 5. Should print 3999654426 101549" +-ppmtomitsu -tiny testimg.ppm | cksum ++ppmtomitsu -tiny testimg.ppm | cksum + +-echo "Test 6. Should print 4201246884 101549" +-ppmtomitsu -tiny ${testimg100_ppm} | cksum ++echo "Test 6. Should print 3103038403 101549" ++ppmtomitsu -tiny ${testimg216_ppm} | cksum + +-rm ${testimg100_ppm} ++rm ${testimg216_ppm} diff --git a/media-libs/netpbm/netpbm-11.2.7.ebuild b/media-libs/netpbm/netpbm-11.2.7.ebuild index 3afe4523512a..df9c2909f438 100644 --- a/media-libs/netpbm/netpbm-11.2.7.ebuild +++ b/media-libs/netpbm/netpbm-11.2.7.ebuild @@ -57,6 +57,7 @@ PATCHES=( "${FILESDIR}"/netpbm-10.86.21-build.patch "${FILESDIR}"/netpbm-11.0.0-misc-deps.patch "${FILESDIR}"/netpbm-11.1.0-fix-clang-O2.patch + "${FILESDIR}"/netpbm-11.2.7-fix-pnmcolormap2-test.patch ) netpbm_libtype() { @@ -160,10 +161,13 @@ src_prepare() { fi # this test requires LC_ALL=en_US.iso88591, not available on musl + # ppmpat-random is broken on musl + # bug #907295 if use elibc_musl; then sed -i \ -e 's:pbmtext-iso88591.*::' \ - test/Test-Order || die + -e 's:ppmpat-random.*::' \ + -i test/Test-Order || die fi } diff --git a/media-libs/netpbm/netpbm-11.5.2.ebuild b/media-libs/netpbm/netpbm-11.5.2.ebuild index 742eedc19d7d..0a74a2fd9cea 100644 --- a/media-libs/netpbm/netpbm-11.5.2.ebuild +++ b/media-libs/netpbm/netpbm-11.5.2.ebuild @@ -57,6 +57,7 @@ PATCHES=( "${FILESDIR}"/netpbm-10.86.21-build.patch "${FILESDIR}"/netpbm-11.0.0-misc-deps.patch "${FILESDIR}"/netpbm-11.1.0-fix-clang-O2.patch + "${FILESDIR}"/netpbm-11.5.2-fix-tests-musl.patch ) netpbm_libtype() { @@ -155,9 +156,13 @@ src_prepare() { fi # this test requires LC_ALL=en_US.iso88591, not available on musl + # ppmpat-random and pnmindex are broken on musl + # bug #907295 if use elibc_musl; then sed \ -e 's:pbmtext-iso88591.*::' \ + -e 's:ppmpat-random.*::' \ + -e 's:pnmindex.*::' \ -i test/Test-Order || die fi } -- cgit v1.2.3