From 719080e04c91a24b928ca0158f950a2e04a20c8e Mon Sep 17 00:00:00 2001 From: imnyang Date: Mon, 14 Sep 2026 11:07:35 +0900 Subject: [PATCH] wow --- pkgs/figma-linux/default.nix | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/pkgs/figma-linux/default.nix b/pkgs/figma-linux/default.nix index d0b1a17..08e7b54 100644 --- a/pkgs/figma-linux/default.nix +++ b/pkgs/figma-linux/default.nix @@ -13,10 +13,22 @@ let hash = "sha256-SLn4y+NVCcBDZrGqIpmpIEQavY7xngt5JMI8yG1g6/0="; }; - appimageContents = appimageTools.extract { inherit pname version src; }; + appimageContents = appimageTools.extract { + inherit pname version src; + + # The upstream AppImage registers an AppImage-specific desktop entry at + # runtime. That bypasses this package's FHS wrapper when a figma:// URL is + # opened, so Electron cannot find libraries such as libnspr4.so. + postExtract = '' + substituteInPlace $out/AppRun \ + --replace-fail 'integrate_desktop 2>/dev/null || true' \ + 'true # Desktop integration is provided by the Nix package' + ''; + }; in -appimageTools.wrapType2 { - inherit pname version src; +appimageTools.wrapAppImage { + inherit pname version; + src = appimageContents; extraInstallCommands = '' install -Dm444 ${appimageContents}/usr/share/applications/io.github.nickvdp.figma-desktop-linux.desktop \