Date: Tue, 16 Jun 2026 13:57:04 +0000 From: Yuri Victorovich <yuri@FreeBSD.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org Subject: git: a321aa4342ac - main - devel/py-dm-tree: update 0.1.8=?utf-8?Q? =E2=86=92 0.1?=.10 Message-ID: <6a315630.36d2f.75819907@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by yuri: URL: https://cgit.FreeBSD.org/ports/commit/?id=a321aa4342ac4ba694b4d07fdb292bf0305be92a commit a321aa4342ac4ba694b4d07fdb292bf0305be92a Author: Yuri Victorovich <yuri@FreeBSD.org> AuthorDate: 2026-06-16 13:40:39 +0000 Commit: Yuri Victorovich <yuri@FreeBSD.org> CommitDate: 2026-06-16 13:56:59 +0000 devel/py-dm-tree: update 0.1.8 → 0.1.10 --- devel/py-dm-tree/Makefile | 24 +++++--- devel/py-dm-tree/distinfo | 6 +- devel/py-dm-tree/files/patch-setup.py | 17 ++++++ devel/py-dm-tree/files/patch-tree_CMakeLists.txt | 76 +++--------------------- devel/py-dm-tree/files/patch-tree_tree.cc | 20 +++++++ devel/py-dm-tree/pkg-plist | 13 ---- 6 files changed, 66 insertions(+), 90 deletions(-) diff --git a/devel/py-dm-tree/Makefile b/devel/py-dm-tree/Makefile index 0cd4909e3e33..775ef3e882a0 100644 --- a/devel/py-dm-tree/Makefile +++ b/devel/py-dm-tree/Makefile @@ -1,9 +1,9 @@ PORTNAME= dm-tree -DISTVERSION= 0.1.8 -PORTREVISION= 3 -CATEGORIES= devel +DISTVERSION= 0.1.10 +CATEGORIES= devel python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} +DISTNAME= ${PORTNAME:S/-/_/g}-${DISTVERSION} MAINTAINER= yuri@FreeBSD.org COMMENT= Library for working with nested data structures @@ -12,13 +12,23 @@ WWW= https://tree.readthedocs.io/en/latest/ LICENSE= APACHE20 LICENSE_FILE= ${WRKSRC}/LICENSE -BUILD_DEPENDS= cmake:devel/cmake-core \ - pybind11>0:devel/pybind11 +BUILD_DEPENDS= ${PY_SETUPTOOLS} \ + ${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} \ + cmake:devel/cmake-core \ + ${PYTHON_PKGNAMEPREFIX}pybind11>0:devel/py-pybind11@${PY_FLAVOR} LIB_DEPENDS= libabsl_strings.so:devel/abseil USES= localbase python -USE_PYTHON= distutils concurrent +USE_PYTHON= pep517 autoplist concurrent pytest -MAKE_ENV= FREEBSD_LOCALBASE=${LOCALBASE} +TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}absl-py>=0.6.1:devel/py-absl-py@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}attrs>=18.2.0:devel/py-attrs@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}numpy>=1.21:math/py-numpy@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}wrapt>=1.11.2:devel/py-wrapt@${PY_FLAVOR} + +TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} +TEST_WRKSRC= ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/tree + +# tests as of 0.1.10: 70 passed .include <bsd.port.mk> diff --git a/devel/py-dm-tree/distinfo b/devel/py-dm-tree/distinfo index 9e63509bbe76..d5aa53a41604 100644 --- a/devel/py-dm-tree/distinfo +++ b/devel/py-dm-tree/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1712465713 -SHA256 (dm-tree-0.1.8.tar.gz) = 0fcaabbb14e7980377439e7140bd05552739ca5e515ecb3119f234acee4b9430 -SIZE (dm-tree-0.1.8.tar.gz) = 35384 +TIMESTAMP = 1781566464 +SHA256 (dm_tree-0.1.10.tar.gz) = 22f37b599e01cc3402a17f79c257a802aebd8d326de05b54657650845956208a +SIZE (dm_tree-0.1.10.tar.gz) = 35748 diff --git a/devel/py-dm-tree/files/patch-setup.py b/devel/py-dm-tree/files/patch-setup.py new file mode 100644 index 000000000000..7019206efd46 --- /dev/null +++ b/devel/py-dm-tree/files/patch-setup.py @@ -0,0 +1,17 @@ +-- Add pybind11_DIR to CMake arguments so that find_package(pybind11) +-- can locate the system pybind11 installation. Without this, CMake's +-- FetchContent falls back to downloading pybind11 from the internet, +-- which fails in offline build environments like poudriere. + +--- setup.py.orig 2026-06-16 03:31:42 UTC ++++ setup.py +@@ -82,7 +82,8 @@ class BuildCMakeExtension(build_ext.build_ext): + f'-DPython3_ROOT_DIR={sys.prefix}', + f'-DPython3_EXECUTABLE={sys.executable}', + f'-DCMAKE_LIBRARY_OUTPUT_DIRECTORY={extension_dir}', +- f'-DCMAKE_BUILD_TYPE={build_cfg}' ++ f'-DCMAKE_BUILD_TYPE={build_cfg}', ++ f'-Dpybind11_DIR={sysconfig.get_paths()["purelib"]}/pybind11/share/cmake/pybind11' + ] + if platform.system() != 'Windows': + cmake_args.extend([ diff --git a/devel/py-dm-tree/files/patch-tree_CMakeLists.txt b/devel/py-dm-tree/files/patch-tree_CMakeLists.txt index ae4dc5952ab4..aa2143bc1a32 100644 --- a/devel/py-dm-tree/files/patch-tree_CMakeLists.txt +++ b/devel/py-dm-tree/files/patch-tree_CMakeLists.txt @@ -1,71 +1,13 @@ ---- tree/CMakeLists.txt.orig 2022-12-18 09:35:42 UTC +--- tree/CMakeLists.txt.orig 2026-06-16 01:25:03 UTC +++ tree/CMakeLists.txt -@@ -52,17 +52,18 @@ set(PYBIND_VER v2.10.1) +@@ -7,8 +7,8 @@ project (tree LANGUAGES CXX) - # Fetch pybind to be able to use pybind11_add_module symbol. - set(PYBIND_VER v2.10.1) --include(FetchContent) --FetchContent_Declare( -- pybind11 -- GIT_REPOSITORY https://github.com/pybind/pybind11 -- GIT_TAG ${PYBIND_VER} --) --if(NOT pybind11_POPULATED) -- FetchContent_Populate(pybind11) -- add_subdirectory(${pybind11_SOURCE_DIR} ${pybind11_BINARY_DIR}) -- include_directories(${pybind11_INCLUDE_DIR}) --endif() -+#include(FetchContent) -+#FetchContent_Declare( -+# pybind11 -+# GIT_REPOSITORY https://github.com/pybind/pybind11 -+# GIT_TAG ${PYBIND_VER} -+#) -+#if(NOT pybind11_POPULATED) -+# FetchContent_Populate(pybind11) -+# add_subdirectory(${pybind11_SOURCE_DIR} ${pybind11_BINARY_DIR}) -+# include_directories(${pybind11_INCLUDE_DIR}) -+#endif() -+find_package(pybind11) + project (tree LANGUAGES CXX) - # Needed to disable Abseil tests. - set (BUILD_TESTING OFF) -@@ -83,27 +84,28 @@ endif() - ${ABSEIL_CMAKE_ARGS} - "-DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES}") - endif() --ExternalProject_Add(abseil-cpp -- GIT_REPOSITORY https://github.com/abseil/abseil-cpp.git -- GIT_TAG ${ABSEIL_VER} -- PREFIX ${CMAKE_SOURCE_DIR}/abseil-cpp -- CMAKE_ARGS ${ABSEIL_CMAKE_ARGS} --) --ExternalProject_Get_Property(abseil-cpp install_dir) --set(abseil_install_dir ${install_dir}) -+#ExternalProject_Add(abseil-cpp -+# GIT_REPOSITORY https://github.com/abseil/abseil-cpp.git -+# GIT_TAG ${ABSEIL_VER} -+# PREFIX ${CMAKE_SOURCE_DIR}/abseil-cpp -+# CMAKE_ARGS ${ABSEIL_CMAKE_ARGS} -+#) -+#ExternalProject_Get_Property(abseil-cpp install_dir) -+find_package(absl REQUIRED) -+set(abseil_install_dir $ENV{FREEBSD_LOCALBASE}) - include_directories (${abseil_install_dir}/include) +-option(USE_SYSTEM_ABSEIL "Force use of system abseil-cpp" OFF) +-option(USE_SYSTEM_PYBIND11 "Force use of system pybind11" OFF) ++option(USE_SYSTEM_ABSEIL "Force use of system abseil-cpp" ON) ++option(USE_SYSTEM_PYBIND11 "Force use of system pybind11" ON) - - # Define pybind11 tree module. - pybind11_add_module(_tree tree.h tree.cc) --add_dependencies(_tree abseil-cpp) -+add_dependencies(_tree absl::strings absl::config) - - if (WIN32 OR MSVC) - set(ABSEIL_LIB_PREF "absl") - set(LIB_SUFF "lib") - else() - set(ABSEIL_LIB_PREF "libabsl") -- set(LIB_SUFF "a") -+ set(LIB_SUFF "so") - endif() - - # Link abseil static libs. + # Required for Python.h and python binding. + find_package(Python3 COMPONENTS Interpreter Development) diff --git a/devel/py-dm-tree/files/patch-tree_tree.cc b/devel/py-dm-tree/files/patch-tree_tree.cc new file mode 100644 index 000000000000..54e632dd2787 --- /dev/null +++ b/devel/py-dm-tree/files/patch-tree_tree.cc @@ -0,0 +1,20 @@ +--- tree/tree.cc.orig 2026-06-16 01:26:05 UTC ++++ tree/tree.cc +@@ -115,7 +115,7 @@ class CachedTypeCheck { + auto* type = Py_TYPE(o); + + { +- absl::MutexLock lock(mutex_); ++ absl::MutexLock lock(&mutex_); + auto it = type_to_sequence_map_.find(type); + if (it != type_to_sequence_map_.end()) { + return it->second; +@@ -135,7 +135,7 @@ class CachedTypeCheck { + // that are eligible for decref. As a precaution, we limit the size of the + // map to 1024. + { +- absl::MutexLock lock(mutex_); ++ absl::MutexLock lock(&mutex_); + if (type_to_sequence_map_.size() < kMaxItemsInCache) { + Py_INCREF(type); + type_to_sequence_map_.insert({type, check_result}); diff --git a/devel/py-dm-tree/pkg-plist b/devel/py-dm-tree/pkg-plist deleted file mode 100644 index b887f6dd4bac..000000000000 --- a/devel/py-dm-tree/pkg-plist +++ /dev/null @@ -1,13 +0,0 @@ -%%PYTHON_SITELIBDIR%%/tree/__init__.py -%%PYTHON_SITELIBDIR%%/tree/__pycache__/__init__%%PYTHON_TAG%%.opt-1.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/__init__%%PYTHON_TAG%%.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/sequence%%PYTHON_TAG%%.opt-1.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/sequence%%PYTHON_TAG%%.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/tree_benchmark%%PYTHON_TAG%%.opt-1.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/tree_benchmark%%PYTHON_TAG%%.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/tree_test%%PYTHON_TAG%%.opt-1.pyc -%%PYTHON_SITELIBDIR%%/tree/__pycache__/tree_test%%PYTHON_TAG%%.pyc -%%PYTHON_SITELIBDIR%%/tree/_tree%%PYTHON_TAG%%.so -%%PYTHON_SITELIBDIR%%/tree/sequence.py -%%PYTHON_SITELIBDIR%%/tree/tree_benchmark.py -%%PYTHON_SITELIBDIR%%/tree/tree_test.pyhome | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6a315630.36d2f.75819907>
