Accepting request 1100666 from systemsmanagement
OBS-URL: https://build.opensuse.org/request/show/1100666 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/ipmitool?expand=0&rev=47
This commit is contained in:
commit
d6e67e2559
@ -1,130 +0,0 @@
|
||||
From 44faed961d148ded6e6a75b73a25d85bcbdd843c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Klaus=20K=C3=A4mpf?= <kkaempf@suse.de>
|
||||
Date: Wed, 23 Sep 2020 09:44:29 +0200
|
||||
Subject: [PATCH 6/6] Make IANA PEN download configurable - fix uninitalized
|
||||
DOWNLOAD variable
|
||||
|
||||
Currently if you do not have wget and curl requirement met, you get
|
||||
this error:
|
||||
[ 93s] configure: WARNING: ** Neither wget nor curl could be found.
|
||||
[ 93s] configure: WARNING: ** IANA PEN database will not be installed by `make install` !
|
||||
[ 93s] configure: WARNING: ** Download is:
|
||||
[ 93s] configure: WARNING:
|
||||
...
|
||||
[ 104s] configure: error: conditional "DOWNLOAD" was never defined.
|
||||
[ 104s] Usually this means the macro was only invoked conditionally.
|
||||
[ 104s] error: Bad exit status from /var/tmp/rpm-tmp.TYnvu5 (%build)
|
||||
|
||||
Internet download is restricted in most build environments.
|
||||
So there must be a knob to enable/disable IANA PEN database download.
|
||||
For security reasons and as a good manner for open source tools, the internet
|
||||
download is by default set to off.
|
||||
|
||||
This patch initializes all needed variables and also introduces to make the
|
||||
IANA PEN internet download configurable.
|
||||
|
||||
./configure
|
||||
then has this additional feature:
|
||||
|
||||
--enable-iana-download Download IANA PEN database [default=no]
|
||||
|
||||
Depending on whether it has explicitly been enabled this additional output
|
||||
is shown after build env is successfully set up via ./configure:
|
||||
|
||||
Download IANA PEN database : yes
|
||||
IANA PEN database URL : http://www.iana.org/assignments/enterprise-numbers
|
||||
|
||||
The URL is unfortunately hardcoded in the message. I couldn't find a quick
|
||||
way to show the IANA_PEN_URL variable there, so if this is ever changed (it is
|
||||
not configurable right now, but maybe with a follow up patch in the future),
|
||||
it has to be changed in the help string as well.
|
||||
---
|
||||
Makefile.am | 5 ++---
|
||||
configure.ac | 39 ++++++++++++++++++++++++++-------------
|
||||
2 files changed, 28 insertions(+), 16 deletions(-)
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index ce3267f00bc8..05fa209e90bc 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -41,7 +41,6 @@ MAINTAINERCLEANFILES = Makefile.in aclocal.m4 configure configure-stamp \
|
||||
$(distdir).tar.gz $(distdir).tar.bz2
|
||||
|
||||
SUBDIRS = lib src include doc contrib control
|
||||
-IANA_PEN = http://www.iana.org/assignments/enterprise-numbers
|
||||
|
||||
dist-hook:
|
||||
cp control/ipmitool.spec $(distdir)
|
||||
@@ -53,8 +52,8 @@ if DOWNLOAD
|
||||
|
||||
enterprise-numbers:
|
||||
@echo Downloading IANA PEN database...
|
||||
- @$(DOWNLOAD) "$(IANA_PEN)" > tmpfile.$$PPID || {\
|
||||
- echo "FAILED to download the IANA PEN database"; \
|
||||
+ @$(DOWNLOAD) "$(IANA_PEN_URL)" > tmpfile.$$PPID || {\
|
||||
+ echo "FAILED to download the IANA PEN database from $(IANA_PEN_URL)"; \
|
||||
rm tmpfile.$$PPID; \
|
||||
false; \
|
||||
}
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index b421192daef7..c7a20cad1dc3 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -56,23 +56,34 @@ if test "x$exec_prefix" = "xNONE"; then
|
||||
exec_prefix="$prefix"
|
||||
fi
|
||||
|
||||
-if test "x$WGET" = "x"; then
|
||||
- if test "x$CURL" = "x"; then
|
||||
- AC_MSG_WARN([** Neither wget nor curl could be found.])
|
||||
- AC_MSG_WARN([** IANA PEN database will not be installed by `make install` !])
|
||||
+xiana_pen_url="http://www.iana.org/assignments/enterprise-numbers"
|
||||
+AC_SUBST(IANA_PEN_URL, xiana_pen_url)
|
||||
+
|
||||
+AC_ARG_ENABLE([iana-download],
|
||||
+ [AC_HELP_STRING([--enable-iana-download],
|
||||
+ [Download IANA PEN database [default=no]])],
|
||||
+ [xenable_iana_download=$enableval],
|
||||
+ [xenable_iana_download=no])
|
||||
+if test "x$xenable_iana_download" = "xyes"; then
|
||||
+ if test "x$WGET" = "x"; then
|
||||
+ if test "x$CURL" = "x"; then
|
||||
+ AC_MSG_WARN([** Neither wget nor curl could be found.])
|
||||
+ AC_MSG_WARN([** IANA PEN database will not be installed by `make install` !])
|
||||
+ xenable_iana_download="no"
|
||||
+ else
|
||||
+ DOWNLOAD="$CURL -#"
|
||||
+ fi
|
||||
else
|
||||
- DOWNLOAD="$CURL --location --progress-bar"
|
||||
- AM_CONDITIONAL([DOWNLOAD], [true])
|
||||
+ DOWNLOAD="$WGET -c -nd -O -"
|
||||
fi
|
||||
+fi
|
||||
+if test "x$xenable_iana_download" = "xyes"; then
|
||||
+ AM_CONDITIONAL([DOWNLOAD], [true])
|
||||
+ AC_SUBST(DOWNLOAD, $DOWNLOAD)
|
||||
else
|
||||
- DOWNLOAD="$WGET -c -nd -O -"
|
||||
- AM_CONDITIONAL([DOWNLOAD], [true])
|
||||
+ AM_CONDITIONAL([DOWNLOAD], [false])
|
||||
fi
|
||||
|
||||
-AC_MSG_WARN([** Download is:])
|
||||
-AC_MSG_WARN($DOWNLOAD)
|
||||
-AC_SUBST(DOWNLOAD, $DOWNLOAD)
|
||||
-
|
||||
dnl
|
||||
dnl set default option values
|
||||
dnl
|
||||
@@ -773,4 +784,6 @@ AC_MSG_RESULT([Extra tools])
|
||||
AC_MSG_RESULT([ ipmievd : yes])
|
||||
AC_MSG_RESULT([ ipmishell : $xenable_ipmishell])
|
||||
AC_MSG_RESULT([])
|
||||
-
|
||||
+AC_MSG_RESULT([ Download IANA PEN database : $xenable_iana_download])
|
||||
+AC_MSG_RESULT([ IANA PEN database URL : $xiana_pen_url])
|
||||
+AC_MSG_RESULT([])
|
||||
--
|
||||
2.26.0
|
||||
|
56
Fix-time-format-for-sel-list-v.patch
Normal file
56
Fix-time-format-for-sel-list-v.patch
Normal file
@ -0,0 +1,56 @@
|
||||
From: Thomas Renninger <trenn@suse.com>
|
||||
Subject: Fix time format for sel list -v
|
||||
References: bsc#1213390
|
||||
Patch-Mainline:
|
||||
Git-commit: d34a56908da3d85c4ddce1be1aab90941177b13b
|
||||
Git-repo: git@github.com:watologo1/ipmitool.git.git
|
||||
|
||||
The time for sel entries gets wrongly formatted:
|
||||
|
||||
SEL Record ID : 3135
|
||||
Record Type : 02
|
||||
Timestamp : 18.07.2023 18.07.2023
|
||||
Generator ID : 0044
|
||||
|
||||
This patch fixes this:
|
||||
|
||||
SEL Record ID : 3135
|
||||
Record Type : 02
|
||||
Timestamp : 18.07.2023 11:26:24 CEST
|
||||
Generator ID : 0044
|
||||
|
||||
The first hunk for:
|
||||
`sel list -v`
|
||||
The snd hunk for:
|
||||
`sel get ID`
|
||||
|
||||
|
||||
Signed-off-by: <trenn@suse.com>
|
||||
diff --git a/lib/ipmi_sel.c b/lib/ipmi_sel.c
|
||||
index 31c0eea..7d6d01f 100644
|
||||
--- a/lib/ipmi_sel.c
|
||||
+++ b/lib/ipmi_sel.c
|
||||
@@ -2043,11 +2043,9 @@ ipmi_sel_print_std_entry_verbose(struct ipmi_intf * intf, struct sel_event_recor
|
||||
{
|
||||
printf(" Timestamp : ");
|
||||
if (evt->record_type < 0xc0)
|
||||
- printf("%s %s", ipmi_timestamp_date(evt->sel_type.standard_type.timestamp),
|
||||
- ipmi_timestamp_time(evt->sel_type.standard_type.timestamp));
|
||||
+ printf("%s", ipmi_timestamp_numeric(evt->sel_type.standard_type.timestamp));
|
||||
else
|
||||
- printf("%s %s", ipmi_timestamp_date(evt->sel_type.oem_ts_type.timestamp),
|
||||
- ipmi_timestamp_time(evt->sel_type.oem_ts_type.timestamp));
|
||||
+ printf("%s", ipmi_timestamp_numeric(evt->sel_type.oem_ts_type.timestamp));
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
@@ -2133,8 +2131,7 @@ ipmi_sel_print_extended_entry_verbose(struct ipmi_intf * intf, struct sel_event_
|
||||
if (evt->record_type < 0xe0)
|
||||
{
|
||||
printf(" Timestamp : ");
|
||||
- printf("%s %s\n", ipmi_timestamp_date(evt->sel_type.standard_type.timestamp),
|
||||
- ipmi_timestamp_time(evt->sel_type.standard_type.timestamp));
|
||||
+ printf("%s\n", ipmi_timestamp_numeric(evt->sel_type.standard_type.timestamp));
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
<servicedata>
|
||||
<service name="tar_scm">
|
||||
<param name="url">https://github.com/ipmitool/ipmitool.git</param>
|
||||
<param name="changesrevision">19d78782d795d0cf4ceefe655f616210c9143e62</param></service></servicedata>
|
||||
<param name="changesrevision">be11d948f89b10be094e28d8a0a5e8fb532c7b60</param></service></servicedata>
|
8386
enterprise-numbers
8386
enterprise-numbers
File diff suppressed because it is too large
Load Diff
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e87775b05b2aa4cbd6e964e3644fc6dfb0f18a3353d074c127d10aa8de68aba6
|
||||
size 3038220
|
BIN
ipmitool-1.8.19.13.gbe11d94.obscpio
(Stored with Git LFS)
Normal file
BIN
ipmitool-1.8.19.13.gbe11d94.obscpio
(Stored with Git LFS)
Normal file
Binary file not shown.
@ -1,3 +1,25 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Jul 24 10:38:53 UTC 2023 - trenn@suse.de
|
||||
|
||||
- Fix: ipmitool duplicates the timestamp (bsc#1213390)
|
||||
A Fix-time-format-for-sel-list-v.patch
|
||||
- Remove: Make-IANA-PEN-download-configurable (is mainline)
|
||||
D 0006-Make-IANA-PEN-download-configurable-fix-uninitalized.patch
|
||||
- Update to version 1.8.19.13.gbe11d94:
|
||||
* configure.ac: allow disabling registry downloads
|
||||
* lan: channel: Fix set alert on/off
|
||||
* make: use correct docdir variable provided by autotools
|
||||
* Do not require the IANA PEN registry file
|
||||
* configure.ac: fix readline static build
|
||||
* Update github actions for modern OSes
|
||||
* Update macos target name in github actions
|
||||
* delloem: Fix the unalign bug in arm64
|
||||
* lanplus: Realloc the msg if the payload_length gets updated
|
||||
* fru print: Add area checksum verification
|
||||
* fru: Add decoder for multirec system mgmt records
|
||||
* Fix enterprise-numbers URL
|
||||
* Update issue templates
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Sep 07 03:06:48 UTC 2022 - trenn@suse.de
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
name: ipmitool
|
||||
version: 1.8.19.0.g19d7878
|
||||
mtime: 1662057751
|
||||
commit: 19d78782d795d0cf4ceefe655f616210c9143e62
|
||||
version: 1.8.19.13.gbe11d94
|
||||
mtime: 1673520680
|
||||
commit: be11d948f89b10be094e28d8a0a5e8fb532c7b60
|
||||
|
@ -17,7 +17,7 @@
|
||||
|
||||
|
||||
Name: ipmitool
|
||||
Version: 1.8.19.0.g19d7878
|
||||
Version: 1.8.19.13.gbe11d94
|
||||
Release: 0
|
||||
Summary: Utility for IPMI Control
|
||||
License: BSD-3-Clause
|
||||
@ -32,7 +32,7 @@ Patch2: 0002-Fix-file-permissions.patch
|
||||
Patch3: 0003-Cleanup-and-compiler-issues-only-no-functional-chang.patch
|
||||
Patch4: 0004-Adjust-SUSE-paths.patch
|
||||
Patch5: 0005-HPM-x-compatibility-message-is-DEBUG-only.patch
|
||||
Patch6: 0006-Make-IANA-PEN-download-configurable-fix-uninitalized.patch
|
||||
Patch6: Fix-time-format-for-sel-list-v.patch
|
||||
BuildRequires: libtool
|
||||
BuildRequires: openssl-devel
|
||||
BuildRequires: readline-devel
|
||||
@ -79,7 +79,8 @@ autoreconf -fiv
|
||||
# file-security: enables more security checks on files
|
||||
%configure \
|
||||
--enable-file-security \
|
||||
--enable-intf-usb
|
||||
--enable-intf-usb \
|
||||
--enable-registry-download=no
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
|
Loading…
Reference in New Issue
Block a user