git: 3fb91363d0e1 - main - www/py-dj40-django-auth-ldap: Switch to PEP517

From: Kai Knoblich <kai_at_FreeBSD.org>
Date: Sun, 12 Feb 2023 13:02:00 UTC
The branch main has been updated by kai:

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

commit 3fb91363d0e1f4a9a67c2f61767c2d4600972edc
Author:     Kai Knoblich <kai@FreeBSD.org>
AuthorDate: 2023-02-12 12:59:38 +0000
Commit:     Kai Knoblich <kai@FreeBSD.org>
CommitDate: 2023-02-12 13:01:23 +0000

    www/py-dj40-django-auth-ldap: Switch to PEP517
    
    * Bump PORTREVISION as the package no longer contains byte-code.
---
 www/py-dj40-django-auth-ldap/Makefile       | 12 ++++++------
 www/py-dj40-django-auth-ldap/files/setup.py |  5 -----
 2 files changed, 6 insertions(+), 11 deletions(-)

diff --git a/www/py-dj40-django-auth-ldap/Makefile b/www/py-dj40-django-auth-ldap/Makefile
index f946503c2e77..79d839331f93 100644
--- a/www/py-dj40-django-auth-ldap/Makefile
+++ b/www/py-dj40-django-auth-ldap/Makefile
@@ -1,5 +1,6 @@
 PORTNAME=	django-auth-ldap
 PORTVERSION=	4.1.0
+PORTREVISION=	1
 CATEGORIES=	www security python
 MASTER_SITES=	PYPI
 PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}dj40-
@@ -11,12 +12,13 @@ WWW=		https://github.com/django-auth-ldap/django-auth-ldap
 LICENSE=	BSD2CLAUSE
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
-BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}setuptools_scm>=3.4:devel/py-setuptools_scm@${PY_FLAVOR}
+BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}setuptools_scm>=3.4:devel/py-setuptools_scm@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR}
 RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}django40>=2.2:www/py-django40@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}ldap>=3.1:net/py-ldap@${PY_FLAVOR}
 
 USES=		python:3.6+
-USE_PYTHON=	autoplist concurrent distutils
+USE_PYTHON=	autoplist concurrent pep517
 
 CONFLICTS_INSTALL=	${PYTHON_PKGNAMEPREFIX}*${PORTNAME}
 
@@ -24,11 +26,9 @@ NO_ARCH=	yes
 PORTDOCS=	*
 OPTIONS_DEFINE=	DOCS
 DOCS_BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}sphinx>=0,1:textproc/py-sphinx@${PY_FLAVOR}
-DOCS_VARS=		PYDISTUTILS_BUILD_TARGET+="build_sphinx -a -E"
 
-# Workaround to make the port still buildable with "distutils"
-post-extract:
-	@${CP} ${FILESDIR}/setup.py ${WRKSRC}/
+post-build-DOCS-on:
+	${LOCALBASE}/bin/sphinx-build-${PYTHON_VER} -d ${WRKDIR} -b html ${WRKSRC}/docs ${WRKSRC}/build/sphinx/html
 
 post-install-DOCS-on:
 	@${MKDIR} ${STAGEDIR}${DOCSDIR}
diff --git a/www/py-dj40-django-auth-ldap/files/setup.py b/www/py-dj40-django-auth-ldap/files/setup.py
deleted file mode 100644
index 927cf403e2f6..000000000000
--- a/www/py-dj40-django-auth-ldap/files/setup.py
+++ /dev/null
@@ -1,5 +0,0 @@
-# Taken from the previous release (= 3.0.0)
-
-from setuptools import setup
-
-setup()