Skip to content

Commit

Permalink
devel/py-build: Convert to USE_PYTHON=pep517
Browse files Browse the repository at this point in the history
- Add build for all Python flavors/versions (USE_PYTHON=allflavors)
- Bump PORTREVISION for dependency and package change
  • Loading branch information
sunpoet committed Feb 12, 2023
1 parent 74ca7d8 commit e7cfa31
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 64 deletions.
11 changes: 6 additions & 5 deletions devel/py-build/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
PORTNAME= build
PORTVERSION= 0.10.0
PORTREVISION= 1
CATEGORIES= devel python
MASTER_SITES= PYPI
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
Expand All @@ -14,11 +15,14 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}packaging>=19.0:devel/py-packaging@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pyproject_hooks>=0:devel/py-pyproject_hooks@${PY_FLAVOR}

USES= python:3.7+
USE_PYTHON= autoplist concurrent distutils
USES= python
USE_PYTHON= allflavors autoplist concurrent pep517

NO_ARCH= yes

PEP517_BUILD_CMD= ${PYTHON_CMD} -m flit_core.wheel
PEP517_BUILD_DEPEND= ${PYTHON_PKGNAMEPREFIX}flit-core>=3.4:devel/py-flit-core@${PY_FLAVOR}

.include <bsd.port.pre.mk>

.if ${PYTHON_REL} < 30800
Expand All @@ -29,7 +33,4 @@ RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}importlib-metadata>=0.22:devel/py-importlib
RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}tomli>=1.1.0:textproc/py-tomli@${PY_FLAVOR}
.endif

post-patch:
@${SED} -e 's|%%PORTVERSION%%|${PORTVERSION}|' ${FILESDIR}/setup.py > ${WRKSRC}/setup.py

.include <bsd.port.post.mk>
59 changes: 0 additions & 59 deletions devel/py-build/files/setup.py

This file was deleted.

0 comments on commit e7cfa31

Please sign in to comment.