Blame python-adafruit-platformdetect.spec

cd0165c
%global pypi_name adafruit-platformdetect
cd0165c
cd0165c
Name:           python-%{pypi_name}
3fc76e1
Version:        3.22.1
1c55455
Release:        %autorelease
5a104ab
cd0165c
Summary:        Platform detection module
cd0165c
cd0165c
License:        MIT
cd0165c
URL:            https://github.com/adafruit/Adafruit_Python_PlatformDetect
cd0165c
Source0:        %{pypi_source Adafruit-PlatformDetect}
cd0165c
BuildArch:      noarch
cd0165c
cd0165c
%description
cd0165c
This library provides best-guess platform detection for a range of
cd0165c
single-board computers and (potentially) other platforms.
cd0165c
cd0165c
%package -n     python3-%{pypi_name}
cd0165c
Summary:        %{summary}
cd0165c
cd0165c
BuildRequires:  python3-devel
cd0165c
BuildRequires:  python3dist(setuptools)
cd0165c
BuildRequires:  python3dist(setuptools-scm)
cd0165c
%{?python_provide:%python_provide python3-%{pypi_name}}
cd0165c
cd0165c
%description -n python3-%{pypi_name}
cd0165c
This library provides best-guess platform detection for a range of
cd0165c
single-board computers and (potentially) other platforms.
cd0165c
cd0165c
%package -n python-%{pypi_name}-doc
cd0165c
Summary:        Documentation for adafruit-platformdetect
cd0165c
cd0165c
BuildRequires:  python3dist(sphinx)
cd0165c
%description -n python-%{pypi_name}-doc
cd0165c
Documentation for adafruit-platformdetect.
cd0165c
cd0165c
%prep
cd0165c
%autosetup -n Adafruit-PlatformDetect-%{version}
cd0165c
rm -rf %{pypi_name}.egg-info
cd0165c
cd0165c
%build
cd0165c
%py3_build
cd0165c
PYTHONPATH=${PWD} sphinx-build-3 docs html
cd0165c
rm -rf html/.{doctrees,buildinfo}
cd0165c
cd0165c
%install
cd0165c
%py3_install
cd0165c
cd0165c
%ifarch %{arm} %{arm64}
cd0165c
%check
cd0165c
%pytest -v tests
cd0165c
%endif
cd0165c
cd0165c
%files -n python3-%{pypi_name}
cd0165c
%license LICENSE
cd0165c
%doc README.rst
cd0165c
%{python3_sitelib}/adafruit_platformdetect/
cd0165c
%{python3_sitelib}/Adafruit_PlatformDetect-%{version}-py%{python3_version}.egg-info/
cd0165c
cd0165c
%files -n python-%{pypi_name}-doc
cd0165c
%doc html
cd0165c
%license LICENSE
cd0165c
cd0165c
%changelog
1c55455
%autochangelog