From 2277241ffb5ba686fd5a243d037fcb818d817d9d Mon Sep 17 00:00:00 2001 From: CoprDistGit Date: Mon, 10 Apr 2023 12:06:33 +0000 Subject: automatic import of python-sacrebleu --- python-sacrebleu.spec | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 python-sacrebleu.spec (limited to 'python-sacrebleu.spec') diff --git a/python-sacrebleu.spec b/python-sacrebleu.spec new file mode 100644 index 0000000..e3554fc --- /dev/null +++ b/python-sacrebleu.spec @@ -0,0 +1,82 @@ +%global _empty_manifest_terminate_build 0 +Name: python-sacrebleu +Version: 2.3.1 +Release: 1 +Summary: Hassle-free computation of shareable, comparable, and reproducible BLEU, chrF, and TER scores +License: Apache License 2.0 +URL: https://github.com/mjpost/sacrebleu +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/ab/ae/6724b9bd5018f35184c8d0a14157b3fd885db2857ce2237d59b01d6fdd21/sacrebleu-2.3.1.tar.gz +BuildArch: noarch + +Requires: python3-portalocker +Requires: python3-regex +Requires: python3-tabulate +Requires: python3-numpy +Requires: python3-colorama +Requires: python3-lxml +Requires: python3-mecab-python3 +Requires: python3-ipadic +Requires: python3-mecab-ko +Requires: python3-mecab-ko-dic + +%description + + +%package -n python3-sacrebleu +Summary: Hassle-free computation of shareable, comparable, and reproducible BLEU, chrF, and TER scores +Provides: python-sacrebleu +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-sacrebleu + + +%package help +Summary: Development documents and examples for sacrebleu +Provides: python3-sacrebleu-doc +%description help + + +%prep +%autosetup -n sacrebleu-2.3.1 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-sacrebleu -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Mon Apr 10 2023 Python_Bot - 2.3.1-1 +- Package Spec generated -- cgit v1.2.3