remove python2
This commit is contained in:
parent
eff1294c33
commit
deb4f0434d
21
pywbem.spec
21
pywbem.spec
@ -1,16 +1,16 @@
|
|||||||
%global py2_build_dir %{_builddir}/%{name}-%{version}-%{release}-python2
|
%global py2_build_dir %{_builddir}/%{name}-%{version}-%{release}-python2
|
||||||
%bcond_with python2
|
%define with_python2 0
|
||||||
%global __requires_exclude ^.*python[2|3]*.7dist\\(.*\\).*$
|
%global __requires_exclude ^.*python[2|3]*.7dist\\(.*\\).*$
|
||||||
|
|
||||||
Name: pywbem
|
Name: pywbem
|
||||||
Version: 0.12.4
|
Version: 0.12.4
|
||||||
Release: 4
|
Release: 5
|
||||||
Summary: WBEM client and WBEM indication listener
|
Summary: WBEM client and WBEM indication listener
|
||||||
License: LGPLv2
|
License: LGPLv2
|
||||||
URL: https://github.com/pywbem/pywbem
|
URL: https://github.com/pywbem/pywbem
|
||||||
Source0: pywbem-%{version}.tar.gz
|
Source0: pywbem-%{version}.tar.gz
|
||||||
|
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
BuildRequires: python2-pip python2-pbr python2-pyyaml python2-ply python2-rpm-macros python2-devel
|
BuildRequires: python2-pip python2-pbr python2-pyyaml python2-ply python2-rpm-macros python2-devel
|
||||||
%endif
|
%endif
|
||||||
BuildRequires: python3-pip python3-PyYAML python3-ply python3-rpm-macros python3-pbr python3-devel git
|
BuildRequires: python3-pip python3-PyYAML python3-ply python3-rpm-macros python3-pbr python3-devel git
|
||||||
@ -24,7 +24,7 @@ standards DSP0200 and DSP0201. The CIM/WBEM infrastructure is used for a wide
|
|||||||
variety of systems management tasks supported by systems running WBEM servers.
|
variety of systems management tasks supported by systems running WBEM servers.
|
||||||
A WBEM indication listener allows receiving indications generated by a WBEM server.
|
A WBEM indication listener allows receiving indications generated by a WBEM server.
|
||||||
|
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
%package -n python2-pywbem
|
%package -n python2-pywbem
|
||||||
Summary: Python2 WBEM client and WBEM indication listener
|
Summary: Python2 WBEM client and WBEM indication listener
|
||||||
Requires: m2crypto python2-pyyaml python2-six python2-ply python2-mock python2-pbr
|
Requires: m2crypto python2-pyyaml python2-six python2-ply python2-mock python2-pbr
|
||||||
@ -52,7 +52,7 @@ standards DSP0200 and DSP0201. The CIM/WBEM infrastructure is used for a wide
|
|||||||
variety of systems management tasks supported by systems running WBEM servers.
|
variety of systems management tasks supported by systems running WBEM servers.
|
||||||
A WBEM indication listener allows receiving indications generated by a WBEM server.
|
A WBEM indication listener allows receiving indications generated by a WBEM server.
|
||||||
|
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
%package twisted
|
%package twisted
|
||||||
Summary: Python2 WBEM client bindings for Twisted Python
|
Summary: Python2 WBEM client bindings for Twisted Python
|
||||||
Requires: python2-twisted %{name} = %{version}-%{release}
|
Requires: python2-twisted %{name} = %{version}-%{release}
|
||||||
@ -68,13 +68,13 @@ the open source MIT license.
|
|||||||
|
|
||||||
%build
|
%build
|
||||||
|
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
cp -a . %{py2_build_dir}
|
cp -a . %{py2_build_dir}
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
PBR_VERSION="%{version}" CFLAGS="%{optflags}" %{__python3} setup.py build
|
PBR_VERSION="%{version}" CFLAGS="%{optflags}" %{__python3} setup.py build
|
||||||
|
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
cd %{py2_build_dir}
|
cd %{py2_build_dir}
|
||||||
PBR_VERSION="%{version}" CFLAGS="%{optflags}" %{__python2} setup.py build
|
PBR_VERSION="%{version}" CFLAGS="%{optflags}" %{__python2} setup.py build
|
||||||
cd -
|
cd -
|
||||||
@ -82,7 +82,7 @@ cd -
|
|||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
cd %{py2_build_dir}
|
cd %{py2_build_dir}
|
||||||
env PYTHONPATH=%{buildroot}/%{python2_sitelib} PBR_VERSION="%{version}" \
|
env PYTHONPATH=%{buildroot}/%{python2_sitelib} PBR_VERSION="%{version}" \
|
||||||
%{__python2} setup.py install -O1 --skip-build --root %{buildroot}
|
%{__python2} setup.py install -O1 --skip-build --root %{buildroot}
|
||||||
@ -95,7 +95,7 @@ env PYTHONPATH=%{buildroot}/%{python3_sitelib} PBR_VERSION="%{version}" \
|
|||||||
%{__python3} setup.py install -O1 --skip-build --root %{buildroot}
|
%{__python3} setup.py install -O1 --skip-build --root %{buildroot}
|
||||||
|
|
||||||
|
|
||||||
%if %{with python2}
|
%if 0%{?with_python2}
|
||||||
%files -n python2-pywbem
|
%files -n python2-pywbem
|
||||||
%doc LICENSE.txt
|
%doc LICENSE.txt
|
||||||
%{python2_sitelib}/*.egg-info
|
%{python2_sitelib}/*.egg-info
|
||||||
@ -113,6 +113,9 @@ env PYTHONPATH=%{buildroot}/%{python3_sitelib} PBR_VERSION="%{version}" \
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Mar 14 2020 gulining<gulining1@huawei.com> - 0.12.4-5
|
||||||
|
- remove python2
|
||||||
|
|
||||||
* Mon Dec 16 2019 likexin<likexin4@huawei.com> - 0.12.4-4
|
* Mon Dec 16 2019 likexin<likexin4@huawei.com> - 0.12.4-4
|
||||||
- modify requires_exclude
|
- modify requires_exclude
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user