14
0
forked from pool/python-pypng

- Update to 0.0.19:

* No upstream changelog, many flake/codewarning fixes

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pypng?expand=0&rev=5
This commit is contained in:
Tomáš Chvátal
2019-03-01 09:54:32 +00:00
committed by Git OBS Bridge
parent fc792335a7
commit 70edd18563
4 changed files with 16 additions and 25 deletions

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-pypng
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,25 +17,20 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%bcond_without test
Name: python-pypng
Version: 0.0.18
Version: 0.0.19
Release: 0
Summary: Pure Python PNG image encoder/decoder
License: MIT
Group: Development/Languages/Python
Url: https://github.com/drj11/pypng
URL: https://github.com/drj11/pypng
Source: https://files.pythonhosted.org/packages/source/p/pypng/pypng-%{version}.tar.gz
BuildRequires: %{python_module Cython}
BuildRequires: %{python_module numpy}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: python3-2to3
%if %{with test}
BuildRequires: %{python_module numpy}
%endif
BuildArch: noarch
%python_subpackages
%description
@@ -52,22 +47,12 @@ sed -i -e '/^#!\//, 1d' code/png.py
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%if %{with test}
%check
%python_expand cp code/test_png.py test_png_%{$python_bin_suffix}.py
if [ -f test_png_%{python3_bin_suffix}.py ]; then
2to3 -wn test_png_%{python3_bin_suffix}.py
fi
%{python_expand export PYTHONPATH=%{buildroot}%{$python_sitelib}:code
$python test_png_%{$python_bin_suffix}.py
}
%endif
%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib}:code $python code/test_png.py
%files %{python_files}
%defattr(-,root,root,-)
%doc README.txt
%doc README.md
%license LICENCE
%{python_sitelib}/*
%changelog