You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
65 lines
1.4 KiB
65 lines
1.4 KiB
1 year ago
|
# Copyright 2022-2023 Gentoo Authors
|
||
|
# Distributed under the terms of the GNU General Public License v2
|
||
|
|
||
|
EAPI=8
|
||
|
|
||
|
PYTHON_COMPAT=( python3_{9..11} )
|
||
1 year ago
|
inherit fortran-2 cmake python-single-r1
|
||
1 year ago
|
|
||
|
MYPN=HepMC3
|
||
|
MYP=${MYPN}-${PV}
|
||
|
|
||
|
DESCRIPTION="Event Record for Monte Carlo Generators"
|
||
|
HOMEPAGE="https://hepmc.web.cern.ch/hepmc/"
|
||
|
|
||
|
if [[ ${PV} == 9999 ]]; then
|
||
|
inherit git-r3
|
||
|
EGIT_REPO_URI="https://gitlab.cern.ch/hepmc/HepMC3"
|
||
|
else
|
||
1 year ago
|
SRC_URI="https://hepmc.web.cern.ch/hepmc/releases/${MYP}.tar.gz"
|
||
|
S="${WORKDIR}/${MYP}"
|
||
1 year ago
|
KEYWORDS="~amd64 ~x86"
|
||
|
fi
|
||
|
|
||
|
LICENSE="GPL-3+"
|
||
|
SLOT="3"
|
||
|
IUSE="doc test examples python root"
|
||
|
RESTRICT="!test? ( test )"
|
||
|
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
|
||
|
|
||
1 year ago
|
RDEPEND="
|
||
|
python? (
|
||
|
${PYTHON_DEPS}
|
||
|
$(python_gen_cond_dep '
|
||
|
dev-python/numpy[${PYTHON_USEDEP}]
|
||
|
')
|
||
|
)
|
||
|
"
|
||
1 year ago
|
DEPEND="${RDEPEND}"
|
||
|
BDEPEND="
|
||
|
root? ( sci-physics/root:= )
|
||
|
doc? (
|
||
|
app-doc/doxygen[dot]
|
||
|
dev-texlive/texlive-latex
|
||
|
dev-texlive/texlive-latexextra
|
||
|
dev-texlive/texlive-latexrecommended
|
||
|
)
|
||
|
"
|
||
|
|
||
|
src_configure() {
|
||
|
local mycmakeargs=(
|
||
|
-DHEPMC3_ENABLE_ROOTIO=$(usex root ON OFF)
|
||
|
-DHEPMC3_ENABLE_PYTHON=$(usex python ON OFF)
|
||
|
-DHEPMC3_ENABLE_TEST=$(usex test ON OFF)
|
||
|
-DHEPMC3_BUILD_DOCS=$(usex doc ON OFF)
|
||
|
-DHEPMC3_BUILD_EXAMPLES=$(usex examples ON OFF)
|
||
|
)
|
||
|
cmake_src_configure
|
||
|
}
|
||
|
|
||
|
src_install() {
|
||
|
cmake_src_install
|
||
|
use examples && docompress -x /usr/share/doc/${PF}/examples
|
||
1 year ago
|
use python && python_optimize
|
||
1 year ago
|
}
|