uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
92
pkgs/applications/networking/remote/anydesk/default.nix
Normal file
92
pkgs/applications/networking/remote/anydesk/default.nix
Normal file
|
|
@ -0,0 +1,92 @@
|
|||
{ 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
|
||||
, pulseaudio }:
|
||||
|
||||
let
|
||||
description = "Desktop sharing application, providing remote support and online meetings";
|
||||
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "AnyDesk";
|
||||
exec = "@out@/bin/anydesk";
|
||||
icon = "anydesk";
|
||||
desktopName = "AnyDesk";
|
||||
genericName = description;
|
||||
categories = [ "Network" ];
|
||||
startupNotify = false;
|
||||
};
|
||||
|
||||
in stdenv.mkDerivation rec {
|
||||
pname = "anydesk";
|
||||
version = "6.1.1";
|
||||
|
||||
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"
|
||||
];
|
||||
sha256 = "1ai58fsivb8al1279bayl800qavy0kfj40rjhf87g902ap3p4bhh";
|
||||
};
|
||||
|
||||
passthru = {
|
||||
updateScript = genericUpdater {
|
||||
inherit pname version;
|
||||
versionLister = writeShellScript "anydesk-versionLister" ''
|
||||
echo "# Versions for $1:" >> "$2"
|
||||
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'
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
atk cairo gdk-pixbuf glib gtk2 stdenv.cc.cc pango
|
||||
gnome2.gtkglext libGLU libGL minizip freetype
|
||||
fontconfig polkit polkit_gnome pulseaudio
|
||||
] ++ (with xorg; [
|
||||
libxcb libxkbfile libX11 libXdamage libXext libXfixes libXi libXmu
|
||||
libXrandr libXtst libXt libICE libSM libXrender
|
||||
]);
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/bin $out/share/{applications,doc/anydesk,icons/hicolor}
|
||||
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
|
||||
'';
|
||||
|
||||
postFixup = ''
|
||||
patchelf \
|
||||
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
|
||||
--set-rpath "${lib.makeLibraryPath buildInputs}" \
|
||||
$out/bin/anydesk
|
||||
|
||||
# pangox is not actually necessary (it was only added as a part of gtkglext)
|
||||
patchelf \
|
||||
--remove-needed libpangox-1.0.so.0 \
|
||||
$out/bin/anydesk
|
||||
|
||||
wrapProgram $out/bin/anydesk \
|
||||
--prefix PATH : ${lib.makeBinPath [ lsb-release pciutils ]}
|
||||
|
||||
substituteInPlace $out/share/applications/*.desktop \
|
||||
--subst-var out
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
inherit description;
|
||||
homepage = "https://www.anydesk.com";
|
||||
license = licenses.unfree;
|
||||
platforms = [ "x86_64-linux" ];
|
||||
maintainers = with maintainers; [ shyim ];
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,72 @@
|
|||
{ stdenv, lib
|
||||
, makeWrapper, dpkg, fetchurl, autoPatchelfHook
|
||||
, curl, libkrb5, lttng-ust, libpulseaudio, gtk3, openssl_1_1, icu, webkitgtk, librsvg, gdk-pixbuf, libsoup, glib-networking
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "aws-workspaces";
|
||||
version = "4.0.1.1302";
|
||||
|
||||
src = fetchurl {
|
||||
# ref https://d3nt0h4h6pmmc4.cloudfront.net/ubuntu/dists/bionic/main/binary-amd64/Packages
|
||||
urls = [
|
||||
"https://d3nt0h4h6pmmc4.cloudfront.net/ubuntu/dists/bionic/main/binary-amd64/workspacesclient_${version}_amd64.deb"
|
||||
"https://web.archive.org/web/20210921220718/https://d3nt0h4h6pmmc4.cloudfront.net/ubuntu/dists/bionic/main/binary-amd64/workspacesclient_${version}_amd64.deb"
|
||||
];
|
||||
sha256 = "208e67a544be5be7ff25218d68b4eb2ea9e65abfed444c99a0f7a6738d69ab9a";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoPatchelfHook
|
||||
makeWrapper
|
||||
];
|
||||
|
||||
# Crashes at startup when stripping:
|
||||
# "Failed to create CoreCLR, HRESULT: 0x80004005"
|
||||
dontStrip = true;
|
||||
|
||||
buildInputs = [
|
||||
stdenv.cc.cc.lib
|
||||
libkrb5
|
||||
curl
|
||||
lttng-ust
|
||||
libpulseaudio
|
||||
gtk3
|
||||
openssl_1_1.out
|
||||
icu
|
||||
webkitgtk
|
||||
librsvg
|
||||
gdk-pixbuf
|
||||
libsoup
|
||||
glib-networking
|
||||
];
|
||||
|
||||
unpackPhase = ''
|
||||
${dpkg}/bin/dpkg -x $src $out
|
||||
'';
|
||||
|
||||
preFixup = ''
|
||||
patchelf --replace-needed liblttng-ust.so.0 liblttng-ust.so $out/lib/libcoreclrtraceptprovider.so
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin $out/lib
|
||||
mv $out/opt/workspacesclient/* $out/lib
|
||||
rm -rf $out/opt
|
||||
|
||||
wrapProgram $out/lib/workspacesclient \
|
||||
--prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath buildInputs}" \
|
||||
--set GDK_PIXBUF_MODULE_FILE "${librsvg.out}/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache" \
|
||||
--set GIO_EXTRA_MODULES "${glib-networking.out}/lib/gio/modules"
|
||||
|
||||
mv $out/lib/workspacesclient $out/bin
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Client for Amazon WorkSpaces, a managed, secure Desktop-as-a-Service (DaaS) solution";
|
||||
homepage = "https://clients.amazonworkspaces.com";
|
||||
license = licenses.unfree;
|
||||
platforms = [ "x86_64-linux" ]; # TODO Mac support
|
||||
maintainers = [ maintainers.mausch ];
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
{ lib, callPackage }:
|
||||
|
||||
# For detailed information about the Citrix source-tarball, please refer to the OEM
|
||||
# reference guide: https://developer-docs.citrix.com/projects/workspace-app-for-linux-oem-guide/en/latest/
|
||||
|
||||
let
|
||||
inherit (callPackage ./sources.nix { }) supportedVersions unsupportedVersions;
|
||||
mkCitrix = callPackage ./generic.nix { };
|
||||
|
||||
toAttrName = x: "citrix_workspace_${builtins.replaceStrings [ "." ] [ "_" ] x}";
|
||||
|
||||
unsupported = lib.listToAttrs (
|
||||
map (x: lib.nameValuePair (toAttrName x) (throw ''
|
||||
Citrix Workspace at version ${x} is not supported anymore!
|
||||
|
||||
Actively supported releases are listed here:
|
||||
https://www.citrix.com/support/product-lifecycle/milestones/receiver.html
|
||||
'')) unsupportedVersions
|
||||
);
|
||||
|
||||
supported = lib.mapAttrs' (
|
||||
attr: versionInfo: lib.nameValuePair (toAttrName attr) (callPackage ./generic.nix versionInfo)
|
||||
) supportedVersions;
|
||||
in
|
||||
supported // unsupported
|
||||
213
pkgs/applications/networking/remote/citrix-workspace/generic.nix
Normal file
213
pkgs/applications/networking/remote/citrix-workspace/generic.nix
Normal file
|
|
@ -0,0 +1,213 @@
|
|||
{ lib, stdenv, requireFile, makeWrapper, autoPatchelfHook, wrapGAppsHook, which, more
|
||||
, file, atk, alsa-lib, cairo, fontconfig, gdk-pixbuf, glib, webkitgtk, gtk2-x11, gtk3
|
||||
, heimdal, krb5, libsoup, libvorbis, speex, openssl, zlib, xorg, pango, gtk2
|
||||
, gnome2, mesa, nss, nspr, gtk_engines, freetype, dconf, libpng12, libxml2
|
||||
, libjpeg, libredirect, tzdata, cacert, systemd, libcxxabi, libcxx, e2fsprogs, symlinkJoin
|
||||
, libpulseaudio, pcsclite, glib-networking, llvmPackages_12
|
||||
|
||||
, homepage, version, prefix, hash
|
||||
|
||||
, extraCerts ? []
|
||||
}:
|
||||
|
||||
let
|
||||
openssl' = symlinkJoin {
|
||||
name = "openssl-backwards-compat";
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
paths = [ (lib.getLib openssl) ];
|
||||
postBuild = ''
|
||||
ln -sf $out/lib/libcrypto.so $out/lib/libcrypto.so.1.0.0
|
||||
ln -sf $out/lib/libssl.so $out/lib/libssl.so.1.0.0
|
||||
'';
|
||||
};
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "citrix-workspace";
|
||||
inherit version;
|
||||
|
||||
src = requireFile rec {
|
||||
name = "${prefix}-${version}.tar.gz";
|
||||
sha256 = hash;
|
||||
|
||||
message = ''
|
||||
In order to use Citrix Workspace, you need to comply with the Citrix EULA and download
|
||||
the ${if stdenv.is64bit then "64-bit" else "32-bit"} binaries, .tar.gz from:
|
||||
|
||||
${homepage}
|
||||
|
||||
(if you do not find version ${version} there, try at
|
||||
https://www.citrix.com/downloads/workspace-app/
|
||||
|
||||
Once you have downloaded the file, please use the following command and re-run the
|
||||
installation:
|
||||
|
||||
nix-prefetch-url file://\$PWD/${name}
|
||||
'';
|
||||
};
|
||||
|
||||
dontBuild = true;
|
||||
dontConfigure = true;
|
||||
sourceRoot = ".";
|
||||
preferLocalBuild = true;
|
||||
passthru.icaroot = "${placeholder "out"}/opt/citrix-icaclient";
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoPatchelfHook
|
||||
file
|
||||
makeWrapper
|
||||
more
|
||||
which
|
||||
wrapGAppsHook
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
alsa-lib
|
||||
atk
|
||||
cairo
|
||||
dconf
|
||||
fontconfig
|
||||
freetype
|
||||
gdk-pixbuf
|
||||
gnome2.gtkglext
|
||||
glib-networking
|
||||
webkitgtk
|
||||
gtk2
|
||||
gtk2-x11
|
||||
gtk3
|
||||
gtk_engines
|
||||
heimdal
|
||||
krb5
|
||||
libcxx
|
||||
libcxxabi
|
||||
libjpeg
|
||||
libpng12
|
||||
libsoup
|
||||
libvorbis
|
||||
libxml2
|
||||
mesa
|
||||
nspr
|
||||
nss
|
||||
openssl'
|
||||
pango
|
||||
speex
|
||||
(lib.getLib systemd)
|
||||
stdenv.cc.cc
|
||||
xorg.libXaw
|
||||
xorg.libXmu
|
||||
xorg.libXScrnSaver
|
||||
xorg.libXtst
|
||||
zlib
|
||||
] ++ lib.optional (lib.versionOlder version "20.04") e2fsprogs
|
||||
++ lib.optional (lib.versionAtLeast version "20.10") libpulseaudio
|
||||
++ lib.optional (lib.versionAtLeast version "21.12") llvmPackages_12.libunwind;
|
||||
|
||||
runtimeDependencies = [
|
||||
glib
|
||||
glib-networking
|
||||
pcsclite
|
||||
|
||||
xorg.libX11
|
||||
xorg.libXScrnSaver
|
||||
xorg.libXext
|
||||
xorg.libXfixes
|
||||
xorg.libXinerama
|
||||
xorg.libXmu
|
||||
xorg.libXrender
|
||||
xorg.libXtst
|
||||
xorg.libxcb
|
||||
];
|
||||
|
||||
installPhase = let
|
||||
icaFlag = program:
|
||||
if (builtins.match "selfservice(.*)" program) != null then "--icaroot"
|
||||
else if (lib.versionAtLeast version "21.12" && builtins.match "wfica(.*)" program != null) then null
|
||||
else "-icaroot";
|
||||
wrap = program: ''
|
||||
wrapProgram $out/opt/citrix-icaclient/${program} \
|
||||
${lib.optionalString (icaFlag program != null) ''--add-flags "${icaFlag program} $ICAInstDir"''} \
|
||||
--set ICAROOT "$ICAInstDir" \
|
||||
--prefix LD_LIBRARY_PATH : "$ICAInstDir:$ICAInstDir/lib" \
|
||||
--set LD_PRELOAD "${libredirect}/lib/libredirect.so" \
|
||||
--set NIX_REDIRECTS "/usr/share/zoneinfo=${tzdata}/share/zoneinfo:/etc/zoneinfo=${tzdata}/share/zoneinfo:/etc/timezone=$ICAInstDir/timezone"
|
||||
'';
|
||||
wrapLink = program: ''
|
||||
${wrap program}
|
||||
ln -sf $out/opt/citrix-icaclient/${program} $out/bin/${baseNameOf program}
|
||||
'';
|
||||
|
||||
copyCert = path: ''
|
||||
cp -v ${path} $out/opt/citrix-icaclient/keystore/cacerts/${baseNameOf path}
|
||||
'';
|
||||
|
||||
mkWrappers = lib.concatMapStringsSep "\n";
|
||||
|
||||
toWrap = [ "wfica" "selfservice" "util/configmgr" "util/conncenter" "util/ctx_rehash" ]
|
||||
++ lib.optional (lib.versionOlder version "20.06") "selfservice_old";
|
||||
in ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/{bin,share/applications}
|
||||
export ICAInstDir="$out/opt/citrix-icaclient"
|
||||
export HOME=$(mktemp -d)
|
||||
|
||||
# Run upstream installer in the store-path.
|
||||
sed -i -e 's,^ANSWER="",ANSWER="$INSTALLER_YES",g' -e 's,/bin/true,true,g' ./${prefix}/hinst
|
||||
${stdenv.shell} ${prefix}/hinst CDROM "$(pwd)"
|
||||
|
||||
if [ -f "$ICAInstDir/util/setlog" ]; then
|
||||
chmod +x "$ICAInstDir/util/setlog"
|
||||
ln -sf "$ICAInstDir/util/setlog" "$out/bin/citrix-setlog"
|
||||
fi
|
||||
${mkWrappers wrapLink toWrap}
|
||||
${mkWrappers wrap [ "PrimaryAuthManager" "ServiceRecord" "AuthManagerDaemon" "util/ctxwebhelper" ]}
|
||||
|
||||
ln -sf $ICAInstDir/util/storebrowse $out/bin/storebrowse
|
||||
|
||||
# As explained in https://wiki.archlinux.org/index.php/Citrix#Security_Certificates
|
||||
echo "Expanding certificates..."
|
||||
pushd "$ICAInstDir/keystore/cacerts"
|
||||
awk 'BEGIN {c=0;} /BEGIN CERT/{c++} { print > "cert." c ".pem"}' \
|
||||
< ${cacert}/etc/ssl/certs/ca-bundle.crt
|
||||
popd
|
||||
|
||||
${mkWrappers copyCert extraCerts}
|
||||
|
||||
# See https://developer-docs.citrix.com/projects/workspace-app-for-linux-oem-guide/en/latest/reference-information/#library-files
|
||||
# Those files are fallbacks to support older libwekit.so and libjpeg.so
|
||||
rm $out/opt/citrix-icaclient/lib/ctxjpeg_fb_8.so || true
|
||||
rm $out/opt/citrix-icaclient/lib/UIDialogLibWebKit.so || true
|
||||
|
||||
# We support only Gstreamer 1.0
|
||||
rm $ICAInstDir/util/{gst_aud_{play,read},gst_*0.10,libgstflatstm0.10.so}
|
||||
ln -sf $ICAInstDir/util/gst_play1.0 $ICAInstDir/util/gst_play
|
||||
ln -sf $ICAInstDir/util/gst_read1.0 $ICAInstDir/util/gst_read
|
||||
|
||||
echo "We arbitrarily set the timezone to UTC. No known consequences at this point."
|
||||
echo UTC > "$ICAInstDir/timezone"
|
||||
|
||||
echo "Copy .desktop files."
|
||||
cp $out/opt/citrix-icaclient/desktop/* $out/share/applications/
|
||||
|
||||
# We introduce a dependency on the source file so that it need not be redownloaded everytime
|
||||
echo $src >> "$out/share/workspace_dependencies.pin"
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
# Make sure that `autoPatchelfHook` is executed before
|
||||
# running `ctx_rehash`.
|
||||
dontAutoPatchelf = true;
|
||||
postFixup = ''
|
||||
autoPatchelf -- "$out"
|
||||
$out/opt/citrix-icaclient/util/ctx_rehash
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
license = licenses.unfree;
|
||||
description = "Citrix Workspace";
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ pmenke michaeladler ];
|
||||
inherit homepage;
|
||||
};
|
||||
}
|
||||
102
pkgs/applications/networking/remote/citrix-workspace/sources.nix
Normal file
102
pkgs/applications/networking/remote/citrix-workspace/sources.nix
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
{ stdenv, lib }:
|
||||
|
||||
let
|
||||
mkVersionInfo = _: { major, minor, patch, x64hash, x86hash, x64suffix, x86suffix, homepage }:
|
||||
{ inherit homepage;
|
||||
version = "${major}.${minor}.${patch}.${if stdenv.is64bit then x64suffix else x86suffix}";
|
||||
prefix = "linuxx${if stdenv.is64bit then "64" else "86"}";
|
||||
hash = if stdenv.is64bit then x64hash else x86hash;
|
||||
};
|
||||
|
||||
# Attribute-set with all actively supported versions of the Citrix workspace app
|
||||
# for Linux.
|
||||
#
|
||||
# The latest versions can be found at https://www.citrix.com/downloads/workspace-app/linux/
|
||||
supportedVersions = lib.mapAttrs mkVersionInfo {
|
||||
"21.01.0" = {
|
||||
major = "21";
|
||||
minor = "1";
|
||||
patch = "0";
|
||||
x64hash = "01m9g1bs6iiqbd778gjps2zznvqijlyn3mfw38aa0w1rr6ms326a";
|
||||
x86hash = "1mmx5r3wi9i6bwh4kdlpw446m8kijkaar8shi0q1n21fv0ygg3r5";
|
||||
x64suffix = "14";
|
||||
x86suffix = "14";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/legacy-workspace-app-for-linux/workspace-app-for-linux-2101.html";
|
||||
};
|
||||
|
||||
"21.03.0" = {
|
||||
major = "21";
|
||||
minor = "3";
|
||||
patch = "0";
|
||||
x64hash = "004pgvxl81l99sqvrs5xzvjivjlc21rrlm2gky9hmbsm53nsl3zc";
|
||||
x86hash = "11nn9734a515dm1q880z9wmhvx8ikyh3riayyn42z22q4kd852n3";
|
||||
x64suffix = "38";
|
||||
x86suffix = "38";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/legacy-workspace-app-for-linux/workspace-app-for-linux-2103.html";
|
||||
};
|
||||
|
||||
"21.06.0" = {
|
||||
major = "21";
|
||||
minor = "6";
|
||||
patch = "0";
|
||||
x64hash = "f3f98c60b0aaac31eb44dc98f22ee7ae7df229c960d5d29785eb5e9554f85f68";
|
||||
x86hash = "c2d9652ad9488a9ff171e62df8455ebe6890bcfade1cc289893ee35322d9d812";
|
||||
x64suffix = "28";
|
||||
x86suffix = "28";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/legacy-workspace-app-for-linux/workspace-app-for-linux-2106.html";
|
||||
};
|
||||
|
||||
"21.08.0" = {
|
||||
major = "21";
|
||||
minor = "8";
|
||||
patch = "0";
|
||||
x64hash = "69ddae29cc8b4b68341c3d9503a54ee70ab58a5795fd83e79573f013eda5518c";
|
||||
x86hash = "b6d1bde5a8533f22374e1f5bbb3f5949e5b89773d0703e021fbe784b455aad3f";
|
||||
x64suffix = "40";
|
||||
x86suffix = "40";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/legacy-workspace-app-for-linux/workspace-app-for-linux-2108.html";
|
||||
};
|
||||
|
||||
"21.09.0" = {
|
||||
major = "21";
|
||||
minor = "9";
|
||||
patch = "0";
|
||||
x64hash = "d58d5cbbcb5ace95b75b1400061d475b8e72dbdf5f03abacea6d39686991f848";
|
||||
x86hash = "c646c52889e88aa0bb051070076763d5407f21fb6ad6dfcb0fe635ac01180c51";
|
||||
x64suffix = "25";
|
||||
x86suffix = "25";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/legacy-workspace-app-for-linux/workspace-app-for-linux-2109.html";
|
||||
};
|
||||
|
||||
"21.12.0" = {
|
||||
major = "21";
|
||||
minor = "12";
|
||||
patch = "0";
|
||||
x64hash = "de81deab648e1ebe0ddb12aa9591c8014d7fad4eba0db768f25eb156330bb34d";
|
||||
x86hash = "3746cdbe26727f7f6fb85fbe5f3e6df0322d79bb66e3a70158b22cb4f6b6b292";
|
||||
x64suffix = "18";
|
||||
x86suffix = "18";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/legacy-workspace-app-for-linux/workspace-app-for-linux-2112.html";
|
||||
};
|
||||
|
||||
"22.05.0" = {
|
||||
major = "22";
|
||||
minor = "5";
|
||||
patch = "0";
|
||||
x64hash = "49786fd3b5361b1f42b7bb0e36572a209e95acb1335737da5216345b6420f053";
|
||||
x86hash = "f2dc1fd64e5314b62ba87f384958c2bbd48b06b55bed10345cddb05fdc8cffa1";
|
||||
x64suffix = "16";
|
||||
x86suffix = "16";
|
||||
homepage = "https://www.citrix.com/downloads/workspace-app/linux/workspace-app-for-linux-latest.html";
|
||||
};
|
||||
};
|
||||
|
||||
# Retain attribute-names for abandoned versions of Citrix workspace to
|
||||
# provide a meaningful error-message if it's attempted to use such an old one.
|
||||
#
|
||||
# The lifespans of Citrix products can be found here:
|
||||
# https://www.citrix.com/support/product-lifecycle/milestones/receiver.html
|
||||
unsupportedVersions = [ ];
|
||||
in {
|
||||
inherit supportedVersions unsupportedVersions;
|
||||
}
|
||||
148
pkgs/applications/networking/remote/freerdp/default.nix
Normal file
148
pkgs/applications/networking/remote/freerdp/default.nix
Normal file
|
|
@ -0,0 +1,148 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, pkg-config
|
||||
, alsa-lib
|
||||
, ffmpeg
|
||||
, glib
|
||||
, openssl
|
||||
, pcre
|
||||
, zlib
|
||||
, libX11
|
||||
, libXcursor
|
||||
, libXdamage
|
||||
, libXext
|
||||
, libXi
|
||||
, libXinerama
|
||||
, libXrandr
|
||||
, libXrender
|
||||
, libXv
|
||||
, libXtst
|
||||
, libxkbcommon
|
||||
, libxkbfile
|
||||
, wayland
|
||||
, gstreamer
|
||||
, gst-plugins-base
|
||||
, gst-plugins-good
|
||||
, libunwind
|
||||
, orc
|
||||
, libxslt
|
||||
, cairo
|
||||
, libusb1
|
||||
, libpulseaudio
|
||||
, cups
|
||||
, pcsclite
|
||||
, systemd
|
||||
, libjpeg_turbo
|
||||
, buildServer ? true
|
||||
, nocaps ? false
|
||||
}:
|
||||
|
||||
let
|
||||
cmFlag = flag: if flag then "ON" else "OFF";
|
||||
disabledTests = [
|
||||
# this one is probably due to our sandbox
|
||||
{
|
||||
dir = "libfreerdp/crypto/test";
|
||||
file = "Test_x509_cert_info.c";
|
||||
}
|
||||
];
|
||||
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "freerdp";
|
||||
version = "2.7.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "FreeRDP";
|
||||
repo = "FreeRDP";
|
||||
rev = version;
|
||||
sha256 = "sha256-XBYRhbwknVa8eXxk31b7n9gMWBcTjCecDN+j2FGcpw0=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
export HOME=$TMP
|
||||
|
||||
# failing test(s)
|
||||
${lib.concatMapStringsSep "\n" (e: ''
|
||||
substituteInPlace ${e.dir}/CMakeLists.txt \
|
||||
--replace ${e.file} ""
|
||||
rm ${e.dir}/${e.file}
|
||||
'') disabledTests}
|
||||
|
||||
substituteInPlace "libfreerdp/freerdp.pc.in" \
|
||||
--replace "Requires:" "Requires: @WINPR_PKG_CONFIG_FILENAME@"
|
||||
'' + lib.optionalString (pcsclite != null) ''
|
||||
substituteInPlace "winpr/libwinpr/smartcard/smartcard_pcsc.c" \
|
||||
--replace "libpcsclite.so" "${lib.getLib pcsclite}/lib/libpcsclite.so"
|
||||
'' + lib.optionalString nocaps ''
|
||||
substituteInPlace "libfreerdp/locale/keyboard_xkbfile.c" \
|
||||
--replace "RDP_SCANCODE_CAPSLOCK" "RDP_SCANCODE_LCONTROL"
|
||||
'';
|
||||
|
||||
buildInputs = [
|
||||
alsa-lib
|
||||
cairo
|
||||
cups
|
||||
ffmpeg
|
||||
glib
|
||||
gst-plugins-base
|
||||
gst-plugins-good
|
||||
gstreamer
|
||||
libX11
|
||||
libXcursor
|
||||
libXdamage
|
||||
libXext
|
||||
libXi
|
||||
libXinerama
|
||||
libXrandr
|
||||
libXrender
|
||||
libXtst
|
||||
libXv
|
||||
libjpeg_turbo
|
||||
libpulseaudio
|
||||
libunwind
|
||||
libusb1
|
||||
libxkbcommon
|
||||
libxkbfile
|
||||
libxslt
|
||||
openssl
|
||||
orc
|
||||
pcre
|
||||
pcsclite
|
||||
wayland
|
||||
zlib
|
||||
] ++ lib.optional stdenv.isLinux systemd;
|
||||
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
|
||||
doCheck = true;
|
||||
|
||||
cmakeFlags = [ "-DCMAKE_INSTALL_LIBDIR=lib" ]
|
||||
++ lib.mapAttrsToList (k: v: "-D${k}=${if v then "ON" else "OFF"}") {
|
||||
BUILD_TESTING = doCheck;
|
||||
WITH_CUNIT = doCheck;
|
||||
WITH_CUPS = (cups != null);
|
||||
WITH_OSS = false;
|
||||
WITH_PCSC = (pcsclite != null);
|
||||
WITH_PULSE = (libpulseaudio != null);
|
||||
WITH_SERVER = buildServer;
|
||||
WITH_SSE2 = stdenv.isx86_64;
|
||||
WITH_VAAPI = true;
|
||||
WITH_JPEG = (libjpeg_turbo != null);
|
||||
WITH_CAIRO = (cairo != null);
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "A Remote Desktop Protocol Client";
|
||||
longDescription = ''
|
||||
FreeRDP is a client-side implementation of the Remote Desktop Protocol (RDP)
|
||||
following the Microsoft Open Specifications.
|
||||
'';
|
||||
homepage = "https://www.freerdp.com/";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ peterhoeg lheckemann ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, glib
|
||||
, libX11
|
||||
, gst_all_1
|
||||
, sqlite
|
||||
, libepoxy
|
||||
, pango
|
||||
, cairo
|
||||
, gdk-pixbuf
|
||||
, e2fsprogs
|
||||
, libkrb5
|
||||
, libva
|
||||
, openssl
|
||||
, pcsclite
|
||||
, gtk3
|
||||
, libselinux
|
||||
, libxml2
|
||||
, libffi
|
||||
, python3Packages
|
||||
, cpio
|
||||
, autoPatchelfHook
|
||||
, wrapGAppsHook
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "nice-dcv-client";
|
||||
version = "2021.2.3797-1";
|
||||
src =
|
||||
fetchurl {
|
||||
url = "https://d1uj6qtbmh3dt5.cloudfront.net/2021.2/Clients/nice-dcv-viewer-${version}.el8.x86_64.rpm";
|
||||
sha256 = "sha256-iLz25SB5v7ghkAZOMGPmpNaPihd8ikzCQS//r1xBNRU=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ autoPatchelfHook wrapGAppsHook python3Packages.rpm ];
|
||||
unpackPhase = ''
|
||||
rpm2cpio $src | ${cpio}/bin/cpio -idm
|
||||
'';
|
||||
|
||||
buildInputs = [
|
||||
libselinux
|
||||
libkrb5
|
||||
libxml2
|
||||
libva
|
||||
e2fsprogs
|
||||
libX11
|
||||
openssl
|
||||
pcsclite
|
||||
gtk3
|
||||
cairo
|
||||
libepoxy
|
||||
pango
|
||||
gdk-pixbuf
|
||||
gst_all_1.gstreamer
|
||||
gst_all_1.gst-plugins-base
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin/
|
||||
mkdir -p $out/lib64/
|
||||
mv usr/bin/dcvviewer $out/bin/dcvviewer
|
||||
mv usr/lib64/* $out/lib64/
|
||||
mkdir -p $out/libexec/dcvviewer
|
||||
mv usr/libexec/dcvviewer/dcvviewer $out/libexec/dcvviewer/dcvviewer
|
||||
patchelf \
|
||||
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
|
||||
$out/libexec/dcvviewer/dcvviewer
|
||||
# Fix the wrapper script to have the right basedir.
|
||||
sed -i "s#basedir=/usr#basedir=$out#" $out/bin/dcvviewer
|
||||
mv usr/share $out/
|
||||
|
||||
${glib.dev}/bin/glib-compile-schemas $out/share/glib-2.0/schemas
|
||||
|
||||
# we already ship libffi.so.7
|
||||
ln -s ${lib.getLib libffi}/lib/libffi.so $out/lib64/libffi.so.6
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "High-performance remote display protocol";
|
||||
homepage = "https://aws.amazon.com/hpc/dcv/";
|
||||
license = licenses.unfree;
|
||||
platforms = [ "x86_64-linux" ];
|
||||
maintainers = with maintainers; [ rmcgibbo ];
|
||||
};
|
||||
}
|
||||
55
pkgs/applications/networking/remote/putty/default.nix
Normal file
55
pkgs/applications/networking/remote/putty/default.nix
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
{ stdenv, lib, fetchurl, autoconf, automake, pkg-config, libtool
|
||||
, gtk2, halibut, ncurses, perl, darwin
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "0.76";
|
||||
pname = "putty";
|
||||
|
||||
src = fetchurl {
|
||||
urls = [
|
||||
"https://the.earth.li/~sgtatham/putty/${version}/${pname}-${version}.tar.gz"
|
||||
"ftp://ftp.wayne.edu/putty/putty-website-mirror/${version}/${pname}-${version}.tar.gz"
|
||||
];
|
||||
sha256 = "0gvi8phabszqksj2by5jrjmshm7bpirhgavz0dqyz1xaimxdjz2l";
|
||||
};
|
||||
|
||||
# glib-2.62 deprecations
|
||||
NIX_CFLAGS_COMPILE = "-DGLIB_DISABLE_DEPRECATION_WARNINGS";
|
||||
|
||||
preConfigure = lib.optionalString stdenv.hostPlatform.isUnix ''
|
||||
perl mkfiles.pl
|
||||
( cd doc ; make );
|
||||
./mkauto.sh
|
||||
cd unix
|
||||
'' + lib.optionalString stdenv.hostPlatform.isWindows ''
|
||||
cd windows
|
||||
'';
|
||||
|
||||
TOOLPATH = stdenv.cc.targetPrefix;
|
||||
makefile = if stdenv.hostPlatform.isWindows then "Makefile.mgw" else null;
|
||||
|
||||
installPhase = if stdenv.hostPlatform.isWindows then ''
|
||||
for exe in *.exe; do
|
||||
install -D $exe $out/bin/$exe
|
||||
done
|
||||
'' else null;
|
||||
|
||||
nativeBuildInputs = [ autoconf automake halibut libtool perl pkg-config ];
|
||||
buildInputs = lib.optionals stdenv.hostPlatform.isUnix [
|
||||
gtk2 ncurses
|
||||
] ++ lib.optional stdenv.isDarwin darwin.apple_sdk.libs.utmp;
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "A Free Telnet/SSH Client";
|
||||
longDescription = ''
|
||||
PuTTY is a free implementation of Telnet and SSH for Windows and Unix
|
||||
platforms, along with an xterm terminal emulator.
|
||||
It is written and maintained primarily by Simon Tatham.
|
||||
'';
|
||||
homepage = "https://www.chiark.greenend.org.uk/~sgtatham/putty/";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.unix ++ platforms.windows;
|
||||
};
|
||||
}
|
||||
34
pkgs/applications/networking/remote/rdesktop/default.nix
Normal file
34
pkgs/applications/networking/remote/rdesktop/default.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{ lib, stdenv, fetchFromGitHub, openssl, libX11, krb5, libXcursor, libtasn1
|
||||
, nettle, gnutls, pkg-config, autoreconfHook, libiconv
|
||||
, enableCredssp ? (!stdenv.isDarwin)
|
||||
} :
|
||||
|
||||
stdenv.mkDerivation (rec {
|
||||
pname = "rdesktop";
|
||||
version = "1.9.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = pname;
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "1s6k1jwd28y38ymk3lfv76ch4arpfwrbdhpkbnwwy3fc4617gb78";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [pkg-config autoreconfHook];
|
||||
buildInputs = [openssl libX11 libXcursor libtasn1 nettle gnutls]
|
||||
++ lib.optional enableCredssp krb5
|
||||
++ lib.optional stdenv.isDarwin libiconv;
|
||||
|
||||
configureFlags = [
|
||||
"--with-ipv6"
|
||||
"--with-openssl=${openssl.dev}"
|
||||
"--disable-smartcard"
|
||||
] ++ lib.optional (!enableCredssp) "--disable-credssp";
|
||||
|
||||
meta = {
|
||||
description = "Open source client for Windows Terminal Services";
|
||||
homepage = "http://www.rdesktop.org/";
|
||||
platforms = lib.platforms.linux ++ lib.platforms.darwin;
|
||||
license = lib.licenses.gpl2;
|
||||
};
|
||||
})
|
||||
64
pkgs/applications/networking/remote/remmina/default.nix
Normal file
64
pkgs/applications/networking/remote/remmina/default.nix
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
{ lib, stdenv, fetchFromGitLab, cmake, ninja, pkg-config, wrapGAppsHook
|
||||
, glib, gtk3, gettext, libxkbfile, libX11
|
||||
, freerdp, libssh, libgcrypt, gnutls, vte
|
||||
, pcre2, libdbusmenu-gtk3, libappindicator-gtk3
|
||||
, libvncserver, libpthreadstubs, libXdmcp, libxkbcommon
|
||||
, libsecret, libsoup, spice-protocol, spice-gtk, libepoxy, at-spi2-core
|
||||
, openssl, gsettings-desktop-schemas, json-glib, libsodium, webkitgtk, harfbuzz
|
||||
# The themes here are soft dependencies; only icons are missing without them.
|
||||
, gnome
|
||||
, withLibsecret ? true
|
||||
, withVte ? true
|
||||
}:
|
||||
|
||||
with lib;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "remmina";
|
||||
version = "1.4.25";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
owner = "Remmina";
|
||||
repo = "Remmina";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-1val/KCClEtw1prVWuXJe8DmmQ7e7oqwAfAnT9G9iHI=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ninja pkg-config wrapGAppsHook ];
|
||||
buildInputs = [
|
||||
gsettings-desktop-schemas
|
||||
glib gtk3 gettext libxkbfile libX11
|
||||
freerdp libssh libgcrypt gnutls
|
||||
pcre2 libdbusmenu-gtk3 libappindicator-gtk3
|
||||
libvncserver libpthreadstubs libXdmcp libxkbcommon
|
||||
libsoup spice-protocol spice-gtk libepoxy at-spi2-core
|
||||
openssl gnome.adwaita-icon-theme json-glib libsodium webkitgtk
|
||||
harfbuzz
|
||||
] ++ optionals withLibsecret [ libsecret ]
|
||||
++ optionals withVte [ vte ];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DWITH_VTE=${if withVte then "ON" else "OFF"}"
|
||||
"-DWITH_TELEPATHY=OFF"
|
||||
"-DWITH_AVAHI=OFF"
|
||||
"-DWITH_LIBSECRET=${if withLibsecret then "ON" else "OFF"}"
|
||||
"-DFREERDP_LIBRARY=${freerdp}/lib/libfreerdp2.so"
|
||||
"-DFREERDP_CLIENT_LIBRARY=${freerdp}/lib/libfreerdp-client2.so"
|
||||
"-DFREERDP_WINPR_LIBRARY=${freerdp}/lib/libwinpr2.so"
|
||||
"-DWINPR_INCLUDE_DIR=${freerdp}/include/winpr2"
|
||||
];
|
||||
|
||||
preFixup = ''
|
||||
gappsWrapperArgs+=(
|
||||
--prefix LD_LIBRARY_PATH : "${libX11.out}/lib"
|
||||
)
|
||||
'';
|
||||
|
||||
meta = {
|
||||
license = licenses.gpl2Plus;
|
||||
homepage = "https://gitlab.com/Remmina/Remmina";
|
||||
description = "Remote desktop client written in GTK";
|
||||
maintainers = with maintainers; [ melsigl ryantm ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
50
pkgs/applications/networking/remote/rustdesk/cargo.patch
Normal file
50
pkgs/applications/networking/remote/rustdesk/cargo.patch
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
diff --git a/Cargo.lock b/Cargo.lock
|
||||
index c3e139e..b77d8bd 100644
|
||||
--- a/Cargo.lock
|
||||
+++ b/Cargo.lock
|
||||
@@ -1761,11 +1761,11 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "magnum-opus"
|
||||
-version = "0.3.4-2"
|
||||
-source = "git+https://github.com/open-trade/magnum-opus#ad0836164abf4a4df69009b1ee08eabe3a13b33f"
|
||||
+version = "0.4.0"
|
||||
+source = "git+https://github.com/TheRadioGuy/magnum-opus#171e1d021004626f7444d1e39b98f50bc3cb2604"
|
||||
dependencies = [
|
||||
- "bindgen 0.59.1",
|
||||
- "target_build_utils",
|
||||
+ "libc",
|
||||
+ "opusic-sys",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -2188,6 +2188,16 @@ version = "0.1.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "28988d872ab76095a6e6ac88d99b54fd267702734fd7ffe610ca27f533ddb95a"
|
||||
|
||||
+[[package]]
|
||||
+name = "opusic-sys"
|
||||
+version = "0.3.6"
|
||||
+source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
+checksum = "5eace752ce07a037241dba8f02c654799f051e431b27028056bcb480e83b54f5"
|
||||
+dependencies = [
|
||||
+ "cmake",
|
||||
+ "libc",
|
||||
+]
|
||||
+
|
||||
[[package]]
|
||||
name = "parity-tokio-ipc"
|
||||
version = "0.7.2"
|
||||
diff --git a/Cargo.toml b/Cargo.toml
|
||||
index 75504a0..43e1624 100644
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -32,7 +32,7 @@ libc = "0.2"
|
||||
parity-tokio-ipc = { git = "https://github.com/open-trade/parity-tokio-ipc" }
|
||||
flexi_logger = "0.17"
|
||||
runas = "0.2"
|
||||
-magnum-opus = { git = "https://github.com/open-trade/magnum-opus" }
|
||||
+magnum-opus = { git = "https://github.com/TheRadioGuy/magnum-opus" }
|
||||
dasp = { version = "0.11", features = ["signal", "interpolate-linear", "interpolate"], optional = true }
|
||||
rubato = { version = "0.8", optional = true }
|
||||
samplerate = { version = "0.2", optional = true }
|
||||
104
pkgs/applications/networking/remote/rustdesk/default.nix
Normal file
104
pkgs/applications/networking/remote/rustdesk/default.nix
Normal file
|
|
@ -0,0 +1,104 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, makeDesktopItem
|
||||
, copyDesktopItems
|
||||
, makeWrapper
|
||||
, rustPlatform
|
||||
, cmake
|
||||
, yasm
|
||||
, nasm
|
||||
, zip
|
||||
, pkg-config
|
||||
, clang
|
||||
, gtk3
|
||||
, xdotool
|
||||
, libxcb
|
||||
, libXfixes
|
||||
, alsa-lib
|
||||
, pulseaudio
|
||||
, libXtst
|
||||
, libvpx
|
||||
, libyuv
|
||||
, libopus
|
||||
, libsciter
|
||||
, llvmPackages
|
||||
, wrapGAppsHook
|
||||
}:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "rustdesk";
|
||||
version = "1.1.8";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "rustdesk";
|
||||
repo = "rustdesk";
|
||||
rev = "0325500ebf331b66220cec6e9078afb83b0e98a7";
|
||||
sha256 = "sha256-xglyyoiAjJx3y8+A2OYHZffjqjDkcTjIluPA/J42VVg=";
|
||||
};
|
||||
|
||||
cargoSha256 = "sha256-4MQKa54f3X7IHGd29H6RY7v2toeHvTHInIpgXjdotjw=";
|
||||
|
||||
LIBCLANG_PATH="${llvmPackages.libclang.lib}/lib";
|
||||
|
||||
# Change magnus-opus version to upstream so that it does not use
|
||||
# vcpkg for libopus since it does not work.
|
||||
cargoPatches = [
|
||||
./cargo.patch
|
||||
];
|
||||
|
||||
# Manually simulate a vcpkg installation so that it can link the libaries
|
||||
# properly.
|
||||
postUnpack = let
|
||||
vcpkg_target = "x64-linux";
|
||||
in ''
|
||||
export VCPKG_ROOT="$TMP/vcpkg";
|
||||
|
||||
mkdir -p $VCPKG_ROOT/installed/${vcpkg_target}/lib
|
||||
|
||||
ln -s ${libvpx.out}/lib/* $VCPKG_ROOT/installed/${vcpkg_target}/lib/
|
||||
ln -s ${libyuv.out}/lib/* $VCPKG_ROOT/installed/${vcpkg_target}/lib/
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ pkg-config cmake makeWrapper copyDesktopItems yasm nasm clang wrapGAppsHook ];
|
||||
buildInputs = [ alsa-lib pulseaudio libXfixes libxcb xdotool gtk3 libvpx libopus libXtst libyuv ];
|
||||
|
||||
# Checks require an active X display.
|
||||
doCheck = false;
|
||||
|
||||
desktopItems = [ (makeDesktopItem {
|
||||
name = "rustdesk";
|
||||
exec = meta.mainProgram;
|
||||
icon = "rustdesk";
|
||||
desktopName = "RustDesk";
|
||||
comment = meta.description;
|
||||
genericName = "Remote Desktop";
|
||||
categories = ["Network"];
|
||||
}) ];
|
||||
|
||||
# Add static ui resources and libsciter to same folder as binary so that it
|
||||
# can find them.
|
||||
postInstall = ''
|
||||
mkdir -p $out/{share/src,lib/rustdesk}
|
||||
|
||||
# so needs to be next to the executable
|
||||
mv $out/bin/rustdesk $out/lib/rustdesk
|
||||
ln -s ${libsciter}/lib/libsciter-gtk.so $out/lib/rustdesk
|
||||
|
||||
makeWrapper $out/lib/rustdesk/rustdesk $out/bin/rustdesk \
|
||||
--chdir "$out/share"
|
||||
|
||||
cp -a $src/src/ui $out/share/src
|
||||
|
||||
install -Dm0644 $src/logo.svg $out/share/icons/hicolor/scalable/apps/rustdesk.svg
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Yet another remote desktop software";
|
||||
homepage = "https://rustdesk.com";
|
||||
license = licenses.gpl3Only;
|
||||
maintainers = with maintainers; [ leixb ];
|
||||
platforms = [ "x86_64-linux" ];
|
||||
mainProgram = "rustdesk";
|
||||
};
|
||||
}
|
||||
104
pkgs/applications/networking/remote/teamviewer/default.nix
Normal file
104
pkgs/applications/networking/remote/teamviewer/default.nix
Normal file
|
|
@ -0,0 +1,104 @@
|
|||
{ mkDerivation, lib, fetchurl, autoPatchelfHook, makeWrapper, xdg-utils, dbus
|
||||
, qtbase, qtwebkit, qtwebengine, qtx11extras, qtquickcontrols, getconf, glibc
|
||||
, libXrandr, libX11, libXext, libXdamage, libXtst, libSM, libXfixes, coreutils
|
||||
, wrapQtAppsHook
|
||||
}:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "teamviewer";
|
||||
# teamviewer itself has not development files but the dev output removes propagated other dev outputs from runtime
|
||||
outputs = [ "out" "dev" ];
|
||||
version = "15.29.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://dl.tvcdn.de/download/linux/version_15x/teamviewer_${version}_amd64.deb";
|
||||
sha256 = "sha256-jkFqOtU+D62S7QmNPvz58Z8wJ79lkN11pWQrtNdD+Uk=";
|
||||
};
|
||||
|
||||
unpackPhase = ''
|
||||
ar x $src
|
||||
tar xf data.tar.*
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ autoPatchelfHook makeWrapper wrapQtAppsHook ];
|
||||
buildInputs = [ dbus getconf qtbase qtwebkit qtwebengine qtx11extras libX11 ];
|
||||
propagatedBuildInputs = [ qtquickcontrols ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/share/teamviewer $out/bin $out/share/applications
|
||||
cp -a opt/teamviewer/* $out/share/teamviewer
|
||||
rm -R \
|
||||
$out/share/teamviewer/logfiles \
|
||||
$out/share/teamviewer/config \
|
||||
$out/share/teamviewer/tv_bin/RTlib \
|
||||
$out/share/teamviewer/tv_bin/xdg-utils \
|
||||
$out/share/teamviewer/tv_bin/script/{teamviewer_setup,teamviewerd.sysv,teamviewerd.service,teamviewerd.*.conf,tv-delayed-start.sh}
|
||||
|
||||
ln -s $out/share/teamviewer/tv_bin/script/teamviewer $out/bin
|
||||
ln -s $out/share/teamviewer/tv_bin/teamviewerd $out/bin
|
||||
ln -s $out/share/teamviewer/tv_bin/desktop/com.teamviewer.*.desktop $out/share/applications
|
||||
ln -s /var/lib/teamviewer $out/share/teamviewer/config
|
||||
ln -s /var/log/teamviewer $out/share/teamviewer/logfiles
|
||||
ln -s ${xdg-utils}/bin $out/share/teamviewer/tv_bin/xdg-utils
|
||||
|
||||
declare in_script_dir="./opt/teamviewer/tv_bin/script"
|
||||
|
||||
install -d "$out/share/dbus-1/services"
|
||||
install -m 644 "$in_script_dir/com.teamviewer.TeamViewer.service" "$out/share/dbus-1/services"
|
||||
substituteInPlace "$out/share/dbus-1/services/com.teamviewer.TeamViewer.service" \
|
||||
--replace '/opt/teamviewer/tv_bin/TeamViewer' \
|
||||
"$out/share/teamviewer/tv_bin/TeamViewer"
|
||||
install -m 644 "$in_script_dir/com.teamviewer.TeamViewer.Desktop.service" "$out/share/dbus-1/services"
|
||||
substituteInPlace "$out/share/dbus-1/services/com.teamviewer.TeamViewer.Desktop.service" \
|
||||
--replace '/opt/teamviewer/tv_bin/TeamViewer_Desktop' \
|
||||
"$out/share/teamviewer/tv_bin/TeamViewer_Desktop"
|
||||
|
||||
install -d "$out/share/dbus-1/system.d"
|
||||
install -m 644 "$in_script_dir/com.teamviewer.TeamViewer.Daemon.conf" "$out/share/dbus-1/system.d"
|
||||
|
||||
install -d "$out/share/polkit-1/actions"
|
||||
install -m 644 "$in_script_dir/com.teamviewer.TeamViewer.policy" "$out/share/polkit-1/actions"
|
||||
substituteInPlace "$out/share/polkit-1/actions/com.teamviewer.TeamViewer.policy" \
|
||||
--replace '/opt/teamviewer/tv_bin/script/execscript' \
|
||||
"$out/share/teamviewer/tv_bin/script/execscript"
|
||||
|
||||
for i in 16 20 24 32 48 256; do
|
||||
size=$i"x"$i
|
||||
|
||||
mkdir -p $out/share/icons/hicolor/$size/apps
|
||||
ln -s $out/share/teamviewer/tv_bin/desktop/teamviewer_$i.png $out/share/icons/hicolor/$size/apps/TeamViewer.png
|
||||
done;
|
||||
|
||||
sed -i "s,/opt/teamviewer,$out/share/teamviewer,g" $out/share/teamviewer/tv_bin/desktop/com.teamviewer.*.desktop
|
||||
|
||||
substituteInPlace $out/share/teamviewer/tv_bin/script/tvw_aux \
|
||||
--replace '/lib64/ld-linux-x86-64.so.2' '${glibc.out}/lib/ld-linux-x86-64.so.2'
|
||||
substituteInPlace $out/share/teamviewer/tv_bin/script/tvw_config \
|
||||
--replace '/var/run/' '/run/'
|
||||
'';
|
||||
|
||||
makeWrapperArgs = [
|
||||
"--prefix PATH : ${lib.makeBinPath [ getconf coreutils ]}"
|
||||
"--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ libXrandr libX11 libXext libXdamage libXtst libSM libXfixes dbus ]}"
|
||||
];
|
||||
|
||||
postFixup = ''
|
||||
wrapProgram $out/share/teamviewer/tv_bin/teamviewerd ''${makeWrapperArgs[@]}
|
||||
# tv_bin/script/teamviewer runs tvw_main which runs tv_bin/TeamViewer
|
||||
wrapProgram $out/share/teamviewer/tv_bin/script/teamviewer ''${makeWrapperArgs[@]} ''${qtWrapperArgs[@]}
|
||||
wrapProgram $out/share/teamviewer/tv_bin/teamviewer-config ''${makeWrapperArgs[@]} ''${qtWrapperArgs[@]}
|
||||
wrapProgram $out/share/teamviewer/tv_bin/TeamViewer_Desktop ''${makeWrapperArgs[@]} ''${qtWrapperArgs[@]}
|
||||
'';
|
||||
|
||||
dontStrip = true;
|
||||
dontWrapQtApps = true;
|
||||
preferLocalBuild = true;
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://www.teamviewer.com";
|
||||
license = licenses.unfree;
|
||||
description = "Desktop sharing application, providing remote support and online meetings";
|
||||
platforms = [ "x86_64-linux" ];
|
||||
maintainers = with maintainers; [ jagajaga dasuxullebt jraygauthier ];
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,141 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, buildFHSUserEnv
|
||||
, fetchurl
|
||||
, gsettings-desktop-schemas
|
||||
, makeDesktopItem
|
||||
, makeWrapper
|
||||
, writeTextDir
|
||||
, configText ? ""
|
||||
}:
|
||||
let
|
||||
version = "2203";
|
||||
|
||||
sysArch =
|
||||
if stdenv.hostPlatform.system == "x86_64-linux" then "x64"
|
||||
else throw "Unsupported system: ${stdenv.hostPlatform.system}";
|
||||
# The downloaded archive also contains ARM binaries, but these have not been tested.
|
||||
|
||||
# For USB support, ensure that /var/run/vmware/<YOUR-UID>
|
||||
# exists and is owned by you. Then run vmware-usbarbitrator as root.
|
||||
bins = [ "vmware-view" "vmware-usbarbitrator" ];
|
||||
|
||||
# This forces the default GTK theme (Adwaita) because Horizon is prone to
|
||||
# UI usability issues when using non-default themes, such as Adwaita-dark.
|
||||
wrapBinCommands = name: ''
|
||||
makeWrapper "$out/bin/${name}" "$out/bin/${name}_wrapper" \
|
||||
--set GTK_THEME Adwaita \
|
||||
--suffix XDG_DATA_DIRS : "${gsettings-desktop-schemas}/share/gsettings-schemas/${gsettings-desktop-schemas.name}" \
|
||||
--suffix LD_LIBRARY_PATH : "$out/lib/vmware/view/crtbora:$out/lib/vmware"
|
||||
'';
|
||||
|
||||
vmwareHorizonClientFiles = stdenv.mkDerivation {
|
||||
name = "vmwareHorizonClientFiles";
|
||||
inherit version;
|
||||
src = fetchurl {
|
||||
url = "https://download3.vmware.com/software/CART23FQ1_LIN_2203_TARBALL/VMware-Horizon-Client-Linux-2203-8.5.0-19586897.tar.gz";
|
||||
sha256 = "27429dddaeedfa8b701d7aa7868f60ad58efa42687d7f27e84375fda9f5cd137";
|
||||
};
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
installPhase = ''
|
||||
mkdir ext $out
|
||||
find ${sysArch} -type f -print0 | xargs -0n1 tar -Cext --strip-components=1 -xf
|
||||
mv ext/bin ext/lib ext/share "$out"/
|
||||
|
||||
# Horizon includes a copy of libstdc++ which is loaded via $LD_LIBRARY_PATH
|
||||
# when it cannot detect a new enough version already present on the system.
|
||||
# The checks are distribution-specific and do not function correctly on NixOS.
|
||||
# Deleting the bundled library is the simplest way to force it to use our version.
|
||||
rm "$out/lib/vmware/gcc/libstdc++.so.6"
|
||||
|
||||
# This library causes the program to core-dump occasionally. Use ours instead.
|
||||
rm $out/lib/vmware/view/crtbora/libcairo.*
|
||||
|
||||
${lib.concatMapStrings wrapBinCommands bins}
|
||||
'';
|
||||
};
|
||||
|
||||
vmwareFHSUserEnv = name: buildFHSUserEnv {
|
||||
inherit name;
|
||||
|
||||
runScript = "${vmwareHorizonClientFiles}/bin/${name}_wrapper";
|
||||
|
||||
targetPkgs = pkgs: with pkgs; [
|
||||
at-spi2-atk
|
||||
atk
|
||||
cairo
|
||||
dbus
|
||||
fontconfig
|
||||
freetype
|
||||
gdk-pixbuf
|
||||
glib
|
||||
gtk2
|
||||
gtk3-x11
|
||||
harfbuzz
|
||||
liberation_ttf
|
||||
libjpeg
|
||||
libpulseaudio
|
||||
libtiff
|
||||
libudev0-shim
|
||||
libuuid
|
||||
libv4l
|
||||
libxml2
|
||||
pango
|
||||
pcsclite
|
||||
pixman
|
||||
vmwareHorizonClientFiles
|
||||
xorg.libX11
|
||||
xorg.libXcursor
|
||||
xorg.libXext
|
||||
xorg.libXi
|
||||
xorg.libXinerama
|
||||
xorg.libxkbfile
|
||||
xorg.libXrandr
|
||||
xorg.libXrender
|
||||
xorg.libXScrnSaver
|
||||
xorg.libXtst
|
||||
zlib
|
||||
|
||||
(writeTextDir "etc/vmware/config" configText)
|
||||
];
|
||||
};
|
||||
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "vmware-view";
|
||||
desktopName = "VMware Horizon Client";
|
||||
icon = "${vmwareHorizonClientFiles}/share/icons/vmware-view.png";
|
||||
exec = "${vmwareFHSUserEnv "vmware-view"}/bin/vmware-view %u";
|
||||
mimeTypes = [ "x-scheme-handler/vmware-view" ];
|
||||
};
|
||||
|
||||
binLinkCommands = lib.concatMapStringsSep
|
||||
"\n"
|
||||
(bin: "ln -s ${vmwareFHSUserEnv bin}/bin/${bin} $out/bin/")
|
||||
bins;
|
||||
|
||||
in
|
||||
stdenv.mkDerivation {
|
||||
pname = "vmware-horizon-client";
|
||||
inherit version;
|
||||
|
||||
dontUnpack = true;
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin $out/share/applications
|
||||
cp ${desktopItem}/share/applications/* $out/share/applications/
|
||||
${binLinkCommands}
|
||||
'';
|
||||
|
||||
unwrapped = vmwareHorizonClientFiles;
|
||||
|
||||
passthru.updateScript = ./update.sh;
|
||||
|
||||
meta = with lib; {
|
||||
mainProgram = "vmware-view";
|
||||
description = "Allows you to connect to your VMware Horizon virtual desktop";
|
||||
homepage = "https://www.vmware.com/go/viewclients";
|
||||
license = licenses.unfree;
|
||||
platforms = [ "x86_64-linux" ];
|
||||
maintainers = with maintainers; [ buckley310 ];
|
||||
};
|
||||
}
|
||||
27
pkgs/applications/networking/remote/vmware-horizon-client/update.sh
Executable file
27
pkgs/applications/networking/remote/vmware-horizon-client/update.sh
Executable file
|
|
@ -0,0 +1,27 @@
|
|||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -p curl -p jq -p common-updater-scripts -i bash
|
||||
set -e
|
||||
|
||||
entryPointURL='https://customerconnect.vmware.com/channel/public/api/v1.0/products/getRelatedDLGList?locale=en_US&category=desktop_end_user_computing&product=vmware_horizon_clients&version=horizon_8&dlgType=PRODUCT_BINARY'
|
||||
|
||||
function getTarballMetaUrl {
|
||||
curl "$entryPointURL" | jq -r '
|
||||
.dlgEditionsLists | .[] | select(.name | contains("Client for Linux")) |
|
||||
.dlgList | .[] | select(.name | contains("tarball version")) |
|
||||
@uri "https://customerconnect.vmware.com/channel/public/api/v1.0/dlg/details?locale=en_US&downloadGroup=\(.code)&productId=\(.productId)&rPId=\(.releasePackageId)"
|
||||
'
|
||||
}
|
||||
|
||||
meta="$( curl "$(getTarballMetaUrl)" | jq ".downloadFiles | .[]" )"
|
||||
|
||||
ver="$( echo "$meta" | jq -r .version )"
|
||||
url="$( echo "$meta" | jq -r .thirdPartyDownloadUrl )"
|
||||
sum="$( echo "$meta" | jq -r .sha256checksum )"
|
||||
|
||||
echo
|
||||
echo "version: $ver"
|
||||
echo "tar url: $url"
|
||||
echo " sha256: $sum"
|
||||
|
||||
cd "$(dirname "$0")/../../../../.."
|
||||
update-source-version vmware-horizon-client.unwrapped "$ver" "$sum" "$url"
|
||||
39
pkgs/applications/networking/remote/waypipe/default.nix
Normal file
39
pkgs/applications/networking/remote/waypipe/default.nix
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
{ lib, stdenv, fetchFromGitLab
|
||||
, meson, ninja, pkg-config, scdoc
|
||||
, mesa, lz4, zstd, ffmpeg, libva
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "waypipe";
|
||||
version = "0.8.2";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
domain = "gitlab.freedesktop.org";
|
||||
owner = "mstoeckl";
|
||||
repo = "waypipe";
|
||||
rev = "v${version}";
|
||||
sha256 = "02q8l1qaahmd41h6v3r46akh7xlqz7fpwwsy15qww4jdvypg6vg4";
|
||||
};
|
||||
|
||||
strictDeps = true;
|
||||
depsBuildBuild = [ pkg-config ];
|
||||
nativeBuildInputs = [ meson ninja pkg-config scdoc ];
|
||||
buildInputs = [
|
||||
# Optional dependencies:
|
||||
mesa lz4 zstd ffmpeg libva
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A network proxy for Wayland clients (applications)";
|
||||
longDescription = ''
|
||||
waypipe is a proxy for Wayland clients. It forwards Wayland messages and
|
||||
serializes changes to shared memory buffers over a single socket. This
|
||||
makes application forwarding similar to ssh -X feasible.
|
||||
'';
|
||||
homepage = "https://mstoeckl.com/notes/gsoc/blog.html";
|
||||
changelog = "https://gitlab.freedesktop.org/mstoeckl/waypipe/-/releases#v${version}";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ primeos ];
|
||||
};
|
||||
}
|
||||
34
pkgs/applications/networking/remote/wayvnc/default.nix
Normal file
34
pkgs/applications/networking/remote/wayvnc/default.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{ lib, stdenv, fetchFromGitHub, meson, pkg-config, ninja, scdoc, wayland-scanner
|
||||
, pixman, libxkbcommon, wayland, neatvnc, libdrm, libX11, aml, pam
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "wayvnc";
|
||||
version = "0.4.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "any1";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "0cws9jfnmxqycmlyllvvqzw4jsbrwwk10v9gy8wifv3c61rwgdkk";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ meson pkg-config ninja scdoc wayland-scanner ];
|
||||
buildInputs = [ pixman libxkbcommon wayland neatvnc libdrm libX11 aml pam ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A VNC server for wlroots based Wayland compositors";
|
||||
longDescription = ''
|
||||
This is a VNC server for wlroots based Wayland compositors. It attaches
|
||||
to a running Wayland session, creates virtual input devices and exposes a
|
||||
single display via the RFB protocol. The Wayland session may be a
|
||||
headless one, so it is also possible to run wayvnc without a physical
|
||||
display attached.
|
||||
'';
|
||||
inherit (src.meta) homepage;
|
||||
changelog = "https://github.com/any1/wayvnc/releases/tag/v${version}";
|
||||
license = licenses.isc;
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ primeos ];
|
||||
};
|
||||
}
|
||||
68
pkgs/applications/networking/remote/x2goclient/default.nix
Normal file
68
pkgs/applications/networking/remote/x2goclient/default.nix
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
{ lib
|
||||
, fetchurl
|
||||
, cups
|
||||
, libssh
|
||||
, libXpm
|
||||
, nx-libs
|
||||
, openldap
|
||||
, openssh
|
||||
, qt5
|
||||
, qtbase
|
||||
, qtsvg
|
||||
, qtx11extras
|
||||
, qttools
|
||||
, phonon
|
||||
, pkg-config
|
||||
}:
|
||||
|
||||
qt5.mkDerivation rec {
|
||||
pname = "x2goclient";
|
||||
version = "4.1.2.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://code.x2go.org/releases/source/${pname}/${pname}-${version}.tar.gz";
|
||||
sha256 = "yZUyZ8QPpnEZrZanO6yx8mYZbaIFnwzc0bjVGZQh0So=";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
cups
|
||||
libssh
|
||||
libXpm
|
||||
nx-libs
|
||||
openldap
|
||||
openssh
|
||||
qtbase
|
||||
qtsvg
|
||||
qtx11extras
|
||||
qttools
|
||||
phonon
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
qt5.wrapQtAppsHook
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace src/onmainwindow.cpp --replace "/usr/sbin/sshd" "${openssh}/bin/sshd"
|
||||
substituteInPlace Makefile \
|
||||
--replace "SHELL=/bin/bash" "SHELL=$SHELL" \
|
||||
--replace "lrelease-qt4" "${qttools.dev}/bin/lrelease" \
|
||||
--replace "qmake-qt4" "${qtbase.dev}/bin/qmake" \
|
||||
--replace "-o root -g root" ""
|
||||
'';
|
||||
|
||||
makeFlags = [ "PREFIX=$(out)" "ETCDIR=$(out)/etc" "build_client" "build_man" ];
|
||||
|
||||
installTargets = [ "install_client" "install_man" ];
|
||||
|
||||
qtWrapperArgs = [ "--suffix PATH : ${nx-libs}/bin:${openssh}/libexec" "--set QT_QPA_PLATFORM xcb" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Graphical NoMachine NX3 remote desktop client";
|
||||
homepage = "http://x2go.org/";
|
||||
maintainers = with maintainers; [ mkg20001 ];
|
||||
license = licenses.gpl2;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
93
pkgs/applications/networking/remote/x2goserver/default.nix
Normal file
93
pkgs/applications/networking/remote/x2goserver/default.nix
Normal file
|
|
@ -0,0 +1,93 @@
|
|||
{ stdenv, lib, fetchurl, perlPackages, makeWrapper, perl, which, nx-libs
|
||||
, util-linux, coreutils, glibc, gawk, gnused, gnugrep, findutils, xorg
|
||||
, nettools, iproute2, bc, procps, psmisc, lsof, pwgen, openssh, sshfs, bash
|
||||
}:
|
||||
|
||||
let
|
||||
pname = "x2goserver";
|
||||
version = "4.1.0.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://code.x2go.org/releases/source/${pname}/${pname}-${version}.tar.gz";
|
||||
sha256 = "Z3aqo1T1pE40nws8F21JiMiKYYwu30bJijeuicBp3NA=";
|
||||
};
|
||||
|
||||
x2go-perl = perlPackages.buildPerlPackage rec {
|
||||
pname = "X2Go";
|
||||
inherit version src;
|
||||
makeFlags = [ "-f" "Makefile.perl" ];
|
||||
patchPhase = ''
|
||||
substituteInPlace X2Go/Config.pm --replace '/etc/x2go' '/var/lib/x2go/conf'
|
||||
substituteInPlace X2Go/Server/DB.pm \
|
||||
--replace '$x2go_lib_path/libx2go-server-db-sqlite3-wrapper' \
|
||||
'/run/wrappers/bin/x2gosqliteWrapper'
|
||||
substituteInPlace X2Go/Server/DB/SQLite3.pm --replace "user='x2gouser'" "user='x2go'"
|
||||
'';
|
||||
};
|
||||
|
||||
perlEnv = perl.withPackages (p: with p; [
|
||||
x2go-perl DBI DBDSQLite FileBaseDir TryTiny CaptureTiny ConfigSimple Switch FileWhich
|
||||
]);
|
||||
|
||||
binaryDeps = [
|
||||
perlEnv which nx-libs util-linux coreutils glibc.bin gawk gnused gnugrep
|
||||
findutils nettools iproute2 bc procps psmisc lsof pwgen openssh sshfs
|
||||
xorg.xauth xorg.xinit xorg.xrandr xorg.xmodmap xorg.xwininfo xorg.fontutil
|
||||
xorg.xkbcomp xorg.setxkbmap
|
||||
];
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
inherit pname version src;
|
||||
|
||||
buildInputs = [ perlEnv bash ];
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
||||
prePatch = ''
|
||||
patchShebangs .
|
||||
sed -i '/Makefile.PL\|Makefile.perl/d' Makefile
|
||||
for i in */Makefile; do
|
||||
substituteInPlace "$i" --replace "-o root -g root " ""
|
||||
done
|
||||
substituteInPlace libx2go-server-db-perl/Makefile --replace "chmod 2755" "chmod 755"
|
||||
for i in x2goserver/sbin/x2godbadmin x2goserver/bin/x2go*
|
||||
do
|
||||
substituteInPlace $i --replace '/etc/x2go' '/var/lib/x2go/conf'
|
||||
done
|
||||
substituteInPlace x2goserver/sbin/x2gocleansessions \
|
||||
--replace '/var/run/x2goserver.pid' '/var/run/x2go/x2goserver.pid'
|
||||
substituteInPlace x2goserver/sbin/x2godbadmin --replace 'user="x2gouser"' 'user="x2go"'
|
||||
substituteInPlace x2goserver-xsession/etc/Xsession \
|
||||
--replace "SSH_AGENT /bin/bash -c" "SSH_AGENT ${bash}/bin/bash -c" \
|
||||
--replace "[ -f /etc/redhat-release ]" "[ -d /etc/nix ] || [ -f /etc/redhat-release ]"
|
||||
'';
|
||||
|
||||
makeFlags = [ "PREFIX=/" "NXLIBDIR=${nx-libs}/lib/nx" ];
|
||||
|
||||
installFlags = [ "DESTDIR=$(out)" ];
|
||||
|
||||
postInstall = ''
|
||||
mv $out/etc/x2go/x2goserver.conf{,.example}
|
||||
mv $out/etc/x2go/x2goagent.options{,.example}
|
||||
ln -sf ${nx-libs}/bin/nxagent $out/bin/x2goagent
|
||||
for i in $out/sbin/x2go* $(find $out/bin -type f) \
|
||||
$(ls $out/lib/x2go/x2go* | grep -v x2gocheckport)
|
||||
do
|
||||
wrapProgram $i --prefix PATH : ${lib.makeBinPath binaryDeps}:$out
|
||||
done
|
||||
# We're patching @INC of the setgid wrapper, because we can't mix
|
||||
# the perl wrapper (for PERL5LIB) with security.wrappers (for setgid)
|
||||
sed -ie "s,.\+bin/perl,#!${perl}/bin/perl -I ${perlEnv}/lib/perl5/site_perl," \
|
||||
$out/lib/x2go/libx2go-server-db-sqlite3-wrapper.pl
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Remote desktop application, server component";
|
||||
homepage = "http://x2go.org/";
|
||||
platforms = lib.platforms.linux;
|
||||
license = licenses.gpl2;
|
||||
maintainers = with maintainers; [ averelld mkg20001 ];
|
||||
};
|
||||
}
|
||||
105
pkgs/applications/networking/remote/xrdp/default.nix
Normal file
105
pkgs/applications/networking/remote/xrdp/default.nix
Normal file
|
|
@ -0,0 +1,105 @@
|
|||
{ lib, stdenv, fetchFromGitHub, pkg-config, which, perl, autoconf, automake, libtool, openssl, systemd, pam, fuse, libjpeg, libopus, nasm, xorg }:
|
||||
|
||||
let
|
||||
xorgxrdp = stdenv.mkDerivation rec {
|
||||
pname = "xorgxrdp";
|
||||
version = "0.2.9";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "neutrinolabs";
|
||||
repo = "xorgxrdp";
|
||||
rev = "v${version}";
|
||||
sha256 = "1bhp5x47hajhinvglmc4vxxnpjvfjm6369njb3ghqfr7c5xypvzr";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config autoconf automake which libtool nasm ];
|
||||
|
||||
buildInputs = [ xorg.xorgserver ];
|
||||
|
||||
postPatch = ''
|
||||
# patch from Debian, allows to run xrdp daemon under unprivileged user
|
||||
substituteInPlace module/rdpClientCon.c \
|
||||
--replace 'g_sck_listen(dev->listen_sck);' 'g_sck_listen(dev->listen_sck); g_chmod_hex(dev->uds_data, 0x0660);'
|
||||
|
||||
substituteInPlace configure.ac \
|
||||
--replace 'moduledir=`pkg-config xorg-server --variable=moduledir`' "moduledir=$out/lib/xorg/modules" \
|
||||
--replace 'sysconfdir="/etc"' "sysconfdir=$out/etc"
|
||||
'';
|
||||
|
||||
preConfigure = "./bootstrap";
|
||||
|
||||
configureFlags = [ "XRDP_CFLAGS=-I${xrdp.src}/common" ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
};
|
||||
|
||||
xrdp = stdenv.mkDerivation rec {
|
||||
version = "0.9.9";
|
||||
pname = "xrdp";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "volth";
|
||||
repo = "xrdp";
|
||||
rev = "refs/tags/runtime-cfg-path-${version}"; # Fixes https://github.com/neutrinolabs/xrdp/issues/609; not a patch on top of the official repo because "xorgxrdp.configureFlags" above includes "xrdp.src" which must be patched already
|
||||
fetchSubmodules = true;
|
||||
sha256 = "0ynj6pml4f38y8571ryhifza57wfqg4frdrjcwzw3fmryiznfm1z";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config autoconf automake which libtool nasm ];
|
||||
|
||||
buildInputs = [ openssl systemd pam fuse libjpeg libopus xorg.libX11 xorg.libXfixes xorg.libXrandr ];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace sesman/xauth.c --replace "xauth -q" "${xorg.xauth}/bin/xauth -q"
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
(cd librfxcodec && ./bootstrap && ./configure --prefix=$out --enable-static --disable-shared)
|
||||
./bootstrap
|
||||
'';
|
||||
dontDisableStatic = true;
|
||||
configureFlags = [ "--with-systemdsystemunitdir=/var/empty" "--enable-ipv6" "--enable-jpeg" "--enable-fuse" "--enable-rfxcodec" "--enable-opus" ];
|
||||
|
||||
installFlags = [ "DESTDIR=$(out)" "prefix=" ];
|
||||
|
||||
postInstall = ''
|
||||
# remove generated keys (as non-determenistic) and upstart script
|
||||
rm $out/etc/xrdp/{rsakeys.ini,key.pem,cert.pem,xrdp.sh}
|
||||
|
||||
cp $src/keygen/openssl.conf $out/share/xrdp/openssl.conf
|
||||
|
||||
substituteInPlace $out/etc/xrdp/sesman.ini --replace /etc/xrdp/pulse $out/etc/xrdp/pulse
|
||||
|
||||
# remove all session types except Xorg (they are not supported by this setup)
|
||||
${perl}/bin/perl -i -ne 'print unless /\[(X11rdp|Xvnc|console|vnc-any|sesman-any|rdp-any|neutrinordp-any)\]/ .. /^$/' $out/etc/xrdp/xrdp.ini
|
||||
|
||||
# remove all session types and then add Xorg
|
||||
${perl}/bin/perl -i -ne 'print unless /\[(X11rdp|Xvnc|Xorg)\]/ .. /^$/' $out/etc/xrdp/sesman.ini
|
||||
|
||||
cat >> $out/etc/xrdp/sesman.ini <<EOF
|
||||
|
||||
[Xorg]
|
||||
param=${xorg.xorgserver}/bin/Xorg
|
||||
param=-modulepath
|
||||
param=${xorgxrdp}/lib/xorg/modules,${xorg.xorgserver}/lib/xorg/modules
|
||||
param=-config
|
||||
param=${xorgxrdp}/etc/X11/xrdp/xorg.conf
|
||||
param=-noreset
|
||||
param=-nolisten
|
||||
param=tcp
|
||||
param=-logfile
|
||||
param=.xorgxrdp.%s.log
|
||||
EOF
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "An open source RDP server";
|
||||
homepage = "https://github.com/neutrinolabs/xrdp";
|
||||
license = licenses.asl20;
|
||||
maintainers = [ maintainers.volth ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
};
|
||||
in xrdp
|
||||
Loading…
Add table
Add a link
Reference in a new issue