diff --git a/sci-physics/yoda/Manifest b/sci-physics/yoda/Manifest index 622995ca798af..31e528c852eb7 100644 --- a/sci-physics/yoda/Manifest +++ b/sci-physics/yoda/Manifest @@ -2,3 +2,4 @@ DIST YODA-1.9.10.tar.bz2 1278729 BLAKE2B f6ae9b579d79b6be62e9644e327f0b449882c0f DIST YODA-1.9.5.tar.bz2 1077442 BLAKE2B 010ab725c57dfab8160e0304d461dc44c140d1ce234f3b70834ee58b8f269159529122095a94e6b79ef752612a6659a17e1874fda2941cfbcec1f53802916b6a SHA512 46e30b33d369f5d28ec228b71eaa298f3010cc06fe568785c74bbaf3d7468c26738cc2ee40da9bcc54d978f394187a2ee9289197283c86a3358583a3c0ecd247 DIST YODA-2.0.2.tar.bz2 1869694 BLAKE2B cb5628bbfe0ecdd59073ff49496cd79ff6df95d94bbb36463c9de2cd6f576d0a8b8b4c1373f7f06354bb1ceb190a461cf61b4367085c44c44c5fb3982061a3ba SHA512 214f2caa2610a959588b1440fc66e238023829ca2fe7cf0e2f818891dd8db62fc0db288ac03c885c26c8de2a8813cd08deb53cefa0fb7d659b9b129d94d707c7 DIST YODA-2.1.0.tar.bz2 1935119 BLAKE2B fe8e50759dd4191fb5f1ea8c20ff5a2bdaf444c81234b635c9566ac6f8248991eb998a31a0504bae1ac6ec47f8735ce263382ccdd800f201072cfe4c1d44dc57 SHA512 e17ec7e64082c835e98e4c03eb9d3128a2345b999d3d3a30b7b5b4b34afafd6d51c164011c5357c6fc38b35a511d8f98183de0d9edb13e32a73d5024733b02fc +DIST YODA-2.1.1.tar.bz2 1023366 BLAKE2B de09ddfaddf365e35c83ba8e514638b91180c251bedb3009252be7bb2c08dbe64f98bea54dad3867906f20dac633c53182da7395d765e3a18cfa1157b7388222 SHA512 961426b17abbdee271a156965bb12a502a57e844e5ea4e5e7d201629aaf0b586684f99a71cba61de19fafc209cfbd653ff2601bc4915b2727cc36400c49ff5c8 diff --git a/sci-physics/yoda/files/yoda-2.1.1-testpaths.patch b/sci-physics/yoda/files/yoda-2.1.1-testpaths.patch new file mode 100644 index 0000000000000..4e6eb8f821c0a --- /dev/null +++ b/sci-physics/yoda/files/yoda-2.1.1-testpaths.patch @@ -0,0 +1,26 @@ +https://gitlab.com/hepcedar/yoda/-/merge_requests/362 +From 9a47654ff88dffc94cefa89b52819941364f1259 Mon Sep 17 00:00:00 2001 +From: Alexander Puck Neuwirth +Date: Tue, 19 Aug 2025 09:28:35 +0000 +Subject: [PATCH] Allow lib64 in testpaths too + +--- + tests/TestPaths.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/TestPaths.cc b/tests/TestPaths.cc +index 5c9ec5ce3..13cf2407a 100644 +--- a/tests/TestPaths.cc ++++ b/tests/TestPaths.cc +@@ -9,7 +9,7 @@ using namespace YODA; + auto testPaths() { + + const std::string libPath = getLibPath(); +- if ( !Utils::endswith(libPath, "/lib") ) return CHECK_TEST_RES(false); ++ if ( !Utils::endswith(libPath, "/lib") && !Utils::endswith(libPath, "/lib64") ) return CHECK_TEST_RES(false); + + const std::string dataPath = getDataPath(); + if ( !Utils::endswith(dataPath, "/share/YODA") ) return CHECK_TEST_RES(false); +-- +GitLab + diff --git a/sci-physics/yoda/files/yoda-2.1.1-testwriter.patch b/sci-physics/yoda/files/yoda-2.1.1-testwriter.patch new file mode 100644 index 0000000000000..3639923f40a01 --- /dev/null +++ b/sci-physics/yoda/files/yoda-2.1.1-testwriter.patch @@ -0,0 +1,42 @@ +https://gitlab.com/hepcedar/yoda/-/merge_requests/363 +From 9ea39901ed84e1b2c76c08830cc2df927216eda2 Mon Sep 17 00:00:00 2001 +From: Christian Gutschow +Date: Tue, 19 Aug 2025 11:47:50 +0100 +Subject: [PATCH] add H5 protection + +--- + include/YODA/Writer.h | 2 +- + tests/TestWriter.cc | 2 ++ + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/include/YODA/Writer.h b/include/YODA/Writer.h +index 0372533e8..5f9c0e5e6 100644 +--- a/include/YODA/Writer.h ++++ b/include/YODA/Writer.h +@@ -9,8 +9,8 @@ + #include "YODA/AnalysisObject.h" + #include "YODA/Utils/Traits.h" + +-#ifdef HAVE_HDF5 + #include ++#ifdef HAVE_HDF5 + #ifdef WITH_HIGHFIVE + #include + #else +diff --git a/tests/TestWriter.cc b/tests/TestWriter.cc +index fc0bd0792..8750f225e 100644 +--- a/tests/TestWriter.cc ++++ b/tests/TestWriter.cc +@@ -5,7 +5,9 @@ + #include "YODA/Scatter.h" + #include "YODA/WriterYODA.h" + #include "YODA/WriterYODA1.h" ++#ifdef HAVE_HDF5 + #include "YODA/WriterH5.h" ++#endif + #include + #include + #include +-- +GitLab + diff --git a/sci-physics/yoda/yoda-2.1.1.ebuild b/sci-physics/yoda/yoda-2.1.1.ebuild new file mode 100644 index 0000000000000..2b0f536b15f79 --- /dev/null +++ b/sci-physics/yoda/yoda-2.1.1.ebuild @@ -0,0 +1,114 @@ +# Copyright 2022-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{11..13} ) + +inherit bash-completion-r1 python-single-r1 optfeature autotools + +DESCRIPTION="Yet more Objects for (High Energy Physics) Data Analysis" +HOMEPAGE="https://yoda.hepforge.org/" + +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://gitlab.com/hepcedar/yoda" + EGIT_BRANCH="main" +else + SRC_URI="https://yoda.hepforge.org/downloads?f=${P^^}.tar.bz2 -> ${P^^}.tar.bz2" + S="${WORKDIR}/${P^^}" + KEYWORDS="~amd64" +fi + +LICENSE="GPL-3" +SLOT="0/${PV}" +IUSE="test +highfive +python +zlib" +RESTRICT="!test? ( test )" +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +RDEPEND=" + dev-cpp/yaml-cpp + highfive? ( + sci-libs/HighFive + sci-libs/hdf5[cxx] + ) + python? ( ${PYTHON_DEPS} ) + zlib? ( sys-libs/zlib ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + python? ( + $(python_gen_cond_dep ' + >=dev-python/cython-0.29.24[${PYTHON_USEDEP}] + ') + test? ( + $(python_gen_cond_dep ' + dev-python/numpy[${PYTHON_USEDEP}] + dev-python/matplotlib[${PYTHON_USEDEP}] + ') + ) + ) +" + +PATCHES=( + "${FILESDIR}"/${P}-testpaths.patch + "${FILESDIR}"/${P}-testwriter.patch +) + +pkg_setup() { + use python && python-single-r1_pkg_setup +} + +src_prepare() { + default + # reconf due to 9999 version + eautoreconf +} + +src_configure() { + # we need to use the prefix cython here + econf --disable-static \ + --with-yaml-cpp="${EPREFIX}/usr" \ + $(use_enable highfive h5) \ + $(use_with highfive highfive "${ESYSROOT}/usr") \ + $(use_enable python pyext) \ + $(use_with zlib zlib "${ESYSROOT}/usr") \ + $(usex python CYTHON="${ESYSROOT}/usr/bin/cython") +} + +src_test() { + # PYTESTS and SHTESTS both require python tools + if use python; then + emake check + else + emake check PYTESTS= SHTESTS= NO_PYTHON=1 + fi +} + +src_install() { + default + + if use python ; then + newbashcomp "${ED}"/etc/bash_completion.d/${PN}-completion ${PN}-config + bashcomp_alias ${PN}-config \ + ${PN}ls \ + ${PN}diff \ + ${PN}merge \ + ${PN}stack \ + ${PN}scale \ + ${PN}plot \ + ${PN}envelope \ + ${PN}cnv \ + ${PN}2root + rm "${ED}"/etc/bash_completion.d/${PN}-completion || die + python_optimize + fi + + find "${ED}" -name '*.la' -delete || die +} + +pkg_postinst() { + optfeature "root conversion" sci-physics/root + optfeature "latex plotting support" virtual/latex-base + optfeature "python plotting support" dev-python/matplotlib +}