From 1039efd977b44c16c33a3b03545c95d823685d94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Tue, 26 Jul 2016 21:27:49 +0300 Subject: [PATCH] Clean up no longer needed conditionals Python >= 2.7 is now required, so EL < 7 is out as well. --- python-beautifulsoup4.spec | 29 ++++------------------------- 1 file changed, 4 insertions(+), 25 deletions(-) diff --git a/python-beautifulsoup4.spec b/python-beautifulsoup4.spec index 991d1a8..706d78f 100644 --- a/python-beautifulsoup4.spec +++ b/python-beautifulsoup4.spec @@ -1,9 +1,3 @@ -%if 0%{?fedora} || 0%{?rhel} > 6 -%bcond_without lxml -%else -%bcond_with lxml -%endif - %if 0%{?fedora} > 1 %global with_python3 1 %endif @@ -19,18 +13,11 @@ URL: http://www.crummy.com/software/BeautifulSoup/ Source0: https://files.pythonhosted.org/packages/source/b/%{oname}/%{oname}-%{version}.tar.gz BuildArch: noarch BuildRequires: python-devel >= 2.7 +# html5lib BR just for test coverage BuildRequires: python-html5lib BuildRequires: python-setuptools -%if 0%{?rhel} && 0%{?rhel} <= 6 -BuildRequires: python-unittest2 -BuildRequires: python-nose -%endif -%if %{with lxml} BuildRequires: python-lxml Requires: python-lxml -%else -Requires: python-html5lib -%endif %description Beautiful Soup is a Python HTML/XML parser designed for quick @@ -56,15 +43,12 @@ minutes with Beautiful Soup. Summary: HTML/XML parser for quick-turnaround applications like screen-scraping Group: Development/Languages BuildRequires: python-tools +# html5lib BR just for test coverage BuildRequires: python3-html5lib BuildRequires: python3-devel BuildRequires: python3-setuptools -%if %{with lxml} BuildRequires: python3-lxml Requires: python3-lxml -%else -Requires: python3-html5lib -%endif Obsoletes: python3-BeautifulSoup < 1:3.2.1-2 %description -n python3-beautifulsoup4 @@ -119,12 +103,7 @@ pushd %{py3dir} %endif %check -%if 0%{?rhel} && 0%{?rhel} <= 6 -PYTHONPATH=$(pwd) nosetests -%else %{__python} -m unittest discover -s bs4 -%endif - %if 0%{?with_python3} pushd %{py3dir} %{__python3} -m unittest discover -s bs4 @@ -148,8 +127,8 @@ pushd %{py3dir} * Tue Jul 26 2016 Ville Skyttä - 4.5.0-1 - Update to 4.5.0 - Mark COPYING.txt as %%license -- Don't require html5lib if lxml is required -- Require lxml on EL7 +- Don't require html5lib +- Require lxml on EL too * Tue Jul 19 2016 Fedora Release Engineering - 4.4.1-4 - https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages