From 57d18c82bc4fa29da555a8192fcbf52de48947b68ccbcf80d292dedf23edbdb6 Mon Sep 17 00:00:00 2001 From: Todd R Date: Thu, 7 Sep 2017 21:43:32 +0000 Subject: [PATCH] Accepting request 522178 from home:TheBlackCat:branches:devel:languages:python - Implement single-spec version. OBS-URL: https://build.opensuse.org/request/show/522178 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-discogs-client?expand=0&rev=2 --- python-discogs-client.changes | 5 +++++ python-discogs-client.spec | 39 ++++++++++++++++++++--------------- 2 files changed, 27 insertions(+), 17 deletions(-) diff --git a/python-discogs-client.changes b/python-discogs-client.changes index 7c82bad..9590841 100644 --- a/python-discogs-client.changes +++ b/python-discogs-client.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Sep 7 20:07:01 UTC 2017 - toddrme2178@gmail.com + +- Implement single-spec version. + ------------------------------------------------------------------- Tue Oct 20 23:08:08 UTC 2015 - hpj@urpla.net diff --git a/python-discogs-client.spec b/python-discogs-client.spec index 65765e1..f5f0394 100644 --- a/python-discogs-client.spec +++ b/python-discogs-client.spec @@ -1,7 +1,7 @@ # # spec file for package python-discogs-client # -# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2017 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2015 LISA GmbH, Bingen, Germany. # # All modifications and additions to the file contributed by third parties @@ -16,6 +16,8 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ +%{?!python_module:%define python_module() python-%{**} python3-%{**}} +%bcond_without test Name: python-discogs-client Version: 2.2.1 Release: 0 @@ -23,21 +25,20 @@ License: BSD-2-Clause Summary: Official Python API client for Discogs Url: https://github.com/discogs/discogs_client Group: Development/Languages/Python -Source: https://pypi.python.org/packages/source/d/discogs-client/discogs-client-%{version}.tar.gz -BuildRequires: python-devel -BuildRequires: python-setuptools -BuildRequires: python-requests +Source: https://files.pythonhosted.org/packages/source/d/discogs-client/discogs-client-%{version}.tar.gz +BuildRequires: %{python_module devel} +BuildRequires: %{python_module oauthlib} +BuildRequires: %{python_module requests} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module six} +BuildRequires: fdupes +BuildRequires: python-rpm-macros Requires: python-requests -BuildRequires: python-six Requires: python-six -BuildRequires: python-oauthlib Requires: python-oauthlib -BuildRoot: %{_tmppath}/%{name}-%{version}-build -%if 0%{?suse_version} && 0%{?suse_version} <= 1110 -%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} -%else BuildArch: noarch -%endif + +%python_subpackages %description This is the official Discogs API client for Python. It enables you to query the @@ -50,16 +51,20 @@ and wantlists, inventory, and orders. %setup -q -n discogs-client-%{version} %build -python setup.py build +%python_build %install -python setup.py install --prefix=%{_prefix} --root=%{buildroot} +%python_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} +%if %{with test} %check -python setup.py test +%python_exec setup.py test +%endif -%files +%files %{python_files} %defattr(-,root,root,-) -%{python_sitelib}/* +%{python_sitelib}/discogs_client/ +%{python_sitelib}/discogs_client-%{version}-py*.egg-info %changelog