git: d4ed384c79e2 - main - www/py-drf-yasg: Remove COREAPI option

From: Kai Knoblich <kai_at_FreeBSD.org>
Date: Sun, 29 Jun 2025 10:46:27 UTC
The branch main has been updated by kai:

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

commit d4ed384c79e2a6d104d877b3d59eb6737c98e095
Author:     Kai Knoblich <kai@FreeBSD.org>
AuthorDate: 2025-06-29 10:04:13 +0000
Commit:     Kai Knoblich <kai@FreeBSD.org>
CommitDate: 2025-06-29 10:11:18 +0000

    www/py-drf-yasg: Remove COREAPI option
    
    * The COREAPI option depends on devel/py-coreapi, which is slated for
      removal since 19213c610945.  Therefore, drop the COREAPI option in
      preparation for the removal of devel/py-coreapi which should happen
      in the next few days.
    
    * Also switch to the PEP517 build framework and bump PORTREVISION due
      changed package contents.
---
 www/py-drf-yasg/Makefile                   | 12 ++++++------
 www/py-drf-yasg/files/patch-pyproject.toml |  9 +++++++++
 2 files changed, 15 insertions(+), 6 deletions(-)

diff --git a/www/py-drf-yasg/Makefile b/www/py-drf-yasg/Makefile
index f903134fd6c8..0e363bb41d6a 100644
--- a/www/py-drf-yasg/Makefile
+++ b/www/py-drf-yasg/Makefile
@@ -1,5 +1,6 @@
 PORTNAME=	drf-yasg
 DISTVERSION=	1.21.10
+PORTREVISION=	1
 CATEGORIES=	www python
 MASTER_SITES=	PYPI
 PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
@@ -11,7 +12,9 @@ WWW=		https://github.com/axnsan12/drf-yasg
 LICENSE=	BSD3CLAUSE
 LICENSE_FILE=	${WRKSRC}/LICENSE.rst
 
-BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}setuptools-scm>=3.0.6:devel/py-setuptools-scm@${PY_FLAVOR}
+BUILD_DEPENDS=	${PY_SETUPTOOLS} \
+		${PYTHON_PKGNAMEPREFIX}setuptools-scm>=3.0.6:devel/py-setuptools-scm@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR}
 RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}django42>=2.2.16:www/py-django42@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}djangorestframework>=3.10.3:www/py-djangorestframework@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}inflection>=0.3.1:devel/py-inflection@${PY_FLAVOR} \
@@ -21,20 +24,17 @@ RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}django42>=2.2.16:www/py-django42@${PY_FLAVOR
 		${PYTHON_PKGNAMEPREFIX}pyyaml>=5.1:devel/py-pyyaml@${PY_FLAVOR}
 
 USES=		python
-USE_PYTHON=	distutils autoplist
+USE_PYTHON=	autoplist pep517
 
 CONFLICTS_INSTALL=	${PYTHON_PKGNAMEPREFIX}*${PORTNAME}
 
 NO_ARCH=		yes
 
-OPTIONS_DEFINE=		COREAPI VALIDATION
+OPTIONS_DEFINE=		VALIDATION
 OPTIONS_DEFAULT=	VALIDATION
 
-COREAPI_DESC=		Enable CoreAPI validation mechanisms
 VALIDATION_DESC=	Enable built-in OpenAPI validation mechanisms
 
-COREAPI_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}coreapi>=2.3.3:devel/py-coreapi@${PY_FLAVOR} \
-			${PYTHON_PKGNAMEPREFIX}coreschema>=0.0.4:devel/py-coreschema@${PY_FLAVOR}
 VALIDATION_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}swagger-spec-validator>=2.1.0:devel/py-swagger-spec-validator@${PY_FLAVOR}
 
 .include <bsd.port.mk>
diff --git a/www/py-drf-yasg/files/patch-pyproject.toml b/www/py-drf-yasg/files/patch-pyproject.toml
new file mode 100644
index 000000000000..c60b2ad1b63d
--- /dev/null
+++ b/www/py-drf-yasg/files/patch-pyproject.toml
@@ -0,0 +1,9 @@
+Relax version requirements for py-setuptools.
+
+--- pyproject.toml.orig	2025-06-23 15:36:27 UTC
++++ pyproject.toml
+@@ -1,3 +1,3 @@
+ [build-system]
+-requires = ["setuptools >= 68.0.0", "wheel", "setuptools-scm >= 3.0.3"]
++requires = ["setuptools", "wheel", "setuptools-scm >= 3.0.3"]
+ build-backend = "setuptools.build_meta"