git: 9c3ff364caa1 - main - science/py-OpenMC: update 0.15.0 → 0.16.0

Yuri Victorovich <[email protected]>
Newsgroups gmane.os.freebsd.devel.cvs.ports
Message-ID <[email protected]>
The branch main has been updated by yuri:

URL: https://cgit.FreeBSD.org/ports/commit/?id=9c3ff364caa1721bb614cb4ace9f8ba8544c1a71

commit 9c3ff364caa1721bb614cb4ace9f8ba8544c1a71
Author:     Yuri Victorovich <[email protected]>
AuthorDate: 2026-08-07 04:32:05 +0000
Commit:     Yuri Victorovich <[email protected]>
CommitDate: 2026-08-07 05:09:30 +0000

    science/py-OpenMC: update 0.15.0 → 0.16.0
---
 science/py-OpenMC/Makefile                   | 67 +++++++++++++++++++++++-----
 science/py-OpenMC/distinfo                   |  6 +--
 science/py-OpenMC/files/patch-pyproject.toml | 18 ++++++++
 3 files changed, 76 insertions(+), 15 deletions(-)

diff --git a/science/py-OpenMC/Makefile b/science/py-OpenMC/Makefile
index 51584f094ab9..9278ff552a13 100644
--- a/science/py-OpenMC/Makefile
+++ b/science/py-OpenMC/Makefile
@@ -1,44 +1,46 @@
-PORTNAME=	OpenMC
+PORTNAME=	openmc
 DISTVERSIONPREFIX=	v
-DISTVERSION=	0.15.0
-PORTREVISION=	6
+DISTVERSION=	0.16.0
 CATEGORIES=	science
 PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
 
 MAINTAINER=	[email protected]
 COMMENT=	Monte Carlo neutron and photon transport simulation code (Python)
-WWW=		https://openmc.org/
+WWW=		https://openmc.org/ \
+		https://docs.openmc.org/en/stable/ \
+		https://github.com/openmc-dev/openmc
 
 LICENSE=	MIT
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
-PY_DEPENDS=	${PYTHON_PKGNAMEPREFIX}numpy>=1.16:math/py-numpy@${PY_FLAVOR} \
+PY_DEPENDS=	${PYTHON_PKGNAMEPREFIX}endf>0:science/py-endf@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}h5py>0:science/py-h5py@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}ipython>0:devel/ipython@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}lxml>0:devel/py-lxml@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}matplotlib>0:math/py-matplotlib@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}numpy>0:math/py-numpy@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}pandas>0:math/py-pandas@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}scipy>0:science/py-scipy@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}uncertainties>0:math/py-uncertainties@${PY_FLAVOR}
-BUILD_DEPENDS=	openmc>0:science/openmc \
+BUILD_DEPENDS=	${PY_SETUPTOOLS} \
+		${PYTHON_PKGNAMEPREFIX}setuptools-scm>:devel/py-setuptools-scm@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} \
+		openmc>0:science/openmc \
 		${PY_DEPENDS}
 RUN_DEPENDS=	openmc>0:science/openmc \
 		${PY_DEPENDS}
 
 USES=		python
-USE_PYTHON=	distutils cython concurrent autoplist pytest # tests fail and abort in the middle, see https://github.com/openmc-dev/openmc/issues/2186
+USE_PYTHON=	pep517 cython concurrent autoplist pytest
 
 USE_GITHUB=	yes
