diff --git a/sci-physics/hoppet/Manifest b/sci-physics/hoppet/Manifest index cc73bfc3b12..a4e3d96ba2c 100644 --- a/sci-physics/hoppet/Manifest +++ b/sci-physics/hoppet/Manifest @@ -1 +1,2 @@ DIST hoppet-1.2.0.tgz 575911 BLAKE2B 4d4dc1874b45b7237384ad3955808b5f4995c86b4d44165ef0c4d8b1da21880cdd1a3f1f1537f02ad7928baef5207e950be411465989ab876bcb806f355725cf SHA512 65ceb170cd417f229f8a974aa995138b8ee7ea5ef04538a5382b353181951e9d4489045234cd45c1ea8f88a5faf4755e3a0e246065711f137676bbf726a29f1f +DIST hoppet-2.0.0.gh.tar.gz 13568415 BLAKE2B 4766a649a1ca8162e2a8ed5cc49425add6fe4da244e3b69033da02af5942185bc7c125addce830918bcf7d7f3b3d276b74acfa22da3cbab4c6e3b1dc082a2ca4 SHA512 5c70a00b47c73f9cf3c0018d7217a5cc9ae3f218985eaebde397360a9f7e080306b22dbdcce4b7c190aa44975c7fc3761e9a15f1455363fda2a401daf41241b8 diff --git a/sci-physics/hoppet/hoppet-2.0.0.ebuild b/sci-physics/hoppet/hoppet-2.0.0.ebuild new file mode 100644 index 00000000000..479e9f3f317 --- /dev/null +++ b/sci-physics/hoppet/hoppet-2.0.0.ebuild @@ -0,0 +1,66 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{11..13} ) + +inherit cmake fortran-2 python-single-r1 + +MY_PV=${PV//_/-} +MY_P=${P//_/-} + +DESCRIPTION="Higher Order Perturbative Parton Evolution Toolkit" +HOMEPAGE=" + https://hoppet.hepforge.org/ + https://github.com/gavinsalam/hoppet +" +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/hoppet-code/hoppet" + EGIT_BRANCH="master" +else + SRC_URI="https://github.com/hoppet-code/hoppet/archive/refs/tags/${MY_P}.tar.gz -> ${P}.gh.tar.gz" + S="${WORKDIR}/${PN}-${MY_P}" + KEYWORDS="~amd64" +fi + +SLOT="0" +LICENSE="GPL-3+" +IUSE="exact-coef examples python test" +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" +RESTRICT="!test? ( test )" +DEPEND=" + python? ( + ${PYTHON_DEPS} + dev-lang/swig + ) +" +RDEPEND="${DEPEND}" + +pkg_setup() { + use python && python-single-r1_pkg_setup + fortran-2_pkg_setup +} + +src_configure() { + local mycmakeargs=( + -DHOPPET_USE_EXACT_COEF=$(usex exact-coef) + -DHOPPET_BUILD_PYINTERFACE=$(usex python) + -DHOPPET_BUILD_EXAMPLES=$(usex examples) + -DHOPPET_ENABLE_TESTING=$(usex test) + -DHOPPET_BUILD_BENCHMARK=OFF + -DHOPPET_ENABLE_DEBUG=OFF + ) + cmake_src_configure +} + +src_install() { + cmake_src_install + if use examples; then + docinto examples + dodoc -r example/. + docompress -x /usr/share/doc/${PF}/examples + fi + find "${ED}" -name '*.la' -delete || die +} diff --git a/sci-physics/hoppet/hoppet-9999.ebuild b/sci-physics/hoppet/hoppet-9999.ebuild new file mode 100644 index 00000000000..479e9f3f317 --- /dev/null +++ b/sci-physics/hoppet/hoppet-9999.ebuild @@ -0,0 +1,66 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{11..13} ) + +inherit cmake fortran-2 python-single-r1 + +MY_PV=${PV//_/-} +MY_P=${P//_/-} + +DESCRIPTION="Higher Order Perturbative Parton Evolution Toolkit" +HOMEPAGE=" + https://hoppet.hepforge.org/ + https://github.com/gavinsalam/hoppet +" +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/hoppet-code/hoppet" + EGIT_BRANCH="master" +else + SRC_URI="https://github.com/hoppet-code/hoppet/archive/refs/tags/${MY_P}.tar.gz -> ${P}.gh.tar.gz" + S="${WORKDIR}/${PN}-${MY_P}" + KEYWORDS="~amd64" +fi + +SLOT="0" +LICENSE="GPL-3+" +IUSE="exact-coef examples python test" +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" +RESTRICT="!test? ( test )" +DEPEND=" + python? ( + ${PYTHON_DEPS} + dev-lang/swig + ) +" +RDEPEND="${DEPEND}" + +pkg_setup() { + use python && python-single-r1_pkg_setup + fortran-2_pkg_setup +} + +src_configure() { + local mycmakeargs=( + -DHOPPET_USE_EXACT_COEF=$(usex exact-coef) + -DHOPPET_BUILD_PYINTERFACE=$(usex python) + -DHOPPET_BUILD_EXAMPLES=$(usex examples) + -DHOPPET_ENABLE_TESTING=$(usex test) + -DHOPPET_BUILD_BENCHMARK=OFF + -DHOPPET_ENABLE_DEBUG=OFF + ) + cmake_src_configure +} + +src_install() { + cmake_src_install + if use examples; then + docinto examples + dodoc -r example/. + docompress -x /usr/share/doc/${PF}/examples + fi + find "${ED}" -name '*.la' -delete || die +} diff --git a/sci-physics/hoppet/metadata.xml b/sci-physics/hoppet/metadata.xml index 85cbe5c6286..5d1d935fa9a 100644 --- a/sci-physics/hoppet/metadata.xml +++ b/sci-physics/hoppet/metadata.xml @@ -14,6 +14,9 @@ HOPPET is a Fortran 95 package for carrying out DGLAP evolution and other common manipulations of parton distribution functions (PDFs). - gavinsalam/hoppet + hoppet-code/hoppet + + Use exact coefficient functions +