From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id sMZqFELsO2YjHQEAe85BDQ:P1 (envelope-from ) for ; Wed, 08 May 2024 23:18:58 +0200 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id sMZqFELsO2YjHQEAe85BDQ (envelope-from ) for ; Wed, 08 May 2024 23:18:58 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=IfIbkeMZ; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1715203138; h=from:from:sender:sender: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:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=ZHb8dG5sub12lynvjtOr/UfCHDI3TVsLk9m5zWh51N4=; b=IheUONS1g/xQMZ+qUVWSedpfviL7Qz7FeSXhM7sSsiM8S0bnoNFmOeX+JmivjbO28L1lRL l7sDfEmMZNCdyLjYFzSv6cz2vNEKmeJr3ubFwtSI+WKDTozJxUHvHpXn7HTj2W6H4Z2Tai CYDEybHdxFKhrmkU20iX0OBPNplUpcUoa70WAmofxJhQUXs+7CdgwBC1RSRV9qw4pWnQbA 3t34jTcugh57H0ZcFgwvE46xYhcYhkoHVdA223zidYNmoOzVZiI5FFtCOVUKsMDpUV6NqS 8yOLrm5p+LWMnrzn+u2WKARiMnm2cu+jmn16WjdFo6v8aDfyfrp0BJsc/Sze9A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=IfIbkeMZ; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none) ARC-Seal: i=1; s=key1; d=yhetil.org; t=1715203138; a=rsa-sha256; cv=none; b=RgDhNoBWZ/lWjUXQZJTFbdf7CZFHUQ3wRgcpl44278oj4GrkWlm+legT7+Bp1T52dSY39u YneAj4sZ2VG5yDcE2Au5VZ1yiTXBdXL8IIIV1aZqaP915JzbKXhBXxkXb3D5QobwhR/EDT HBKIDA/ZtfZ2Yu+fkp0QKVFr4eHG8nSgCd/XV/UjoP2BtM0R28dDtSCnCZI63ME9D9XyqT io8ZC4UbKwVrGIemZGIlQFWH36+6Xi05ckIVZLNAHkQktUFer2/5aKyM2++M0u2VH1vj4j v9sMz9ZhgZcMJFw1a7/+mfQ7OgoEPwNHI00ez21jImDNHBfL/jLKaJdKH6a81g== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 20E513FE9F for ; Wed, 8 May 2024 23:18:58 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s4ogQ-0007Nd-2x; Wed, 08 May 2024 17:18:38 -0400 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 1s4ogO-0007N7-Mz for guix-patches@gnu.org; Wed, 08 May 2024 17:18:37 -0400 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 1s4ogO-00082U-7q for guix-patches@gnu.org; Wed, 08 May 2024 17:18:36 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s4ogn-0003LZ-K7 for guix-patches@gnu.org; Wed, 08 May 2024 17:19:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70282] [PATCH v4] gnu: gnome-shell: Wrap screencast service. Resent-From: Dariqq Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 08 May 2024 21:19:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70282 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 70282@debbugs.gnu.org, Vivien Kraus , Liliana Marie Prikler Received: via spool by 70282-submit@debbugs.gnu.org id=B70282.171520312712859 (code B ref 70282); Wed, 08 May 2024 21:19:01 +0000 Received: (at 70282) by debbugs.gnu.org; 8 May 2024 21:18:47 +0000 Received: from localhost ([127.0.0.1]:50948 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s4ogY-0003LL-Dl for submit@debbugs.gnu.org; Wed, 08 May 2024 17:18:47 -0400 Received: from mout01.posteo.de ([185.67.36.65]:44197) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s4ogS-0003LF-Ln for 70282@debbugs.gnu.org; Wed, 08 May 2024 17:18:45 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id EAB95240029 for <70282@debbugs.gnu.org>; Wed, 8 May 2024 23:18:07 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1715203088; bh=l0vklNk/yg2XeskG9i8Y4nAQWDu00qQj5a9g4RjPLtQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:From:Content-Type: Content-Transfer-Encoding:From; b=IfIbkeMZTqnKgkH7AD9uc9iwnAWiDVze5ElX8BRKf2U/Ra/wY7CTYGvEU0ym7NbpW KiNjO3IfHiWj6AELNutoW4qKv1cox1cxUNdG7zn8wpT7zCXtyrbJAZ6oVewY9fgccr riSSoxP8J9cI+vJoJsUwDUgXeBSD1XCjPlvt0FGqoDMC/hkC8jbBmX45HqyIRixHou bEMB+pL2APDqceL0PkEMbdKB92jOp8EtuiXgHYL4zIicv4xN0b7tNyMItffipXfA0K ae0CzLHYTxfO/oHjTHESNfm+w/8LzkLLcWHPnZJ65BbcwHNXLcUpO1BLq+T39qsY7N tzJnr6ZfGQ/8Q== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4VZSfl144Jz6tvq; Wed, 8 May 2024 23:18:07 +0200 (CEST) Message-ID: <9e607cae-97fc-4b6d-85bc-dccf58ee1f08@posteo.net> Date: Wed, 8 May 2024 21:18:04 +0000 MIME-Version: 1.0 References: <213d475bd6ad3781baf3876e89bd84c18029dc5e.1715193210.git.dariqq@posteo.net> <87cypw6q0x.fsf@gmail.com> Content-Language: en-US From: Dariqq In-Reply-To: <87cypw6q0x.fsf@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit 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: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: 3.91 X-Spam-Score: 3.91 X-Migadu-Queue-Id: 20E513FE9F X-Migadu-Scanner: mx13.migadu.com X-TUID: Fq0VSrWvzK01 Hi Maxim, On 08.05.24 21:51, Maxim Cournoyer wrote: > Hi Dariqq, > > Dariqq writes: > >> Adjust screencast such that GI_TYPELIB_PATH and GST_PLUGIN_SYSTEM_PATH are set >> before starting. >> >> Add all required gstreamer plugins to inputs. >> >> To be able to use it a running pipewire service is needed. >> >> * gnu/packages/gnome.scm (gnome-shell): >> [inputs]: Add gst-plugins-good and pipewire. >> [#:phases]<'wrap-programs>: Wrap org.gnome.Shell.Screencast. > > Thanks for your efforts improving our GNOME desktop experience! > The slight annoyance with this is that if pipewire is not running the option to enable the screen recorder is there but it will stop immediately. But at least searching online for this problem has some mentions of pipewire and i added a comment in the pacakge aswell. I think it is definitly a better solution than not knowing that the option is even there as the button does not get displayed at all if the service fails to start. >> Change-Id: I2c31bf1bd92e281b86c57b06988c6a3793a58d40 >> --- >> Here is v4 which appends the gstreamer plugins to >> GST_PLUGIN_SYSTEM_PATH, handling the case when getenv returns null. I >> think the difference between appendending or prepending in this case >> is not too important as the user GST_PLUGIN_PATH should take >> precedent. The more important thing is that the plugins are in any >> plugin path at all. >> >> gnu/packages/gnome.scm | 16 ++++++++++++++++ >> 1 file changed, 16 insertions(+) >> >> diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm >> index 92e35e3c5a..4bbff2a89b 100644 >> --- a/gnu/packages/gnome.scm >> +++ b/gnu/packages/gnome.scm >> @@ -9408,6 +9408,7 @@ (define-public gnome-shell >> (add-after 'install 'wrap-programs >> (lambda* (#:key inputs #:allow-other-keys) >> (let ((gi-typelib-path (getenv "GI_TYPELIB_PATH")) >> + (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH")) >> (python-path >> (string-join >> (filter (lambda (item) >> @@ -9427,6 +9428,19 @@ (define-public gnome-shell >> "path => imports.gi.GIRepository.Repository." >> "prepend_search_path(path));\n" >> all))) >> + ;; Screencast requires a pipewire service running >> + ;; (i.e. as provided by home-pipewire-service-type) >> + (substitute* (string-append #$output "/share/gnome-shell/" >> + "org.gnome.Shell.Screencast") >> + (("imports\\.package\\.start" all) >> + (string-append "'" gi-typelib-path "'.split(':').forEach(" >> + "path => imports.gi.GIRepository.Repository." >> + "prepend_search_path(path));\n" >> + "imports.gi.GLib.setenv('GST_PLUGIN_SYSTEM_PATH'," >> + "[imports.gi.GLib.getenv('GST_PLUGIN_SYSTEM_PATH')," >> + "'" gst-plugin-path "'].filter(v => v).join(':')," >> + "true);\n" >> + all))) > > Perhaps a simple patch would convey the change better and be easier to > maintain in the future / be readily available for other distributions to > use. The simple patch that would do this is basically the patch from nixos in v1 of this which adds a shebang line for gjs to the service invocation files (rather than the dbus service invoking $gjs $service). The problem then is that wrap-program changes the filename to * .real which makes gjs unhappy. The people from nix circumvent this by using some js at the beginning to reset the entrypoint to the correct value. One nice way around avoiding the problem would be using wrap-script instead though that does not support gjs as interpreter (yet?) and adding that forces a rebuild of all packages due to (guix build utils) changing. Maybe another comment, similiar to the one Liliana suggested earlier in this thread, could be added at the beginning to inform about changing to wrap script + patch instead once that is a viable option? > >> (for-each >> (lambda (prog) >> (wrap-program (string-append #$output "/bin/" prog) >> @@ -9492,6 +9506,7 @@ (define-public gnome-shell >> gnome-settings-daemon >> graphene >> gst-plugins-base >> + gst-plugins-good >> ibus >> libcanberra >> libcroco >> @@ -9502,6 +9517,7 @@ (define-public gnome-shell >> mesa-headers >> mutter >> network-manager-applet >> + pipewire >> polkit >> pulseaudio >> python-pygobject > > Otherwise, LGTM! > Have a nice day