%global python3_pkgversion 3.11 %global __python3 /usr/bin/python3.11 # Created by pyp2rpm-3.3.8 %global pypi_name django-auth-ldap Name: python-%{pypi_name} Version: 4.0.0 Release: 4%{?dist} Summary: Django LDAP authentication backend License: BSD URL: https://github.com/django-auth-ldap/django-auth-ldap Source0: https://files.pythonhosted.org/packages/source/d/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch BuildRequires: python%{python3_pkgversion}-devel BuildRequires: python%{python3_pkgversion}-setuptools BuildRequires: python%{python3_pkgversion}-setuptools-scm %description %{summary} %package -n python%{python3_pkgversion}-%{pypi_name} Summary: %{summary} %{?python_provide:%python_provide python%{python3_pkgversion}-%{pypi_name}} Requires: python%{python3_pkgversion}-django >= 2.2 Requires: python%{python3_pkgversion}-ldap >= 3.1 %if 0%{?rhel} == 8 Obsoletes: python39-%{pypi_name} < %{version}-%{release} %endif %description -n python%{python3_pkgversion}-%{pypi_name} %{summary} %prep set -ex %autosetup -n %{pypi_name}-%{version} # Remove bundled egg-info rm -rf %{pypi_name}.egg-info # create a minimal setup.py, the rest will be done by setuptools printf 'from setuptools import setup\nsetup(use_scm_version=True)' > setup.py %build set -ex %py3_build %install set -ex %py3_install %files -n python%{python3_pkgversion}-%{pypi_name} %license LICENSE %doc README.rst %{python3_sitelib}/django_auth_ldap %{python3_sitelib}/django_auth_ldap-%{version}-py%{python3_version}.egg-info %changelog * Tue Jan 16 2024 Odilon Sousa - 4.0.0-4 - Remove SCL bits * Tue Nov 21 2023 Patrick Creech - 4.0.0-3 - Add python39 obsoletes to package * Sat Nov 11 2023 Odilon Sousa - 4.0.0-2 - Build against python 3.11 * Wed Aug 24 2022 Odilon Sousa - 4.0.0-1 - Initial package.