Compare commits

..

No commits in common. "c9" and "c8" have entirely different histories.
c9 ... c8

2 changed files with 64 additions and 62 deletions

View File

@ -0,0 +1,11 @@
diff -up pciutils-3.5.6/lspci.c.freefix pciutils-3.5.6/lspci.c
--- pciutils-3.5.6/lspci.c.freefix 2018-08-21 16:52:35.087706662 +0200
+++ pciutils-3.5.6/lspci.c 2018-08-21 16:52:35.124706469 +0200
@@ -128,6 +128,7 @@ scan_device(struct pci_dev *p)
fprintf(stderr, "lspci: Unable to read the standard configuration space header of device %04x:%02x:%02x.%d\n",
p->domain, p->bus, p->dev, p->func);
seen_errors++;
+ free(d);
return NULL;
}
if ((d->config[PCI_HEADER_TYPE] & 0x7f) == PCI_HEADER_TYPE_CARDBUS)

View File

@ -1,11 +1,7 @@
Name: pciutils Name: pciutils
Version: 3.7.0 Version: 3.7.0
Release: 5%{?dist} Release: 3%{?dist}
Summary: PCI bus related utilities Source: https://mirrors.edge.kernel.org/pub/software/utils/pciutils/%{name}-%{version}.tar.xz
License: GPLv2+
URL: https://mj.ucw.cz/sw/pciutils/
Source0: https://www.kernel.org/pub/software/utils/pciutils/%{name}-%{version}.tar.xz
Source1: multilibconfigh Source1: multilibconfigh
#change pci.ids directory to hwdata, fedora/rhel specific #change pci.ids directory to hwdata, fedora/rhel specific
@ -13,11 +9,19 @@ Patch1: pciutils-2.2.1-idpath.patch
#add support for directory with another pci.ids, rejected by upstream, rhbz#195327 #add support for directory with another pci.ids, rejected by upstream, rhbz#195327
Patch2: pciutils-dir-d.patch Patch2: pciutils-dir-d.patch
Patch3: pciutils-3.7.0-decodercec.patch Patch4: pciutils-3.5.6-freefix.patch
# from upstream, for pciutils <= 3.7.0
Patch5: pciutils-3.7.0-decodercec.patch
License: GPLv2+
URL: http://atrey.karlin.mff.cuni.cz/~mj/pciutils.shtml
ExclusiveOS: Linux
Requires: hwdata Requires: hwdata
Requires: %{name}-libs = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
BuildRequires: gcc make sed kmod-devel BuildRequires: sed kmod-devel
Summary: PCI bus related utilities
Group: Applications/System
Provides: /sbin/lspci /sbin/setpci Provides: /sbin/lspci /sbin/setpci
%description %description
@ -26,7 +30,8 @@ setting devices connected to the PCI bus.
%package devel %package devel
Summary: Linux PCI development library Summary: Linux PCI development library
Requires: zlib-devel pkgconfig %{name}%{?_isa} = %{version}-%{release} Group: Development/Libraries
Requires: zlib-devel pkgconfig %{name}-libs%{?_isa} = %{version}-%{release}
%description devel %description devel
This package contains a library for inspecting and setting This package contains a library for inspecting and setting
@ -34,6 +39,7 @@ devices connected to the PCI bus.
%package libs %package libs
Summary: Linux PCI library Summary: Linux PCI library
Group: System Environment/Libraries
%description libs %description libs
This package contains a library for inspecting and setting This package contains a library for inspecting and setting
@ -41,6 +47,7 @@ devices connected to the PCI bus.
%package devel-static %package devel-static
Summary: Linux PCI static library Summary: Linux PCI static library
Group: System Environment/Libraries
Requires: %{name}-devel%{?_isa} = %{version}-%{release} Requires: %{name}-devel%{?_isa} = %{version}-%{release}
%description devel-static %description devel-static
@ -48,36 +55,47 @@ This package contains a static library for inspecting and setting
devices connected to the PCI bus. devices connected to the PCI bus.
%prep %prep
%autosetup -p1 %setup -q -n pciutils-%{version}
%patch1 -p1 -b .idpath
%patch2 -p1 -b .dird
%patch4 -p1 -b .freefix
%patch5 -p1 -b .decodercec
%build %build
%make_build SHARED="no" ZLIB="no" LIBKMOD=yes STRIP="" OPT="$RPM_OPT_FLAGS" LDFLAGS="$RPM_LD_FLAGS" PREFIX="/usr" LIBDIR="%{_libdir}" IDSDIR="/usr/share/hwdata" PCI_IDS="pci.ids" make SHARED="no" ZLIB="no" LIBKMOD=yes STRIP="" OPT="$RPM_OPT_FLAGS" LDFLAGS="$RPM_LD_FLAGS" PREFIX="/usr" LIBDIR="%{_libdir}" IDSDIR="/usr/share/hwdata" PCI_IDS="pci.ids" %{?_smp_mflags}
mv lib/libpci.a lib/libpci.a.toinstall mv lib/libpci.a lib/libpci.a.toinstall
make clean make clean
%make_build SHARED="yes" ZLIB="no" LIBKMOD=yes STRIP="" OPT="$RPM_OPT_FLAGS" LDFLAGS="$RPM_LD_FLAGS" PREFIX="/usr" LIBDIR="%{_libdir}" IDSDIR="/usr/share/hwdata" PCI_IDS="pci.ids" make SHARED="yes" ZLIB="no" LIBKMOD=yes STRIP="" OPT="$RPM_OPT_FLAGS" LDFLAGS="$RPM_LD_FLAGS" PREFIX="/usr" LIBDIR="%{_libdir}" IDSDIR="/usr/share/hwdata" PCI_IDS="pci.ids" %{?_smp_mflags}
#fix lib vs. lib64 in libpci.pc (static Makefile is used)
sed -i "s|^libdir=.*$|libdir=/%{_libdir}|" lib/libpci.pc
%install %install
install -d $RPM_BUILD_ROOT{%{_sbindir},%{_mandir}/man{7,8},%{_libdir},%{_libdir}/pkgconfig,%{_includedir}/pci} rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{%{_sbindir},%{_mandir}/man8,%{_libdir},%{_libdir}/pkgconfig,%{_includedir}/pci}
install -p lspci setpci update-pciids $RPM_BUILD_ROOT%{_sbindir} install -p lspci setpci update-pciids $RPM_BUILD_ROOT%{_sbindir}
install -p -m 644 lspci.8 setpci.8 update-pciids.8 $RPM_BUILD_ROOT%{_mandir}/man8 install -p -m 644 lspci.8 setpci.8 update-pciids.8 $RPM_BUILD_ROOT%{_mandir}/man8
install -p -m 644 pcilib.7 $RPM_BUILD_ROOT%{_mandir}/man7
install -p lib/libpci.so.* $RPM_BUILD_ROOT%{_libdir}/ install -p lib/libpci.so.* $RPM_BUILD_ROOT%{_libdir}/
ln -s $(basename $RPM_BUILD_ROOT%{_libdir}/*.so.*.*.*) $RPM_BUILD_ROOT%{_libdir}/libpci.so ln -s $(basename $RPM_BUILD_ROOT%{_libdir}/*.so.*.*.*) $RPM_BUILD_ROOT%{_libdir}/libpci.so
mv lib/libpci.a.toinstall lib/libpci.a mv lib/libpci.a.toinstall lib/libpci.a
install -p -m 644 lib/libpci.a $RPM_BUILD_ROOT%{_libdir} install -p -m 644 lib/libpci.a $RPM_BUILD_ROOT%{_libdir}
install -p -m 644 lib/pci.h $RPM_BUILD_ROOT%{_includedir}/pci /sbin/ldconfig -N $RPM_BUILD_ROOT/%{_libdir}
install -p -m 644 lib/header.h $RPM_BUILD_ROOT%{_includedir}/pci install -p lib/pci.h $RPM_BUILD_ROOT%{_includedir}/pci
install -p -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_includedir}/pci/config.h install -p lib/header.h $RPM_BUILD_ROOT%{_includedir}/pci
install -p -m 644 lib/config.h $RPM_BUILD_ROOT%{_includedir}/pci/config.%{_lib}.h install -p %{SOURCE1} $RPM_BUILD_ROOT%{_includedir}/pci/config.h
install -p -m 644 lib/types.h $RPM_BUILD_ROOT%{_includedir}/pci install -p lib/config.h $RPM_BUILD_ROOT%{_includedir}/pci/config.%{_lib}.h
install -p -m 644 lib/libpci.pc $RPM_BUILD_ROOT%{_libdir}/pkgconfig install -p lib/types.h $RPM_BUILD_ROOT%{_includedir}/pci
install -p lib/libpci.pc $RPM_BUILD_ROOT%{_libdir}/pkgconfig
%ldconfig_scriptlets libs %post libs -p /sbin/ldconfig
%postun libs -p /sbin/ldconfig
%files %files
%doc README ChangeLog pciutils.lsm %doc README ChangeLog pciutils.lsm
@ -94,58 +112,31 @@ install -p -m 644 lib/libpci.pc $RPM_BUILD_ROOT%{_libdir}/pkgconfig
%{_libdir}/libpci.a %{_libdir}/libpci.a
%files devel %files devel
%defattr(0644, root, root, 0755)
%{_libdir}/pkgconfig/libpci.pc %{_libdir}/pkgconfig/libpci.pc
%{_libdir}/libpci.so %{_libdir}/libpci.so
%{_includedir}/pci %{_includedir}/pci
%{_mandir}/man7/*
%changelog %changelog
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 3.7.0-5 * Tue Sep 06 2022 Michal Hlavinka <mhlavink@redhat.com> - 3.7.0-3
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags - fix dependency of devel subpkg on libs (#2111644)
Related: rhbz#1991688
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 3.7.0-4 * Tue Sep 06 2022 Michal Hlavinka <mhlavink@redhat.com> - 3.7.0-2
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937 - fix locations wrt UsrMove(#2111644)
* Tue Feb 02 2021 Michal Hlavinka <mhlavink@redhat.com> - 3.7.0-3
- spec file cleanup
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.7.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Fri Oct 30 2020 Michal Hlavinka <mhlavink@redhat.com> - 3.7.0-1 * Fri Oct 30 2020 Michal Hlavinka <mhlavink@redhat.com> - 3.7.0-1
- updated to 3.7.0 - pciutils updated to 3.7.0, add support for basic DVSEC and CXL DVSEC (#1856436)
- add support for RCEC Associated Endpoint (#1856440)
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.4-2 * Wed May 06 2020 Michal Hlavinka <mhlavink@redhat.com> - 3.6.4-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - rebuild package
* Fri Feb 28 2020 Michal Hlavinka <mhlavink@redhat.com> - 3.6.4-1 * Mon May 04 2020 Michal Hlavinka <mhlavink@redhat.com> - 3.6.4-1
- pciutils updated to 3.6.4 - pciutils updated to 3.6.4
- some of the VPD data fields were displayed as unknown (#1828741)
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.3-2 * Tue Oct 16 2018 Michal Hlavinka <mhlavink@redhat.com> - 3.5.6-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - fix covscan found issues (#1607017)
* Wed Jan 22 2020 Peter Robinson <pbrobinson@fedoraproject.org> 3.6.3-1
- pciutils updated to 3.6.3
- spec cleanups, use %%license, use kernel.org download
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Mon Aug 13 2018 Michal Hlavinka <mhlavink@redhat.com> - 3.6.2-1
- pciutils updated to 3.6.2
* Fri Jul 13 2018 Michal Hlavinka <mhlavink@redhat.com> - 3.6.1-1
- pciutils updated to 3.6.1
* Mon Jul 09 2018 Michal Hlavinka <mhlavink@redhat.com> - 3.6.0-1
- pciutils updated to 3.6.0
* Wed Mar 07 2018 Michal Hlavinka <mhlavink@redhat.com> - 3.5.6-4
- add gcc buildrequire
* Sat Feb 24 2018 Florian Weimer <fweimer@redhat.com> - 3.5.6-3 * Sat Feb 24 2018 Florian Weimer <fweimer@redhat.com> - 3.5.6-3
- Use LDFLAGS from redhat-rpm-config - Use LDFLAGS from redhat-rpm-config