gnu: python-django-auth-ldap: Update to 4.8.0.

* gnu/packages/django.scm (python-django-auth-ldap): Update to 4.8.0.
[source]: Switch to git-fetch.
[build-system]: Switch to pyproject-build-system.
[arguments]<#:phases>: Remove 'build and 'install phase replacements.
[native-inputs]: Remove python-wheel, python-setuptools-scm,
python-toml, python-pypa-build, python-pip.

Change-Id: Ife8eb1b63b458ca29f2d69027b86855e1cb8458d
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
This commit is contained in:
Nicolas Graves 2025-09-21 17:08:14 +02:00 committed by Sharlatan Hellseher
parent e3ba868b4e
commit 0016aea186
No known key found for this signature in database
GPG key ID: 76D727BFF62CD2B5

View file

@ -1753,44 +1753,32 @@ backends in a single library.")
(define-public python-django-auth-ldap (define-public python-django-auth-ldap
(package (package
(name "python-django-auth-ldap") (name "python-django-auth-ldap")
(version "4.1.0") (version "4.8.0")
(source (origin (source
(method url-fetch) (origin
(uri (pypi-uri "django-auth-ldap" version)) (method git-fetch)
(sha256 (uri (git-reference
(base32 (url "https://github.com/django-auth-ldap/django-auth-ldap")
"0jd9jms9qpa92fk5n7gqcxjk3zs6ay79r73ann7cw1vqn79lkxvp")))) (commit version)))
(build-system python-build-system) (file-name (git-file-name name version))
(sha256
(base32 "11mgxj05ra1yh2z9knzvcayd3zwqgl39gna0gm0xp290cyw5mnnb"))))
(build-system pyproject-build-system)
(arguments (arguments
(list #:phases (list
#~(modify-phases %standard-phases #:phases
(replace 'build #~(modify-phases %standard-phases
(lambda _ (replace 'check
;; Set file modification times to the early 80's because (lambda* (#:key inputs #:allow-other-keys)
;; the Zip format does not support earlier timestamps. (setenv "SLAPD"
(setenv "SOURCE_DATE_EPOCH" (search-input-file inputs "/libexec/slapd"))
(number->string (* 10 366 24 60 60))) (setenv "SCHEMA"
(invoke "python" "-m" "build" "--wheel" (search-input-directory inputs "etc/openldap/schema"))
"--no-isolation" "."))) (invoke "python"
(replace 'check "-m" "django" "test"
(lambda* (#:key inputs #:allow-other-keys) "--settings" "tests.settings"))))))
(setenv "SLAPD" (search-input-file inputs "/libexec/slapd")) (native-inputs (list openldap python-setuptools))
(setenv "SCHEMA" (propagated-inputs (list python-django python-ldap))
(search-input-directory inputs "etc/openldap/schema"))
(invoke "python" "-m" "django" "test"
"--settings" "tests.settings")))
(replace 'install
(lambda _
(let ((whl (car (find-files "dist" "\\.whl$"))))
(invoke "pip" "--no-cache-dir" "--no-input"
"install" "--no-deps" "--prefix" #$output whl)))))))
(native-inputs
(list openldap python-wheel python-setuptools-scm python-toml
;; These can be removed after <https://bugs.gnu.org/46848>.
python-pypa-build python-pip))
(propagated-inputs
(list python-django python-ldap))
(home-page "https://github.com/django-auth-ldap/django-auth-ldap") (home-page "https://github.com/django-auth-ldap/django-auth-ldap")
(synopsis "Django LDAP authentication backend") (synopsis "Django LDAP authentication backend")
(description (description