PORTNAME=	build
PORTVERSION=	1.4.2
CATEGORIES=	devel python
MASTER_SITES=	PYPI
PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}

MAINTAINER=	sunpoet@FreeBSD.org
COMMENT=	Simple, correct Python build frontend
WWW=		https://build.pypa.io/en/stable/ \
		https://github.com/pypa/build

LICENSE=	MIT
LICENSE_FILE=	${WRKSRC}/LICENSE

RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}packaging>=24.0:devel/py-packaging@${PY_FLAVOR} \
		${PYTHON_PKGNAMEPREFIX}pyproject-hooks>=0:devel/py-pyproject-hooks@${PY_FLAVOR} \
		${PY_TOMLI}

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.11:devel/py-flit-core@${PY_FLAVOR}

#OPTIONS_DEFINE=	VIRTUALENV
#VIRTUALENV_DESC=	Use virtualenv for isolation

#VIRTUALENV_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}virtualenv>=20.31:devel/py-virtualenv@${PY_FLAVOR}

.include <bsd.port.mk>
