python-texttable/python-texttable.spec

97 lines
2.8 KiB
RPMSpec
Raw Normal View History

2022-12-16 15:27:12 +08:00
%global _empty_manifest_terminate_build 0
Name: python-texttable
Version: 1.7.0
2022-12-16 15:27:12 +08:00
Release: 1
Summary: Python module for creating simple ASCII tables
License: MIT
URL: https://github.com/foutaise/texttable
Source0: https://files.pythonhosted.org/packages/source/t/texttable/texttable-%{version}.tar.gz
2022-12-16 15:27:12 +08:00
BuildArch: noarch
2020-02-17 16:58:24 +08:00
%description
Python module for creating simple ASCII tables
%package -n python3-texttable
2022-12-16 15:27:12 +08:00
Summary: Python module for creating simple ASCII tables
Provides: python-texttable = %{version}-%{release}
BuildRequires: python3-devel,
BuildRequires: python3-setuptools,
BuildRequires: python3-pytest
2020-02-17 16:58:24 +08:00
%description -n python3-texttable
Python module for creating simple ASCII tables
2022-12-16 15:27:12 +08:00
%package help
Summary: Development documents and examples for texttable
Provides: python3-texttable-doc
%description help
Python module for creating simple ASCII tables
2020-02-17 16:58:24 +08:00
%prep
%autosetup -n texttable-%{version}
%build
%py3_build
%install
%py3_install
2022-12-16 15:27:12 +08:00
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
if [ -f README.rst ]; then cp -af README.rst %{buildroot}/%{_pkgdocdir}; fi
if [ -f README.md ]; then cp -af README.md %{buildroot}/%{_pkgdocdir}; fi
if [ -f README.txt ]; then cp -af README.txt %{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 .
2020-02-17 16:58:24 +08:00
%check
py.test-%{python3_version} --verbose tests.py
2022-12-16 15:27:12 +08:00
%files -n python3-texttable -f filelist.lst
2020-02-17 16:58:24 +08:00
%license LICENSE
2022-12-16 15:27:12 +08:00
%dir %{python3_sitelib}/*
%files help -f doclist.lst
%{_docdir}/*
2020-02-17 16:58:24 +08:00
%changelog
* Tue Feb 06 2024 xu_ping <707078654@qq.com> - 1.7.0-1
- Update package to version 1.7.0
2022-12-16 15:27:12 +08:00
* Fri Dec 16 2022 wangjunqi <wangjunqi@kylinos.cn> - 1.6.7-1
- Update package to version 1.6.7
2022-08-02 16:56:17 +08:00
* Tue Aug 02 2022 zhaoshuang <zhaoshuang@uniontech.com> - 1.6.4-1
- update package to 1.6.4
* Thu Jan 14 2021 yanglongkang <yanglongkang@huawei.com> - 1.6.3-1
2021-01-28 15:29:37 +08:00
- update package to 1.6.3
2020-10-30 14:32:42 +08:00
* Fri Oct 30 2020 yanglongkang <yanglongkang@huawei.com> - 1.6.2-2
- remove python2 dependency
2020-07-16 10:19:53 +08:00
* Thu Jul 16 2020 jixinjie <jixinjie@huawei.com> - 1.6.2-1
- update package to 1.6.2
2020-07-16 10:33:12 +08:00
2020-02-17 16:58:24 +08:00
* Thu Feb 13 2020 Ruijun Ge <geruijun@huawei.com> - 1.4.0-2
- init package