14
0

Accepting request 480647 from home:tbechtold:branches:devel:languages:python

- Switch to singlespec approach

OBS-URL: https://build.opensuse.org/request/show/480647
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-iso8601?expand=0&rev=15
This commit is contained in:
2017-03-16 19:59:53 +00:00
committed by Git OBS Bridge
parent 0390ec7f06
commit eb1fb20400
2 changed files with 19 additions and 16 deletions

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-iso8601
#
# 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,6 +16,7 @@
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-iso8601
Version: 0.1.11
Release: 0
@@ -25,16 +26,13 @@ License: MIT
Group: Development/Languages/Python
Source: iso8601-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python-devel
BuildRequires: python-setuptools
# Test requirements:
BuildRequires: python-pytest >= 2.4.2
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
Requires: python-argparse
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%else
BuildRequires: %{python_module devel}
BuildRequires: %{python_module pytest >= 2.4.2}
BuildRequires: %{python_module setuptools}
BuildRequires: python-rpm-macros
BuildArch: noarch
%endif
%python_subpackages
%description
Simple module to parse ISO 8601 dates
@@ -46,15 +44,15 @@ This module parses the most common forms of ISO 8601 date strings (e.g.
%setup -q -n iso8601-%{version}
%build
python setup.py build
%check
py.test --verbose iso8601
%python_build
%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
%python_install
%files
%check
%python_exec %{_bindir}/py.test --verbose iso8601
%files %python_files
%defattr(-,root,root,-)
%doc README.rst LICENSE
%{python_sitelib}/*