From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id 4G7XCzyVI2aSXAEAe85BDQ:P1 (envelope-from ) for ; Sat, 20 Apr 2024 12:13:16 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id 4G7XCzyVI2aSXAEAe85BDQ (envelope-from ) for ; Sat, 20 Apr 2024 12:13:16 +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=hUs2u1Yf; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1713607996; a=rsa-sha256; cv=none; b=m6ZMamOjKhiIBuaBrZn7/bj0PLmbnU893WWNXrAmIrgId5+0XM94Rw5lVbbVKt6aXkRBve LzakF737dh67JKa2Ru2sI8onxe4iSauavNEr4S3v5FHt53K3KmKvCHj0lcArz0auxkPmFp T8BC9iYUM0IdQ3Qfp7gocsnk5VV7X3EpO0ZwSvVYOlI4ICo47JrKtEoFNS3wr5Bsa38IPb sK7Cvwo2BtellYROzzijoSPk+yVXQeJG/rNavBZgeg0VjHMCZNnOH/uVlqhA1wvQWBk0zL o6JjVOKOk4nCJOQdEFdzH5YgAUYBEtDbDcY/SfgJXHQJxCUggYGp0wUSCoQATQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=hUs2u1Yf; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); 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" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1713607996; 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=XCIDgy+qLJ9TN1Zp4Ii/RNn+6JF88Ef5XOTwX6BokVs=; b=pJo9Hw622LiGAbLweCM5BU2Cwl6u7kF20Vb+KsUc4sd/NDqoE4aLsG0cVP32PM/Wzh6zJ4 JP0QIoucpn0VEdAqDy2JUy9fMPV4cDt0S5nYz9//U/yy+63eunHefoIlX9aTJC7XK7GTcp F3GY7w7fBWnro2V8agW8iG5GjvA+vRBsMsrEorR5WLDkv0uhFezFuC2r94apIBdHBnmQw6 eLKjUPbI8PBk1zV7HnTcaDBI9GAwridCnnXw+YMoG1MpYn1WPSJoDF9ttb02ZIvwqOCPpU K2Fq/G8R63Gb0l3zltOJifoydm09V0TwuVVJnR8achiaOHdAOo85B0g2ud/ZmA== 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 910996D6B7 for ; Sat, 20 Apr 2024 12:13:15 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ry7iO-00037t-4H; Sat, 20 Apr 2024 06:13:00 -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 1ry7iE-00037F-G7 for guix-patches@gnu.org; Sat, 20 Apr 2024 06:12:50 -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 1ry7iE-0001YZ-5W for guix-patches@gnu.org; Sat, 20 Apr 2024 06:12:50 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ry7iS-0007hS-AR for guix-patches@gnu.org; Sat, 20 Apr 2024 06:13:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70282] [PATCH v2] gnu: gnome-shell: Wrap screencast service. Resent-From: Dariqq Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 20 Apr 2024 10:13:04 +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: Liliana Marie Prikler , 70282@debbugs.gnu.org Cc: Vivien Kraus , Maxim Cournoyer Received: via spool by 70282-submit@debbugs.gnu.org id=B70282.171360793629294 (code B ref 70282); Sat, 20 Apr 2024 10:13:04 +0000 Received: (at 70282) by debbugs.gnu.org; 20 Apr 2024 10:12:16 +0000 Received: from localhost ([127.0.0.1]:35534 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ry7hf-0007cQ-Mn for submit@debbugs.gnu.org; Sat, 20 Apr 2024 06:12:16 -0400 Received: from mout01.posteo.de ([185.67.36.65]:34011) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ry7hb-0007am-Bj for 70282@debbugs.gnu.org; Sat, 20 Apr 2024 06:12:13 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 9DA0924002A for <70282@debbugs.gnu.org>; Sat, 20 Apr 2024 12:11:50 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1713607910; bh=80NwzpQPnozcN7zxOTb1rEhdT+gvH8EKxvuChaXqT5M=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:From:Content-Type: Content-Transfer-Encoding:From; b=hUs2u1Yf5snFjGx4xAE3H+swmnzIZ2p2z6mSbeqpkAf+Wfnw+NFp9vPmaRf1itCoy NRzvAGhTLoBZ0NywHPfbYra4Yd7B1Sx756E0ZktNr0UX9uTsZpxcQL4HE1OYIf6Br5 tdy/CeXMSOiP7bABeXzZJ+UrYOX9RcfUQEWjx52bRrzxWqmX7JBaA77jtXpwiaOBoJ T1MsCO4RhFqG3s0woZHuhOa8lgU0U6ucvVtthjgBljuvLCSfCCyFAkkVg3MC+ZJZlC 8Ip8pjYc+FaWLh+BZg6Xgvf8uNqXA3010q42qVDjMf44+Ct2ZlOjElaAfY0JdpPdZB kE+3oyBefPJ2A== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4VM6kF4sd7z6tm4; Sat, 20 Apr 2024 12:11:49 +0200 (CEST) Message-ID: Date: Sat, 20 Apr 2024 10:11:43 +0000 MIME-Version: 1.0 References: <0497984af8f383af8e8b981d78dc9baf23869e30.camel@gmail.com> Content-Language: en-US From: Dariqq In-Reply-To: <0497984af8f383af8e8b981d78dc9baf23869e30.camel@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit 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-Spam-Score: -2.48 X-Migadu-Queue-Id: 910996D6B7 X-Migadu-Spam-Score: -2.48 X-Migadu-Scanner: mx10.migadu.com X-TUID: H+f1Go6/iXMD On 19.04.24 20:51, Liliana Marie Prikler wrote: > Am Freitag, dem 12.04.2024 um 17:26 +0000 schrieb Dariqq: >> The screencast service can now find typelibs and gstreamer plugins. >> >> * gnu/packages/linux.scm (gnome-shell) >> [inputs]: Add gst-plugins-good and pipewire. >> [#:phases]<'wrap-programs>: Create a wrapper for screencast service >> and use it. >> >> Change-Id: I2c31bf1bd92e281b86c57b06988c6a3793a58d40 >> --- >> >> Hi, >> >> Here is v2 of the patch. The wrapper is now created manually as I was >> unable to find a way to manipulate the gstreamer plugin load path >> from within javascript. Importantly this leaves the original >> javascript file untouched and therefore circumvents the argv[0] >> problem in v1. >> All the required gstreamer plugins (pipewire and gst-plugins-good) >> are now inputs and are in the wrapper via GST_PLUGIN_SYSTEM_PATH. > I'm not sure this fix is sounds. It looks like it misses manual > invocation from the command line, does it not? (Well, it's gnome- > shell, so if you have to invoke it from the command line, things are > broken, but still…) If only the typelib path is set the dbus service now longer greets you with an error but still fails to start without the gstreamer plugins. That's why in v1 I was propagating pipewire through gnome-essential-extras. I am not sure what you mean by manual invocation. The screencast service should get started via dbus. Nothing manual should be required (other than enabling the pipewire home service). What keeps you from wrapping the environment > variable in Javascript? I was unable to find a way to manipulate the GST_PLUGIN_PATH or specify the gst search path from within javascript. There is Gst.Registry().scan_path but this creates a new registry and I don't think is what we want here. (but I don't know anything about gstreamer and javascript so I could be wrong here). I guess the most simple patch for the typelibs would be something like diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index fa6c566c75..28c4e540a6 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -9404,13 +9404,15 @@ (define-public gnome-shell (wrap-program (string-append #$output "/bin/" prog) `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))) '("gnome-shell" "gnome-extensions-app")) - (substitute* (string-append #$output "/share/gnome-shell/" - "org.gnome.Shell.Extensions") - (("imports\\.package\\.start" all) - (string-append "'" gi-typelib-path "'.split(':').forEach(" - "path => imports.gi.GIRepository.Repository." - "prepend_search_path(path));\n" - all))) + (for-each + (lambda (prog) + (substitute* (string-append #$output "/share/gnome-shell/" prog) + (("imports\\.package\\.start" all) + (string-append "'" gi-typelib-path "'.split(':').forEach(" + "path => imports.gi.GIRepository.Repository." + "prepend_search_path(path));\n" + all)))) + '("org.gnome.Shell.Extensions" "org.gnome.Shell.Screencast")) (for-each (lambda (prog) (wrap-program (string-append #$output "/bin/" prog) and dealing with the gstreamer plugins in another way. >> I've also left a comment for the required home-pipewire-service. >> In gnome-shell 45+ the invocation has changed to 'gjs -m service'. >> Should this also be a comment somewhere? > Gnome-shell 45+ is currently irrelevant, but we might have to adapt > things once we get there on gnome-team. We do need a better gjs- > patching strategy. > It would be nice if something like wrap-script would work. But the problem is that the dbus services specify somehting like "Exec= gjs service" rather than executing a gjs-script directly. (which is the main purpose of the patch from nixos). And also gjs not being a valid interpreter for wrap-script (Changing that will rebuild everything) > Cheers > Have an nice day.