Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 7 Mar 2023 09:37:54 GMT
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: bd2fe235ab9b - main - =?utf-8?Q?science/chemicalfun:=20Update=200.1.7=20=E2=86=92=200.1.8?=
Message-ID:  <202303070937.3279bsAL000598@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by yuri:

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

commit bd2fe235ab9b715811db34c804c07778f2bcf2ee
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2023-03-07 09:26:49 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2023-03-07 09:37:50 +0000

    science/chemicalfun: Update 0.1.7 → 0.1.8
---
 science/chemicalfun/Makefile                            | 16 ++++++++++++----
 science/chemicalfun/distinfo                            |  6 +++---
 .../files/patch-python_chemicalfun_CMakeLists.txt       | 17 +++++++++++++----
 science/chemicalfun/pkg-plist                           |  9 +++++++--
 4 files changed, 35 insertions(+), 13 deletions(-)

diff --git a/science/chemicalfun/Makefile b/science/chemicalfun/Makefile
index 1b6b39050c28..6f1d9755098f 100644
--- a/science/chemicalfun/Makefile
+++ b/science/chemicalfun/Makefile
@@ -1,5 +1,5 @@
 PORTNAME=	chemicalfun
-DISTVERSION=	0.1.7
+DISTVERSION=	0.1.8
 CATEGORIES=	science # chemistry
 MASTER_SITES=	https://bitbucket.org/${BB_ACCOUNT}/${PORTNAME}/get/${BB_COMMIT}${EXTRACT_SUFX}?dummy=/:src
 DISTFILES=	${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX}:src
@@ -8,17 +8,21 @@ MAINTAINER=	yuri@FreeBSD.org
 COMMENT=	C++ library for working with chemical reactions and formulas
 WWW=		https://bitbucket.org/gems4/chemicalfun/src/master/
 
