File dmidecode.spec of Package dmidecode.10266

# spec file for package dmidecode
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

Name:           dmidecode
Version:        3.1
Release:        0
Summary:        DMI table decoder
License:        GPL-2.0+
Group:          System/Console
# would be, but tarball is signed by someone else without signatures.
# Source2:        %{name}.keyring
Patch1:         dmioem-reflect-hpe-new-company-name.patch
Patch2:         dmidecode-fix-tpm-device-firmware-version.patch
Patch3:         dmioem-fix-hpe-type-219-uefi-flag.patch
Patch4:         dmidecode-extensions-to-memory-device-type-17.patch
Patch5:         dmidecode-add-logical-non-volatile-device.patch
Provides:       pmtools:%{_sbindir}/dmidecode
Obsoletes:      pmtools < 20071117
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  xz
ExclusiveArch:  %ix86 ia64 x86_64 %arm aarch64

Dmidecode reports information about your system's hardware as described
in your system BIOS according to the SMBIOS/DMI standard. This
information typically includes system manufacturer, model name, serial
number, BIOS version, asset tag as well as a lot of other details of
varying level of interest and reliability depending on the
manufacturer. This will often include usage status for the CPU sockets,
expansion slots (e.g. AGP, PCI, ISA) and memory module slots, and the
list of I/O ports (e.g. serial, parallel, USB).

Beware that DMI data have proven to be too unreliable to be blindly
trusted. Dmidecode does not scan your hardware, it only reports what
the BIOS told it to.

%setup -q
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1

make CFLAGS="%{optflags}" %{?_smp_mflags}

install -dm 755 %{buildroot}%{_sbindir}
install -dm 755 %{buildroot}%{_mandir}/man8
install -dm 755 %{buildroot}%{_docdir}/%{name}
%ifarch ia64 %arm aarch64
for i in dmidecode ; do
for i in dmidecode vpddecode ownership biosdecode ; do
install -m 755 $i %{buildroot}%{_sbindir}/
install -m 644 man/$i.8 %{buildroot}%{_mandir}/man8/
install -m 644 AUTHORS CHANGELOG LICENSE README %{buildroot}%{_docdir}/%{name}/

%doc %{_docdir}/%{name}

openSUSE Build Service is sponsored by