summaryrefslogtreecommitdiff
path: root/sci-physics/geant-vmc
diff options
context:
space:
mode:
Diffstat (limited to 'sci-physics/geant-vmc')
-rw-r--r--sci-physics/geant-vmc/Manifest6
-rw-r--r--sci-physics/geant-vmc/files/geant-vmc-4.4.0-fix-cflags.patch15
-rw-r--r--sci-physics/geant-vmc/geant-vmc-4.3.6-r1.ebuild89
-rw-r--r--sci-physics/geant-vmc/geant-vmc-4.4.0.ebuild96
-rw-r--r--sci-physics/geant-vmc/geant-vmc-9999.ebuild21
5 files changed, 216 insertions, 11 deletions
diff --git a/sci-physics/geant-vmc/Manifest b/sci-physics/geant-vmc/Manifest
index 850a112f232c..3ec595c84f0e 100644
--- a/sci-physics/geant-vmc/Manifest
+++ b/sci-physics/geant-vmc/Manifest
@@ -1,4 +1,8 @@
+AUX geant-vmc-4.4.0-fix-cflags.patch 661 BLAKE2B 121054bdcf8dfae328334221cc85c7d117a8dd9b0b096499ea07938bb05f303759c6478c2187f36e7b4ba22f4e1f0935d980802ce5195c1d2d9b5202d240b683 SHA512 7c6b7c253088a780101c51ac9a055fe79f65d78996206fce77d9e70a558e2b5b222eee4ccba689e68effc429cb8b2d41c6021fe4bead7d44f52daa1820a308a2
DIST geant4_vmc.3.6.tar.gz 1017407 BLAKE2B f386ea49843abedbed16ba1d12a10ae4165123fb0f7842482c416becf4141bc15360be1038626ce40f96a9dbb15d27116cd2fbd46d74b856d5a9391d073784a5 SHA512 eaf8626a3702149a1c5be4adff7843ef828da8024aafb8de489dd6b55b4ee05850581318d01032a4008767ad4e2fc0fde23e1aa5c751693e902d51ce9ad3d1df
+DIST geant4_vmc.4.0.tar.gz 7118838 BLAKE2B 5edbd13adeeb560188deb54c1f5d52fda371dd5f3dc04d676bcaf7edad0bbf8eb573d6345e5c3626b5b64c229d49b7f02aafec77a2587e525cf3f407444391b5 SHA512 faf5fed17b317399b97f77ff1c2a1bf1cead8f0b02a3a89244f01f8ae04ce621763e52b40000e481b3826796bb4d94216368d2e3c98a62f02048c5979f4ee648
+EBUILD geant-vmc-4.3.6-r1.ebuild 2075 BLAKE2B 1decdfb155c65f5317abb59e2d46b175973aedb0b33398eb3c39e71ce997e78a4629a53685880f5d9c7e06a4f03f3c35e5fa8c0677ce735147ca43b00ff65a4d SHA512 d08b40f5f13c8cb498eec3991e71446ae8051145b63a3366d0f5cb0c1360bf8ed8dcef9292f8bae8e4066bdc14b93ee385cf4db501dcd14f7e9957e64ead2d93
EBUILD geant-vmc-4.3.6.ebuild 2100 BLAKE2B 50f6b40d3f35d0835c4d9872055930cabe73ba2bdd03a0ee35e9b85697dc82f304659a55caf0fd5b5ecd6a2db3be13b512b6d1d08be86ef4a7ab8cca86c28460 SHA512 88de1fd5ff56a131daafb174968a93d67d89590e64fc709a8ecb7dd29b312f28a6984592df4451dfc900cc084715845e93f79745dc745d28b5b95a42e9b2d03a
-EBUILD geant-vmc-9999.ebuild 2100 BLAKE2B 50f6b40d3f35d0835c4d9872055930cabe73ba2bdd03a0ee35e9b85697dc82f304659a55caf0fd5b5ecd6a2db3be13b512b6d1d08be86ef4a7ab8cca86c28460 SHA512 88de1fd5ff56a131daafb174968a93d67d89590e64fc709a8ecb7dd29b312f28a6984592df4451dfc900cc084715845e93f79745dc745d28b5b95a42e9b2d03a
+EBUILD geant-vmc-4.4.0.ebuild 2466 BLAKE2B 2b4be636cbbd9431026ef6e81dc7d639ba2b5351c542cf0a0a121a8f87915e4564e25fb820c639a227eaa88b621519b19ed43344b08e6d1273fd8bea5ab830d5 SHA512 d897e2a35bd35ec79597c2fd1ef178cdb054fe3d8818c37752ccc0375503f23faa676040475e5c2b39dbe450a6e5a18b80b7a3a183d52ac26decb2a30e8bb9fa
+EBUILD geant-vmc-9999.ebuild 2111 BLAKE2B be011b3c4a43174045c99051982a88c3efefd954edeb30f15e7baf2152c9300cfb9d86caab1495886dd46ecaeef0a10b7e360c3d10e16c83b078f2523b862d54 SHA512 48a3504c92aed063b64e82e6547e27d2f961ebae57d1bd2934e96b50f79af50413c601d8990a8b02ca54070f6418bf7ff6f030524c6042987fa0e90d9b7a58d6
MISC metadata.xml 859 BLAKE2B 4bec2c6236dfc1bdb9ba9f1caff6c9b545861c6e51c58d90bfa652d2d5aaa323437473173912f1840ba3c690f92798929980e5bcb3cacb5fe4cdd8a0edb014d9 SHA512 15a0f421563051a8553e2bdf9a8f82dc5077e336513cc18ef7e9bea49e084ea4dc1aa32800fbc928743d8c09036d136518a5a6a74c2f57c61215da2f44dc9727
diff --git a/sci-physics/geant-vmc/files/geant-vmc-4.4.0-fix-cflags.patch b/sci-physics/geant-vmc/files/geant-vmc-4.4.0-fix-cflags.patch
new file mode 100644
index 000000000000..d3bf0dfdd308
--- /dev/null
+++ b/sci-physics/geant-vmc/files/geant-vmc-4.4.0-fix-cflags.patch
@@ -0,0 +1,15 @@
+diff --git a/g4root/test/OpNovice/CMakeLists.txt b/g4root/test/OpNovice/CMakeLists.txt
+index 1a8f316c..a2e144b6 100644
+--- a/g4root/test/OpNovice/CMakeLists.txt
++++ b/g4root/test/OpNovice/CMakeLists.txt
+@@ -44,7 +44,9 @@ endif()
+ #----------------------------------------------------------------------------
+ # Setup Geant4 include directories and compile definitions
+ #
+-include(${Geant4_USE_FILE})
++# Workaround for upstream bug: http://bugzilla-geant4.kek.jp/show_bug.cgi?id=1663
++#include(${Geant4_USE_FILE})
++include(UseGeant4)
+
+ #----------------------------------------------------------------------------
+ # Locate sources and headers for this project
diff --git a/sci-physics/geant-vmc/geant-vmc-4.3.6-r1.ebuild b/sci-physics/geant-vmc/geant-vmc-4.3.6-r1.ebuild
new file mode 100644
index 000000000000..b92483ba721f
--- /dev/null
+++ b/sci-physics/geant-vmc/geant-vmc-4.3.6-r1.ebuild
@@ -0,0 +1,89 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake-utils
+
+if [[ ${PV} == *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/vmc-project/geant4_vmc.git"
+else
+ DOWN_PV=$(ver_cut 2-)
+ SRC_URI="http://root.cern.ch/download/vmc/geant4_vmc.${DOWN_PV}.tar.gz"
+ SOURCE_PV=$(ver_rs 1- - ${DOWN_PV})
+ S="${WORKDIR}/geant4_vmc-${SOURCE_PV}"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+fi
+
+DESCRIPTION="Virtual Monte Carlo Geant4 implementation"
+HOMEPAGE="http://root.cern.ch/root/vmc/VirtualMC.html"
+
+LICENSE="GPL-2"
+SLOT="4"
+IUSE="doc examples geant3 +g4root +mtroot vgm test"
+
+# sci-physics/root[c++11] required to match sci-physics/geant flags.
+RDEPEND="
+ >=sci-physics/geant-4.10.03:=[opengl,geant3?]
+ <sci-physics/geant-4.10.05:=
+ sci-physics/root:=[c++11,vmc]
+ vgm? ( >=sci-physics/vgm-4.4:= )"
+DEPEND="${RDEPEND}
+ doc? ( app-doc/doxygen )"
+RESTRICT="
+ !geant3? ( test )
+ !g4root? ( test )
+ !mtroot? ( test )
+ !test? ( test )
+ !vgm? ( test )"
+
+DOCS=(
+ history
+ README.md
+)
+
+src_configure() {
+ local mycmakeargs=(
+ -DGeant4VMC_USE_VGM="$(usex vgm)"
+ -DGeant4VMC_USE_GEANT4_G3TOG4="$(usex geant3)"
+ -DGeant4VMC_USE_G4Root="$(usex g4root)"
+ -DGeant4VMC_BUILD_MTRoot="$(usex mtroot)"
+ -DGeant4VMC_BUILD_EXAMPLES="$(usex test)"
+ -DGeant4VMC_INSTALL_EXAMPLES="$(usex examples)"
+ )
+ cmake-utils_src_configure
+}
+
+src_compile() {
+ cmake-utils_src_compile
+ if use doc ; then
+ local dirs=(
+ source
+ $(usev g4root)
+ $(usev mtroot)
+ $(usev examples)
+ )
+ local d
+ for d in "${dirs[@]}"; do
+ pushd "${d}" > /dev/null || die
+ doxygen || die
+ popd > /dev/null || die
+ done
+ fi
+}
+
+src_test() {
+ # Required by sci-physics/root for pointer validity checking,
+ # see e.g. https://sft.its.cern.ch/jira/browse/ROOT-8146 .
+ addwrite /dev/random
+ cd examples || die
+ ./test_suite.sh --g3=off --builddir="${BUILD_DIR}" || die
+ ./test_suite_exe.sh --g3=off --builddir="${BUILD_DIR}" || die
+}
+
+src_install() {
+ cmake-utils_src_install
+ use doc && local HTML_DOCS=(doc/.)
+ einstalldocs
+}
diff --git a/sci-physics/geant-vmc/geant-vmc-4.4.0.ebuild b/sci-physics/geant-vmc/geant-vmc-4.4.0.ebuild
new file mode 100644
index 000000000000..0f091fe6412e
--- /dev/null
+++ b/sci-physics/geant-vmc/geant-vmc-4.4.0.ebuild
@@ -0,0 +1,96 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake-utils
+
+if [[ ${PV} == *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/vmc-project/geant4_vmc.git"
+else
+ DOWN_PV=$(ver_cut 2-)
+ SRC_URI="http://root.cern.ch/download/vmc/geant4_vmc.${DOWN_PV}.tar.gz"
+ SOURCE_PV=$(ver_rs 1- . ${DOWN_PV})
+ S="${WORKDIR}/geant4_vmc.${SOURCE_PV}"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+fi
+
+DESCRIPTION="Virtual Monte Carlo Geant4 implementation"
+HOMEPAGE="http://root.cern.ch/root/vmc/VirtualMC.html"
+
+LICENSE="GPL-2"
+SLOT="4"
+IUSE="doc examples geant3 +g4root +mtroot vgm test"
+
+# sci-physics/root[c++11] required to match sci-physics/geant flags.
+RDEPEND="
+ >=sci-physics/geant-4.10.03:=[opengl,geant3?]
+ sci-physics/root:=[c++11,vmc]
+ vgm? ( >=sci-physics/vgm-4.4:= )"
+DEPEND="${RDEPEND}
+ doc? ( app-doc/doxygen )"
+RESTRICT="
+ !examples? ( test )
+ !geant3? ( test )
+ !g4root? ( test )
+ !mtroot? ( test )
+ !test? ( test )
+ !vgm? ( test )"
+
+DOCS=(
+ history
+ README.md
+)
+PATCHES=(
+ "${FILESDIR}"/"${PN}-${PV}"-fix-cflags.patch
+)
+
+src_configure() {
+ local mycmakeargs=(
+ -DGeant4VMC_USE_VGM="$(usex vgm)"
+ -DGeant4VMC_USE_GEANT4_G3TOG4="$(usex geant3)"
+ -DGeant4VMC_USE_G4Root="$(usex g4root)"
+ -DGeant4VMC_BUILD_MTRoot="$(usex mtroot)"
+ -DGeant4VMC_BUILD_EXAMPLES="$(usex test)"
+ -DGeant4VMC_INSTALL_EXAMPLES="$(usex examples)"
+ )
+ cmake-utils_src_configure
+}
+
+src_compile() {
+ cmake-utils_src_compile
+ if use doc ; then
+ local dirs=(
+ source
+ $(usev g4root)
+ $(usev mtroot)
+ $(usev examples)
+ )
+ local d
+ for d in "${dirs[@]}"; do
+ pushd "${d}" > /dev/null || die
+ doxygen || die
+ popd > /dev/null || die
+ done
+ fi
+}
+
+src_test() {
+ # Required by sci-physics/root for pointer validity checking,
+ # see e.g. https://sft.its.cern.ch/jira/browse/ROOT-8146 .
+ addwrite /dev/random
+ cd examples || die
+ # Bug: Can not disable Garfield in test suite, fixed upstream.
+ sed -i 's/ExGarfield//' test_suite.sh || die
+ # Bug: Path for E03 sub-examples wrong, see https://github.com/vmc-project/geant4_vmc/pull/11 .
+ sed -i 's#only in E03 test#only in E03 test\nG4EXEDIR=${BUILDDIR}/examples/$EXAMPLE/$OPTION#' test_suite_exe.sh || die
+ ./test_suite.sh --g3=off --builddir="${BUILD_DIR}" || die
+ ./test_suite_exe.sh --g3=off --garfield=off --builddir="${BUILD_DIR}" || die
+}
+
+src_install() {
+ cmake-utils_src_install
+ use doc && local HTML_DOCS=(doc/.)
+ einstalldocs
+}
diff --git a/sci-physics/geant-vmc/geant-vmc-9999.ebuild b/sci-physics/geant-vmc/geant-vmc-9999.ebuild
index 2156a04588fa..ffc8e7dc8743 100644
--- a/sci-physics/geant-vmc/geant-vmc-9999.ebuild
+++ b/sci-physics/geant-vmc/geant-vmc-9999.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
+EAPI=7
-inherit cmake-utils eapi7-ver
+inherit cmake-utils
if [[ ${PV} == *9999* ]]; then
inherit git-r3
@@ -11,8 +11,8 @@ if [[ ${PV} == *9999* ]]; then
else
DOWN_PV=$(ver_cut 2-)
SRC_URI="http://root.cern.ch/download/vmc/geant4_vmc.${DOWN_PV}.tar.gz"
- SOURCE_PV=$(ver_rs 1- - ${DOWN_PV})
- S="${WORKDIR}/geant4_vmc-${SOURCE_PV}"
+ SOURCE_PV=$(ver_rs 1- . ${DOWN_PV})
+ S="${WORKDIR}/geant4_vmc.${SOURCE_PV}"
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
fi
@@ -23,18 +23,19 @@ LICENSE="GPL-2"
SLOT="4"
IUSE="doc examples geant3 +g4root +mtroot vgm test"
-# sci-physics/root[root7] flag activates std=c++14, which we could only support if also Geant is built with it.
-# Disable for now.
+# sci-physics/root[c++11] required to match sci-physics/geant flags.
RDEPEND="
>=sci-physics/geant-4.10.03:=[opengl,geant3?]
- sci-physics/root:=[-root7]
+ sci-physics/root:=[c++11,vmc]
vgm? ( >=sci-physics/vgm-4.4:= )"
DEPEND="${RDEPEND}
doc? ( app-doc/doxygen )"
RESTRICT="
+ !examples? ( test )
!geant3? ( test )
!g4root? ( test )
!mtroot? ( test )
+ !test? ( test )
!vgm? ( test )"
DOCS=(
@@ -77,8 +78,8 @@ src_test() {
# see e.g. https://sft.its.cern.ch/jira/browse/ROOT-8146 .
addwrite /dev/random
cd examples || die
- ./test_suite.sh --g3=off --builddir="${BUILD_DIR}" || die
- ./test_suite_exe.sh --g3=off --builddir="${BUILD_DIR}" || die
+ ./test_suite.sh --debug --g3=off --garfield=off --builddir="${BUILD_DIR}" || die
+ ./test_suite_exe.sh -debug --g3=off --garfield=off --builddir="${BUILD_DIR}" || die
}
src_install() {