From 3596bdd0a4dc8f9d8af4f393326ecf032f2615f78e1377712e3bb9d724d7d26c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Sat, 14 Mar 2020 08:26:48 +0000 Subject: [PATCH] - Fix build without python2 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-jsonpickle?expand=0&rev=18 --- python-jsonpickle.changes | 5 +++++ python-jsonpickle.spec | 15 +++++++-------- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/python-jsonpickle.changes b/python-jsonpickle.changes index df6fa67..d16c85b 100644 --- a/python-jsonpickle.changes +++ b/python-jsonpickle.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sat Mar 14 08:25:54 UTC 2020 - Tomáš Chvátal + +- Fix build without python2 + ------------------------------------------------------------------- Fri Feb 28 18:31:13 CET 2020 - Matej Cepl diff --git a/python-jsonpickle.spec b/python-jsonpickle.spec index 654c663..df316ea 100644 --- a/python-jsonpickle.spec +++ b/python-jsonpickle.spec @@ -18,12 +18,12 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} %define modname jsonpickle +%bcond_without python2 Name: python-jsonpickle Version: 1.3 Release: 0 Summary: Python library for serializing any arbitrary object graph into JSON License: BSD-3-Clause -Group: Development/Languages/Python URL: https://github.com/jsonpickle/jsonpickle Source: https://files.pythonhosted.org/packages/source/j/jsonpickle/jsonpickle-%{version}.tar.gz # PATCH-FIX-UPSTREAM PR292-Python38.patch gh#jsonpickle/jsonpickle#281 mcepl@suse.com @@ -36,23 +36,22 @@ Recommends: python-simplejson Suggests: python-demjson Suggests: python-ujson Suggests: python-yajl +BuildArch: noarch # SECTION test requirements BuildRequires: %{python_module SQLAlchemy} BuildRequires: %{python_module coverage} BuildRequires: %{python_module numpy} BuildRequires: %{python_module pymongo} BuildRequires: %{python_module pytest} -BuildRequires: python -BuildRequires: python3 +BuildRequires: %{pythons} # /SECTION -# SECTION python 2 test requirements +%if %{with python2} BuildRequires: python-enum34 -# /SECTION -# SECTION python 2 requirements +%endif +%ifpython2 Suggests: python-feedparser Suggests: python-jsonlib -BuildArch: noarch -# /SECTION +%endif %python_subpackages %description