git: 0e14eaf98bf2 - main - science/py-HepMC3: New port: Event record for High Energy Physics Monte Carlo generators/simulation
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 17 Apr 2023 08:47:06 UTC
The branch main has been updated by yuri: URL: https://cgit.FreeBSD.org/ports/commit/?id=0e14eaf98bf2f4ca8b12d3ec033ab9aa349998b4 commit 0e14eaf98bf2f4ca8b12d3ec033ab9aa349998b4 Author: Yuri Victorovich <yuri@FreeBSD.org> AuthorDate: 2023-04-17 08:46:21 +0000 Commit: Yuri Victorovich <yuri@FreeBSD.org> CommitDate: 2023-04-17 08:47:01 +0000 science/py-HepMC3: New port: Event record for High Energy Physics Monte Carlo generators/simulation --- science/Makefile | 1 + science/py-HepMC3/Makefile | 26 ++++++++++++++++++++++ science/py-HepMC3/distinfo | 3 +++ science/py-HepMC3/files/patch-CMakeLists.txt | 32 ++++++++++++++++++++++++++++ science/py-HepMC3/pkg-descr | 6 ++++++ science/py-HepMC3/pkg-plist | 3 +++ 6 files changed, 71 insertions(+) diff --git a/science/Makefile b/science/Makefile index 7ff6a322b6e1..dd281aa1b47b 100644 --- a/science/Makefile +++ b/science/Makefile @@ -277,6 +277,7 @@ SUBDIR += py-DendroPy SUBDIR += py-GPy SUBDIR += py-GPyOpt + SUBDIR += py-HepMC3 SUBDIR += py-MDAnalysis SUBDIR += py-MDAnalysisTests SUBDIR += py-OpenFermion diff --git a/science/py-HepMC3/Makefile b/science/py-HepMC3/Makefile new file mode 100644 index 000000000000..c03a6018e892 --- /dev/null +++ b/science/py-HepMC3/Makefile @@ -0,0 +1,26 @@ +PORTNAME= HepMC3 +DISTVERSION= 3.2.6 +CATEGORIES= science +MASTER_SITES= http://hepmc.web.cern.ch/hepmc/releases/ +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= yuri@FreeBSD.org +COMMENT= Event record for High Energy Physics Monte Carlo generators/simulation +WWW= https://hepmc.web.cern.ch/hepmc/ + +LICENSE= GPLv3 +LICENSE_FILE= ${WRKSRC}/../COPYING + +LIB_DEPENDS= libHepMC3.so:science/hepmc3 + +USES= cmake:testing compiler:c++11-lang python +USE_PYTHON= flavors + +WRKSRC_SUBDIR= python + +CMAKE_ON= USE_INSTALLED_HEPMC3 +CMAKE_ARGS= -DPython3_EXECUTABLE=${PYTHON_CMD} +CMAKE_OFF= HEPMC3_ENABLE_TEST +CMAKE_TESTING_ON= HEPMC3_ENABLE_TEST + +.include <bsd.port.mk> diff --git a/science/py-HepMC3/distinfo b/science/py-HepMC3/distinfo new file mode 100644 index 000000000000..baf19deaddc4 --- /dev/null +++ b/science/py-HepMC3/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1681718734 +SHA256 (HepMC3-3.2.6.tar.gz) = 248f3b5b36dd773844cbe73d51f60891458334b986b259754c59dbf4bbf1d525 +SIZE (HepMC3-3.2.6.tar.gz) = 9344806 diff --git a/science/py-HepMC3/files/patch-CMakeLists.txt b/science/py-HepMC3/files/patch-CMakeLists.txt new file mode 100644 index 000000000000..83a78212d418 --- /dev/null +++ b/science/py-HepMC3/files/patch-CMakeLists.txt @@ -0,0 +1,32 @@ +--- CMakeLists.txt.orig 2023-04-12 14:19:36 UTC ++++ CMakeLists.txt +@@ -6,6 +6,8 @@ SET_PROPERTY (GLOBAL PROPERTY CMAKE_ROLE "PROJECT") + endif() + set(CMAKE_VERBOSE_MAKEFILE ON) + ++include(CheckCXXCompilerFlag) ++ + option(USE_INSTALLED_HEPMC3 "Use HepMC3 bindings as a standalone package" OFF) + option(RERUN_BINDER "Rerun binder" OFF) + if (USE_INSTALLED_HEPMC3) +@@ -314,9 +316,9 @@ if (${ver} STREQUAL 2) + unset(_Python2_EXECUTABLE CACHE) # Attempt to make FindPython reenterant + unset(_Python2_INCLUDE_DIR CACHE) # Attempt to make FindPython reenterant + if (${verminor} STREQUAL X) +- find_package (Python2 ${ver} COMPONENTS Interpreter Development.Module) ++ find_package (xPython2 ${ver} COMPONENTS Interpreter Development.Module) + else() +- find_package (Python2 ${ver}.${verminor} EXACT COMPONENTS Interpreter Development.Module) ++ find_package (xPython2 ${ver}.${verminor} EXACT COMPONENTS Interpreter Development.Module) + endif() + if (Python2_VERSION AND Python2_INCLUDE_DIRS AND Python2_EXECUTABLE ) #something is set + SET( Python_VERSION ${Python2_VERSION}) +@@ -336,7 +338,7 @@ if (${ver} STREQUAL 3) + unset(Python3_FOUND CACHE) + unset(Python3_VERSION CACHE) + unset(Python3_Interpreter_FOUND CACHE) +- unset(Python3_EXECUTABLE CACHE) ++ #unset(Python3_EXECUTABLE CACHE) + unset(Python3_INCLUDE_DIR CACHE) + unset(Python3_INCLUDE_DIRS CACHE) + unset(Python3_LIBRARIES CACHE) diff --git a/science/py-HepMC3/pkg-descr b/science/py-HepMC3/pkg-descr new file mode 100644 index 000000000000..8a3321c536a7 --- /dev/null +++ b/science/py-HepMC3/pkg-descr @@ -0,0 +1,6 @@ +The HepMC package is an object oriented, C++ event record for High Energy +Physics Monte Carlo generators and simulation. The original code was written +by M. Dobbs and J.B. Hansen (Comput. Phys. Commun. 134 (2001) 41). Since the +first implementation, the package has undergone several modifications and in +particular, the latest HepMC3 series is a completely new rewrite using +currently available C++11 techniques. diff --git a/science/py-HepMC3/pkg-plist b/science/py-HepMC3/pkg-plist new file mode 100644 index 000000000000..0ed0c97ed536 --- /dev/null +++ b/science/py-HepMC3/pkg-plist @@ -0,0 +1,3 @@ +%%PYTHON_SITELIBDIR%%/pyHepMC3-3.2.6-py%%PYTHON_VER%%.egg-info +%%PYTHON_SITELIBDIR%%/pyHepMC3/__init__.py +%%PYTHON_SITELIBDIR%%/pyHepMC3/pyHepMC3.so