Name: python-html5lib Version: 1.0.1 Release: 4 Epoch: 1 Summary: HTML parser based on the WHAT-WG Web Applications 1 License: MIT URL: https://github.com/html5lib/html5lib-python Source0: https://github.com/html5lib/html5lib-python/archive/html5lib-python-%{version}.tar.gz Patch0: collections-abc.patch BuildArch: noarch %?python_enable_dependency_generator %description Html5lib is a pure-python library for parsing HTML. It is designed to conform to the WHATWG HTML specification, as is implemented by all major web browsers. %package -n python2-html5lib Summary: python2 package for html5lib BuildRequires: python2-devel python2-setuptools python2-mock python2-pytest python2-six BuildRequires: python2-webencodings python2-chardet python2-genshi python2-lxml %{?python_provide:%python_provide python2-html5lib} %description -n python2-html5lib python2 package for html5lib. %package -n python3-html5lib Summary: python3 package for html5lib BuildRequires: python3-devel python3-setuptools python3-mock python3-pytest python3-pytest-expect BuildRequires: python3-webencodings python3-chardet python3-genshi python3-lxml python3-six %{?python_provide:%python_provide python3-html5lib} %description -n python3-html5lib python3 package for html5lib. %package_help %prep %autosetup -n html5lib-python-%{version} -p1 %build %py2_build %py3_build %install %py2_install %py3_install %check %{__python3} -m pytest sed -i \ -e 's/config.option.update_xfail/False/' \ -e 's/^fail_if_missing_pytest_expect.*//' \ html5lib/tests/conftest.py mv html5lib/tests/testdata{,_nope} mkdir -p html5lib/tests/testdata/encoding/chardet/ cp html5lib/tests/testdata{_nope,}/encoding/chardet/test_big5.txt %{__python2} -m pytest %files -n python2-html5lib %defattr(-,root,root) %license LICENSE %{python2_sitelib}/* %files -n python3-html5lib %defattr(-,root,root) %license LICENSE %{python3_sitelib}/* %files help %defattr(-,root,root) %doc CHANGES.rst README.rst %changelog * Tue Sep 17 2019 openEuler Buildteam - 1.0.1-4 - Type:bugfix - Id:NA - SUG:NA - DESC:optimization the spec * Tue Sep 17 2019 openEuler Buildteam - 1.0.1-3 - Package init