-GH_ACCOUNT=	${PORTNAME:tl}-dev
-GH_PROJECT=	${PORTNAME:tl}
+GH_ACCOUNT=	${PORTNAME}-dev
 
 PLIST_FILES=	${PYTHON_SITELIBDIR}/openmc/lib/libopenmc.so
 
 TEST_ENV=	${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
 
 post-install:
-	# strip
-	@${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/openmc/data/*.so
 	# link the library
 	@${LN} -s ${LOCALBASE}/lib/libopenmc.so ${STAGEDIR}${PYTHON_SITELIBDIR}/openmc/lib/libopenmc.so
 
@@ -46,6 +48,47 @@ pre-test:
 	# link the library
 	@if ! [ -e ${WRKSRC}/openmc/lib/libopenmc.so ]; then ${LN} -s ${LOCALBASE}/lib/libopenmc.so ${WRKSRC}/openmc/lib/libopenmc.so; fi
 
-# Some tests fail with the message: RuntimeError: No cross_sections.xml file was specified in materials.xml or in the OPENMC_CROSS_SECTIONS environment variable, see https://github.com/openmc-dev/openmc/issues/3053
+# The full test suite needs the NNDC HDF5 cross-section data set, which is not
+# available in the ports build environment.  Limit pytest to the subset of
+# tests that exercise the Python API without running the OpenMC Monte Carlo
+# executable or loading nuclear data libraries.
+TEST_ARGS=	tests/test_matplotlib_import.py \
+		tests/unit_tests/mesh_to_vtk/test.py \
+		tests/unit_tests/test_bounding_box.py \
+		tests/unit_tests/test_config.py \
+		tests/unit_tests/test_data_dose.py \
+		tests/unit_tests/test_data_mass_attenuation.py \
+		tests/unit_tests/test_deplete_atom_number.py \
+		tests/unit_tests/test_deplete_continue.py \
+		tests/unit_tests/test_deplete_cram.py \
+		tests/unit_tests/test_deplete_decay.py \
+		tests/unit_tests/test_deplete_nuclide.py \
+		tests/unit_tests/test_deplete_operator.py \
+		tests/unit_tests/test_deplete_reaction.py \
+		tests/unit_tests/test_deplete_resultslist.py \
+		tests/unit_tests/test_deplete_restart.py \
+		tests/unit_tests/test_filter_reaction.py \
+		tests/unit_tests/test_lattice.py \
+		tests/unit_tests/test_lattice_discretization.py \
+		tests/unit_tests/test_mcpl_stat_sum.py \
+		tests/unit_tests/test_mesh_from_domain.py \
+		tests/unit_tests/test_mesh_from_lattice.py \
+		tests/unit_tests/test_mg_inverse_velocity.py \
+		tests/unit_tests/test_mgxs_convert_flux.py \
+		tests/unit_tests/test_model_triso.py \
+		tests/unit_tests/test_particle_type.py \
+		tests/unit_tests/test_pathlike_simple.py \
+		tests/unit_tests/test_pin.py \
+		tests/unit_tests/test_plots.py \
+		tests/unit_tests/test_polynomials.py \
+		tests/unit_tests/test_slice_voxel_plots.py \
+		tests/unit_tests/test_surface.py \
+		tests/unit_tests/test_surface_composite.py \
+		tests/unit_tests/test_temp_interp.py \
+		tests/unit_tests/test_transfer_volumes.py \
+		tests/unit_tests/test_vectfit.py \
+		tests/unit_tests/test_waste_classification.py
+
+# tests as of 0.16.0: 325 passed, 1 skipped, 27 warnings in 39.09s
 
 .include <bsd.port.mk>
diff --git a/science/py-OpenMC/distinfo b/science/py-OpenMC/distinfo
index e030d350f4f3..531c84ffe426 100644
--- a/science/py-OpenMC/distinfo
+++ b/science/py-OpenMC/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1719035695
-SHA256 (openmc-dev-openmc-v0.15.0_GH0.tar.gz) = 32517c1af1abee615e0b49330fd6eb6d704dd96d903b5b415091aea8aa52bbf0
-SIZE (openmc-dev-openmc-v0.15.0_GH0.tar.gz) = 7810068
+TIMESTAMP = 1786055834
+SHA256 (openmc-dev-openmc-v0.16.0_GH0.tar.gz) = cfdf10f8dc66e652668dbc94501d5ed99b3dfecabc11cf91989a29ba7984654f
+SIZE (openmc-dev-openmc-v0.16.0_GH0.tar.gz) = 8721314
diff --git a/science/py-OpenMC/files/patch-pyproject.toml b/science/py-OpenMC/files/patch-pyproject.toml
new file mode 100644
index 000000000000..5c3b1de83493
--- /dev/null
+++ b/science/py-OpenMC/files/patch-pyproject.toml
@@ -0,0 +1,18 @@
+--- pyproject.toml.orig	2026-08-05 22:03:39 UTC
++++ pyproject.toml
+@@ -1,5 +1,5 @@
+ [build-system]
+-requires = ["setuptools>=80", "setuptools-scm>=8"]
++requires = ["setuptools", "setuptools-scm>=8"]
+ build-backend = "setuptools.build_meta"
+ 
+ [project]
+@@ -10,8 +10,6 @@ requires-python = ">=3.12"
+ description = "OpenMC"
+ dynamic = ["version"]
+ requires-python = ">=3.12"
+-license = "MIT"
+-license-files = ["LICENSE"]
+ classifiers = [
+     "Development Status :: 4 - Beta",
+     "Intended Audience :: Developers",
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.