From 769e1c6edcc8a4f2e46a1d70f3fefb7c572add49 Mon Sep 17 00:00:00 2001 From: Than Ngo Date: Tue, 23 Sep 2025 11:04:55 +0200 Subject: [PATCH] Resolves: RHEL-93155, multiple errors of vpcupdate during boot --- 99-libvpd.conf | 1 + libvpd-install-rules-in-system-wide-dir.patch | 22 ++++++++++++++++ libvpd.spec | 26 ++++++++++++------- 3 files changed, 40 insertions(+), 9 deletions(-) create mode 100644 99-libvpd.conf create mode 100644 libvpd-install-rules-in-system-wide-dir.patch diff --git a/99-libvpd.conf b/99-libvpd.conf new file mode 100644 index 0000000..8a25d7c --- /dev/null +++ b/99-libvpd.conf @@ -0,0 +1 @@ +install_items+=" /usr/bin/touch " diff --git a/libvpd-install-rules-in-system-wide-dir.patch b/libvpd-install-rules-in-system-wide-dir.patch new file mode 100644 index 0000000..fa1e12d --- /dev/null +++ b/libvpd-install-rules-in-system-wide-dir.patch @@ -0,0 +1,22 @@ +diff -up libvpd-2.2.10/Makefile.am.me libvpd-2.2.10/Makefile.am +--- libvpd-2.2.10/Makefile.am.me 2025-09-23 10:19:07.836805451 +0200 ++++ libvpd-2.2.10/Makefile.am 2025-09-23 10:49:26.932917705 +0200 +@@ -49,6 +49,8 @@ libvpd_cxx_la_SOURCES = src/vpdretriever + CXX_VERSION=@GENERIC_CXX_LIBRARY_VERSION@ + C_VERSION=@GENERIC_C_LIBRARY_VERSION@ + ++udevrulesdir = $(prefix)/lib/udev/rules.d ++ + pkgconfigdir = $(libdir)/pkgconfig + pkgconfig_DATA = libvpd-2.pc libvpd_cxx-2.pc + +@@ -65,7 +67,7 @@ libtool: $(LIBTOOL_DEPS) + $(SHELL) ./config.status --recheck + + install-exec-hook: +- mkdir -p $(DESTDIR)/${sysconfdir}/udev/rules.d/ ++ mkdir -p $(DESTDIR)/${udevrulesdir} + mkdir -p $(DESTDIR)/${localstatedir}/lib/lsvpd/ + install -D --mode=644 90-vpdupdate.rules \ +- ${DESTDIR}/${sysconfdir}/udev/rules.d/90-vpdupdate.rules ++ ${DESTDIR}/${udevrulesdir}/90-vpdupdate.rules diff --git a/libvpd.spec b/libvpd.spec index 31981fd..8006625 100644 --- a/libvpd.spec +++ b/libvpd.spec @@ -1,15 +1,20 @@ Name: libvpd Version: 2.2.10 -Release: 1%{?dist} +Release: 2%{?dist} Summary: VPD Database access library for lsvpd License: LGPL-2.0-or-later URL: https://github.com/power-ras/%{name}/releases -Source: https://github.com/power-ras/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz +Source0: https://github.com/power-ras/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz +Source1: 99-libvpd.conf +Patch1: libvpd-install-rules-in-system-wide-dir.patch +BuildRequires: autoconf automake libtool BuildRequires: gcc-c++ -BuildRequires: sqlite-devel zlib-devel libstdc++-devel libtool BuildRequires: make +BuildRequires: sqlite-devel +BuildRequires: systemd-devel +BuildRequires: zlib-devel ExclusiveArch: %{power64} @@ -24,29 +29,29 @@ Requires: %{name} = %{version}-%{release} sqlite-devel pkgconfig Contains header files for building with libvpd. %prep -%setup -q +%autosetup %build -export CXXFLAGS="-std=c++14 $RPM_OPT_FLAGS" ./bootstrap.sh %configure --disable-static -make %{?_smp_mflags} +%make_build %install -make install DESTDIR=$RPM_BUILD_ROOT +%make_install find %{buildroot} -type f -name "*.la" -delete +install -D -m644 %{SOURCE1} %{buildroot}%{_prefix}/lib/dracut/dracut.conf.d/99-libvpd.conf %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files -%{!?_licensedir:%global license %%doc} %license COPYING %doc README %{_libdir}/libvpd_cxx-2.2.so.* %{_libdir}/libvpd-2.2.so.* -%{_sysconfdir}/udev/rules.d/90-vpdupdate.rules +%{_udevrulesdir}/90-vpdupdate.rules +%{_prefix}/lib/dracut/dracut.conf.d/* %files devel %{_includedir}/libvpd-2 @@ -56,6 +61,9 @@ find %{buildroot} -type f -name "*.la" -delete %{_libdir}/pkgconfig/libvpd_cxx-2.pc %changelog +* Tue Sep 23 2025 Than Ngo - 2.2.10-2 +- Resolves: RHEL-93155, multiple errors of vpcupdate during boot + * Fri Dec 06 2024 Than Ngo - 2.2.10-1 - Update to 2.2.10, fix displaying duplicate VPD details Resolves: RHEL-24572