fix build on big endian arches

This commit is contained in:
Dan Horák 2012-10-18 09:57:02 +02:00
parent 8ff094c6f4
commit 1ec4243477
2 changed files with 25 additions and 2 deletions

View File

@ -0,0 +1,17 @@
diff -up ipmitool-1.8.12/lib/ipmi_delloem.c.bigendian2 ipmitool-1.8.12/lib/ipmi_delloem.c
--- ipmitool-1.8.12/lib/ipmi_delloem.c.bigendian2 2012-10-18 09:46:07.641569464 +0200
+++ ipmitool-1.8.12/lib/ipmi_delloem.c 2012-10-18 09:46:23.471318242 +0200
@@ -4283,10 +4283,10 @@ static int ipmi_set_power_cap(struct ipm
}
#if WORDS_BIGENDIAN
ipmipowercap.PowerCap = BSWAP_16(ipmipowercap.PowerCap);
- ipmipowercap.MaximumPowerConsump = BSWAP_16(ipmipowercap.MaximumPowerConsump);
- ipmipowercap.MinumumPowerConsump = BSWAP_16(ipmipowercap.MinimumPowerConsump);
+ ipmipowercap.MaximumPowerConsmp = BSWAP_16(ipmipowercap.MaximumPowerConsmp);
+ ipmipowercap.MinimumPowerConsmp = BSWAP_16(ipmipowercap.MinimumPowerConsmp);
ipmipowercap.AvailablePower = BSWAP_16(ipmipowercap.AvailablePower);
- ipmipowercap.totalnumpowersupp = BSWP_16(ipmipowercap.totalnumpowersupp);
+ ipmipowercap.totalnumpowersupp = BSWAP_16(ipmipowercap.totalnumpowersupp);
#endif
memset(data, 0, 13);

View File

@ -1,7 +1,7 @@
Name: ipmitool Name: ipmitool
Summary: Utility for IPMI control Summary: Utility for IPMI control
Version: 1.8.12 Version: 1.8.12
Release: 4%{?dist} Release: 5%{?dist}
License: BSD License: BSD
Group: System Environment/Base Group: System Environment/Base
URL: http://ipmitool.sourceforge.net/ URL: http://ipmitool.sourceforge.net/
@ -21,9 +21,11 @@ Patch1: ipmitool-1.8.10-ipmievd-init.patch
Patch2: ipmitool-1.8.10-ipmievd-condrestart.patch Patch2: ipmitool-1.8.10-ipmievd-condrestart.patch
Patch3: ipmitool-1.8.11-remove-umask0.patch Patch3: ipmitool-1.8.11-remove-umask0.patch
Patch4: ipmitool-1.8.11-systemd.patch Patch4: ipmitool-1.8.11-systemd.patch
# https://sourceforge.net/tracker/index.php?func=detail&aid=3564701&group_id=95200&atid=610550 # https://sourceforge.net/tracker/?func=detail&aid=3564701&group_id=95200&atid=610550
Patch5: ipmitool-1.8.12-bigendian.patch Patch5: ipmitool-1.8.12-bigendian.patch
Patch6: ipmitool-cvs-mc-sysinfo-dell.patch Patch6: ipmitool-cvs-mc-sysinfo-dell.patch
# https://sourceforge.net/tracker/?func=detail&aid=3578022&group_id=95200&atid=610550
Patch7: ipmitool-1.8.12-bigendian2.patch
%description %description
This package contains a utility for interfacing with devices that support This package contains a utility for interfacing with devices that support
@ -49,6 +51,7 @@ setting LAN configuration, and chassis power control.
%patch4 -p1 -b .systemd %patch4 -p1 -b .systemd
%patch5 -p1 -b .bigendian %patch5 -p1 -b .bigendian
%patch6 -p1 -b .mcsysinfodell %patch6 -p1 -b .mcsysinfodell
%patch7 -p1 -b .bigendian2
for f in AUTHORS ChangeLog; do for f in AUTHORS ChangeLog; do
iconv -f iso-8859-1 -t utf8 < ${f} > ${f}.utf8 iconv -f iso-8859-1 -t utf8 < ${f} > ${f}.utf8
@ -99,6 +102,9 @@ install -Dpm 644 %{SOURCE1} %{buildroot}%{_sysconfdir}/sysconfig/ipmievd
%changelog %changelog
* Thu Oct 18 2012 Dan Horák <dan[at]danny.cz> - 1.8.12-5
- fix build on big endian arches
* Wed Oct 17 2012 Ales Ledvinka <aledvink@redhat.cz> 1.8.12-4 * Wed Oct 17 2012 Ales Ledvinka <aledvink@redhat.cz> 1.8.12-4
- support setting OS name and Hostname on BMC - support setting OS name and Hostname on BMC