python-openstack-doc-tools/python-openstack-doc-tools.spec
zhangy1317 83a3e7fedd upgrade to 2.0.0
(cherry picked from commit 3df5daa0c6d2606cf5b8ef2a94c847313a0bc74e)
2021-11-17 16:22:18 +08:00

96 lines
2.9 KiB
RPMSpec

%global _empty_manifest_terminate_build 0
Name: python-openstack-doc-tools
Version: 2.0.0
Release: 1
Summary: Tools for OpenStack Documentation
License: Apache-2.0
URL: https://docs.openstack.org/openstack-doc-tools/latest/
Source0: https://files.pythonhosted.org/packages/cb/16/9da8ae1978eca337336d0fd99b99fef404ab21bcbd4a467dcdd1eaacbc6d/openstack-doc-tools-2.0.0.tar.gz
BuildArch: noarch
%description
This repository contains tools used by the OpenStack Documentation.
%package -n python3-openstack-doc-tools
Summary: Tools for OpenStack Documentation
Provides: python-openstack-doc-tools
# Base build requires
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-pbr
BuildRequires: python3-pip
BuildRequires: python3-wheel
# General requires
BuildRequires: python3-iso8601
BuildRequires: python3-lxml
BuildRequires: python3-docutils
#BuildRequires: python3-demjson
BuildRequires: python3-pyyaml
BuildRequires: python3-sphinx
# General requires
Requires: python3-pbr
Requires: python3-iso8601
Requires: python3-lxml
Requires: python3-docutils
#Requires: python3-demjson
Requires: python3-pyyaml
Requires: python3-sphinx
%description -n python3-openstack-doc-tools
This repository contains tools used by the OpenStack Documentation.
%package help
Summary: Tools for OpenStack Documentation
Provides: python3-openstack-doc-tools-doc
%description help
This repository contains tools used by the OpenStack Documentation.
%prep
%autosetup -n openstack-doc-tools-%{version}
sed -i '/demjson/d' requirements.txt
%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-openstack-doc-tools -f filelist.lst
%dir %{python3_sitelib}/*
%files help -f doclist.lst
%{_docdir}/*
%files
%{_datadir}
%changelog
* Wed Nov 17 2021 OpenStack_SIG <openstack@openeuler.org> - 2.0.0-1
- Upgrade to 2.0.0
* Fri Oct 29 2021 OpenStack_SIG <openstack@openeuler.org> - 1.0.1-1
- Init package python3-openstack-doc-tools of version 1.0.1