From f0ff0e1b37ed19477f1349637fd36c55400a2143 Mon Sep 17 00:00:00 2001 From: Nils Koenig Date: Thu, 19 Oct 2023 17:56:03 +0200 Subject: [PATCH 1/8] Use systemd-sysusers to create vhostmd user See also BZ 2095483wq https://bugzilla.redhat.com/show_bug.cgi?id=2095483 --- vhostmd.spec | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/vhostmd.spec b/vhostmd.spec index 30e89e4..95f39a4 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -125,11 +125,7 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %pre # UID:GID 112:112 reserved, see RHBZ#534109. -getent group vhostmd >/dev/null || groupadd -g 112 -r vhostmd -getent passwd vhostmd >/dev/null || \ -useradd -u 112 -r -g vhostmd -d %{_datadir}/vhostmd -s /sbin/nologin \ --c "Virtual Host Metrics Daemon" vhostmd -exit 0 +%sysusers_create_inline u vhostmd 112 "Virtual Host Metrics Daemon" %{_datadir}/vhostmd /sbin/nologin %post From 8cbdb24e2b3b4e8acdc99ee9bf7f282c3228a1e6 Mon Sep 17 00:00:00 2001 From: Yaakov Selkowitz Date: Sun, 24 Dec 2023 15:14:28 -0500 Subject: [PATCH 2/8] Fix for https://fedoraproject.org/wiki/Changes/PortingToModernC https://github.com/vhostmd/vhostmd/pull/13 --- 0020-implicit-function-declarations.patch | 74 +++++++++++++++++++++++ vhostmd.spec | 2 + 2 files changed, 76 insertions(+) create mode 100644 0020-implicit-function-declarations.patch diff --git a/0020-implicit-function-declarations.patch b/0020-implicit-function-declarations.patch new file mode 100644 index 0000000..37d0272 --- /dev/null +++ b/0020-implicit-function-declarations.patch @@ -0,0 +1,74 @@ +From cf555d3bf079ff60b363dba4dc48a349dce5d3b4 Mon Sep 17 00:00:00 2001 +From: Yaakov Selkowitz +Date: Sun, 24 Dec 2023 14:54:09 -0500 +Subject: [PATCH] Fix implicit declarations +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Errors raised in Fedora rawhide and ELN which have added the +-Werror=implicit-function-declaration flag for C: + +virt-util.c:96:9: error: implicit declaration of function ‘calloc’ +virt-util.c:129:10: error: implicit declaration of function ‘free’ + +virtio.c:160:9: error: implicit declaration of function ‘free’ +virtio.c:254:31: error: implicit declaration of function ‘bsearch’ +virtio.c:259:13: error: implicit declaration of function ‘qsort’ +virtio.c:586:33: error: implicit declaration of function ‘calloc’ + +libmetrics.c:136:28: error: implicit declaration of function 'atoi' +libmetrics.c:142:29: error: implicit declaration of function 'atoll' +libmetrics.c:148:28: error: implicit declaration of function 'atof' +libmetrics.c:170:12: error: implicit declaration of function 'calloc' +libmetrics.c:189:12: error: implicit declaration of function 'free' +libmetrics.c:311:7: error: implicit declaration of function 'posix_memalign' +libmetrics.c:385:26: error: implicit declaration of function 'malloc' +libmetrics.c:848:28: error: implicit declaration of function 'realloc' + +Signed-off-by: Yaakov Selkowitz +--- + libmetrics/libmetrics.c | 1 + + vhostmd/virt-util.c | 1 + + vhostmd/virtio.c | 1 + + 3 files changed, 3 insertions(+) + +diff --git a/libmetrics/libmetrics.c b/libmetrics/libmetrics.c +index 8819074..c83fd03 100644 +--- a/libmetrics/libmetrics.c ++++ b/libmetrics/libmetrics.c +@@ -21,6 +21,7 @@ + #include + + #include ++#include + #include + #include + #include +diff --git a/vhostmd/virt-util.c b/vhostmd/virt-util.c +index a94cccd..40765c3 100644 +--- a/vhostmd/virt-util.c ++++ b/vhostmd/virt-util.c +@@ -21,6 +21,7 @@ + #include + + #include ++#include + #include + #include + +diff --git a/vhostmd/virtio.c b/vhostmd/virtio.c +index a6c2515..98340ce 100644 +--- a/vhostmd/virtio.c ++++ b/vhostmd/virtio.c +@@ -30,6 +30,7 @@ + #include + #include + #include ++#include + #include + + #include "util.h" +-- +2.43.0 + diff --git a/vhostmd.spec b/vhostmd.spec index 95f39a4..d5db983 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -33,6 +33,8 @@ Patch0016: 0016-vhostmd-Check-return-value-of-file-functions.patch Patch0017: 0017-vhostmd-Check-for-valide-file-handle-before-calling-.patch Patch0018: 0018-vhostmd-Fix-memory-leak-in-vhostmd_run.patch Patch0019: 0019-virtio-Fix-strncpy-length-parameter.patch +# https://github.com/vhostmd/vhostmd/pull/13 +Patch0020: 0020-implicit-function-declarations.patch BuildRequires: make BuildRequires: gcc From da4b24f541d666bfad50883fa5e741a8fe3cecd9 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 27 Jan 2024 07:42:42 +0000 Subject: [PATCH 3/8] Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild --- vhostmd.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vhostmd.spec b/vhostmd.spec index d5db983..26b2954 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -3,7 +3,7 @@ Summary: Virtualization host metrics daemon Name: vhostmd Version: 1.1 -Release: 14%{?dist} +Release: 15%{?dist} License: LGPL-2.1-or-later URL: https://github.com/vhostmd/vhostmd @@ -179,6 +179,9 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %changelog +* Sat Jan 27 2024 Fedora Release Engineering - 1.1-15 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + * Sat Jul 22 2023 Fedora Release Engineering - 1.1-14 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild From 3e64712b1ead22938fc8c798428816f542a31f6a Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 20 Jul 2024 08:44:51 +0000 Subject: [PATCH 4/8] Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild --- vhostmd.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vhostmd.spec b/vhostmd.spec index 26b2954..5b28244 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -3,7 +3,7 @@ Summary: Virtualization host metrics daemon Name: vhostmd Version: 1.1 -Release: 15%{?dist} +Release: 16%{?dist} License: LGPL-2.1-or-later URL: https://github.com/vhostmd/vhostmd @@ -179,6 +179,9 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %changelog +* Sat Jul 20 2024 Fedora Release Engineering - 1.1-16 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + * Sat Jan 27 2024 Fedora Release Engineering - 1.1-15 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild From 7b6141f39606fb725bb6b0a70d040f7371d9e8c7 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sun, 19 Jan 2025 14:18:40 +0000 Subject: [PATCH 5/8] Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild --- vhostmd.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vhostmd.spec b/vhostmd.spec index 5b28244..704b23b 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -3,7 +3,7 @@ Summary: Virtualization host metrics daemon Name: vhostmd Version: 1.1 -Release: 16%{?dist} +Release: 17%{?dist} License: LGPL-2.1-or-later URL: https://github.com/vhostmd/vhostmd @@ -179,6 +179,9 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %changelog +* Sun Jan 19 2025 Fedora Release Engineering - 1.1-17 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + * Sat Jul 20 2024 Fedora Release Engineering - 1.1-16 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild From 4dab2b5b60f6915ced596a22b60d1da93d001b8e Mon Sep 17 00:00:00 2001 From: Nils Koenig Date: Wed, 15 Jan 2025 23:00:18 +0100 Subject: [PATCH 6/8] Added rpminspect.yaml which avoids a xmllint check for dtd docu files. --- rpminspect.yaml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 rpminspect.yaml diff --git a/rpminspect.yaml b/rpminspect.yaml new file mode 100644 index 0000000..4347770 --- /dev/null +++ b/rpminspect.yaml @@ -0,0 +1,5 @@ +xml: + # Regular expression (man 7 regex) matching directories to ignore + # during the xml inspection. Skip DTD files, which + # contain a mix of XML and code. + exclude_path: .*(\.dtd)$ From 661e2929636a597007239a9be9d598e21a7ce879 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 25 Jul 2025 20:04:19 +0000 Subject: [PATCH 7/8] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild --- vhostmd.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vhostmd.spec b/vhostmd.spec index 704b23b..7402f2c 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -3,7 +3,7 @@ Summary: Virtualization host metrics daemon Name: vhostmd Version: 1.1 -Release: 17%{?dist} +Release: 18%{?dist} License: LGPL-2.1-or-later URL: https://github.com/vhostmd/vhostmd @@ -179,6 +179,9 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %changelog +* Fri Jul 25 2025 Fedora Release Engineering - 1.1-18 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + * Sun Jan 19 2025 Fedora Release Engineering - 1.1-17 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild From 9c76ecd62a43070af372159969aaff1a87fc52bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= Date: Thu, 2 Oct 2025 10:18:22 +0100 Subject: [PATCH 8/8] Disable build on i686 architecture MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit vhostmd is a leaf package so there is no reason to continue building it on i686. Signed-off-by: Daniel P. Berrangé --- vhostmd.spec | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/vhostmd.spec b/vhostmd.spec index 7402f2c..93a1476 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -3,7 +3,7 @@ Summary: Virtualization host metrics daemon Name: vhostmd Version: 1.1 -Release: 18%{?dist} +Release: 19%{?dist} License: LGPL-2.1-or-later URL: https://github.com/vhostmd/vhostmd @@ -36,6 +36,8 @@ Patch0019: 0019-virtio-Fix-strncpy-length-parameter.patch # https://github.com/vhostmd/vhostmd/pull/13 Patch0020: 0020-implicit-function-declarations.patch +ExcludeArch: %{ix86} + BuildRequires: make BuildRequires: gcc BuildRequires: chrpath @@ -179,6 +181,9 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %changelog +* Thu Oct 2 2025 Daniel P. Berrangé - 1.1-19 +- Disable build on i686 architecture + * Fri Jul 25 2025 Fedora Release Engineering - 1.1-18 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild