- Fix Python 3 choosing incorrect binary

Resolves: rhbz#1857247
This commit is contained in:
Oyvind Albrigtsen 2021-07-01 11:12:28 +02:00
parent 211fd6aa88
commit cb0682d4ee

View File

@ -9,7 +9,7 @@
Name: fence-agents Name: fence-agents
Summary: Set of unified programs capable of host isolation ("fencing") Summary: Set of unified programs capable of host isolation ("fencing")
Version: 4.9.0 Version: 4.9.0
Release: 2%{?alphatag:.%{alphatag}}%{?dist} Release: 3%{?alphatag:.%{alphatag}}%{?dist}
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
URL: https://github.com/ClusterLabs/fence-agents URL: https://github.com/ClusterLabs/fence-agents
Source0: https://fedorahosted.org/releases/f/e/fence-agents/%{name}-%{version}.tar.gz Source0: https://fedorahosted.org/releases/f/e/fence-agents/%{name}-%{version}.tar.gz
@ -230,6 +230,10 @@ BuildRequires: %{systemd_units}
sed -i.orig 's|FENCE_ZVM=1|FENCE_ZVM=0|' configure.ac sed -i.orig 's|FENCE_ZVM=1|FENCE_ZVM=0|' configure.ac
%build %build
%if 0%{?fedora} || 0%{?centos} > 7 || 0%{?rhel} > 7 || 0%{?suse_version}
export PYTHON="%{__python3}"
%endif
# support libs # support libs
%ifarch x86_64 %ifarch x86_64
LIBS="%{_sourcedir}/requirements-*.txt" LIBS="%{_sourcedir}/requirements-*.txt"
@ -249,10 +253,6 @@ done
sed -i -e "/^import awscli.clidriver/isys.path.insert(0, '/usr/lib/%{name}/support/awscli')" support/awscli/bin/aws sed -i -e "/^import awscli.clidriver/isys.path.insert(0, '/usr/lib/%{name}/support/awscli')" support/awscli/bin/aws
%endif %endif
%if 0%{?fedora} || 0%{?centos} > 7 || 0%{?rhel} > 7 || 0%{?suse_version}
PYTHON="%{__python3}"
%endif
./autogen.sh ./autogen.sh
%{configure} --disable-libvirt-qmf-plugin PYTHONPATH="support/aliyun:support/aws:support/azure:support/google:support/openstack:support/pexpect" --with-agents='%{supportedagents} %{testagents}' %{configure} --disable-libvirt-qmf-plugin PYTHONPATH="support/aliyun:support/aws:support/azure:support/google:support/openstack:support/pexpect" --with-agents='%{supportedagents} %{testagents}'
CFLAGS="$(echo '%{optflags}')" make %{_smp_mflags} CFLAGS="$(echo '%{optflags}')" make %{_smp_mflags}
@ -1245,7 +1245,7 @@ are located on corosync cluster nodes.
%{_libdir}/fence-virt/cpg.so %{_libdir}/fence-virt/cpg.so
%changelog %changelog
* Thu Jul 1 2021 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.9.0-2 * Thu Jul 1 2021 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.9.0-3
- OpenStack agents: add dependency - OpenStack agents: add dependency
Resolves: rhbz#1857247 Resolves: rhbz#1857247