Blame SPECS/python3.11-attrs.spec

b45136
%global __python3 /usr/bin/python3.11
b45136
%global python3_pkgversion 3.11
b45136
b45136
%global modname attrs
b45136
b45136
%if 0%{?rhel} && 0%{?rhel} <= 9
b45136
# Can't run tests on RHEL9 due to the need for hypothesis and zope-interface
b45136
%bcond_with tests
b45136
%else
b45136
# Turn the tests off when bootstrapping Python, because pytest requires attrs
b45136
%bcond_without tests
b45136
%endif
b45136
b45136
Name:           python%{python3_pkgversion}-attrs
b45136
Version:        22.1.0
b45136
Release:        1%{?dist}
b45136
Summary:        Python attributes without boilerplate
b45136
b45136
License:        MIT
b45136
URL:            http://www.attrs.org/
b45136
BuildArch:      noarch
b45136
Source0:        https://github.com/hynek/%{modname}/archive/%{version}/%{modname}-%{version}.tar.gz
b45136
b45136
BuildRequires:  python%{python3_pkgversion}-devel
b45136
BuildRequires:  python%{python3_pkgversion}-rpm-macros
b45136
BuildRequires:  python%{python3_pkgversion}-setuptools
b45136
%if %{with tests}
b45136
BuildRequires:  python%{python3_pkgversion}-pytest
b45136
BuildRequires:  python%{python3_pkgversion}-hypothesis
b45136
BuildRequires:  python%{python3_pkgversion}-six
b45136
BuildRequires:  python%{python3_pkgversion}-zope-interface
b45136
%endif
b45136
b45136
b45136
%description -n python%{python3_pkgversion}-%{modname}
b45136
attrs is an MIT-licensed Python package with class decorators that
b45136
ease the chores of implementing the most common attribute-related
b45136
object protocols.
b45136
b45136
%prep
b45136
%setup -q -n %{modname}-%{version}
b45136
b45136
%build
b45136
%py3_build
b45136
b45136
%install
b45136
%py3_install
b45136
b45136
%if %{with tests}
b45136
%check
b45136
PYTHONPATH=%{buildroot}/%{python3_sitelib} py.test-%{python3_pkgversion} -v
b45136
%endif
b45136
b45136
%files
b45136
%license LICENSE
b45136
%doc AUTHORS.rst README.rst
b45136
%{python3_sitelib}/*
b45136
b45136
%changelog
b45136
* Wed Oct 19 2022 Charalampos Stratakis <cstratak@redhat.com> - 22.1.0-1
b45136
- Initial package
b45136
- Fedora contributions by:
b45136
      Lumir Balhar <lbalhar@redhat.com>
b45136
      Miro HronĨok <miro@hroncok.cz>
b45136
      Tomas Hrnciar <thrnciar@redhat.com>