use %%uname_m_arch to ensure exact matching

This commit is contained in:
Tom Callaway 2020-08-10 12:01:22 -04:00
parent 248c0adb59
commit a029db4e43

View File

@ -15,6 +15,9 @@
# that $PBS_SERVER_HOME/server_name contains the correct hostname. # that $PBS_SERVER_HOME/server_name contains the correct hostname.
%global server_name localhost %global server_name localhost
# The script checks uname -m to determine architecture
%global uname_m_arch %(uname -m)
# Build doxygen docs # Build doxygen docs
%global doxydoc 1 %global doxydoc 1
@ -71,7 +74,7 @@
Name: torque Name: torque
Version: 4.2.10 Version: 4.2.10
Release: 28%{?dist} Release: 29%{?dist}
Summary: Tera-scale Open-source Resource and QUEue manager Summary: Tera-scale Open-source Resource and QUEue manager
Source0: http://www.adaptivecomputing.com/download/%{name}/%{name}-%{version}.tar.gz Source0: http://www.adaptivecomputing.com/download/%{name}/%{name}-%{version}.tar.gz
Source2: xpbs.desktop Source2: xpbs.desktop
@ -517,7 +520,7 @@ rm %{buildroot}%{_mandir}/man1/basl2c.1
chmod 755 `find %{buildroot}/var/lib/torque -type d` chmod 755 `find %{buildroot}/var/lib/torque -type d`
# Use wrapper script for pbs-config and rename original script to include architecture name # Use wrapper script for pbs-config and rename original script to include architecture name
mv %{buildroot}%{_bindir}/pbs-config %{buildroot}%{_bindir}/pbs-config-%{_target_cpu} mv %{buildroot}%{_bindir}/pbs-config %{buildroot}%{_bindir}/pbs-config-%{uname_m_arch}
install -m0755 -p %{SOURCE100} %{buildroot}%{_bindir}/pbs-config install -m0755 -p %{SOURCE100} %{buildroot}%{_bindir}/pbs-config
%post %post
@ -757,7 +760,7 @@ fi
%{_includedir}/torque %{_includedir}/torque
%exclude %{_includedir}/torque/drmaa.h %exclude %{_includedir}/torque/drmaa.h
%{_bindir}/pbs-config %{_bindir}/pbs-config
%{_bindir}/pbs-config-%{_target_cpu} %{_bindir}/pbs-config-%{uname_m_arch}
%{_mandir}/man3/pbs_alterjob.3.* %{_mandir}/man3/pbs_alterjob.3.*
%{_mandir}/man3/pbs_connect.3.* %{_mandir}/man3/pbs_connect.3.*
%{_mandir}/man3/pbs_default.3.* %{_mandir}/man3/pbs_default.3.*
@ -886,6 +889,9 @@ fi
%endif %endif
%changelog %changelog
* Mon Aug 10 2020 Tom Callaway <spot@fedoraproject.org> - 4.2.10-29
- use %%uname_m_arch to ensure exact matching
* Mon Aug 10 2020 Tom Callaway <spot@fedoraproject.org> - 4.2.10-28 * Mon Aug 10 2020 Tom Callaway <spot@fedoraproject.org> - 4.2.10-28
- using "%%{_arch}" resulted in a mismatch with uname -m on i386. - using "%%{_arch}" resulted in a mismatch with uname -m on i386.
switched to "%%{_target_cpu}" switched to "%%{_target_cpu}"