-BUILD_DEPENDS=	nlohmann-json>0:devel/nlohmann-json
+BUILD_DEPENDS=	nlohmann-json>0:devel/nlohmann-json \
+		${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pip>0:devel/py-pip@${PY_FLAVOR}
 LIB_DEPENDS=	libfmt.so:devel/libfmt # due to SPDLOG_FMT_EXTERNAL
 LIB_DEPENDS+=	libspdlog.so:devel/spdlog
 
 USES=		cmake:testing compiler:c++17-lang eigen:3 localbase
 
 BB_ACCOUNT=	gems4
-BB_COMMIT=	7b43744ec72d
+BB_COMMIT=	46c628fef376
 
 WRKSRC=		${WRKDIR}/${BB_ACCOUNT}-${PORTNAME}-${BB_COMMIT}
 
+CMAKE_ARGS=	-DFREEBSD_PREFIX=${PREFIX} -DFREEBSD_STAGEDIR=${STAGEDIR} \
+		-DPython_EXECUTABLE=${PYTHON_CMD}
 CMAKE_TESTING_ON=	CHEMICALFUN_BUILD_TESTS # tests fail to compile, BitBucket offers no easy way to report this
 CMAKE_TESTING_TARGET=	${ALL_TARGET} # hack to prevent test run
 
@@ -31,10 +35,14 @@ OPTIONS_SUB=		yes
 
 PYTHON_USES=		python
 PYTHON_CMAKE_BOOL=	CHEMICALFUN_BUILD_PYTHON
-PYTHON_CMAKE_ON=	-DFREEBSD_STAGEDIR=${STAGEDIR}
+PYTHON_CMAKE_ON=	-DFREEBSD_PREFIX=${PREFIX}
 PYTHON_BUILD_DEPENDS=	pybind11>0:devel/pybind11
 
 post-install-PYTHON-on:
+	# remove wrong *.pyc, see related bug https://bitbucket.org/gems4/chemicalfun/issues/1/please-support-stagedir
+	@${FIND} ${STAGEDIR} -name "*.pyc" -delete
+	@${FIND} ${STAGEDIR} -name __pycache__ -delete
+	# strip binary
 	@${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/chemicalfun/PyChemicalFun${PYTHON_EXT_SUFFIX}.so
 
 post-test:
diff --git a/science/chemicalfun/distinfo b/science/chemicalfun/distinfo
index c20ba32c0c19..677b1b6d4fb2 100644
--- a/science/chemicalfun/distinfo
+++ b/science/chemicalfun/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1672213422
-SHA256 (chemicalfun-0.1.7.tar.gz) = 1f25409cba68bdf3fda4e01ca8e2e50d8402b986236c0eb52845238602487710
-SIZE (chemicalfun-0.1.7.tar.gz) = 935004
+TIMESTAMP = 1678175797
+SHA256 (chemicalfun-0.1.8.tar.gz) = c260f2b23a0bd75019eb35ced4db8ec6f88627f839fde64ad2b87ec629c272c2
+SIZE (chemicalfun-0.1.8.tar.gz) = 939981
diff --git a/science/chemicalfun/files/patch-python_chemicalfun_CMakeLists.txt b/science/chemicalfun/files/patch-python_chemicalfun_CMakeLists.txt
index 1153bd6914ff..cf20bea619f2 100644
--- a/science/chemicalfun/files/patch-python_chemicalfun_CMakeLists.txt
+++ b/science/chemicalfun/files/patch-python_chemicalfun_CMakeLists.txt
@@ -1,11 +1,20 @@
---- python/chemicalfun/CMakeLists.txt.orig	2022-07-17 18:29:23 UTC
+--- python/chemicalfun/CMakeLists.txt.orig	2023-03-01 15:14:05 UTC
 +++ python/chemicalfun/CMakeLists.txt
-@@ -43,7 +43,7 @@ install(CODE
+@@ -31,7 +31,7 @@ add_custom_target(chemicalfun ALL
+     COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:PyChemicalFun>
+         ${CMAKE_CURRENT_BINARY_DIR}/$<TARGET_FILE_NAME:PyChemicalFun>
+     #COMMAND ${PYTHON_EXECUTABLE} -m pip install ${_PIP_ARG} -e ${CMAKE_CURRENT_BINARY_DIR}
+-    COMMAND ${PYTHON_EXECUTABLE} -m pip install --prefix ${CMAKE_BINARY_DIR} --ignore-installed .
++    COMMAND ${PYTHON_EXECUTABLE} -m pip install --root ${FREEBSD_STAGEDIR} --prefix ${FREEBSD_PREFIX} --ignore-installed .
+     WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
+ 
+ # Set dependencies of PyChemicalFun target
+@@ -60,7 +60,7 @@ install(CODE
      endif()
  
      execute_process(
--        COMMAND ${PYTHON_EXECUTABLE} ${SETUP_PY} install --prefix=\${CHEMICALFUN_PYTHON_INSTALL_PREFIX_NATIVE}
-+        COMMAND ${PYTHON_EXECUTABLE} ${SETUP_PY} install --root=${FREEBSD_STAGEDIR} --prefix=\${CHEMICALFUN_PYTHON_INSTALL_PREFIX_NATIVE}
+-        COMMAND ${PYTHON_EXECUTABLE} -m pip install --prefix \${CHEMICALFUN_PYTHON_INSTALL_PREFIX_NATIVE} ${CMAKE_CURRENT_BINARY_DIR}
++        COMMAND ${PYTHON_EXECUTABLE} -m pip install --root ${FREEBSD_STAGEDIR} --prefix ${FREEBSD_PREFIX} ${CMAKE_CURRENT_BINARY_DIR}
          WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
  "
  )
diff --git a/science/chemicalfun/pkg-plist b/science/chemicalfun/pkg-plist
index b5b2c6ef3830..b730080e8561 100644
--- a/science/chemicalfun/pkg-plist
+++ b/science/chemicalfun/pkg-plist
@@ -13,7 +13,12 @@ lib/cmake/ChemicalFun/ChemicalFunConfigVersion.cmake
 lib/cmake/ChemicalFun/ChemicalFunTargets-%%CMAKE_BUILD_TYPE%%.cmake
 lib/cmake/ChemicalFun/ChemicalFunTargets.cmake
 lib/libChemicalFun.so
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/INSTALLER
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/METADATA
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/RECORD
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/REQUESTED
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/WHEEL
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/direct_url.json
+%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.8.dist-info/top_level.txt
 %%PYTHON_SITELIBDIR%%/chemicalfun/PyChemicalFun%%PYTHON_EXT_SUFFIX%%.so
 %%PYTHON_SITELIBDIR%%/chemicalfun/__init__.py
-%%PYTHON_SITELIBDIR%%/chemicalfun/__pycache__/__init__%%PYTHON_EXT_SUFFIX%%.pyc
-%%PYTHON_SITELIBDIR%%/chemicalfun-0.1.7-py%%PYTHON_VER%%.egg-info



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202303070937.3279bsAL000598>