From patchwork Fri Jan 26 04:58:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hilton Chain X-Patchwork-Id: 59415 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 8528227BBEA; Fri, 26 Jan 2024 04:59:20 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FROM_SUSPICIOUS_NTLD,MAILING_LIST_MULTI,PDS_OTHER_BAD_TLD, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,URIBL_BLOCKED, URIBL_SBL_A autolearn=no autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 4E37A27BBE2 for ; Fri, 26 Jan 2024 04:59:19 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rTEIs-000579-5w; Thu, 25 Jan 2024 23:58:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rTEIq-00056Z-RV for guix-patches@gnu.org; Thu, 25 Jan 2024 23:58:56 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rTEIq-0007mf-9A for guix-patches@gnu.org; Thu, 25 Jan 2024 23:58:56 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rTEIw-0000Qz-C2; Thu, 25 Jan 2024 23:59:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#68728] [PATCH 1/2] gnu: virt-manager: Update package style. Resent-From: Hilton Chain Original-Sender: "Debbugs-submit" Resent-CC: hako@ultrarare.space, guix-patches@gnu.org Resent-Date: Fri, 26 Jan 2024 04:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68728 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 68728@debbugs.gnu.org Cc: Hilton Chain , Hilton Chain X-Debbugs-Original-Xcc: Hilton Chain Received: via spool by 68728-submit@debbugs.gnu.org id=B68728.17062451351644 (code B ref 68728); Fri, 26 Jan 2024 04:59:02 +0000 Received: (at 68728) by debbugs.gnu.org; 26 Jan 2024 04:58:55 +0000 Received: from localhost ([127.0.0.1]:49874 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rTEIo-0000QM-Lf for submit@debbugs.gnu.org; Thu, 25 Jan 2024 23:58:55 -0500 Received: from mail.boiledscript.com ([144.168.59.46]:34536) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rTEIl-0000QB-J8 for 68728@debbugs.gnu.org; Thu, 25 Jan 2024 23:58:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ultrarare.space; s=dkim; t=1706245087; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=CrCa+pUyxVIzyy2QH13yBVLWs8kvMPW7sP61XuyZ6V0=; b=l+NaVYuRMuhYvYFipM8yHsu+4aBH5ImhiiTTaTOjM2LfF92/nlAW+QlYN+daDMSZ9Ascjn +QCQ1P5/HJjSO7cJ5+r2TDWBMww7GXRlB9NK4xTU9Wx9klX4/88PaQBzeDrlJUd07X4tKe AwLSeMblMtgeR+WLCxCQpTP4NEqtZfeUxvxKQRMT3RIUvjABFpdxyj3ReB2N+EGShe9x/z 264PvHwjg/R2fB1P5Ay78itT5w+3TLVhUcr5wn0HE3TwLnj/uulOoKKTITdoeUYbU5+h+b ZvuyGsRDOxwU5WLufWNVs8/zUWWYygsFvTIA3Z2sFQ3BhN2JrV8Nq+ZAlCrYQw== Authentication-Results: mail.boiledscript.com; auth=pass smtp.mailfrom=hako@ultrarare.space Date: Fri, 26 Jan 2024 12:58:19 +0800 Message-ID: In-Reply-To: References: MIME-Version: 1.0 X-Spamd-Bar: -- X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Hilton Chain X-ACL-Warn: , Hilton Chain via Guix-patches X-Patchwork-Original-From: Hilton Chain via Guix-patches via From: Hilton Chain Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/virtualization.scm (virt-manager)[arguments]: Remove trailing #t. Use gexps. [inputs]: Sort alphabetically. [native-inputs]: Remove labels. Change-Id: I6efe95061ff13feb01c45809004884ab0a563d0c --- gnu/packages/virtualization.scm | 153 ++++++++++++++++---------------- 1 file changed, 75 insertions(+), 78 deletions(-) diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm index 35bac9a5ac..1c971471c7 100644 --- a/gnu/packages/virtualization.scm +++ b/gnu/packages/virtualization.scm @@ -1623,98 +1623,95 @@ (define-public virt-manager "18lhlnd3gmyzhbnjc16gdyzhjcd33prlxnca4xlidiidngbq21lm")))) (build-system python-build-system) (arguments - `(#:use-setuptools? #f ; uses custom distutils 'install' command - #:tests? #f ; TODO The tests currently fail - ; RuntimeError: Loop condition wasn't - ; met - #:imported-modules ((guix build glib-or-gtk-build-system) - ,@%python-build-system-modules) - #:modules ((ice-9 match) - (srfi srfi-26) - (guix build python-build-system) - ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) - (guix build utils)) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-setup - (lambda* (#:key outputs #:allow-other-keys) - (substitute* "virtinst/buildconfig.py" - (("/usr") (assoc-ref outputs "out"))) - #t)) - (add-after 'unpack 'fix-default-uri - (lambda* (#:key inputs #:allow-other-keys) - ;; Xen is not available for now - so only patch qemu. - (substitute* "virtManager/createconn.py" - (("/usr(/bin/qemu-system-[a-zA-Z0-9_-]+)" _ suffix) - (search-input-file inputs suffix))) - #t)) - (add-before 'wrap 'wrap-with-GI_TYPELIB_PATH - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((bin (string-append (assoc-ref outputs "out") "/bin")) - (bin-files (find-files bin ".*")) - (paths (map (match-lambda - ((output . directory) - (let* ((girepodir (string-append - directory - "/lib/girepository-1.0"))) - (if (file-exists? girepodir) - girepodir #f)))) - inputs))) - (for-each (lambda (file) - (format #t "wrapping ~a\n" file) - (wrap-program file - `("GI_TYPELIB_PATH" ":" prefix - ,(filter identity paths)))) - bin-files)) - #t)) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (setenv "HOME" "/tmp") - (setenv "XDG_CACHE_HOME" "/tmp") - (system "Xvfb :1 &") - (setenv "DISPLAY" ":1") - ;; Dogtail requires that Assistive Technology support be enabled - (setenv "GTK_MODULES" "gail:atk-bridge") - (invoke "dbus-run-session" "--" "pytest" "--uitests")) - #t)) - (add-after 'install 'glib-or-gtk-compile-schemas - (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas)) - (add-after 'wrap 'glib-or-gtk-wrap - (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))))) + (list #:use-setuptools? #f ; uses custom distutils 'install' command + #:tests? #f ; TODO: The tests currently fail + ; RuntimeError: Loop condition wasn't met + #:imported-modules + `((guix build glib-or-gtk-build-system) + ,@%python-build-system-modules) + #:modules + '((ice-9 match) + (srfi srfi-26) + (guix build python-build-system) + ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) + (guix build utils)) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-setup + (lambda _ + (substitute* "virtinst/buildconfig.py" + (("/usr") #$output)))) + (add-after 'unpack 'fix-default-uri + (lambda* (#:key inputs #:allow-other-keys) + ;; Xen is not available for now - so only patch qemu. + (substitute* "virtManager/createconn.py" + (("/usr(/bin/qemu-system-[a-zA-Z0-9_-]+)" _ suffix) + (search-input-file inputs suffix))))) + (add-before 'wrap 'wrap-with-GI_TYPELIB_PATH + (lambda* (#:key inputs #:allow-other-keys) + (let* ((bin (string-append #$output "/bin")) + (bin-files (find-files bin ".*")) + (paths (map (match-lambda + ((output . directory) + (let* ((girepodir (string-append + directory + "/lib/girepository-1.0"))) + (if (file-exists? girepodir) + girepodir #f)))) + inputs))) + (for-each (lambda (file) + (format #t "wrapping ~a\n" file) + (wrap-program file + `("GI_TYPELIB_PATH" ":" prefix + ,(filter identity paths)))) + bin-files)))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") + (setenv "XDG_CACHE_HOME" "/tmp") + (system "Xvfb :1 &") + (setenv "DISPLAY" ":1") + ;; Dogtail requires that Assistive Technology support be enabled + (setenv "GTK_MODULES" "gail:atk-bridge") + (invoke "dbus-run-session" "--" "pytest" "--uitests")))) + (add-after 'install 'glib-or-gtk-compile-schemas + (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas)) + (add-after 'wrap 'glib-or-gtk-wrap + (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))))) (inputs (list dconf gtk+ gtk-vnc gtksourceview-4 + libosinfo libvirt libvirt-glib - libosinfo - vte python-libvirt - python-requests + python-libxml2 python-pycairo python-pygobject - python-libxml2 - spice-gtk)) + python-requests + spice-gtk + vte)) ;; virt-manager searches for qemu-img or kvm-img in the PATH. (propagated-inputs (list qemu)) (native-inputs - `(("glib" ,glib "bin") ; glib-compile-schemas - ("gobject-introspection" ,gobject-introspection) - ("gtk+" ,gtk+ "bin") ; gtk-update-icon-cache - ("perl" ,perl) ; pod2man - ("intltool" ,intltool) - ("rst2man" ,python-docutils) - ;; The following are required for running the tests - ;; ("python-pytest" ,python-pytest) - ;; ("python-dogtail" ,python-dogtail) - ;; ("xvfb" ,xorg-server-for-tests) - ;; ("dbus" ,dbus) - ;; ("at-spi2-core" ,at-spi2-core) - ;; ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) - )) + (list `(,glib "bin") ; glib-compile-schemas + gobject-introspection + `(,gtk+ "bin") ; gtk-update-icon-cache + intltool + perl ; pod2man + python-docutils ; rst2man + ;; The following are required for running the tests + ;; at-spi2-core + ;; dbus + ;; gsettings-desktop-schemas + ;; python-dogtail + ;; python-pytest + ;; xorg-server-for-tests ; xvfb + )) (home-page "https://virt-manager.org/") (synopsis "Manage virtual machines") (description From patchwork Fri Jan 26 04:58:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Hilton Chain X-Patchwork-Id: 59414 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 7843927BBEA; Fri, 26 Jan 2024 04:59:09 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FROM_SUSPICIOUS_NTLD,MAILING_LIST_MULTI,PDS_OTHER_BAD_TLD, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 5980F27BBE2 for ; Fri, 26 Jan 2024 04:59:05 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rTEIr-000575-Vk; Thu, 25 Jan 2024 23:58:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rTEIr-00056f-1X for guix-patches@gnu.org; Thu, 25 Jan 2024 23:58:57 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rTEIq-0007mh-Nj for guix-patches@gnu.org; Thu, 25 Jan 2024 23:58:56 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rTEIw-0000R7-TQ; Thu, 25 Jan 2024 23:59:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#68728] [PATCH 2/2] gnu: virt-manager: Fix qemu path substitution. Resent-From: Hilton Chain Original-Sender: "Debbugs-submit" Resent-CC: hako@ultrarare.space, guix-patches@gnu.org Resent-Date: Fri, 26 Jan 2024 04:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68728 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 68728@debbugs.gnu.org Cc: Hilton Chain , Hilton Chain X-Debbugs-Original-Xcc: Hilton Chain Received: via spool by 68728-submit@debbugs.gnu.org id=B68728.17062451401657 (code B ref 68728); Fri, 26 Jan 2024 04:59:02 +0000 Received: (at 68728) by debbugs.gnu.org; 26 Jan 2024 04:59:00 +0000 Received: from localhost ([127.0.0.1]:49876 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rTEIt-0000Qe-FL for submit@debbugs.gnu.org; Thu, 25 Jan 2024 23:58:59 -0500 Received: from mail.boiledscript.com ([144.168.59.46]:50030) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rTEIo-0000QK-Dd for 68728@debbugs.gnu.org; Thu, 25 Jan 2024 23:58:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ultrarare.space; s=dkim; t=1706245090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=PhSD029P0uOW6LtKHiT25RXtKMWdvSb/98PH9hVyfnA=; b=GpjG+7rGIx3ysU4NhXEMer8ROS3fRlVxC+P76chinaic8iz6croTPpHkmGvRl3Mw9ZX9ef V4NzM/xHe0D7Alwpz44u1nlLJzf6ceB7wV6DOew2Xfg86CRSnqE8jp4ib+3P3b2X5goyjn YUbbyrktcpUUc26cKSBjXrhsM7FRfCKN4SICVLAWxhQ4zUI4a5KrrRVdJpME+L41TYHgit rjyH2dm6pGZBNRK5bpWdftP2mvFhqsfD0doP2fCQxQaFRyMFvrzCK158CLOwQOr87xz8Bw sg4bDv/vUITVLPpZCNXWOPuaMvklflweq8u+l/gG+hyUDB0P1pKGfaGxV1tKlA== Authentication-Results: mail.boiledscript.com; auth=pass smtp.mailfrom=hako@ultrarare.space Date: Fri, 26 Jan 2024 12:58:20 +0800 Message-ID: In-Reply-To: References: MIME-Version: 1.0 X-Spamd-Bar: --- X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Hilton Chain X-ACL-Warn: , Hilton Chain via Guix-patches X-Patchwork-Original-From: Hilton Chain via Guix-patches via From: Hilton Chain Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/virtualization.scm (virt-manager)[arguments]<#:phases>: Adjust ‘fix-default-uri’ according to source change. Change-Id: Ic5085841db4759096b844d6f92f81d90554709d1 --- gnu/packages/virtualization.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm index 1c971471c7..5888d777ea 100644 --- a/gnu/packages/virtualization.scm +++ b/gnu/packages/virtualization.scm @@ -1645,8 +1645,8 @@ (define-public virt-manager (lambda* (#:key inputs #:allow-other-keys) ;; Xen is not available for now - so only patch qemu. (substitute* "virtManager/createconn.py" - (("/usr(/bin/qemu-system-[a-zA-Z0-9_-]+)" _ suffix) - (search-input-file inputs suffix))))) + (("/usr(/bin/qemu-system-\\*)" _ suffix) + (string-append #$(this-package-input "qemu") suffix))))) (add-before 'wrap 'wrap-with-GI_TYPELIB_PATH (lambda* (#:key inputs #:allow-other-keys) (let* ((bin (string-append #$output "/bin"))