1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-06-11 02:15:21 +09:00

tigervnc: 1.14.0 -> 1.15.0, also use tag / hash / finalAttrs (#409035)

This commit is contained in:
Felix Bargfeldt 2025-05-23 16:55:13 +02:00 committed by GitHub
commit 1f0932ed8d
Signed by: github
GPG key ID: B5690EEEBB952194

View file

@ -2,7 +2,6 @@
lib,
stdenv,
fetchFromGitHub,
fetchpatch,
xorg,
xkeyboard_config,
zlib,
@ -25,25 +24,17 @@
ffmpeg,
}:
stdenv.mkDerivation rec {
version = "1.14.0";
stdenv.mkDerivation (finalAttrs: {
version = "1.15.0";
pname = "tigervnc";
src = fetchFromGitHub {
owner = "TigerVNC";
repo = "tigervnc";
rev = "v${version}";
sha256 = "sha256-TgVV/4MRsQHYKpDf9L5eHMLVpdwvNy1KPDIe7xMlQ9o=";
tag = "v${finalAttrs.version}";
hash = "sha256-ZuuvRJe/lAqULWObPxGHVJrDPCTK4IVSqX0K1rWOctw=";
};
patches = [
(fetchpatch {
name = "vncauth-security-type.patch";
url = "https://github.com/TigerVNC/tigervnc/commit/4f6a3521874da5a67fd746389cfa9b6199eb3582.diff";
hash = "sha256-lSkR8e+jsBwkQUJZmA0tb8nM5iSbYtO8uVXtgk5wdF8=";
})
];
postPatch =
lib.optionalString stdenv.hostPlatform.isLinux ''
sed -i -e '/^\$cmd \.= " -pn";/a$cmd .= " -xkbdir ${xkeyboard_config}/etc/X11/xkb";' unix/vncserver/vncserver.in
@ -125,10 +116,10 @@ stdenv.mkDerivation rec {
''
+ lib.optionalString stdenv.hostPlatform.isDarwin ''
mkdir -p $out/Applications
mv 'TigerVNC Viewer ${version}.app' $out/Applications/
mv 'TigerVNC Viewer ${finalAttrs.version}.app' $out/Applications/
rm $out/bin/vncviewer
echo "#!/usr/bin/env bash
open $out/Applications/TigerVNC\ Viewer\ ${version}.app --args \$@" >> $out/bin/vncviewer
open $out/Applications/TigerVNC\ Viewer\ ${finalAttrs.version}.app --args \$@" >> $out/bin/vncviewer
chmod +x $out/bin/vncviewer
'';
@ -194,7 +185,8 @@ stdenv.mkDerivation rec {
description = "Fork of tightVNC, made in cooperation with VirtualGL";
maintainers = [ ];
platforms = lib.platforms.unix;
broken = stdenv.hostPlatform.isDarwin;
# Prevent a store collision.
priority = 4;
};
}
})