%global pypi_name nudepy
Name: python-%{pypi_name}
Version: 0.4
Release: 2%{?dist}
Summary: A Python module for nudity detection
License: MIT
URL: https://github.com/hhatto/nude.py
Source0: https://github.com/hhatto/nude.py/archive/ver%{version}/%{pypi_name}-%{version}.tar.gz
BuildRequires: gcc
%description
Nudity detection in images with Python.
%package -n python3-%{pypi_name}
Summary: %{summary}
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-Cython
%{?python_provide:%python_provide python3-%{pypi_name}}
%description -n python3-%{pypi_name}
Nudity detection in images with Python.
%package -n %{pypi_name}
Summary: %{summary}
Requires: python3-%{pypi_name}
%description -n %{pypi_name}
Command line tools for nudity detection in images.
%prep
%autosetup -n nude.py-ver%{version}
sed -i -e '/^#!\//, 1d' nude.py
%build
%py3_build
%install
%py3_install
%files -n python3-%{pypi_name}
%doc README.rst
# https://github.com/hhatto/nude.py/pull/22
#%license LICENSE
%{python3_sitearch}/nude.py
%{python3_sitearch}/__pycache__/*
%{python3_sitearch}/skin_classifier*
%{python3_sitearch}/%{pypi_name}*.egg-info
%files -n %{pypi_name}
%doc README.rst
#%license LICENSE
%{_bindir}/%{pypi_name}
%changelog
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.4-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Thu Jun 20 2019 Fabian Affolter <mail@fabian-affolter.ch> - 0.4-1
- Initial package for Fedora