]> git.pld-linux.org Git - packages/python-pyenchant.git/blame - python-pyenchant.spec
- disable python3 here
[packages/python-pyenchant.git] / python-pyenchant.spec
CommitLineData
dde642e5
JB
1#
2# Conditional build:
3%bcond_with tests # unit tests (require en_US dictionary)
4%bcond_without python2 # CPython 2.x module
b56722e6 5%bcond_with python3 # CPython 3.x module (built from python3-pyenchant.spec)
dde642e5
JB
6
7Summary: Spellchecking library for Python 2
8Summary(pl.UTF-8): Biblioteka Pythona 2 sprawdzająca pisownię
9Name: python-pyenchant
b56722e6 10# keep 2.x here for python2 support
dde642e5 11Version: 2.0.0
78553e4d 12Release: 5
e94c4e84 13License: LGPL v2.1+
dde642e5
JB
14Group: Libraries/Python
15#Source0Download: https://pypi.org/simple/pyenchant/
16Source0: https://files.pythonhosted.org/packages/source/p/pyenchant/pyenchant-%{version}.tar.gz
17# Source0-md5: c224ea53e119b04116d5301e5027051c
18URL: https://pypi.org/project/pyenchant/
19%if %{with python2}
20BuildRequires: python-devel >= 1:2.5
21BuildRequires: python-setuptools >= 1:7
22%endif
23%if %{with python3}
24BuildRequires: python3-2to3 >= 1:3.2
25BuildRequires: python3-devel >= 1:3.2
26BuildRequires: python3-setuptools >= 1:7
27%endif
7b2aaf41 28BuildRequires: rpm-pythonprov
dde642e5
JB
29BuildRequires: rpmbuild(macros) >= 1.714
30Requires: enchant >= 1.6.0
31Requires: python-libs >= 1:2.5
32BuildArch: noarch
7b2aaf41 33BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35%description
36PyEnchant is a set of language bindings and some wrapper classes to
37make the excellent Enchant spellchecker available as a Python module.
38
bc7d51f2
JR
39%description -l pl.UTF-8
40PyEnchant to zbiór dowiązań języka i klas obudowujących
41udostępniających świetną bibliotekę sprawdzania pisowni Enchant jako
42moduł Pythona.
af14651e 43
dde642e5
JB
44%package -n python3-pyenchant
45Summary: Spellchecking library for Python 3
46Summary(pl.UTF-8): Biblioteka Pythona 3 sprawdzająca pisownię
47Group: Libraries/Python
48Requires: enchant >= 1.6.0
49Requires: python3-libs >= 1:3.2
50
51%description -n python3-pyenchant
52PyEnchant is a set of language bindings and some wrapper classes to
53make the excellent Enchant spellchecker available as a Python module.
54
55%description -n python3-pyenchant -l pl.UTF-8
56PyEnchant to zbiór dowiązań języka i klas obudowujących
57udostępniających świetną bibliotekę sprawdzania pisowni Enchant jako
58moduł Pythona.
59
7b2aaf41 60%prep
dde642e5 61%setup -q -n pyenchant-%{version}
7b2aaf41 62
63%build
dde642e5
JB
64%if %{with python2}
65%py_build %{?with_tests:test}
66%endif
67
68%if %{with python3}
69%py3_build %{?with_tests:test}
70%endif
7b2aaf41 71
72%install
73rm -rf $RPM_BUILD_ROOT
74
dde642e5
JB
75%if %{with python2}
76%py_install
7b2aaf41 77
4517f318 78%py_postclean
dde642e5
JB
79%{__rm} $RPM_BUILD_ROOT%{py_sitescriptdir}/enchant/tests.py*
80%endif
81
82%if %{with python3}
83%py3_install
84
85%{__rm} $RPM_BUILD_ROOT%{py3_sitescriptdir}/enchant/tests.py
86%{__rm} $RPM_BUILD_ROOT%{py3_sitescriptdir}/enchant/__pycache__/tests.*.py*
87%endif
7b2aaf41 88
89%clean
90rm -rf $RPM_BUILD_ROOT
91
dde642e5 92%if %{with python2}
7b2aaf41 93%files
94%defattr(644,root,root,755)
4517f318 95%doc README.txt TODO.txt
dde642e5 96%{py_sitescriptdir}/enchant
4517f318 97%{py_sitescriptdir}/pyenchant-%{version}-py*.egg-info
dde642e5
JB
98%endif
99
100%if %{with python3}
101%files -n python3-pyenchant
102%defattr(644,root,root,755)
103%doc README.txt TODO.txt
104%{py3_sitescriptdir}/enchant
105%{py3_sitescriptdir}/pyenchant-%{version}-py*.egg-info
106%endif
This page took 0.175712 seconds and 4 git commands to generate.