Convert from Fedora for the Python 3.12 stack in RHEL

This commit is contained in:
Tomáš Hrnčiar 2023-10-17 23:29:38 +02:00
parent 053f5412b2
commit e801a404ef

View File

@ -1,20 +1,25 @@
Name: python-iniconfig
%global __python3 /usr/bin/python3.12
%global python3_pkgversion 3.12
Name: python%{python3_pkgversion}-iniconfig
Version: 1.1.1
Release: 14%{?dist}
Release: 1%{?dist}
Summary: Brain-dead simple parsing of ini files
# SPDX
License: MIT
URL: http://github.com/RonnyPfannschmidt/iniconfig
BuildArch: noarch
BuildRequires: python3-devel
BuildRequires: pyproject-rpm-macros
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-rpm-macros
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: python%{python3_pkgversion}-wheel
# pytest 6+ needs this and this uses pytest for tests
%bcond_without tests
%bcond_with tests
%if %{with tests}
# We BR pytest manually to avoid a dependency on tox in ELN/RHEL
BuildRequires: python3-pytest
BuildRequires: python%{python3_pkgversion}-pytest
%endif
Source0: %{pypi_source iniconfig}
@ -33,11 +38,6 @@ having a unique set of features:
%description %_description
%package -n python3-iniconfig
Summary: %{summary}
%description -n python3-iniconfig %_description
%prep
%autosetup -n iniconfig-%{version}
# Remove undeclared dependency on python-py
@ -45,17 +45,16 @@ Summary: %{summary}
sed -i "s/py\.test/pytest/" testing/test_iniconfig.py
%generate_buildrequires
%pyproject_buildrequires
# Remove dependency on setuptools-scm
sed -i "s/ *use_scm_version=.*,/version='%{version}',/" setup.py
%build
%pyproject_wheel
%py3_build
%install
%pyproject_install
%pyproject_save_files iniconfig
%py3_install
%if %{with tests}
@ -64,56 +63,18 @@ sed -i "s/py\.test/pytest/" testing/test_iniconfig.py
%endif
%files -n python3-iniconfig -f %{pyproject_files}
%files -n python%{python3_pkgversion}-iniconfig
%doc README.txt
%license LICENSE
%{python3_sitelib}/iniconfig-%{version}-py%{python3_version}.egg-info/
%{python3_sitelib}/iniconfig/
%changelog
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Tue Oct 17 2023 Tomáš Hrnčiar <thrnciar@redhat.com> - 1.1.1-1
- Initial package
- Fedora contributions by:
Lumir Balhar <lbalhar@redhat.com>
Miro Hrončok <miro@hroncok.cz>
Tomas Hrnciar <thrnciar@redhat.com>
* Fri Jun 16 2023 Python Maint <python-maint@redhat.com> - 1.1.1-13
- Rebuilt for Python 3.12
* Tue Jun 13 2023 Python Maint <python-maint@redhat.com> - 1.1.1-12
- Bootstrap for Python 3.12
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Dec 08 2022 Lumír Balhar <lbalhar@redhat.com> - 1.1.1-10
- Fix build with pytest 7.2 and tox 4
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 1.1.1-8
- Rebuilt for Python 3.11
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 1.1.1-7
- Bootstrap for Python 3.11
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 1.1.1-4
- Rebuilt for Python 3.10
* Wed Jun 02 2021 Python Maint <python-maint@redhat.com> - 1.1.1-3
- Bootstrap for Python 3.10
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Thu Oct 15 2020 Tomas Hrnciar <thrnciar@redhat.com> - 1.1.1-1
- Update to 1.1.1 (#1888157)
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Mon Jul 13 2020 Miro Hrončok <mhroncok@redhat.com> - 1.0.0-1
- Initial package (#1856421)