From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id iATJE3ud/2Vw0AAAqHPOHw:P1 (envelope-from ) for ; Sun, 24 Mar 2024 04:26:51 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id iATJE3ud/2Vw0AAAqHPOHw (envelope-from ) for ; Sun, 24 Mar 2024 04:26:51 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=quic.us header.s=default header.b=m3qQ73Gi; dmarc=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=1711250811; a=rsa-sha256; cv=none; b=nzFdgJXJUVQc/opWAEX79y//TCGZgSJoDClbKptjTnzLKA0L0gLNVtrinK7gtWTaQqeGCT HlonaszzdqiXjUqTHqcxuYYtIc1DF5dmC5FVsNqULNpgKWWjF/1dtpWSz10z8efrbL4cM4 2UQ82DVThw5Dg6E4tdgw5oTb7bDeQFQ0jTbmXMG/0IAU5GeF8E2urk+vP1mzTbKMpY2azx agP7cEX1iymAuZpcZY4inywHc3KejCHlDQceGe5W7gue/TWGESYswMZGURhfYz3bK/nhbN 8uJPoTGDDsWETuYE23nnCgb4EyEW125G3I5IgC4xfYsCDf4xTM7EcYFgs2hnFg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=quic.us header.s=default header.b=m3qQ73Gi; dmarc=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=1711250811; 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:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=Op8GNATlSTiQEfyN3iAEG2XUVDnw903H1IzP1cp8/0U=; b=gvsuWs3SfxDo9cyj+dfvuFyVBvv9y7nVWiQy2klZdwWanHQPSdWP4mPX/2aqFiZDKR1V1W NgTo4gWqmTL7rwDSj/zsoq+w3EZSJDFjY4cqG6i3PohN0MoMHiOc1JiIBG1M6jbCdkI7R7 YxXcHCNr/Hai56gQCCHXP8Z9fXZ0eFC1V34xVrfalsrrowaaui/mSYFeRx91Dl0VAWCzOO n9nsleyYc2LT0X9tafS0ntv84VuQfXqnxIq9jnK4vH1pFmCOZSwR1m4taWcr5LGiORcbMu eykvTr4gKTEyMANDP8XTRdrgPhLTqzEOj5/nN4mukLn7c+K8EROkn+WC4dv0XA== 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 BFEBD13925 for ; Sun, 24 Mar 2024 04:26:50 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1roEV9-0003qm-1u; Sat, 23 Mar 2024 23:26:27 -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 1roEV7-0003qW-Ea for guix-patches@gnu.org; Sat, 23 Mar 2024 23:26:25 -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 1roEV7-00050q-6e for guix-patches@gnu.org; Sat, 23 Mar 2024 23:26:25 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1roEVi-0003qT-4o; Sat, 23 Mar 2024 23:27:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#69971] [PATCH] gnu: webkitgtk: Add locale and dri access to gtk sandbox in order to silence gtk locale warnings and enable hardware accelerated video, respectively. Resent-From: Abhishek Cherath Original-Sender: "Debbugs-submit" Resent-CC: liliana.prikler@gmail.com, maxim.cournoyer@gmail.com, rg@raghavgururajan.name, vivien@planete-kraus.eu, guix-patches@gnu.org Resent-Date: Sun, 24 Mar 2024 03:27:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 69971 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 69971@debbugs.gnu.org Cc: Abhishek Cherath , Liliana Marie Prikler , Maxim Cournoyer , Raghav Gururajan , Vivien Kraus X-Debbugs-Original-To: guix-patches@gnu.org X-Debbugs-Original-Xcc: Liliana Marie Prikler , Maxim Cournoyer , Raghav Gururajan , Vivien Kraus Received: via spool by submit@debbugs.gnu.org id=B.171125081014743 (code B ref -1); Sun, 24 Mar 2024 03:27:01 +0000 Received: (at submit) by debbugs.gnu.org; 24 Mar 2024 03:26:50 +0000 Received: from localhost ([127.0.0.1]:47797 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1roEVU-0003pZ-Gi for submit@debbugs.gnu.org; Sat, 23 Mar 2024 23:26:49 -0400 Received: from lists.gnu.org ([209.51.188.17]:49056) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1roEVO-0003p0-FP for submit@debbugs.gnu.org; Sat, 23 Mar 2024 23:26:43 -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 1roE8c-0001b9-4M for guix-patches@gnu.org; Sat, 23 Mar 2024 23:03:10 -0400 Received: from mta-09-4.privateemail.com ([198.54.127.118]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1roE8O-0000d1-Tr for guix-patches@gnu.org; Sat, 23 Mar 2024 23:03:09 -0400 Received: from mta-09.privateemail.com (localhost [127.0.0.1]) by mta-09.privateemail.com (Postfix) with ESMTP id DF37318000AD; Sat, 23 Mar 2024 23:02:48 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=quic.us; s=default; t=1711249368; bh=iie0M50JsBe1TZwwN83d9RwqXwF2yyboBPoPEScEVs0=; h=From:To:Cc:Subject:Date:From; b=m3qQ73GieDSjKqyk+EqPuXBdGTaiiz44lKVVmD6l1/OyJGm/dsdrTrSqn0c5v73i7 7MTIn/fRuMaUErOokx1xQWkdpGKC3hl163yDgIPyEdUPcHuAMW9GKqffVwgP9zNOWB J1NEd6GHxOlr5RfyAVxiV4qFovFg/XBP86hrG974al4/OHeBXIdVmr3qdGZtiUs/KV EWd8u0CzkEEvMTcL5xGJgL+KEUXeg2alhlYJEUoKTuO67kfeZzB4PUPag+al/WWhOl eh95s9u7HP4d5Z3BWq3Bc4+Fe5qCvXNxgX/E8Jd6O3+R8A4cbkCCNdYz00+O05edRf YAenpVD2+EMTQ== Received: from localhost (207-237-25-55.s5642.c3-0.wsd-cbr1.qens-wsd.ny.cable.rcncustomer.com [207.237.25.55]) by mta-09.privateemail.com (Postfix) with ESMTPA; Sat, 23 Mar 2024 23:02:46 -0400 (EDT) Received: from localhost (localhost [local]) by localhost (OpenSMTPD) with ESMTPA id 4d90692a; Sun, 24 Mar 2024 03:02:44 +0000 (UTC) From: Abhishek Cherath Date: Sat, 23 Mar 2024 22:02:13 -0400 Message-ID: <02189bbb2583491df0be62c56568caa4bf245997.1711245733.git.abhi@quic.us> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP Received-SPF: pass client-ip=198.54.127.118; envelope-from=abhi@quic.us; helo=MTA-09-4.privateemail.com X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, DKIM_INVALID=0.1, DKIM_SIGNED=0.1, SPF_HELO_PASS=-0.001, T_SPF_TEMPERROR=0.01, UNPARSEABLE_RELAY=0.001 autolearn=no 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: , 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: -0.03 X-Migadu-Queue-Id: BFEBD13925 X-Migadu-Scanner: mx12.migadu.com X-Migadu-Spam-Score: -0.03 X-TUID: 4Z/UwLQoWiJF * gnu/packages/patches/webkitgtk-adjust-bubblewrap-paths.patch: Add @dridir@ and @localedir@ to bubblewrap gtk sandbox * gnu/packages/webkit.scm (webkitgtk)[arguments]: In the 'configure-bubblewrap-store-directory' phase, also supply locale and dri directory paths to webkitgtk-adjust-bubblewrap-paths.patch template. Change-Id: Id1ffe23e56a8da4ff3c81a2cde7d9622f024bdea --- .../patches/webkitgtk-adjust-bubblewrap-paths.patch | 8 +++++++- gnu/packages/webkit.scm | 11 ++++++++++- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/gnu/packages/patches/webkitgtk-adjust-bubblewrap-paths.patch b/gnu/packages/patches/webkitgtk-adjust-bubblewrap-paths.patch index 18ddb645ad..793f6a414b 100644 --- a/gnu/packages/patches/webkitgtk-adjust-bubblewrap-paths.patch +++ b/gnu/packages/patches/webkitgtk-adjust-bubblewrap-paths.patch @@ -5,7 +5,7 @@ diff --git a/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp b/Sour index f0a5e4b05dff..88b11f806968 100644 --- a/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp +++ b/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp -@@ -854,27 +854,12 @@ GRefPtr bubblewrapSpawn(GSubprocessLauncher* launcher, const Proces +@@ -854,27 +854,18 @@ GRefPtr bubblewrapSpawn(GSubprocessLauncher* launcher, const Proces "--ro-bind", "/sys/dev", "/sys/dev", "--ro-bind", "/sys/devices", "/sys/devices", @@ -33,6 +33,12 @@ index f0a5e4b05dff..88b11f806968 100644 + + // Bind mount the store inside the WebKitGTK sandbox. + "--ro-bind", "@storedir@", "@storedir@", ++ ++ // This is needed for locales in /run/current-system/locales ++ "--ro-bind-try", "@localedir@", "@localedir@", ++ ++ // This is needed for video hardware acceleration (va-api) via /lib/dri ++ "--ro-bind-try", "@dridir@", "@dridir@", }; if (launchOptions.processType == ProcessLauncher::ProcessType::DBusProxy) { diff --git a/gnu/packages/webkit.scm b/gnu/packages/webkit.scm index bf24a65e83..4777a9b96e 100644 --- a/gnu/packages/webkit.scm +++ b/gnu/packages/webkit.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2019 Marius Bakke ;;; Copyright © 2021, 2022, 2023 Maxim Cournoyer ;;; Copyright © 2022, 2023 Efraim Flashner +;;; Copyright © 2024 Abhishek Cherath ;;; ;;; This file is part of GNU Guix. ;;; @@ -190,7 +191,15 @@ (define-public webkitgtk (let ((store-directory (%store-directory))) (substitute* "Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp" - (("@storedir@") store-directory))))) + (("@storedir@") store-directory) + ;; this adds access to drivers for va-api + ;; for hardware accelerated video + (("@localedir@") "/run/current-system/profile/lib/dri") + ;; this silences gtk locale errors + ;; Unfortunately, simply bind mounting /run/current-system + ;; does not work since it leads to weird issues + ;; with symlinks that confuse bubblewrap. + (("@dridir@") "/run/current-system/locale"))))) (add-after 'unpack 'do-not-disable-new-dtags ;; Ensure the linker uses new dynamic tags as this is what Guix ;; uses and validates in the validate-runpath phase. base-commit: d67e4f0f9b10c7ddac8fb0ca68cbf1d6ad0a6e5d prerequisite-patch-id: 2feff8a49a2bca7cb55d49c21c04736f9828df0e prerequisite-patch-id: c3460fa91fad7c4f67859f672420ca72e616d89b -- 2.41.0