2018-03-03 18:38:09 +01:00
|
|
|
#
|
|
|
|
# spec file for package python-lexicon
|
|
|
|
#
|
2021-09-17 05:51:30 +02:00
|
|
|
# Copyright (c) 2021 SUSE LLC
|
2018-03-03 18:38:09 +01: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.
|
|
|
|
|
2018-12-04 14:38:10 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2018-03-04 10:43:32 +01:00
|
|
|
#
|
2018-03-03 18:38:09 +01:00
|
|
|
|
|
|
|
|
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
|
|
Name: python-lexicon
|
2021-09-17 05:51:30 +02:00
|
|
|
Version: 2.0.1
|
2018-03-03 18:38:09 +01:00
|
|
|
Release: 0
|
2018-03-04 10:43:32 +01:00
|
|
|
Summary: Python dict subclass(es) with aliasing and attribute access
|
2018-03-03 18:38:09 +01:00
|
|
|
License: BSD-2-Clause
|
2018-04-23 15:16:38 +02:00
|
|
|
URL: https://github.com/bitprophet/lexicon
|
2018-03-03 18:38:09 +01:00
|
|
|
Source: https://files.pythonhosted.org/packages/source/l/lexicon/lexicon-%{version}.tar.gz
|
2021-09-17 05:51:30 +02:00
|
|
|
Patch0: add-pytest-ini.patch
|
2018-03-03 18:38:09 +01:00
|
|
|
BuildRequires: %{python_module setuptools}
|
2018-04-23 15:16:38 +02:00
|
|
|
BuildRequires: fdupes
|
2018-03-04 10:43:32 +01:00
|
|
|
BuildRequires: python-rpm-macros
|
2018-04-23 15:16:38 +02:00
|
|
|
Requires: python-six
|
|
|
|
# Completely different pkg but same namespece in sitelib folder
|
|
|
|
Conflicts: python-dns-lexicon
|
|
|
|
BuildArch: noarch
|
2018-03-03 18:38:09 +01:00
|
|
|
# SECTION tests
|
2021-09-17 05:51:30 +02:00
|
|
|
BuildRequires: %{python_module pytest-relaxed}
|
2018-03-03 18:38:09 +01:00
|
|
|
# /SECTION tests
|
|
|
|
%python_subpackages
|
|
|
|
|
|
|
|
%description
|
2018-03-04 10:43:32 +01:00
|
|
|
Lexicon is a collection of dict subclasses:
|
2018-03-03 18:38:09 +01:00
|
|
|
|
|
|
|
* AliasDict, a dictionary supporting both simple and complex key aliasing
|
2018-03-04 10:43:32 +01:00
|
|
|
* AttributeDict, supporting attribute read and write access
|
2018-03-03 18:38:09 +01:00
|
|
|
* Lexicon, a subclass of both of the above which exhibits both sets of behavior
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n lexicon-%{version}
|
2021-09-17 05:51:30 +02:00
|
|
|
%autopatch -p1
|
2018-03-03 18:38:09 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
%python_build
|
|
|
|
|
|
|
|
%install
|
|
|
|
%python_install
|
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
|
|
|
|
|
|
|
%check
|
2021-09-17 05:51:30 +02:00
|
|
|
%pytest
|
2018-03-03 18:38:09 +01:00
|
|
|
|
|
|
|
%files %{python_files}
|
2021-09-17 05:51:30 +02:00
|
|
|
%doc README.rst
|
2018-03-03 18:38:09 +01:00
|
|
|
%license LICENSE
|
|
|
|
%{python_sitelib}/*
|
|
|
|
|
|
|
|
%changelog
|