2020-12-02 15:45:03 +00:00
|
|
|
{ stdenv, lib, fetchFromGitHub
|
2021-12-03 04:03:55 +00:00
|
|
|
, cmake, qtwebsockets, qtwebengine, wrapQtAppsHook, openconnect
|
2020-12-02 15:45:03 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "globalprotect-openconnect";
|
2022-07-28 14:03:09 +01:00
|
|
|
version = "1.4.8";
|
2020-12-02 15:45:03 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "yuezk";
|
|
|
|
repo = "GlobalProtect-openconnect";
|
|
|
|
fetchSubmodules = true;
|
2021-12-03 04:03:55 +00:00
|
|
|
rev = "v${version}";
|
2022-07-28 14:03:09 +01:00
|
|
|
sha256 = "sha256-PQAlGeHVayImKalCNv2SwPcxD0ts4BVSqeo1hKYmnMA=";
|
2020-12-02 15:45:03 +00:00
|
|
|
};
|
|
|
|
|
2021-12-03 04:03:55 +00:00
|
|
|
nativeBuildInputs = [ cmake wrapQtAppsHook ];
|
2020-12-02 15:45:03 +00:00
|
|
|
|
|
|
|
buildInputs = [ openconnect qtwebsockets qtwebengine ];
|
|
|
|
|
|
|
|
patchPhase = ''
|
|
|
|
substituteInPlace GPService/gpservice.h \
|
|
|
|
--replace /usr/local/bin/openconnect ${openconnect}/bin/openconnect;
|
2022-05-31 04:08:14 +01:00
|
|
|
substituteInPlace GPService/CMakeLists.txt \
|
|
|
|
--replace /etc/gpservice $out/etc/gpservice;
|
2020-12-02 15:45:03 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "GlobalProtect VPN client (GUI) for Linux based on OpenConnect that supports SAML auth mode";
|
|
|
|
homepage = "https://github.com/yuezk/GlobalProtect-openconnect";
|
|
|
|
license = licenses.gpl3Only;
|
|
|
|
maintainers = [ maintainers.jerith666 ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|