2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv
|
2020-04-10 11:09:13 +01:00
|
|
|
, fetchurl
|
|
|
|
, appimageTools
|
|
|
|
, makeWrapper
|
2021-08-02 08:29:33 +01:00
|
|
|
, electron
|
2021-03-12 10:32:19 +00:00
|
|
|
, xorg
|
2022-01-03 09:43:55 +00:00
|
|
|
, pipewire
|
2020-04-10 11:09:13 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "jitsi-meet-electron";
|
2022-02-08 13:35:16 +00:00
|
|
|
version = "2022.1.1";
|
2020-04-10 11:09:13 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/jitsi/jitsi-meet-electron/releases/download/v${version}/jitsi-meet-x86_64.AppImage";
|
2022-02-08 13:35:16 +00:00
|
|
|
sha256 = "0x3fdqgjnsd570b7nszfx3h8l5c8x2kg32ig85n2a2g481c7xi6l";
|
2020-06-03 17:44:25 +01:00
|
|
|
name = "${pname}-${version}.AppImage";
|
2020-04-10 11:09:13 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
appimageContents = appimageTools.extractType2 {
|
|
|
|
name = "${pname}-${version}";
|
|
|
|
inherit src;
|
|
|
|
};
|
|
|
|
|
|
|
|
dontUnpack = true;
|
|
|
|
dontConfigure = true;
|
|
|
|
dontBuild = true;
|
|
|
|
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
mkdir -p $out/bin $out/share/${pname} $out/share/applications
|
|
|
|
|
|
|
|
cp -a ${appimageContents}/{locales,resources} $out/share/${pname}
|
|
|
|
cp -a ${appimageContents}/jitsi-meet.desktop $out/share/applications/${pname}.desktop
|
|
|
|
cp -a ${appimageContents}/usr/share/icons $out/share
|
|
|
|
|
|
|
|
substituteInPlace $out/share/applications/${pname}.desktop \
|
|
|
|
--replace 'Exec=AppRun' 'Exec=${pname}'
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
|
|
|
postFixup = ''
|
2020-06-03 17:44:25 +01:00
|
|
|
makeWrapper ${electron}/bin/electron $out/bin/${pname} \
|
2020-04-10 11:09:13 +01:00
|
|
|
--add-flags $out/share/${pname}/resources/app.asar \
|
2022-01-03 09:43:55 +00:00
|
|
|
--prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ stdenv.cc.cc xorg.libXtst pipewire ]}"
|
2020-04-10 11:09:13 +01:00
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-04-10 11:09:13 +01:00
|
|
|
description = "Jitsi Meet desktop application powered by Electron";
|
|
|
|
homepage = "https://github.com/jitsi/jitsi-meet-electron";
|
|
|
|
license = licenses.asl20;
|
2020-08-04 20:46:14 +01:00
|
|
|
maintainers = teams.jitsi.members;
|
2020-04-10 11:09:13 +01:00
|
|
|
platforms = [ "x86_64-linux" ];
|
|
|
|
};
|
|
|
|
}
|