diff options
| author | Maxim Cournoyer <maxim@guixotic.coop> | 2026-01-05 13:45:44 +0900 |
|---|---|---|
| committer | Maxim Cournoyer <maxim@guixotic.coop> | 2026-01-27 11:16:12 +0900 |
| commit | 5b1f7552e2df9b718420da31017e319b067bddf1 (patch) | |
| tree | be44732de09dd004921ecce8fc34c68f84c86486 | |
| parent | 476e0818c15f538297af724443e25faa77b08022 (diff) | |
gnu: qemu: Update to 10.2.0.
* gnu/packages/virtualization.scm (qemu): Update to 10.2.0.
* gnu/packages/patches/qemu-fix-agent-paths.patch: Update patch.
* gnu/packages/patches/qemu-fix-test-virtio-version.patch: Adjust for file
name change.
Relates-to: #2447
Change-Id: I26034baf660af802cf4a4646d3b303f949bb1f3f
| -rw-r--r-- | gnu/packages/patches/qemu-fix-agent-paths.patch | 53 | ||||
| -rw-r--r-- | gnu/packages/patches/qemu-fix-test-virtio-version.patch | 4 | ||||
| -rw-r--r-- | gnu/packages/virtualization.scm | 6 |
3 files changed, 19 insertions, 44 deletions
diff --git a/gnu/packages/patches/qemu-fix-agent-paths.patch b/gnu/packages/patches/qemu-fix-agent-paths.patch index 91572fb664c..9ace7000251 100644 --- a/gnu/packages/patches/qemu-fix-agent-paths.patch +++ b/gnu/packages/patches/qemu-fix-agent-paths.patch @@ -1,46 +1,21 @@ -Allow a QEMU host to set the time and shutdown Guix guests. Styled -after the patch from the Nix package: - -https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/virtualization/qemu/fix-qemu-ga.patch - diff --git a/qga/commands-posix.c b/qga/commands-posix.c -index 6e3c15f539..eaef900b6e 100644 +index 837be51c40..d0d4d99b5e 100644 --- a/qga/commands-posix.c +++ b/qga/commands-posix.c -@@ -216,6 +216,7 @@ out: - void qmp_guest_shutdown(const char *mode, Error **errp) - { - const char *shutdown_flag; -+ const char *command; - Error *local_err = NULL; +@@ -216,9 +216,9 @@ out: + return retcode; + } - #ifdef CONFIG_SOLARIS -@@ -235,16 +236,24 @@ void qmp_guest_shutdown(const char *mode, Error **errp) - slog("guest-shutdown called, mode: %s", mode); - if (!mode || strcmp(mode, "powerdown") == 0) { - shutdown_flag = powerdown_flag; -+ command = "shutdown"; - } else if (strcmp(mode, "halt") == 0) { - shutdown_flag = halt_flag; -+ command = "halt"; - } else if (strcmp(mode, "reboot") == 0) { - shutdown_flag = reboot_flag; -+ command = "reboot"; - } else { - error_setg(errp, - "mode is invalid (valid values are: halt|powerdown|reboot"); - return; - } +-#define POWEROFF_CMD_PATH "/sbin/poweroff" +-#define HALT_CMD_PATH "/sbin/halt" +-#define REBOOT_CMD_PATH "/sbin/reboot" ++#define POWEROFF_CMD_PATH "/run/current-system/profile/sbin/shutdown" ++#define HALT_CMD_PATH "/run/current-system/profile/sbin/halt" ++#define REBOOT_CMD_PATH "/run/current-system/profile/sbin/reboot" -+ /* Try Guix’s shutdown/halt/reboot first. */ -+ char *path = g_strdup_printf("/run/current-system/profile/sbin/%s", command); -+ execl(path, command, (char *) NULL); -+ g_free(path); -+ - const char *argv[] = {"/sbin/shutdown", - #ifdef CONFIG_SOLARIS - shutdown_flag, "-g0", "-y", -@@ -269,7 +278,7 @@ void qmp_guest_set_time(bool has_time, int64_t time_ns, Error **errp) + void qmp_guest_shutdown(const char *mode, Error **errp) + { +@@ -295,7 +295,7 @@ void qmp_guest_set_time(bool has_time, int64_t time_ns, Error **errp) int ret; Error *local_err = NULL; struct timeval tv; @@ -49,7 +24,7 @@ index 6e3c15f539..eaef900b6e 100644 /* If user has passed a time, validate and set it. */ if (has_time) { -@@ -302,6 +311,11 @@ void qmp_guest_set_time(bool has_time, int64_t time_ns, Error **errp) +@@ -328,6 +328,11 @@ void qmp_guest_set_time(bool has_time, int64_t time_ns, Error **errp) * hardware clock (RTC). */ ga_run_command(argv, NULL, "set hardware clock to system time", &local_err); diff --git a/gnu/packages/patches/qemu-fix-test-virtio-version.patch b/gnu/packages/patches/qemu-fix-test-virtio-version.patch index 8e466324e7e..43fb527a875 100644 --- a/gnu/packages/patches/qemu-fix-test-virtio-version.patch +++ b/gnu/packages/patches/qemu-fix-test-virtio-version.patch @@ -5,8 +5,8 @@ There were some discussion in <https://gitlab.com/qemu-project/qemu/-/issues/162 diff --git a/tests/functional/test_virtio_version.py b/tests/functional/test_virtio_version.py index a5ea73237f..501545f655 100755 ---- a/tests/functional/test_virtio_version.py -+++ b/tests/functional/test_virtio_version.py +--- a/tests/functional/x86_64/test_virtio_version.py ++++ b/tests/functional/x86_64/test_virtio_version.py @@ -10,6 +10,8 @@ # This work is licensed under the terms of the GNU GPL, version 2 or # later. See the COPYING file in the top-level directory. diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm index 9e81d8e8d59..40c5f463b70 100644 --- a/gnu/packages/virtualization.scm +++ b/gnu/packages/virtualization.scm @@ -15,7 +15,7 @@ ;;; Copyright © 2020, 2021 Brice Waegeneire <brice@waegenei.re> ;;; Copyright © 2020 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020, 2021, 2022 Marius Bakke <marius@gnu.org> -;;; Copyright © 2020-2025 Maxim Cournoyer <maxim@guixotic.coop> +;;; Copyright © 2020-2026 Maxim Cournoyer <maxim@guixotic.coop> ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org> ;;; Copyright © 2021 Leo Famulari <leo@famulari.name> ;;; Copyright © 2021, 2022 Pierre Langlois <pierre.langlois@gmx.com> @@ -201,14 +201,14 @@ ;; Do not forget to update the various firmware used by QEMU, and sync the ;; configuration options used by the seabios-qemu package with those ;; provided by QEMU. - (version "10.1.0") + (version "10.2.0") (source (origin (method url-fetch) (uri (string-append "https://download.qemu.org/qemu-" version ".tar.xz")) (sha256 - (base32 "0ldyh3qia7zwv0xq6f67cp567i6ma1hb11gsqaz3x9qcnm4p6lg0")) + (base32 "0fl8hlkngmm61h65822xxb6cyfbz56mx30hm01il8ywzicdssc4y")) (patches (search-patches "qemu-build-info-manual.patch" "qemu-fix-agent-paths.patch" "qemu-fix-test-virtio-version.patch")) |
