forked from pool/python-jsonschema
- Add condition around the python2 code to make sure we can build
in python3 only URL OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-jsonschema?expand=0&rev=29
This commit is contained in:
committed by
Git OBS Bridge
parent
b1fcffcda7
commit
d59cd154fc
@@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jan 24 10:24:27 UTC 2018 - tchvatal@suse.com
|
||||||
|
|
||||||
|
- Add condition around the python2 code to make sure we can build
|
||||||
|
in python3 only enviroment
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Apr 19 22:13:57 UTC 2017 - toddrme2178@gmail.com
|
Wed Apr 19 22:13:57 UTC 2017 - toddrme2178@gmail.com
|
||||||
|
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-jsonschema
|
# spec file for package python-jsonschema
|
||||||
#
|
#
|
||||||
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -17,6 +17,7 @@
|
|||||||
|
|
||||||
|
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
|
%bcond_without python2
|
||||||
Name: python-jsonschema
|
Name: python-jsonschema
|
||||||
Version: 2.6.0
|
Version: 2.6.0
|
||||||
Release: 0
|
Release: 0
|
||||||
@@ -25,21 +26,20 @@ License: MIT
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Url: http://github.com/Julian/jsonschema
|
Url: http://github.com/Julian/jsonschema
|
||||||
Source: https://files.pythonhosted.org/packages/source/j/jsonschema/jsonschema-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/j/jsonschema/jsonschema-%{version}.tar.gz
|
||||||
BuildRequires: fdupes
|
BuildRequires: %{python_module mock}
|
||||||
BuildRequires: python-rpm-macros
|
|
||||||
BuildRequires: %{python_module devel}
|
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module vcversioner >= 2.16.0.0}
|
BuildRequires: %{python_module vcversioner >= 2.16.0.0}
|
||||||
|
BuildRequires: fdupes
|
||||||
|
BuildRequires: python-rpm-macros
|
||||||
|
%if %{with python2}
|
||||||
BuildRequires: python2-functools32
|
BuildRequires: python2-functools32
|
||||||
# Test build requirements
|
|
||||||
BuildRequires: python2-mock
|
|
||||||
%ifpython2
|
|
||||||
Requires: python-functools32
|
|
||||||
%endif
|
%endif
|
||||||
Requires(post): update-alternatives
|
Requires(post): update-alternatives
|
||||||
Requires(preun): update-alternatives
|
Requires(preun): update-alternatives
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
%ifpython2
|
||||||
|
Requires: python-functools32
|
||||||
|
%endif
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -69,7 +69,6 @@ for Python (supporting 2.6+ including Python 3).
|
|||||||
%python_uninstall_alternative jsonschema
|
%python_uninstall_alternative jsonschema
|
||||||
|
|
||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%defattr(-,root,root,-)
|
|
||||||
%doc COPYING README.rst
|
%doc COPYING README.rst
|
||||||
%python_alternative %{_bindir}/jsonschema
|
%python_alternative %{_bindir}/jsonschema
|
||||||
%{python_sitelib}/*
|
%{python_sitelib}/*
|
||||||
|
Reference in New Issue
Block a user