fc73918
%global srcname kiwisolver
fc73918
fc73918
Name:           python-%{srcname}
90479f5
Version:        1.1.0
90479f5
Release:        1%{?dist}
fc73918
Summary:        A fast implementation of the Cassowary constraint solver
fc73918
fc73918
License:        BSD
fc73918
URL:            https://github.com/nucleic/kiwi
fc73918
Source0:        https://github.com/nucleic/kiwi/archive/%{version}/%{srcname}-%{version}.tar.gz
fc73918
fc73918
%global _description \
fc73918
Kiwi is an efficient C++ implementation of the Cassowary constraint solving \
fc73918
algorithm. Kiwi is an implementation of the algorithm based on the seminal \
fc73918
Cassowary paper. It is *not* a refactoring of the original C++ solver. Kiwi has \
fc73918
been designed from the ground up to be lightweight and fast.
fc73918
3bd87bb
BuildRequires:  gcc-c++
3bd87bb
fc73918
%description %{_description}
fc73918
fc73918
fc73918
%package -n     python2-%{srcname}
fc73918
Summary:        %{summary}
fc73918
%{?python_provide:%python_provide python2-%{srcname}}
fc73918
fc73918
BuildRequires:  python2-devel
fc73918
BuildRequires:  python2-setuptools
fc73918
BuildRequires:  python2-pytest
fc73918
fc73918
%description -n python2-%{srcname} %{_description}
fc73918
fc73918
fc73918
%package -n     python3-%{srcname}
fc73918
Summary:        %{summary}
fc73918
%{?python_provide:%python_provide python3-%{srcname}}
fc73918
fc73918
BuildRequires:  python3-devel
fc73918
BuildRequires:  python3-setuptools
fc73918
BuildRequires:  python3-pytest
fc73918
fc73918
%description -n python3-%{srcname} %{_description}
fc73918
fc73918
fc73918
%prep
fc73918
%autosetup -n kiwi-%{version}
fc73918
fc73918
# Remove bundled egg-info
fc73918
rm -rf %{srcname}.egg-info
fc73918
fc73918
fc73918
%build
fc73918
%py2_build
fc73918
%py3_build
fc73918
fc73918
fc73918
%install
fc73918
%py2_install
fc73918
%py3_install
fc73918
fc73918
fc73918
%check
fc73918
PYTHONPATH="%{buildroot}%{python3_sitearch}" \
fc73918
    py.test-3 py/tests/
fc73918
PYTHONPATH="%{buildroot}%{python2_sitearch}" \
fc73918
    py.test-2 py/tests/
fc73918
fc73918
fc73918
%files -n python2-%{srcname}
fc73918
%doc README.rst
90479f5
%license LICENSE
fc73918
%{python2_sitearch}/%{srcname}.so
fc73918
%{python2_sitearch}/%{srcname}-%{version}-py?.?.egg-info
fc73918
fc73918
fc73918
%files -n python3-%{srcname}
fc73918
%doc README.rst
90479f5
%license LICENSE
fc73918
%{python3_sitearch}/%{srcname}.cpython-*.so
fc73918
%{python3_sitearch}/%{srcname}-%{version}-py?.?.egg-info
fc73918
fc73918
fc73918
%changelog
90479f5
* Thu May 16 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 1.1.0-1
90479f5
- Update to latest version
90479f5
a69625f
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-4
a69625f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
a69625f
7824e64
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-3
7824e64
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
7824e64
232cb54
* Tue Jun 19 2018 Miro HronĨok <mhroncok@redhat.com> - 1.0.1-2
232cb54
- Rebuilt for Python 3.7
232cb54
fc73918
* Sat Feb 03 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 1.0.1-1
fc73918
- Initial package.