Enable building for ppc64le
This commit is contained in:
commit
968d5739e9
29
0001-appliance-Ignore-sit0-network-device-in-the-guest.patch
Normal file
29
0001-appliance-Ignore-sit0-network-device-in-the-guest.patch
Normal file
@ -0,0 +1,29 @@
|
||||
From dc218b25f0bc2704918748e4e8120ec436783e58 Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Tue, 24 Jun 2025 14:04:10 +0100
|
||||
Subject: [PATCH] appliance: Ignore sit0 network device in the guest
|
||||
|
||||
Reported-by: Srikanth Aithal <sraithal@amd.com>
|
||||
Fixed-by: Stefano Brivio <sbrivio@redhat.com>
|
||||
Tested-by: Srikanth Aithal <sraithal@amd.com>
|
||||
See-also: https://lists.libguestfs.org/archives/list/guestfs@lists.libguestfs.org/thread/566LAY7RNM7T7EMQQQYIQA2VK5TXETK5/
|
||||
---
|
||||
appliance/init | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/appliance/init b/appliance/init
|
||||
index 5d35a47dd..47eb97dfc 100755
|
||||
--- a/appliance/init
|
||||
+++ b/appliance/init
|
||||
@@ -127,7 +127,7 @@ ip addr add 127.0.0.1/8 brd + dev lo scope host
|
||||
ip link set dev lo up
|
||||
|
||||
if test "$guestfs_network" = 1; then
|
||||
- iface=$(ls -I all -I default -I lo /proc/sys/net/ipv4/conf)
|
||||
+ iface=$(ls -I all -I default -I lo -I sit0 /proc/sys/net/ipv4/conf)
|
||||
# Two workarounds for Ubuntu:
|
||||
touch /etc/fstab
|
||||
rm -f /etc/dhcp/dhclient-enter-hooks.d/resolved
|
||||
--
|
||||
2.47.1
|
||||
|
@ -1,42 +0,0 @@
|
||||
From 7cf0ed750ef7119503fc72cb19c29a269a893e8e Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Wed, 11 Jun 2025 22:45:51 +0100
|
||||
Subject: [PATCH] lib: Enable ACPI for the libvirt backend
|
||||
|
||||
Many years ago we used to pass acpi=off on the Linux kernel command
|
||||
line. In commit db1f811b2 we stopped doing that (around 2016).
|
||||
However unless you also use:
|
||||
|
||||
<features>
|
||||
<acpi/>
|
||||
</features>
|
||||
|
||||
then it turns out that libvirt disables ACPI generation at the qemu
|
||||
level. None of this mattered until SeaBIOS 1.17 changed its
|
||||
behaviour, causing ACPI to be required for virtio devices to work.
|
||||
|
||||
Updates: commit db1f811b29b055625ae1b03cf0daa9fed0d443ac
|
||||
Related: https://bugzilla.redhat.com/show_bug.cgi?id=2372329
|
||||
Thanks: Gerd Hoffmann
|
||||
---
|
||||
lib/launch-libvirt.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/lib/launch-libvirt.c b/lib/launch-libvirt.c
|
||||
index aa9534c68..40b57f7ca 100644
|
||||
--- a/lib/launch-libvirt.c
|
||||
+++ b/lib/launch-libvirt.c
|
||||
@@ -1175,6 +1175,10 @@ construct_libvirt_xml_cpu (guestfs_h *g,
|
||||
|
||||
single_element_format ("vcpu", "%d", g->smp);
|
||||
|
||||
+ start_element ("features") {
|
||||
+ empty_element ("acpi");
|
||||
+ } end_element ();
|
||||
+
|
||||
start_element ("clock") {
|
||||
attribute ("offset", "utc");
|
||||
|
||||
--
|
||||
2.47.1
|
||||
|
@ -1,35 +0,0 @@
|
||||
From f6fe0611a8980694b8e4e33b9c824805d353679f Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Thu, 12 Jun 2025 08:11:56 +0100
|
||||
Subject: [PATCH] lib: Make libvirt ACPI feature flag conditional on x86 or Arm
|
||||
|
||||
On ppc64 and s390x it failed with an error like:
|
||||
|
||||
unsupported configuration: machine type 'pseries-10.0' does not support ACPI
|
||||
|
||||
Updates: commit 7cf0ed750ef7119503fc72cb19c29a269a893e8e
|
||||
Related: https://bugzilla.redhat.com/show_bug.cgi?id=2372329
|
||||
---
|
||||
lib/launch-libvirt.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/lib/launch-libvirt.c b/lib/launch-libvirt.c
|
||||
index 40b57f7ca..55a4ad41c 100644
|
||||
--- a/lib/launch-libvirt.c
|
||||
+++ b/lib/launch-libvirt.c
|
||||
@@ -1175,9 +1175,12 @@ construct_libvirt_xml_cpu (guestfs_h *g,
|
||||
|
||||
single_element_format ("vcpu", "%d", g->smp);
|
||||
|
||||
+#if defined(__i386__) || defined(__x86_64__) || \
|
||||
+ defined(__arm__) || defined(__aarch64__)
|
||||
start_element ("features") {
|
||||
empty_element ("acpi");
|
||||
} end_element ();
|
||||
+#endif
|
||||
|
||||
start_element ("clock") {
|
||||
attribute ("offset", "utc");
|
||||
--
|
||||
2.47.1
|
||||
|
@ -0,0 +1,29 @@
|
||||
From 0a91731356a5bb0ab8eee620fc1fed1656b117f9 Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Fri, 25 Jul 2025 09:36:35 +0100
|
||||
Subject: [PATCH] lib: libvirt: Debug error from virDomainDestroyFlags
|
||||
|
||||
It's useful to see the error returned from virDomainDestroyFlags, so
|
||||
make sure this gets written to debug output.
|
||||
---
|
||||
lib/launch-libvirt.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/lib/launch-libvirt.c b/lib/launch-libvirt.c
|
||||
index 55a4ad41c..8dbde5341 100644
|
||||
--- a/lib/launch-libvirt.c
|
||||
+++ b/lib/launch-libvirt.c
|
||||
@@ -2173,6 +2173,10 @@ destroy_domain (guestfs_h *g, virDomainPtr dom, int check_for_errors)
|
||||
|
||||
/* Error returned by virDomainDestroyFlags ... */
|
||||
err = virGetLastError ();
|
||||
+ if (err && err->code != 0) {
|
||||
+ debug (g, "virDomainDestroy: %s [code=%d int1=%d]",
|
||||
+ err->message, err->code, err->int1);
|
||||
+ }
|
||||
|
||||
/* Retry (indefinitely) if we're just waiting for qemu to shut down. See:
|
||||
* https://www.redhat.com/archives/libvir-list/2016-January/msg00767.html
|
||||
--
|
||||
2.47.1
|
||||
|
@ -0,0 +1,32 @@
|
||||
From c7aaa89fba21499fa6ba11e41fdc8de610819a87 Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Fri, 25 Jul 2025 09:39:51 +0100
|
||||
Subject: [PATCH] lib: libvirt: Sleep before retrying virDomainDestroyFlags
|
||||
|
||||
This saves us going into a loop if virDomainDestroyFlags keeps
|
||||
returning -EBUSY quickly, which apparenrly can happen in containers.
|
||||
|
||||
The equivalent 'direct' backend code sleeps for 2 seconds in this case.
|
||||
---
|
||||
lib/launch-libvirt.c | 4 +++-
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lib/launch-libvirt.c b/lib/launch-libvirt.c
|
||||
index 8dbde5341..c690a444a 100644
|
||||
--- a/lib/launch-libvirt.c
|
||||
+++ b/lib/launch-libvirt.c
|
||||
@@ -2181,8 +2181,10 @@ destroy_domain (guestfs_h *g, virDomainPtr dom, int check_for_errors)
|
||||
/* Retry (indefinitely) if we're just waiting for qemu to shut down. See:
|
||||
* https://www.redhat.com/archives/libvir-list/2016-January/msg00767.html
|
||||
*/
|
||||
- if (err && err->code == VIR_ERR_SYSTEM_ERROR && err->int1 == EBUSY)
|
||||
+ if (err && err->code == VIR_ERR_SYSTEM_ERROR && err->int1 == EBUSY) {
|
||||
+ sleep (1);
|
||||
goto again;
|
||||
+ }
|
||||
|
||||
/* "Domain not found" is not treated as an error. */
|
||||
if (err && err->code == VIR_ERR_NO_DOMAIN)
|
||||
--
|
||||
2.47.1
|
||||
|
49
0004-daemon-Add-contents-of-etc-fstab-to-verbose-log.patch
Normal file
49
0004-daemon-Add-contents-of-etc-fstab-to-verbose-log.patch
Normal file
@ -0,0 +1,49 @@
|
||||
From f4f84a882468cb7b2dc4c265bdc18a5df79c3d4d Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Wed, 30 Jul 2025 10:53:20 +0100
|
||||
Subject: [PATCH] daemon: Add contents of /etc/fstab to verbose log
|
||||
|
||||
Also some mdadm configuration files. This is useful for debugging.
|
||||
|
||||
The output looks like this:
|
||||
|
||||
info: /etc/fstab in /dev/VG/Root
|
||||
LABEL=BOOT /boot ext2 default 0 0$
|
||||
LABEL=ROOT / ext2 default 0 0$
|
||||
|
||||
Fixes: https://issues.redhat.com/browse/RHEL-106490
|
||||
---
|
||||
daemon/inspect_fs_unix_fstab.ml | 17 +++++++++++++++++
|
||||
1 file changed, 17 insertions(+)
|
||||
|
||||
diff --git a/daemon/inspect_fs_unix_fstab.ml b/daemon/inspect_fs_unix_fstab.ml
|
||||
index 8e765454a..b4652a39d 100644
|
||||
--- a/daemon/inspect_fs_unix_fstab.ml
|
||||
+++ b/daemon/inspect_fs_unix_fstab.ml
|
||||
@@ -43,6 +43,23 @@ let rec check_fstab ?(mdadm_conf = false) (root_mountable : Mountable.t)
|
||||
if mdadm_conf then ["/etc/mdadm.conf"; "/etc/mdadm/mdadm.conf"] else [] in
|
||||
let configfiles = "/etc/fstab" :: mdadmfiles in
|
||||
|
||||
+ (* If verbose, dump the contents of each config file as that can be
|
||||
+ * useful for debugging.
|
||||
+ *)
|
||||
+ if verbose () then (
|
||||
+ List.iter (
|
||||
+ fun filename ->
|
||||
+ let sysroot_filename = Sysroot.sysroot_path filename in
|
||||
+ if Sys.file_exists sysroot_filename then (
|
||||
+ eprintf "info: %s in %s\n%!"
|
||||
+ filename (Mountable.to_string root_mountable);
|
||||
+ let cmd = sprintf "cat -A %s >&2" (quote sysroot_filename) in
|
||||
+ ignore (Sys.command cmd);
|
||||
+ eprintf "\n%!"
|
||||
+ )
|
||||
+ ) configfiles
|
||||
+ );
|
||||
+
|
||||
with_augeas ~name:"check_fstab_aug"
|
||||
configfiles (check_fstab_aug mdadm_conf root_mountable os_type)
|
||||
|
||||
--
|
||||
2.47.1
|
||||
|
@ -0,0 +1,47 @@
|
||||
From 217823da95aad095a1c86a90aa4b1db8d46319e4 Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Wed, 30 Jul 2025 11:05:17 +0100
|
||||
Subject: [PATCH] appliance/init: Add lsblk and blkid output to verbose log
|
||||
|
||||
This is useful for debugging. The output looks like:
|
||||
|
||||
+ lsblk
|
||||
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
|
||||
sda 8:0 0 1G 0 disk
|
||||
|-sda1 8:1 0 512M 0 part
|
||||
`-sda2 8:2 0 512M 0 part
|
||||
|-VG-Root 252:0 0 32M 0 lvm
|
||||
|-VG-LV1 252:1 0 32M 0 lvm
|
||||
|-VG-LV2 252:2 0 32M 0 lvm
|
||||
`-VG-LV3 252:3 0 64M 0 lvm
|
||||
sdb 8:16 0 4G 0 disk /
|
||||
+ blkid
|
||||
/dev/mapper/VG-LV1: UUID="cc8a3437-4169-4b1c-b432-ee8adc563f6d" BLOCK_SIZE="4096" TYPE="ext2"
|
||||
/dev/sdb: UUID="30c70ddc-d00b-4620-a408-025890e59aa6" BLOCK_SIZE="4096" TYPE="ext2"
|
||||
/dev/mapper/VG-LV2: UUID="747009aa-e183-46ba-a034-0c437b15cebc" BLOCK_SIZE="1024" TYPE="ext2"
|
||||
/dev/mapper/VG-Root: LABEL="ROOT" UUID="01234567-0123-0123-0123-012345678902" BLOCK_SIZE="4096" TYPE="ext2"
|
||||
/dev/sda2: UUID="DfEjc1-wRU6-vh8U-we7U-ivEl-FRwo-rG0ZuL" TYPE="LVM2_member" PARTUUID="184cbb43-02"
|
||||
/dev/sda1: LABEL="BOOT" UUID="01234567-0123-0123-0123-012345678901" BLOCK_SIZE="4096" TYPE="ext2" PARTUUID="184cbb43-01"
|
||||
/dev/mapper/VG-LV3: UUID="f9e5dc21-9a2a-45a0-85b0-e2889607139a" BLOCK_SIZE="2048" TYPE="ext2"
|
||||
|
||||
Fixes: https://issues.redhat.com/browse/RHEL-106490
|
||||
---
|
||||
appliance/init | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/appliance/init b/appliance/init
|
||||
index 47eb97dfc..62526ac77 100755
|
||||
--- a/appliance/init
|
||||
+++ b/appliance/init
|
||||
@@ -184,6 +184,8 @@ if test "$guestfs_verbose" = 1 && test "$guestfs_boot_analysis" != 1; then
|
||||
ls -lR /dev
|
||||
cat /proc/mounts
|
||||
cat /proc/mdstat
|
||||
+ lsblk
|
||||
+ blkid
|
||||
lvm config
|
||||
lvm pvs
|
||||
lvm vgs
|
||||
--
|
||||
2.47.1
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 3adbeb6b3fce8edd2af43e77a876c58a3ea1a424 Mon Sep 17 00:00:00 2001
|
||||
From e80928d0242730dd613ad9b30a72ef23760b4a6d Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Mon, 29 Jul 2013 14:47:56 +0100
|
||||
Subject: [PATCH] RHEL: Disable unsupported remote drive protocols
|
@ -1,4 +1,4 @@
|
||||
From 61a520e98fc12fd642230a276e9478c8d75f8bec Mon Sep 17 00:00:00 2001
|
||||
From 4a0e2396b9ed6426733dc9d2d9e033c8a769d0d1 Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Tue, 7 Jul 2015 09:28:03 -0400
|
||||
Subject: [PATCH] RHEL: Reject use of libguestfs-winsupport features except for
|
@ -1,4 +1,4 @@
|
||||
From eab15d4fba9c82d1910d70bd58b080ccbd398923 Mon Sep 17 00:00:00 2001
|
||||
From 4490b82bc44ef2fe8b5619dfaf5debc93d8e32d4 Mon Sep 17 00:00:00 2001
|
||||
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||||
Date: Tue, 13 May 2025 17:28:25 +0100
|
||||
Subject: [PATCH] RHEL: appliance/init: Run depmod -a to rebuild kernel module
|
||||
@ -9,7 +9,7 @@ Subject: [PATCH] RHEL: appliance/init: Run depmod -a to rebuild kernel module
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/appliance/init b/appliance/init
|
||||
index 5d35a47dd..a3c5654ea 100755
|
||||
index 62526ac77..c94f50079 100755
|
||||
--- a/appliance/init
|
||||
+++ b/appliance/init
|
||||
@@ -116,6 +116,9 @@ $UDEVD --daemon #--debug
|
@ -41,8 +41,8 @@ ExcludeArch: %{ix86}
|
||||
Summary: Access and modify virtual machine disk images
|
||||
Name: libguestfs
|
||||
Epoch: 1
|
||||
Version: 1.56.0
|
||||
Release: 1%{?dist}.1.alma.1
|
||||
Version: 1.56.1
|
||||
Release: 1%{?dist}.alma.1
|
||||
License: LGPL-2.1-or-later
|
||||
|
||||
# Build only for architectures that have a kernel
|
||||
@ -82,11 +82,14 @@ Source8: copy-patches.sh
|
||||
# https://github.com/libguestfs/libguestfs/commits/rhel-10.1
|
||||
|
||||
# Patches.
|
||||
Patch0001: 0001-lib-Enable-ACPI-for-the-libvirt-backend.patch
|
||||
Patch0002: 0002-lib-Make-libvirt-ACPI-feature-flag-conditional-on-x8.patch
|
||||
Patch0003: 0003-RHEL-Disable-unsupported-remote-drive-protocols-RHBZ.patch
|
||||
Patch0004: 0004-RHEL-Reject-use-of-libguestfs-winsupport-features-ex.patch
|
||||
Patch0005: 0005-RHEL-appliance-init-Run-depmod-a-to-rebuild-kernel-m.patch
|
||||
Patch0001: 0001-appliance-Ignore-sit0-network-device-in-the-guest.patch
|
||||
Patch0002: 0002-lib-libvirt-Debug-error-from-virDomainDestroyFlags.patch
|
||||
Patch0003: 0003-lib-libvirt-Sleep-before-retrying-virDomainDestroyFl.patch
|
||||
Patch0004: 0004-daemon-Add-contents-of-etc-fstab-to-verbose-log.patch
|
||||
Patch0005: 0005-appliance-init-Add-lsblk-and-blkid-output-to-verbose.patch
|
||||
Patch0006: 0006-RHEL-Disable-unsupported-remote-drive-protocols-RHBZ.patch
|
||||
Patch0007: 0007-RHEL-Reject-use-of-libguestfs-winsupport-features-ex.patch
|
||||
Patch0008: 0008-RHEL-appliance-init-Run-depmod-a-to-rebuild-kernel-m.patch
|
||||
|
||||
BuildRequires: autoconf, automake, libtool, gettext-devel
|
||||
|
||||
@ -1073,11 +1076,11 @@ rm ocaml/html/.gitignore
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Jun 13 2025 Eduard Abdullin <eabdullin@almalinux.org> - 1:1.56.0-1.1.alma.1
|
||||
* Thu Jul 31 2025 Eduard Abdullin <eabdullin@almalinux.org> - 1:1.56.1-1.alma.1
|
||||
- Enable building for ppc64le
|
||||
|
||||
* Thu Jun 12 2025 Richard W.M. Jones <rjones@redhat.com> - 1:1.56.0-1.el10.1
|
||||
- Rebase to libguestfs 1.56.0
|
||||
* Wed Jul 30 2025 Richard W.M. Jones <rjones@redhat.com> - 1:1.56.1-1
|
||||
- Rebase to libguestfs 1.56.1
|
||||
resolves: RHEL-81733
|
||||
- Include host kernel information in libguestfs debugging output
|
||||
resolves: RHEL-83026
|
||||
@ -1096,6 +1099,8 @@ rm ocaml/html/.gitignore
|
||||
resolves: RHEL-92239
|
||||
- Ignore btrfs snapshots of roots
|
||||
resolves: RHEL-93109
|
||||
- Add /etc/fstab, lsblk and blkid to verbose output
|
||||
resolves: RHEL-106490
|
||||
|
||||
* Tue Nov 26 2024 Richard W.M. Jones <rjones@redhat.com> - 1:1.54.0-5
|
||||
- Rebase to libguestfs 1.54.0
|
||||
|
4
sources
4
sources
@ -1,2 +1,2 @@
|
||||
SHA512 (libguestfs-1.56.0.tar.gz) = 2aae2a4222680000ff06954adf074825e2f6ef182694d84b3e0f39ba4b2e942b3a214f438f937341fd5c72be67620d97330639739720cde6312502fc81d868ae
|
||||
SHA512 (libguestfs-1.56.0.tar.gz.sig) = 481ec244a787ea19343ee4b7e6820d5273b483a0c1e29b934a7608e9efefae9562db5fd6d33d6bf76997de4eeeff966e6d33a3873ecaee8432150b5a9d86d8f3
|
||||
SHA512 (libguestfs-1.56.1.tar.gz) = 8ec8db8b3de7471c7ab77161fa98349d7b6f88a803ab563f1859606a2ef55737f323b1cf3ef2ebb3055770f4140aabb056f97099ef76fa7ad0f7bd792cc699fc
|
||||
SHA512 (libguestfs-1.56.1.tar.gz.sig) = 80fcdf73e8a4b453e96b40b8a29d91dcad0418865d8472300f5e1d972f849b0d2cfd0e204bb20b79285471756c9180f259dc4aa10c56cfdf7153ffb1ef646036
|
||||
|
Loading…
Reference in New Issue
Block a user