science/geant4: adding Geant4, a TK for the simulation of the passage of particles through matter

PR:		268300
Reported by:	erik (at) tenku.dk
This commit is contained in:
Erik Jensen
2022-12-26 16:01:50 +01:00
committed by Thierry Thomas
parent 5b8e2dac93
commit 3f600a75ea
8 changed files with 55107 additions and 0 deletions
+1
View File
@@ -108,6 +108,7 @@
SUBDIR += gbtolib
SUBDIR += gchemutils
SUBDIR += gdma
SUBDIR += geant4
SUBDIR += gemmi
SUBDIR += getdp
SUBDIR += ghemical
+79
View File
@@ -0,0 +1,79 @@
PORTNAME= geant4
DISTVERSION= 11.0.3
CATEGORIES= science parallel python devel cad
# Supplementary data files for Geant4 fetched from MASTER_SITES:n with "n"= "data" - Geant4 itself is fetched from GL_SITE defined further down
MASTER_SITES= https://cern.ch/geant4-data/datasets/:data
# Names of supplementary data files for Geant4 defined in DISTFILES:n with "n"= "data"
DISTFILES+= G4ABLA.3.1.tar.gz:data \
G4EMLOW.8.0.tar.gz:data \
G4ENSDFSTATE.2.3.tar.gz:data \
G4INCL.1.0.tar.gz:data \
G4NDL.4.6.tar.gz:data \
G4PARTICLEXS.4.0.tar.gz:data \
G4PhotonEvaporation.5.7.tar.gz:data \
G4PII.1.3.tar.gz:data \
G4RadioactiveDecay.5.6.tar.gz:data \
G4RealSurface.2.2.tar.gz:data \
G4SAIDDATA.2.0.tar.gz:data
DIST_SUBDIR= ${PORTNAME}-${DISTVERSION}
MAINTAINER= erik@tenku.dk
COMMENT= Simulate the passage of particles through matter
WWW= https://geant4.cern.ch/
LICENSE= GEANT4
LICENSE_NAME= Geant4 Software License
LICENSE_FILE= ${WRKSRC}/LICENSE
LICENSE_PERMS= dist-mirror pkg-mirror auto-accept
BUILD_DEPENDS= git:devel/git
LIB_DEPENDS= libexpat.so:textproc/expat2 \
libfontconfig.so:x11-fonts/fontconfig \
libfreetype.so:print/freetype2 \
libpng.so:graphics/png \
libxcb-icccm.so:x11/xcb-util-wm \
libxcb-util.so:x11/xcb-util \
libxerces-c.so:textproc/xerces-c3 \
libxkbcommon.so:x11/libxkbcommon \
${PY_BOOST}
USES= cmake \
compiler:c++17-lang \
gl \
motif \
python:3.9+ \
xorg
CMAKE_ON= GEANT4_BUILD_MULTITHREADED \
GEANT4_USE_GDML \
GEANT4_USE_OPENGL_X11 \
GEANT4_USE_PYTHON \
GEANT4_USE_RAYTRACER_X11 \
GEANT4_USE_XM \
GEANT4_USE_FREETYPE
USE_GITLAB= yes
GL_SITE= https://gitlab.cern.ch/
GL_COMMIT= 3136fa97238bf2b24eba982206fb72b32b898d96
USE_GL= egl gl glu opengl
USE_LDCONFIG= yes
USE_XORG= ice sm x11 xau xaw xcb xcomposite \
xcursor xdamage xdmcp xext xfixes \
xfont xfont2 xft xi xinerama \
xkbfile xmu xpm xrandr xrender \
xres xscrnsaver xt xtst xv xxf86vm
CONFIGURE_WRKSRC?= ${WRKDIR}/.build
STAGEDIR?= ${WRKDIR}/stage
CMAKE_ARGS+= -DGEANT4_BUILD_TLS_MODEL=global-dynamic
G4_DATADIRS= G4ABLA3.1 G4EMLOW8.0 G4ENSDFSTATE2.3 \
G4INCL1.0 G4NDL4.6 G4PARTICLEXS4.0 \
G4PII1.3 G4SAIDDATA2.0 \
PhotonEvaporation5.7 \
RadioactiveDecay5.6 RealSurface2.2
post-install:
.for dir in ${G4_DATADIRS}
cd ${WRKDIR} && ${COPYTREE_SHARE} ${dir} ${STAGEDIR}${PREFIX}/share/Geant4-${DISTVERSION}/data/
.endfor
.include <bsd.port.mk>
+25
View File
@@ -0,0 +1,25 @@
TIMESTAMP = 1672014081
SHA256 (geant4-11.0.3/G4ABLA.3.1.tar.gz) = 7698b052b58bf1b9886beacdbd6af607adc1e099fc730ab6b21cf7f090c027ed
SIZE (geant4-11.0.3/G4ABLA.3.1.tar.gz) = 107286
SHA256 (geant4-11.0.3/G4EMLOW.8.0.tar.gz) = d919a8e5838688257b9248a613910eb2a7633059e030c8b50c0a2c2ad9fd2b3b
SIZE (geant4-11.0.3/G4EMLOW.8.0.tar.gz) = 326834565
SHA256 (geant4-11.0.3/G4ENSDFSTATE.2.3.tar.gz) = 9444c5e0820791abd3ccaace105b0e47790fadce286e11149834e79c4a8e9203
SIZE (geant4-11.0.3/G4ENSDFSTATE.2.3.tar.gz) = 290745
SHA256 (geant4-11.0.3/G4INCL.1.0.tar.gz) = 716161821ae9f3d0565fbf3c2cf34f4e02e3e519eb419a82236eef22c2c4367d
SIZE (geant4-11.0.3/G4INCL.1.0.tar.gz) = 95840
SHA256 (geant4-11.0.3/G4NDL.4.6.tar.gz) = 9d287cf2ae0fb887a2adce801ee74fb9be21b0d166dab49bcbee9408a5145408
SIZE (geant4-11.0.3/G4NDL.4.6.tar.gz) = 599862135
SHA256 (geant4-11.0.3/G4PARTICLEXS.4.0.tar.gz) = 9381039703c3f2b0fd36ab4999362a2c8b4ff9080c322f90b4e319281133ca95
SIZE (geant4-11.0.3/G4PARTICLEXS.4.0.tar.gz) = 12242648
SHA256 (geant4-11.0.3/G4PhotonEvaporation.5.7.tar.gz) = 761e42e56ffdde3d9839f9f9d8102607c6b4c0329151ee518206f4ee9e77e7e5
SIZE (geant4-11.0.3/G4PhotonEvaporation.5.7.tar.gz) = 10089240
SHA256 (geant4-11.0.3/G4PII.1.3.tar.gz) = 6225ad902675f4381c98c6ba25fc5a06ce87549aa979634d3d03491d6616e926
SIZE (geant4-11.0.3/G4PII.1.3.tar.gz) = 4293607
SHA256 (geant4-11.0.3/G4RadioactiveDecay.5.6.tar.gz) = 3886077c9c8e5a98783e6718e1c32567899eeb2dbb33e402d4476bc2fe4f0df1
SIZE (geant4-11.0.3/G4RadioactiveDecay.5.6.tar.gz) = 1059792
SHA256 (geant4-11.0.3/G4RealSurface.2.2.tar.gz) = 9954dee0012f5331267f783690e912e72db5bf52ea9babecd12ea22282176820
SIZE (geant4-11.0.3/G4RealSurface.2.2.tar.gz) = 132506346
SHA256 (geant4-11.0.3/G4SAIDDATA.2.0.tar.gz) = 1d26a8e79baa71e44d5759b9f55a67e8b7ede31751316a9e9037d80090c72e91
SIZE (geant4-11.0.3/G4SAIDDATA.2.0.tar.gz) = 38502
SHA256 (geant4-11.0.3/geant4-geant4-3136fa97238bf2b24eba982206fb72b32b898d96_GL0.tar.gz) = 403573c6028b7dbd01858980846565ec5a9b4030ce968e46503369f7bdb37da6
SIZE (geant4-11.0.3/geant4-geant4-3136fa97238bf2b24eba982206fb72b32b898d96_GL0.tar.gz) = 35651209
@@ -0,0 +1,8 @@
--- CMakeLists.txt.orig 2022-09-16 07:46:17 UTC
+++ CMakeLists.txt
@@ -49,3 +49,5 @@ include(G4CMakeMain)
#
include(G4CMakeMain)
+find_library(EXECINFO NAMES execinfo)
+target_link_libraries(G4run PUBLIC ${EXECINFO})
@@ -0,0 +1,11 @@
--- source/global/management/include/G4Backtrace.hh.orig 2022-09-16 07:46:17 UTC
+++ source/global/management/include/G4Backtrace.hh
@@ -114,7 +114,7 @@ using G4ResultOf_t = std::invoke_result_t<FuncT, ArgTy
#endif
#if !defined(G4PSIGINFO_AVAILABLE)
-# if _XOPEN_SOURCE >= 700 || _POSIX_C_SOURCE >= 200809L
+# if (_XOPEN_SOURCE >= 700 || _POSIX_C_SOURCE >= 200809L) && !defined(__FreeBSD__)
# define G4PSIGINFO_AVAILABLE 1
# else
# define G4PSIGINFO_AVAILABLE 0
@@ -0,0 +1,12 @@
--- source/global/management/include/tls.hh.orig 2022-09-16 07:46:17 UTC
+++ source/global/management/include/tls.hh
@@ -39,7 +39,8 @@
# if defined(G4MULTITHREADED)
# if(defined(__MACH__) && defined(__clang__)) || \
- (defined(__linux__) && defined(__clang__))
+ (defined(__linux__) && defined(__clang__)) || \
+ (defined(__FreeBSD__) && defined(__clang__))
# define G4ThreadLocalStatic static thread_local
# define G4ThreadLocal thread_local
# elif((defined(__linux__) || defined(__MACH__)) && \
+9
View File
@@ -0,0 +1,9 @@
Geant4 is a toolkit for the simulation of the passage of particles through
matter. Its areas of application include high energy, nuclear and accelerator
physics, as well as studies in medical and space science.
The three main reference papers for Geant4 are published in Nuclear Instruments
and Methods in Physics Research A 506 (2003) 250-303, IEEE Transactions on
Nuclear Science 53 No. 1 (2006) 270-278 and Nuclear Instruments and Methods in
Physics Research A 835 (2016) 186-225.
[Text copied from Geant4's website 2022-12-10. Links to the three papers
referenced in the description are available on the Geant4 website.]
File diff suppressed because it is too large Load Diff