add command --compat-uuid

Signed-off-by: Yang Yanchao <yangyanchao6@huawei.com>
(cherry picked from commit dcf950cc4ae0509e783f4c84ff844b3e7ad9e835)
This commit is contained in:
Yang Yanchao 2022-01-29 10:24:46 +08:00 committed by openeuler-sync-bot
parent 8c1a309a91
commit 8f98e3ea20
2 changed files with 9 additions and 4 deletions

View File

@ -20,9 +20,9 @@ index a3e9d6c..35c19c2 100644
*/ */
- if (ver >= 0x0206) - if (ver >= 0x0206)
+ if (ver >= 0x0206 && !(opt.flags & FLAG_COMPAT_UUID)) + if (ver >= 0x0206 && !(opt.flags & FLAG_COMPAT_UUID))
printf("%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x", {
p[3], p[2], p[1], p[0], p[5], p[4], p[7], p[6], if (print_cb)
p[8], p[9], p[10], p[11], p[12], p[13], p[14], p[15]); print_cb(attr,
diff --git a/dmiopt.c b/dmiopt.c diff --git a/dmiopt.c b/dmiopt.c
index 2f285f3..dede0f9 100644 index 2f285f3..dede0f9 100644
--- a/dmiopt.c --- a/dmiopt.c

View File

@ -1,6 +1,6 @@
Name: dmidecode Name: dmidecode
Version: 3.3 Version: 3.3
Release: 1 Release: 2
Epoch: 1 Epoch: 1
Summary: DMI data report tool Summary: DMI data report tool
@ -8,6 +8,8 @@ License: GPLv2+
URL: https://www.nongnu.org/dmidecode/ URL: https://www.nongnu.org/dmidecode/
Source0: http://download.savannah.gnu.org/releases/dmidecode/%{name}-%{version}.tar.xz Source0: http://download.savannah.gnu.org/releases/dmidecode/%{name}-%{version}.tar.xz
Patch6000: bugfix-compat_uuid.patch
BuildRequires: make gcc xz BuildRequires: make gcc xz
ExclusiveArch: %{ix86} x86_64 ia64 aarch64 amd64 ExclusiveArch: %{ix86} x86_64 ia64 aarch64 amd64
@ -48,6 +50,9 @@ make %{?_smp_mflags} CFLAGS="%{__global_cflags}" LDFLAGS="%{__global_ldflags}"
%{_mandir}/man8/*.8.gz %{_mandir}/man8/*.8.gz
%changelog %changelog
* Sat Jan 29 2022 Yang Yanchao <yangyanchao6@huawei.com> - 3.3-2
- add command --compat-uuid
* Tue Nov 30 2021 zhouwenpei <zhouwenpei1@huawei.com> - 3.3-1 * Tue Nov 30 2021 zhouwenpei <zhouwenpei1@huawei.com> - 3.3-1
- update to 3.3 - update to 3.3