commit cf82fd99ba15b8424997d4f5ceccc54452d7b330 Author: overweight <5324761+overweight@user.noreply.gitee.com> Date: Mon Sep 30 11:15:39 2019 -0400 Package init diff --git a/python-webencodings-0.5.1.tar.gz b/python-webencodings-0.5.1.tar.gz new file mode 100644 index 0000000..32fcc86 Binary files /dev/null and b/python-webencodings-0.5.1.tar.gz differ diff --git a/python-webencodings.spec b/python-webencodings.spec new file mode 100644 index 0000000..138f413 --- /dev/null +++ b/python-webencodings.spec @@ -0,0 +1,117 @@ +%bcond_without python2 +%bcond_without python3 + +Name: python-webencodings +Version: 0.5.1 +Release: 7 +Summary: Character encoding for the web +License: BSD +URL: https://github.com/gsnedders/python-webencodings +BuildArch: noarch + +Source0: %{url}/archive/%{name}-%{version}.tar.gz + +%if %{with python2} +BuildRequires: python2-devel +BuildRequires: python2-pytest +%endif + +%if %{with python3} +BuildRequires: python3-devel +BuildRequires: python3-pytest +BuildRequires: python3-sphinx +%endif + +%description +This is a Python implementation of the WHATWG Encoding standard. + +%package help +Summary: Documentation for python-webencodings +Provides: python-webencodings-doc +Obsoletes: python-webencodings-doc + +%description help +Documentation for python-webencodings. + +%if %{with python2} +%package -n python2-webencodings +Summary: %{summary} + +%{?python_provide:%python_provide python2-webencodings} + +Requires: python2 + +%description -n python2-webencodings +This is a Python2 implementation of the WHATWG Encoding standard. +%endif + +%if %{with python3} +%package -n python3-webencodings +Summary: %{summary} + +%{?python_provide:%python_provide python3-webencodings} + +Requires: python3 + +%description -n python3-webencodings +This is a Python3 implementation of the WHATWG Encoding standard. +%endif + +%prep +%autosetup -n python-webencodings-%{version} + +%build +%if %{with python2} +%py2_build +%endif + +%if %{with python3} +%py3_build +%endif + +PYTHONPATH=. sphinx-build-3 docs docs/_build + +rm -rf docs/_build/.buildinfo +rm -rf docs/_build/.doctrees + +%install +%if %{with python2} +%py2_install +%endif + +%if %{with python3} +%py3_install +%endif + + +%check +%if %{with python2} +py.test-2 +%endif + +%if %{with python3} +py.test-3 +%endif + +%files help +%doc docs/_build + +%if %{with python2} +%files -n python2-webencodings +%license LICENSE +%doc README.rst +%{python2_sitelib}/webencodings +%{python2_sitelib}/*.egg-info +%endif + +%if %{with python3} +%files -n python3-webencodings +%license LICENSE +%doc README.rst +%{python3_sitelib}/webencodings +%{python3_sitelib}/*.egg-info +%endif + +%changelog +* Tue Aug 27 2019 openEuler Buildteam - 0.5.1-7 +- Package init