2021-06-10 03:57:09 +01:00
|
|
|
{ alsa-lib
|
2021-01-05 08:52:55 +00:00
|
|
|
, at-spi2-atk
|
|
|
|
, at-spi2-core
|
|
|
|
, atk
|
2021-06-24 07:33:31 +01:00
|
|
|
, autoPatchelfHook
|
2021-01-05 08:52:55 +00:00
|
|
|
, cairo
|
|
|
|
, cups
|
|
|
|
, curl
|
|
|
|
, dbus
|
|
|
|
, dnsmasq
|
|
|
|
, dpkg
|
|
|
|
, expat
|
|
|
|
, fetchurl
|
|
|
|
, gdk-pixbuf
|
|
|
|
, glib
|
|
|
|
, gtk3
|
|
|
|
, icu
|
2021-03-14 16:05:16 +00:00
|
|
|
, iproute2
|
2021-01-05 08:52:55 +00:00
|
|
|
, krb5
|
|
|
|
, lib
|
2021-01-11 10:51:00 +00:00
|
|
|
, libdrm
|
2021-01-05 08:52:55 +00:00
|
|
|
, libsecret
|
|
|
|
, libuuid
|
|
|
|
, libxcb
|
2021-06-24 07:33:31 +01:00
|
|
|
, libxkbcommon
|
2021-01-05 08:52:55 +00:00
|
|
|
, lttng-ust
|
|
|
|
, makeWrapper
|
2021-06-24 07:33:31 +01:00
|
|
|
, mesa
|
2021-01-05 08:52:55 +00:00
|
|
|
, networkmanager
|
|
|
|
, nspr
|
|
|
|
, nss
|
|
|
|
, openssl
|
|
|
|
, pango
|
|
|
|
, procps
|
2021-08-30 00:00:25 +01:00
|
|
|
, python3
|
2021-01-05 08:52:55 +00:00
|
|
|
, stdenv
|
|
|
|
, systemd
|
2021-04-06 17:52:18 +01:00
|
|
|
, xdg-utils
|
2021-06-24 07:33:31 +01:00
|
|
|
, xorg
|
2021-01-05 08:52:55 +00:00
|
|
|
, zlib
|
|
|
|
}:
|
2021-01-15 13:21:58 +00:00
|
|
|
with lib;
|
2021-01-05 08:52:55 +00:00
|
|
|
let
|
|
|
|
deps = [
|
2021-06-10 03:57:09 +01:00
|
|
|
alsa-lib
|
2021-01-05 08:52:55 +00:00
|
|
|
at-spi2-atk
|
|
|
|
at-spi2-core
|
|
|
|
atk
|
|
|
|
cairo
|
|
|
|
cups
|
|
|
|
curl
|
|
|
|
dbus
|
|
|
|
expat
|
|
|
|
gdk-pixbuf
|
|
|
|
glib
|
|
|
|
gtk3
|
|
|
|
icu
|
|
|
|
krb5
|
2021-01-11 10:51:00 +00:00
|
|
|
libdrm
|
2021-01-05 08:52:55 +00:00
|
|
|
libsecret
|
|
|
|
libuuid
|
|
|
|
libxcb
|
2021-06-24 07:33:31 +01:00
|
|
|
libxkbcommon
|
2021-01-05 08:52:55 +00:00
|
|
|
lttng-ust
|
2021-06-24 07:33:31 +01:00
|
|
|
mesa
|
2021-01-05 08:52:55 +00:00
|
|
|
nspr
|
|
|
|
nss
|
|
|
|
openssl
|
|
|
|
pango
|
|
|
|
stdenv.cc.cc
|
|
|
|
systemd
|
2021-06-24 07:33:31 +01:00
|
|
|
xorg.libX11
|
|
|
|
xorg.libXScrnSaver
|
|
|
|
xorg.libXcomposite
|
|
|
|
xorg.libXcursor
|
|
|
|
xorg.libXdamage
|
|
|
|
xorg.libXext
|
|
|
|
xorg.libXfixes
|
|
|
|
xorg.libXi
|
|
|
|
xorg.libXrandr
|
|
|
|
xorg.libXrender
|
|
|
|
xorg.libXtst
|
|
|
|
xorg.libxkbfile
|
|
|
|
xorg.libxshmfence
|
2021-01-05 08:52:55 +00:00
|
|
|
zlib
|
|
|
|
];
|
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "appgate-sdp";
|
2021-12-21 21:30:48 +00:00
|
|
|
version = "5.5.1";
|
2021-01-05 08:52:55 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-06-24 07:33:31 +01:00
|
|
|
url = "https://bin.appgate-sdp.com/${versions.majorMinor version}/client/appgate-sdp_${version}_amd64.deb";
|
2021-12-21 21:30:48 +00:00
|
|
|
sha256 = "sha256-gN9UAdn61qUZBJLi/9QiHjNRohbQQDV1uVHgcpuXq+Y=";
|
2021-01-05 08:52:55 +00:00
|
|
|
};
|
|
|
|
|
2021-06-24 07:33:31 +01:00
|
|
|
# just patch interpreter
|
|
|
|
autoPatchelfIgnoreMissingDeps = true;
|
2021-01-05 08:52:55 +00:00
|
|
|
dontConfigure = true;
|
|
|
|
dontBuild = true;
|
|
|
|
|
|
|
|
buildInputs = [
|
2021-08-30 00:00:25 +01:00
|
|
|
python3
|
|
|
|
python3.pkgs.dbus-python
|
2021-01-05 08:52:55 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2021-06-24 07:33:31 +01:00
|
|
|
autoPatchelfHook
|
2021-01-05 08:52:55 +00:00
|
|
|
makeWrapper
|
|
|
|
dpkg
|
|
|
|
];
|
|
|
|
|
|
|
|
unpackPhase = ''
|
|
|
|
dpkg-deb -x $src $out
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
cp -r $out/usr/share $out/share
|
|
|
|
|
2021-06-24 07:33:31 +01:00
|
|
|
substituteInPlace $out/lib/systemd/system/appgate-dumb-resolver.service \
|
|
|
|
--replace "/opt/" "$out/opt/"
|
2021-01-11 10:51:00 +00:00
|
|
|
|
|
|
|
substituteInPlace $out/lib/systemd/system/appgatedriver.service \
|
2021-06-24 07:33:31 +01:00
|
|
|
--replace "/opt/" "$out/opt/" \
|
2021-01-11 10:51:00 +00:00
|
|
|
--replace "InaccessiblePaths=/mnt /srv /boot /media" "InaccessiblePaths=-/mnt -/srv -/boot -/media"
|
|
|
|
|
|
|
|
substituteInPlace $out/lib/systemd/system/appgate-resolver.service \
|
2021-06-24 07:33:31 +01:00
|
|
|
--replace "/usr/sbin/dnsmasq" "${dnsmasq}/bin/dnsmasq" \
|
|
|
|
--replace "/opt/" "$out/opt/"
|
|
|
|
|
|
|
|
substituteInPlace $out/opt/appgate/linux/nm.py \
|
2021-01-11 10:51:00 +00:00
|
|
|
--replace "/usr/sbin/dnsmasq" "${dnsmasq}/bin/dnsmasq"
|
|
|
|
|
2021-06-24 07:33:31 +01:00
|
|
|
substituteInPlace $out/opt/appgate/linux/set_dns \
|
|
|
|
--replace "/etc/appgate.conf" "$out/etc/appgate.conf"
|
2021-01-05 08:52:55 +00:00
|
|
|
|
2021-06-24 07:33:31 +01:00
|
|
|
wrapProgram $out/opt/appgate/service/createdump \
|
|
|
|
--set LD_LIBRARY_PATH "${makeLibraryPath [ stdenv.cc.cc ]}"
|
|
|
|
|
|
|
|
wrapProgram $out/opt/appgate/appgate-driver \
|
|
|
|
--prefix PATH : ${makeBinPath [ iproute2 networkmanager dnsmasq ]} \
|
|
|
|
--set LD_LIBRARY_PATH $out/opt/appgate/service
|
|
|
|
|
|
|
|
makeWrapper $out/opt/appgate/Appgate $out/bin/appgate \
|
|
|
|
--prefix PATH : ${makeBinPath [ xdg-utils ]} \
|
|
|
|
--set LD_LIBRARY_PATH $out/opt/appgate:${makeLibraryPath deps}
|
2021-01-05 08:52:55 +00:00
|
|
|
|
|
|
|
wrapProgram $out/opt/appgate/linux/set_dns --set PYTHONPATH $PYTHONPATH
|
|
|
|
'';
|
2021-06-24 07:33:31 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2021-01-05 08:52:55 +00:00
|
|
|
description = "Appgate SDP (Software Defined Perimeter) desktop client";
|
2021-02-21 15:19:02 +00:00
|
|
|
homepage = "https://www.appgate.com/support/software-defined-perimeter-support";
|
2021-01-05 08:52:55 +00:00
|
|
|
license = licenses.unfree;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ ymatsiuk ];
|
|
|
|
};
|
|
|
|
}
|