2011-04-15 15:47:52 +02:00
|
|
|
#
|
|
|
|
# spec file for package python-pyenchant
|
|
|
|
#
|
2024-03-11 18:12:13 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2011-04-15 15:47:52 +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.
|
2013-06-17 14:52:59 +02:00
|
|
|
|
2019-01-08 12:26:59 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2011-04-15 15:47:52 +02:00
|
|
|
#
|
|
|
|
|
2013-06-17 14:52:59 +02:00
|
|
|
|
2023-09-30 15:01:35 +02:00
|
|
|
%{?sle15_python_module_pythons}
|
2017-08-31 18:51:54 +02:00
|
|
|
Name: python-pyenchant
|
2021-12-01 09:00:18 +01:00
|
|
|
Version: 3.2.2
|
2011-04-15 15:47:52 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Python bindings for the Enchant spellchecking system
|
2018-08-24 15:05:32 +02:00
|
|
|
License: LGPL-2.1-or-later
|
2020-03-20 10:15:49 +01:00
|
|
|
URL: https://pyenchant.github.io/pyenchant
|
|
|
|
Source: https://github.com/pyenchant/pyenchant/archive/v%{version}.tar.gz#/pyenchant-%{version}.tar.gz
|
2023-09-30 15:01:35 +02:00
|
|
|
BuildRequires: %{python_module pip}
|
2020-03-20 10:15:49 +01:00
|
|
|
BuildRequires: %{python_module pytest}
|
2017-08-31 18:51:54 +02:00
|
|
|
BuildRequires: %{python_module setuptools}
|
2023-09-30 15:01:35 +02:00
|
|
|
BuildRequires: %{python_module wheel}
|
2019-01-08 12:26:59 +01:00
|
|
|
%if 0%{?suse_version} > 1500
|
2018-08-24 15:05:32 +02:00
|
|
|
BuildRequires: enchant-2-backend-hunspell
|
2019-01-08 12:26:59 +01:00
|
|
|
%else
|
|
|
|
BuildRequires: enchant
|
|
|
|
%endif
|
2017-08-31 18:51:54 +02:00
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: myspell-en
|
|
|
|
BuildRequires: myspell-en_AU
|
|
|
|
BuildRequires: myspell-en_US
|
2018-08-24 15:05:32 +02:00
|
|
|
BuildRequires: python-rpm-macros
|
2019-01-08 12:26:59 +01:00
|
|
|
%if 0%{?suse_version} > 1500
|
2018-08-24 15:05:32 +02:00
|
|
|
Requires: enchant-2-backend-hunspell
|
2019-01-08 12:26:59 +01:00
|
|
|
%else
|
|
|
|
Requires: enchant
|
|
|
|
%endif
|
2018-08-24 15:05:32 +02:00
|
|
|
Provides: python-enchant
|
2012-02-20 14:35:59 +01:00
|
|
|
BuildArch: noarch
|
2017-08-31 18:51:54 +02:00
|
|
|
%python_subpackages
|
2011-04-15 15:47:52 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
PyEnchant is a spellchecking library for Python, based on the excellent Enchant library.
|
|
|
|
|
|
|
|
%prep
|
2017-08-31 18:51:54 +02:00
|
|
|
%setup -q -n pyenchant-%{version}
|
|
|
|
chmod a-x *.txt
|
2020-03-20 10:15:49 +01:00
|
|
|
# cleanup github tarball
|
|
|
|
rm -rf website .github archive tools
|
2011-04-15 15:47:52 +02:00
|
|
|
|
|
|
|
%build
|
2023-09-30 15:01:35 +02:00
|
|
|
%pyproject_wheel
|
2011-04-15 15:47:52 +02:00
|
|
|
|
|
|
|
%install
|
2023-09-30 15:01:35 +02:00
|
|
|
%pyproject_install
|
2017-08-31 18:51:54 +02:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
|
|
|
|
|
|
|
%check
|
|
|
|
export LANG=en_US.UTF-8
|
2020-05-21 18:11:05 +02:00
|
|
|
%python_exec -c 'import enchant; print(vars(enchant.Dict()))'
|
2024-03-11 18:12:13 +01:00
|
|
|
ignore=""
|
|
|
|
%if 0%{suse_version} == 1600
|
|
|
|
# test_can_use_multiprocessing fails to build in OBS for ALP,
|
|
|
|
# bsc#1221034
|
|
|
|
ignore="--ignore tests/test_multiprocessing.py"
|
|
|
|
%endif
|
|
|
|
%pytest $ignore
|
2011-04-15 15:47:52 +02:00
|
|
|
|
2017-08-31 18:51:54 +02:00
|
|
|
%files %{python_files}
|
2018-08-24 15:05:32 +02:00
|
|
|
%license LICENSE.txt
|
2020-03-20 10:15:49 +01:00
|
|
|
%doc README.rst TODO.txt
|
2017-08-31 18:51:54 +02:00
|
|
|
%{python_sitelib}/enchant
|
2023-09-30 15:01:35 +02:00
|
|
|
%{python_sitelib}/pyenchant-%{version}.dist-info
|
2011-04-15 15:47:52 +02:00
|
|
|
|
|
|
|
%changelog
|