Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[23.11] anydesk: 6.3.0 -> 6.3.2 #307183

Merged
merged 4 commits into from
Apr 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
61 changes: 29 additions & 32 deletions pkgs/applications/networking/remote/anydesk/default.nix
Original file line number Diff line number Diff line change
@@ -1,42 +1,20 @@
{ lib, stdenv, fetchurl, makeWrapper, makeDesktopItem, genericUpdater, writeShellScript
, atk, cairo, gdk-pixbuf, glib, gnome2, gtk2, libGLU, libGL, pango, xorg, minizip
, lsb-release, freetype, fontconfig, polkit, polkit_gnome, pciutils
, lsb-release, freetype, fontconfig, polkit, polkit_gnome, pciutils, copyDesktopItems
, pulseaudio }:

let
description = "Desktop sharing application, providing remote support and online meetings";

desktopItem = makeDesktopItem {
name = "AnyDesk";
exec = "@out@/bin/anydesk %u";
icon = "anydesk";
desktopName = "AnyDesk";
genericName = description;
categories = [ "Network" ];
startupNotify = false;
};

in stdenv.mkDerivation rec {
pname = "anydesk";
version = "6.3.0";
version = "6.3.2";

src = fetchurl {
urls = [
"https://download.anydesk.com/linux/${pname}-${version}-amd64.tar.gz"
"https://download.anydesk.com/linux/generic-linux/${pname}-${version}-amd64.tar.gz"
"https://download.anydesk.com/linux/anydesk-${version}-amd64.tar.gz"
"https://download.anydesk.com/linux/generic-linux/anydesk-${version}-amd64.tar.gz"
];
hash = "sha256-seMzfTXOGa+TljgpmIsgFOis+79r0bWt+4vH3Nb+5FI=";
};

passthru = {
updateScript = genericUpdater {
versionLister = writeShellScript "anydesk-versionLister" ''
curl -s https://anydesk.com/en/downloads/linux \
| grep "https://[a-z0-9._/-]*-amd64.tar.gz" -o \
| uniq \
| sed 's,.*/anydesk-\(.*\)-amd64.tar.gz,\1,g'
'';
};
hash = "sha256-nSY4qHRsEvQk4M3JDHalAk3C6Y21WlfDQ2Gpp6/jjMs=";
};

buildInputs = [
Expand All @@ -48,7 +26,19 @@ in stdenv.mkDerivation rec {
libXrandr libXtst libXt libICE libSM libXrender
]);

nativeBuildInputs = [ makeWrapper ];
nativeBuildInputs = [ copyDesktopItems makeWrapper ];

desktopItems = [
(makeDesktopItem {
name = "AnyDesk";
exec = "anydesk %u";
icon = "anydesk";
desktopName = "AnyDesk";
genericName = description;
categories = [ "Network" ];
startupNotify = false;
})
];

installPhase = ''
runHook preInstall
Expand All @@ -57,7 +47,6 @@ in stdenv.mkDerivation rec {
install -m755 anydesk $out/bin/anydesk
cp copyright README $out/share/doc/anydesk
cp -r icons/hicolor/* $out/share/icons/hicolor/
cp ${desktopItem}/share/applications/*.desktop $out/share/applications

runHook postInstall
'';
Expand All @@ -75,11 +64,19 @@ in stdenv.mkDerivation rec {

wrapProgram $out/bin/anydesk \
--prefix PATH : ${lib.makeBinPath [ lsb-release pciutils ]}

substituteInPlace $out/share/applications/*.desktop \
--subst-var out
'';

passthru = {
updateScript = genericUpdater {
versionLister = writeShellScript "anydesk-versionLister" ''
curl -s https://anydesk.com/en/downloads/linux \
| grep "https://[a-z0-9._/-]*-amd64.tar.gz" -o \
| uniq \
| sed 's,.*/anydesk-\(.*\)-amd64.tar.gz,\1,g'
'';
};
};

meta = with lib; {
inherit description;
homepage = "https://www.anydesk.com";
Expand Down
Loading