diff --git a/python-docker-compose.changes b/python-docker-compose.changes index 7e24fba..5a14e98 100644 --- a/python-docker-compose.changes +++ b/python-docker-compose.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Fri Jan 10 14:56:46 UTC 2020 - Tomáš Chvátal + +- Properly conditionalize python2 build + ------------------------------------------------------------------- Thu Jan 9 18:28:21 UTC 2020 - Todd R diff --git a/python-docker-compose.spec b/python-docker-compose.spec index bb40a00..764aa49 100644 --- a/python-docker-compose.spec +++ b/python-docker-compose.spec @@ -17,7 +17,12 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define skip_python2 1 +%if 0%{suse_version} > 1500 +%bcond_with python2 +%define skip_python2 1 +%else +%bcond_without python2 +%endif Name: python-docker-compose Version: 1.25.1 Release: 0 @@ -57,8 +62,26 @@ Requires: python-texttable >= 0.9.1 Requires: python-urllib3 >= 1.21.1 Requires: python-websocket-client >= 0.32.0 BuildArch: noarch +# This is py3 only as we have the binary just there +%ifpython3 Provides: docker-compose = %{version} Obsoletes: docker-compose < %{version} +%endif +%if %{with python2} +BuildRequires: python2-backports.shutil_get_terminal_size >= 1.0.0 +BuildRequires: python2-backports.ssl_match_hostname >= 3.5 +BuildRequires: python2-enum34 >= 1.0.4 +BuildRequires: python2-ipaddress >= 1.0.16 +BuildRequires: python2-mock >= 1.0.1 +BuildRequires: python2-subprocess32 >= 3.5.4 +%endif +%ifpython2 +Requires: python-backports.shutil_get_terminal_size >= 1.0.0 +Requires: python-backports.ssl_match_hostname >= 3.5 +Requires: python-enum34 >= 1.0.4 +Requires: python-ipaddress >= 1.0.16 +Requires: python-subprocess32 >= 3.5.4 +%endif %python_subpackages %description