From 3e6d34e6366ae91b76e25bdd2417c6c9bc9e5035 Mon Sep 17 00:00:00 2001 From: zhanchengbin Date: Mon, 6 Sep 2021 15:20:40 +0800 Subject: [PATCH] remove "%bcond_with python3" from spec file to resolve local rpmbuild failure issue Signed-off-by: zhanchengbin --- python-rtslib.spec | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/python-rtslib.spec b/python-rtslib.spec index 7610e05..42e1ec1 100644 --- a/python-rtslib.spec +++ b/python-rtslib.spec @@ -1,10 +1,8 @@ -%bcond_with python3 - %global oname rtslib-fb Name: python-rtslib Version: 2.1.70 -Release: 7 +Release: 8 Summary: Python object API for Linux kernel LIO SCSI target License: ASL 2.0 @@ -28,7 +26,6 @@ Obsoletes: python-rtslib-doc which includes the 'target' service and targetctl tool for restoring configuration. -%if %{with python3} %package -n python3-rtslib Summary: Python3 object API for Linux kernel LIO SCSI target BuildRequires: python3-devel, python3-setuptools @@ -39,13 +36,10 @@ Requires: python3-kmod, python3-six, python3-pyudev python3-rtslib is a python object API for generic Linux SCSI kernel target which includes the 'target' service and targetctl tool for restoring configuration. -%endif %package -n target-restore Summary: Systemd service for targetcli/rtslib -%if %{with python3} Requires: python3-rtslib = %{version}-%{release} -%endif %description -n target-restore Systemd service to restore the LIO kernel target settings on system @@ -56,27 +50,21 @@ restart. %prep %autosetup -n %{oname}-%{version} -p1 -%if %{with python3} rm -rf %{py3dir} cp -a . %{py3dir} -%endif %build gzip --stdout doc/targetctl.8 > doc/targetctl.8.gz gzip --stdout doc/saveconfig.json.5 > doc/saveconfig.json.5.gz -%if 0%{?with_python3} pushd %{py3dir} %py3_build popd -%endif %install -%if %{with python3} pushd %{py3dir} %py3_install popd -%endif mkdir -p %{buildroot}%{_mandir}/man8/ mkdir -p %{buildroot}%{_mandir}/man5/ @@ -97,12 +85,10 @@ install -m 644 doc/saveconfig.json.5.gz %{buildroot}%{_mandir}/man5/ %postun -n target-restore %systemd_postun_with_restart target.service -%if %{with python3} %files -n python3-rtslib %defattr(-,root,root) %license COPYING %{python3_sitelib}/* -%endif %files -n target-restore %defattr(-,root,root) @@ -121,6 +107,9 @@ install -m 644 doc/saveconfig.json.5.gz %{buildroot}%{_mandir}/man5/ %{_mandir}/man5/saveconfig.json.5.gz %changelog +* Mon Sep 6 2021 zhanchengbin - 2.1.70-8 +- remove "%bcond_with python3" from spec file to resolve local rpmbuild failure issue + * Mon Nov 2 2020 Zhiqiang Liu - 2.1.70-7 - backport upstream patch to solve one problem -- Gitee