Группа :: Development/Python3
Пакет: python3-module-nltk
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
%define _unpackaged_files_terminate_build 1
%define pypi_name nltk
%define mod_name %pypi_name
%def_with check
Name: python3-module-%pypi_name
Version: 3.8.1
Release: alt1
Summary: Python modules for Natural Language Processing (NLP)
License: Apache-2.0
Group: Development/Python3
Url: http://www.nltk.org
VCS: https://github.com/nltk/nltk
BuildArch: noarch
Source: %name-%version.tar
# apply only for tests on RPM build
Patch0: skip_nltk_data_tests.patch
# direct dep
%py3_requires joblib
# optional deps, not packaged yet
%filter_from_requires /python3\(\.[[:digit:]]\)\?(twython\(\..*\)\?)/d
BuildRequires(pre): rpm-build-python3
# build backend and its deps
BuildRequires: python3(setuptools)
BuildRequires: python3(wheel)
%if_with check
BuildRequires: python3(click)
BuildRequires: python3(joblib)
BuildRequires: python3(pytest)
BuildRequires: python3(pytest_mock)
BuildRequires: python3(regex)
BuildRequires: python3(scipy)
BuildRequires: python3(sklearn)
BuildRequires: python3(sqlite3)
BuildRequires: python3(tqdm)
%endif
%description
NLTK -- the Natural Language Toolkit -- is a suite of open source Python
modules, data sets, and tutorials supporting research and development in
Natural Language Processing.
%prep
%setup
%build
%pyproject_build
%install
%pyproject_install
# don't package tests
rm -r %buildroot%python3_sitelibdir/*/test
%check
patch -p1 < %PATCH0
%pyproject_run_pytest -vra nltk --ignore nltk/test/unit/test_downloader.py
%files
%_bindir/nltk
%python3_sitelibdir/%mod_name/
%python3_sitelibdir/%{pyproject_distinfo %pypi_name}/
%changelog
…
Полный changelog можно просмотреть здесь
%define pypi_name nltk
%define mod_name %pypi_name
%def_with check
Name: python3-module-%pypi_name
Version: 3.8.1
Release: alt1
Summary: Python modules for Natural Language Processing (NLP)
License: Apache-2.0
Group: Development/Python3
Url: http://www.nltk.org
VCS: https://github.com/nltk/nltk
BuildArch: noarch
Source: %name-%version.tar
# apply only for tests on RPM build
Patch0: skip_nltk_data_tests.patch
# direct dep
%py3_requires joblib
# optional deps, not packaged yet
%filter_from_requires /python3\(\.[[:digit:]]\)\?(twython\(\..*\)\?)/d
BuildRequires(pre): rpm-build-python3
# build backend and its deps
BuildRequires: python3(setuptools)
BuildRequires: python3(wheel)
%if_with check
BuildRequires: python3(click)
BuildRequires: python3(joblib)
BuildRequires: python3(pytest)
BuildRequires: python3(pytest_mock)
BuildRequires: python3(regex)
BuildRequires: python3(scipy)
BuildRequires: python3(sklearn)
BuildRequires: python3(sqlite3)
BuildRequires: python3(tqdm)
%endif
%description
NLTK -- the Natural Language Toolkit -- is a suite of open source Python
modules, data sets, and tutorials supporting research and development in
Natural Language Processing.
%prep
%setup
%build
%pyproject_build
%install
%pyproject_install
# don't package tests
rm -r %buildroot%python3_sitelibdir/*/test
%check
patch -p1 < %PATCH0
%pyproject_run_pytest -vra nltk --ignore nltk/test/unit/test_downloader.py
%files
%_bindir/nltk
%python3_sitelibdir/%mod_name/
%python3_sitelibdir/%{pyproject_distinfo %pypi_name}/
%changelog
…
Полный changelog можно просмотреть здесь