2014-09-15 17:02:46 +02:00
|
|
|
#
|
|
|
|
# spec file for package python-xmltodict
|
|
|
|
#
|
2017-05-18 17:26:31 +02:00
|
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
2014-09-15 17:02:46 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
2014-11-04 17:21:05 +01:00
|
|
|
#
|
2014-09-15 17:02:46 +02:00
|
|
|
|
|
|
|
|
2017-05-18 17:26:31 +02:00
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
|
|
%bcond_without test
|
2014-09-15 17:02:46 +02:00
|
|
|
Name: python-xmltodict
|
2017-05-18 17:26:31 +02:00
|
|
|
Version: 0.11.0
|
2014-09-15 17:02:46 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Makes working with XML feel like you are working with JSON
|
2014-11-04 17:21:05 +01:00
|
|
|
License: MIT
|
2014-09-15 17:02:46 +02:00
|
|
|
Group: Development/Languages/Python
|
2014-11-04 17:21:05 +01:00
|
|
|
Url: https://github.com/martinblech/xmltodict
|
2017-05-18 17:26:31 +02:00
|
|
|
Source: https://files.pythonhosted.org/packages/source/x/xmltodict/xmltodict-%{version}.tar.gz
|
|
|
|
BuildRequires: %{python_module devel}
|
|
|
|
BuildRequires: %{python_module setuptools}
|
|
|
|
BuildRequires: %{python_module xml}
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
%if %{with test}
|
|
|
|
BuildRequires: %{python_module nose >= 1.0}
|
2014-11-04 17:21:05 +01:00
|
|
|
%endif
|
2017-05-18 17:26:31 +02:00
|
|
|
Requires: python-xml
|
2014-09-15 17:02:46 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
BuildArch: noarch
|
2017-05-18 17:26:31 +02:00
|
|
|
%python_subpackages
|
2014-09-15 17:02:46 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
xmltodict is a Python module that makes working with XML feel like you are
|
2017-05-18 17:26:31 +02:00
|
|
|
working with json, as in this:
|
2014-09-15 17:02:46 +02:00
|
|
|
http://www.xml.com/pub/a/2006/05/31/converting-between-xml-and-json.html
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n xmltodict-%{version}
|
2017-05-18 17:26:31 +02:00
|
|
|
sed -i '1{\@^#!/usr/bin/env python@d}' xmltodict.py
|
2014-09-15 17:02:46 +02:00
|
|
|
|
|
|
|
%build
|
2017-05-18 17:26:31 +02:00
|
|
|
%python_build
|
2014-09-15 17:02:46 +02:00
|
|
|
|
|
|
|
%install
|
2017-05-18 17:26:31 +02:00
|
|
|
%python_install
|
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
2014-09-15 17:02:46 +02:00
|
|
|
|
2017-05-18 17:26:31 +02:00
|
|
|
%if %{with test}
|
2016-09-07 10:42:31 +02:00
|
|
|
%check
|
2017-05-18 17:26:31 +02:00
|
|
|
%python_expand nosetests-%{$python_bin_suffix}
|
2016-09-07 10:42:31 +02:00
|
|
|
%endif
|
|
|
|
|
2017-05-18 17:26:31 +02:00
|
|
|
%files %{python_files}
|
2014-09-15 17:02:46 +02:00
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%doc README.md LICENSE
|
2017-05-18 17:26:31 +02:00
|
|
|
%{python_sitelib}/xmltodict.py*
|
|
|
|
%pycache_only %{python_sitelib}/__pycache__/xmltodict.*.py*
|
|
|
|
%{python_sitelib}/xmltodict-%{version}-py*.egg-info
|
2014-09-15 17:02:46 +02:00
|
|
|
|
2014-11-04 17:21:05 +01:00
|
|
|
%changelog
|