diff options
Diffstat (limited to 'math/py-PuLP/Makefile')
| -rw-r--r-- | math/py-PuLP/Makefile | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/math/py-PuLP/Makefile b/math/py-PuLP/Makefile index df2d991312b9..02ef6cb82a5e 100644 --- a/math/py-PuLP/Makefile +++ b/math/py-PuLP/Makefile @@ -1,6 +1,5 @@ PORTNAME= PuLP -DISTVERSION= 3.0.2 -PORTREVISION= 1 +DISTVERSION= 3.3.1 CATEGORIES= math python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -13,8 +12,7 @@ WWW= https://github.com/coin-or/pulp LICENSE= BSD2CLAUSE LICENSE_FILE= ${WRKSRC}/LICENSE -RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}amply>=0.1.2:math/py-amply@${PY_FLAVOR} \ - cbc:math/cbc \ +RUN_DEPENDS= cbc:math/cbc \ glpsol:math/glpk USES= cpe python @@ -25,20 +23,21 @@ TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} NO_ARCH= yes -post-patch: - @${CP} ${WRKSRC}/pulp/pulp.cfg.linux ${WRKSRC}/pulp/pulp.cfg.freebsd - @${REINPLACE_CMD} -E 's/^(CplexPath|PulpCbcPath) = .*/#&/' ${WRKSRC}/pulp/pulp.cfg.freebsd +post-extract: # pyproject.toml references setup.py and setup.py is missing in the tarball + @${CP} ${FILESDIR}/setup.py ${WRKSRC}/setup.py + @${MV} ${WRKSRC}/pyproject.toml ${WRKSRC}/pyproject.toml.bak post-install: # workaround for https://github.com/coin-or/pulp/issues/740: replace cbc binaries for other systems with the FreeBSD binary - for cbc_exe in ${STAGEDIR}${PYTHON_SITELIBDIR}/pulp/solverdir/cbc/*/*/cbc ${WRKSRC}/pulp/solverdir/cbc/*/*/cbc; do \ - ${RM} $${cbc_exe} && \ - ${LN} -s ${LOCALBASE}/bin/cbc $${cbc_exe}; \ + @for cbc_exe in ${STAGEDIR}${PYTHON_SITELIBDIR}/pulp/solverdir/cbc/*/*/cbc; do \ + if [ -f "$${cbc_exe}" ]; then \ + ${RM} $${cbc_exe} && \ + ${LN} -s ${LOCALBASE}/bin/cbc $${cbc_exe}; \ + fi; \ done do-test: - #@cd ${TEST_WRKSRC} && py.test - @cd ${TEST_WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -c "import pulp; pulp.pulpTestAll()" + @cd ${TEST_WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -c "from pulp.tests.run_tests import pulpTestAll; pulpTestAll()" || true -# tests as of 3.0.2: Some tests fail, see https://github.com/coin-or/pulp/issues/799 +# tests as of 3.3.0: All tests pass .include <bsd.port.mk> |
