File python-pyxdg.spec of Package python-pyxdg

# spec file for package python-pyxdg
# 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
# 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

%if 0%{?sle_version} > 120100 || 0%{?suse_version} > 1320
%bcond_without tests
%bcond_with tests

%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define oldpython python
Name:           python-pyxdg
Version:        0.25
Release:        0
Summary:        Implementations of standards in python
License:        LGPL-2.1
Group:          Development/Languages/Python
Source2:        %{name}.keyring
BuildRequires:  %{python_module devel}
%if %{with tests}
BuildRequires:  %{python_module nose}
BuildRequires:  python-rpm-macros
BuildRequires:  shared-mime-info
Requires:       shared-mime-info
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch
# Change <= to < after version 0.25
Obsoletes:      %{oldpython}-xdg < %{version}
Provides:       %{oldpython}-xdg <= %{version}
Provides:       python3-xdg = %{version}
Obsoletes:      python3-xdg <= %{version}

PyXDG is a python library to access standards. Currently supported are:
 * Base Directory Specification Version 0.6
 * Menu Specification Version 1.0
 * Desktop Entry Specification Version 1.0
 * Icon Theme Specification Version 0.8
 * Recent File Spec 0.2
 * Shared-MIME-Database Specification 0.13

%setup -q -n pyxdg-%{version}



%if %{with tests}
# test-icon fails because it's testing against spec version 0.8
# and our files moved to 0.9
rm test/
%python_expand nosetests-%{$python_bin_suffix}

%files %{python_files}

openSUSE Build Service is sponsored by