Accepting request 507531 from home:okurz:branches:devel:languages:python

Convert to singlespec

OBS-URL: https://build.opensuse.org/request/show/507531
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-attrs?expand=0&rev=5
This commit is contained in:
Thomas Bechtold 2017-07-03 11:17:31 +00:00 committed by Git OBS Bridge
parent a5ead23504
commit d308681a38
2 changed files with 25 additions and 11 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sat Jul 1 14:53:33 UTC 2017 - okurz@suse.com
- Convert to singlespec
-------------------------------------------------------------------
Tue Jul 5 17:20:56 UTC 2016 - hpj@urpla.net

View File

@ -1,7 +1,7 @@
#
# spec file for package python-attrs
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -16,16 +16,22 @@
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-attrs
%global modname attrs
Version: 16.0.0
Release: 0
Summary: Attributes without boilerplate
License: MIT
Group: Development/Languages/Python
Url: https://github.com/hynek/attrs/
Source: https://pypi.io/packages/source/a/attrs/attrs-%{version}.tar.gz
BuildRequires: python-devel
BuildRequires: python-pytest
Url: https://github.com/hynek/%{modname}/
Source: https://pypi.io/packages/source/a/%{modname}/%{modname}-%{version}.tar.gz
BuildRequires: %{python_module devel}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
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()")}
@ -33,6 +39,8 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%endif
%python_subpackages
%description
attrs is an MIT-licensed Python package with class decorators that ease the
chores of implementing the most common attribute-related object protocols.
@ -54,18 +62,19 @@ life!
python-attrs is the successor to python-characterstic
%prep
%setup -q -n attrs-%{version}
%setup -q -n %{modname}-%{version}
%build
python setup.py build
%python_build
%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
%python_install
%fdupes %{buildroot}%{_prefix}
%files
%files %{python_files}
%defattr(-,root,root,-)
%doc CHANGELOG.rst LICENSE README.rst
%{python_sitelib}/attr/
%{python_sitelib}/attrs-%{version}-py*.egg-info
%{python_sitelib}/*
%{python_sitelib}/%{modname}-%{version}-py*.egg-info
%changelog