From patchwork Sat Jan 4 00:33:33 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Giacomo Leidi X-Patchwork-Id: 36429 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 AAE7227BBEA; Sat, 4 Jan 2025 00:35:28 +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=-6.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham 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 F3B4927BBE2 for ; Sat, 4 Jan 2025 00:35:25 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tTs89-0004aS-CF; Fri, 03 Jan 2025 19:35:05 -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 1tTs87-0004aE-Px for guix-patches@gnu.org; Fri, 03 Jan 2025 19:35:03 -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 1tTs87-00023z-Cy for guix-patches@gnu.org; Fri, 03 Jan 2025 19:35:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:From:To:Subject; bh=gvF7AXU3L8zwPH2TY509wcgytKHAKrk5MDJ9PT5NAo8=; b=q/c4zbOwDMAM15xBHN9SBlRNZbTbU2YZ/kA8cN1lOwtp6NP16t1jUle9Z4hEZv9G2U0xQnwJ7g7gtrniz//i8lhK4bH+6g8kIdcCLAH1ksjC5mkHtyRlgye37iLUVFTIgpHDyJfqKhZEYJwun6Mi4U/VRKB78xF9ocvTOrlgxMaZG+OwVZ/zKtUezmtwFBgJ7YUd6HCqQ6Guob+aV0MZXqayPIUf+wHLgXAHzPPCOLO/YxL1kiH3FY+BiTfRc7VVmFxOzOv6ivZuk0WqjysM7uzMvFJ7SyPE+lbq9SKAksfbiY+k6ChDFJaoNfuKv4MaYX1e85oQPpYGEY2k01u0Ig==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tTs86-0005YG-9k; Fri, 03 Jan 2025 19:35:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#75331] [PATCH rust-team] gnu: authenticator: Deprecate in favor of gnome-authenticator. Resent-From: Giacomo Leidi Original-Sender: "Debbugs-submit" Resent-CC: liliana.prikler@gmail.com, maxim.cournoyer@gmail.com, vivien@planete-kraus.eu, guix-patches@gnu.org Resent-Date: Sat, 04 Jan 2025 00:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 75331 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 75331@debbugs.gnu.org Cc: Giacomo Leidi , Liliana Marie Prikler , Maxim Cournoyer , Vivien Kraus X-Debbugs-Original-To: guix-patches@gnu.org X-Debbugs-Original-Xcc: Liliana Marie Prikler , Maxim Cournoyer , Vivien Kraus Received: via spool by submit@debbugs.gnu.org id=B.173595087421295 (code B ref -1); Sat, 04 Jan 2025 00:35:02 +0000 Received: (at submit) by debbugs.gnu.org; 4 Jan 2025 00:34:34 +0000 Received: from localhost ([127.0.0.1]:52664 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tTs7d-0005XN-2R for submit@debbugs.gnu.org; Fri, 03 Jan 2025 19:34:34 -0500 Received: from lists.gnu.org ([2001:470:142::17]:56330) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tTs7Z-0005X5-Ix for submit@debbugs.gnu.org; Fri, 03 Jan 2025 19:34:32 -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 1tTs7T-0004Yh-Hy for guix-patches@gnu.org; Fri, 03 Jan 2025 19:34:23 -0500 Received: from confino.investici.org ([93.190.126.19]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tTs7O-0001p2-Rq for guix-patches@gnu.org; Fri, 03 Jan 2025 19:34:23 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=autistici.org; s=stigmate; t=1735950848; bh=gvF7AXU3L8zwPH2TY509wcgytKHAKrk5MDJ9PT5NAo8=; h=From:To:Cc:Subject:Date:From; b=o3h14rVpbpxp9Skw35LpIct7smjpAN7H6MsoVB1CLUDZLfeCCeSeOyWPCOLsZXR+C LfHeR/omiLNbu2/+rdtebbgCAXve72Dw1fDBG1APv7ViZjv0dgRy0liHced/PASS/V kK5yhrODQDpQP9tAywQodANtha4UqLC0ugckMFoU= Received: from mx1.investici.org (unknown [127.0.0.1]) by confino.investici.org (Postfix) with ESMTP id 4YQ1f82Ltkz112y; Sat, 4 Jan 2025 00:34:08 +0000 (UTC) Received: from [93.190.126.19] (mx1.investici.org [93.190.126.19]) (Authenticated sender: goodoldpaul@autistici.org) by localhost (Postfix) with ESMTPSA id 4YQ1f81K3qz112t; Sat, 4 Jan 2025 00:34:08 +0000 (UTC) Date: Sat, 4 Jan 2025 01:33:33 +0100 Message-ID: <93ae237973b0ea60e36a4c32e520c5249f4a3fe2.1735950813.git.goodoldpaul@autistici.org> X-Mailer: git-send-email 2.47.1 MIME-Version: 1.0 Received-SPF: pass client-ip=93.190.126.19; envelope-from=goodoldpaul@autistici.org; helo=confino.investici.org X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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: Giacomo Leidi X-ACL-Warn: , Giacomo Leidi via Guix-patches X-Patchwork-Original-From: Giacomo Leidi via Guix-patches via From: Giacomo Leidi 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 This commit is a follow up to 64bcc8ba0f1ea8addaf0a1c65b3fca6cb1bf5422, it deprecates the old Python authenticator package in favor of the new gnome-authenticator Rust implementation. * gnu/services/gnome.scm (authenticator): Deprecate in favor of gnome-authenticator. Change-Id: I02081f4cd1dfdb8bd2327a9931299e97f8a11aee --- gnu/packages/gnome.scm | 326 ++++++++++++++++------------------------- 1 file changed, 127 insertions(+), 199 deletions(-) base-commit: 5f92f009a19c1a5a8b7df5a7bcb1e1f283a953f8 diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index a5891cb82d..30038379f5 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -36,7 +36,7 @@ ;;; Copyright © 2019 Danny Milosavljevic ;;; Copyright © 2019, 2020, 2022 Marius Bakke ;;; Copyright © 2019 Florian Pelz -;;; Copyright © 2019 Giacomo Leidi +;;; Copyright © 2019, 2024, 2025 Giacomo Leidi ;;; Copyright © 2019 Jelle Licht ;;; Copyright © 2019 Jonathan Frederickson ;;; Copyright © 2019-2024 Maxim Cournoyer @@ -79,7 +79,6 @@ ;;; Copyright © 2023 Zhu Zihao ;;; Copyright © 2024 Dariqq ;;; Copyright © 2024 James Smith -;;; Copyright © 2024 Giacomo Leidi ;;; ;;; This file is part of GNU Guix. ;;; @@ -10493,81 +10492,152 @@ (define-public byzanz (home-page "https://git.gnome.org/browse/byzanz") (license license:gpl2+)))) -(define-public authenticator +(define-public gnome-authenticator (package - (name "authenticator") - (version "3.32.2") + (name "gnome-authenticator") + (version "4.4.0") (source (origin (method git-fetch) (uri (git-reference - (url "https://gitlab.gnome.org/World/Authenticator") + (url "https://gitlab.gnome.org/World/Authenticator.git/") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1c4r9rnrz5gazrfg0z2rcwax4nscs7z391bcjcl74k6ln3blwzpr")))) - (build-system meson-build-system) + (base32 "0zavax35n048spx097ymiq31s8b879qwbg8xmcxcx73r6m823mic")))) + (build-system cargo-build-system) (arguments (list - #:glib-or-gtk? #t + #:install-source? #f + #:vendor-dir "vendor" + #:cargo-inputs + (list rust-aes-gcm-0.10 + rust-anyhow-1 + rust-async-std-1 + rust-aperture-0.3 + rust-ashpd-0.6 + rust-data-encoding-2 + rust-diesel-2 + rust-diesel-migrations-2 + rust-futures-channel-0.3 + rust-futures-executor-0.3 + rust-futures-util-0.3 + rust-gettext-rs-0.7 + rust-gtk4-0.7 + rust-hex-0.4 + rust-image-0.24 + rust-libadwaita-0.5 + rust-oo7-0.2 + rust-percent-encoding-2 + rust-prost-0.12 + rust-qrencode-0.14 + rust-quick-xml-0.30 + rust-rand-0.8 + rust-reqwest-0.11 + rust-ring-0.17 + rust-rust-argon2-2 + rust-scrypt-0.11 + rust-search-provider-0.6 + rust-serde-1 + rust-serde-json-1 + rust-svg-metadata-0.4 + rust-tokio-1 + rust-tracing-0.1 + rust-tracing-subscriber-0.3 + rust-url-2 + rust-uuid-1 + rust-zbar-rust-0.0.23 ; any 0.0.* + rust-zeroize-1) + #:imported-modules `(,@%meson-build-system-modules + ,@%glib-or-gtk-build-system-modules + ,@%cargo-build-system-modules) + #:modules `((guix build cargo-build-system) + ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) + ((guix build meson-build-system) #:prefix meson:) + (guix build utils)) #:phases #~(modify-phases %standard-phases - (add-after 'unpack 'patch-meson.build + (add-after 'unpack 'generate-gdk-pixbuf-loaders-cache-file + (assoc-ref glib-or-gtk:%standard-phases + 'generate-gdk-pixbuf-loaders-cache-file)) + (add-after 'unpack 'prepare-for-build (lambda _ - (substitute* "data/meson.build" - (("^ 'desktop',.*") "") - (("^ 'appdata',.*") "")))) - (add-after 'glib-or-gtk-wrap 'python-and-gi-wrap - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((prog (search-input-file outputs "bin/authenticator")) - (pylib (string-append #$output "/lib/python" - #$(version-major+minor - (package-version - (this-package-input "python"))) - "/site-packages"))) - (wrap-program prog - `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH") ,pylib)) - `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))))))))) - (native-inputs - (list desktop-file-utils - gettext-minimal - `(,glib "bin") - gobject-introspection - `(,gtk+ "bin") - pkg-config)) - (inputs - (list bash-minimal - gsettings-desktop-schemas - gtk+ - libhandy-0.0 - libsecret - python - python-beautifulsoup4 - python-pillow - python-pyfavicon - python-pygobject - python-pyotp - python-pyzbar - yoyo-migrations - zbar)) - (home-page "https://gitlab.gnome.org/World/Authenticator/") - (synopsis "Two-factor authentication application built for GNOME") - (description - "Authenticator is a two-factor authentication (2FA) application built for -the GNOME desktop environment. + (substitute* "meson.build" + (("gtk_update_icon_cache: true") + "gtk_update_icon_cache: false") + (("update_desktop_database: true") + "update_desktop_database: false")) + ;; Help the tests find the Cargo.toml in the sources. + (substitute* "src/meson.build" + (("'test'") "'test', cargo_options")) + (delete-file "Cargo.lock"))) + ;; Add meson-configure phase here and not before 'configure because + ;; the meson 'configure phase changes to a different directory and + ;; we need it created before unpacking the crates. + (add-before 'unpack-rust-crates 'meson-configure + (lambda args + (apply (assoc-ref meson:%standard-phases 'configure) + #:build-type "debugoptimized" + #:configure-flags '() + args))) + (replace 'build + (assoc-ref meson:%standard-phases 'build)) + (replace 'check + (lambda args + (apply (assoc-ref meson:%standard-phases 'check) + #:test-options '() + args))) + (replace 'install + (assoc-ref meson:%standard-phases 'install)) + (add-after 'install 'glib-or-gtk-compile-schemas + (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas)) + (add-after 'install 'glib-or-gtk-wrap + (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)) + (add-after 'glib-or-gtk-wrap 'wrap-extra-paths + (lambda _ + (let ((gst-plugins-path (getenv "GST_PLUGIN_SYSTEM_PATH"))) + (wrap-program (string-append #$output "/bin/authenticator") + `("GST_PLUGIN_SYSTEM_PATH" ":" suffix (,gst-plugins-path)))))) + (add-after 'strip 'shrink-runpath + (assoc-ref meson:%standard-phases 'shrink-runpath))))) + (native-inputs (list gettext-minimal + `(,glib "bin") ; for glib-compile-schemas + meson + ninja + pkg-config)) + (inputs (list bash-minimal + glib + gstreamer + gst-plugins-base + gst-plugins-bad + gtk + libadwaita + openssl + pipewire ; Needed but not listed + sqlite + zbar)) + (home-page "https://apps.gnome.org/Authenticator") + (synopsis "Generate two-factor codes") + (description "Simple application for generating Two-Factor Authentication +Codes: -Features: +It features: @itemize -@item QR code scanner +@item Time-based/Counter-based/Steam methods support +@item SHA-1/SHA-256/SHA-512 algorithms support +@item QR code scanner using a camera or from a screenshot +@item Lock the application with a password @item Beautiful UI -@item Huge database of more than 560 supported services -@item Keep your PIN tokens secure by locking the application with a password -@item Automatically fetch an image for services using their favicon -@item The possibility to add new services +@item GNOME Shell search provider +@item Backup/Restore from/into known applications like FreeOTP+, +Aegis (encrypted / plain-text), andOTP, Google Authenticator @end itemize") (license license:gpl3+))) +(define-public authenticator + (deprecated-package "authenticator" gnome-authenticator)) + (define-public gsound (package (name "gsound") @@ -13567,148 +13637,6 @@ (define-public gnome-builder profiler via Sysprof, debugging support, and more.") (license license:gpl3+))) -(define-public gnome-authenticator - (package - (name "gnome-authenticator") - (version "4.4.0") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://gitlab.gnome.org/World/Authenticator.git/") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 "0zavax35n048spx097ymiq31s8b879qwbg8xmcxcx73r6m823mic")))) - (build-system cargo-build-system) - (arguments - (list - #:install-source? #f - #:vendor-dir "vendor" - #:cargo-inputs - (list rust-aes-gcm-0.10 - rust-anyhow-1 - rust-async-std-1 - rust-aperture-0.3 - rust-ashpd-0.6 - rust-data-encoding-2 - rust-diesel-2 - rust-diesel-migrations-2 - rust-futures-channel-0.3 - rust-futures-executor-0.3 - rust-futures-util-0.3 - rust-gettext-rs-0.7 - rust-gtk4-0.7 - rust-hex-0.4 - rust-image-0.24 - rust-libadwaita-0.5 - rust-oo7-0.2 - rust-percent-encoding-2 - rust-prost-0.12 - rust-qrencode-0.14 - rust-quick-xml-0.30 - rust-rand-0.8 - rust-reqwest-0.11 - rust-ring-0.17 - rust-rust-argon2-2 - rust-scrypt-0.11 - rust-search-provider-0.6 - rust-serde-1 - rust-serde-json-1 - rust-svg-metadata-0.4 - rust-tokio-1 - rust-tracing-0.1 - rust-tracing-subscriber-0.3 - rust-url-2 - rust-uuid-1 - rust-zbar-rust-0.0.23 ; any 0.0.* - rust-zeroize-1) - #:imported-modules `(,@%meson-build-system-modules - ,@%glib-or-gtk-build-system-modules - ,@%cargo-build-system-modules) - #:modules `((guix build cargo-build-system) - ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) - ((guix build meson-build-system) #:prefix meson:) - (guix build utils)) - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'generate-gdk-pixbuf-loaders-cache-file - (assoc-ref glib-or-gtk:%standard-phases - 'generate-gdk-pixbuf-loaders-cache-file)) - (add-after 'unpack 'prepare-for-build - (lambda _ - (substitute* "meson.build" - (("gtk_update_icon_cache: true") - "gtk_update_icon_cache: false") - (("update_desktop_database: true") - "update_desktop_database: false")) - ;; Help the tests find the Cargo.toml in the sources. - (substitute* "src/meson.build" - (("'test'") "'test', cargo_options")) - (delete-file "Cargo.lock"))) - ;; Add meson-configure phase here and not before 'configure because - ;; the meson 'configure phase changes to a different directory and - ;; we need it created before unpacking the crates. - (add-before 'unpack-rust-crates 'meson-configure - (lambda args - (apply (assoc-ref meson:%standard-phases 'configure) - #:build-type "debugoptimized" - #:configure-flags '() - args))) - (replace 'build - (assoc-ref meson:%standard-phases 'build)) - (replace 'check - (lambda args - (apply (assoc-ref meson:%standard-phases 'check) - #:test-options '() - args))) - (replace 'install - (assoc-ref meson:%standard-phases 'install)) - (add-after 'install 'glib-or-gtk-compile-schemas - (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas)) - (add-after 'install 'glib-or-gtk-wrap - (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)) - (add-after 'glib-or-gtk-wrap 'wrap-extra-paths - (lambda _ - (let ((gst-plugins-path (getenv "GST_PLUGIN_SYSTEM_PATH"))) - (wrap-program (string-append #$output "/bin/authenticator") - `("GST_PLUGIN_SYSTEM_PATH" ":" suffix (,gst-plugins-path)))))) - (add-after 'strip 'shrink-runpath - (assoc-ref meson:%standard-phases 'shrink-runpath))))) - (native-inputs (list gettext-minimal - `(,glib "bin") ; for glib-compile-schemas - meson - ninja - pkg-config)) - (inputs (list glib - gstreamer - gst-plugins-base - gst-plugins-bad - gtk - libadwaita - openssl - pipewire ; Needed but not listed - sqlite - zbar)) - (home-page "https://apps.gnome.org/Authenticator") - (synopsis "Generate two-factor codes") - (description "Simple application for generating Two-Factor Authentication -Codes: - -It features: - -@itemize -@item Time-based/Counter-based/Steam methods support -@item SHA-1/SHA-256/SHA-512 algorithms support -@item QR code scanner using a camera or from a screenshot -@item Lock the application with a password -@item Beautiful UI -@item GNOME Shell search provider -@item Backup/Restore from/into known applications like FreeOTP+, -Aegis (encrypted / plain-text), andOTP, Google Authenticator -@end itemize") - (license license:gpl3+))) - (define-public komikku (package (name "komikku")