nixpkgs/pkgs/tools/security/qdigidoc/default.nix

54 lines
1.5 KiB
Nix
Raw Normal View History

{ lib, mkDerivation, fetchgit, fetchurl, cmake, darkhttpd, gettext, makeWrapper, pkg-config
2018-11-08 11:42:01 +00:00
, libdigidocpp, opensc, openldap, openssl, pcsclite, qtbase, qttranslations, qtsvg }:
2016-04-26 21:48:13 +00:00
mkDerivation rec {
pname = "qdigidoc";
2021-06-04 18:43:43 +00:00
version = "4.2.8";
2016-04-26 21:48:13 +00:00
2018-07-05 12:41:15 +00:00
src = fetchgit {
2018-11-08 11:42:01 +00:00
url = "https://github.com/open-eid/DigiDoc4-Client";
2018-07-05 12:41:15 +00:00
rev = "v${version}";
2021-06-04 18:43:43 +00:00
sha256 = "02k2s6l79ssvrksa0midm7bq856llrmq0n40yxwm3j011nvc8vsm";
2018-07-05 12:41:15 +00:00
fetchSubmodules = true;
2016-04-26 21:48:13 +00:00
};
2018-08-10 10:50:22 +00:00
tsl = fetchurl {
url = "https://ec.europa.eu/information_society/policy/esignature/trusted-list/tl-mp.xml";
2021-06-04 18:43:43 +00:00
sha256 = "0klz9blrp0jjhlr9k1i266afp44pqmii1x0y8prk0417ia3fxpli";
2018-08-10 10:50:22 +00:00
};
2021-06-04 18:43:43 +00:00
# Adds explicit imports for QPainterPath, fixed in upstream (https://github.com/open-eid/DigiDoc4-Client/pull/914)
patches = [ ./qt5.15.patch ];
2021-01-17 03:51:22 +00:00
nativeBuildInputs = [ cmake darkhttpd gettext makeWrapper pkg-config ];
2018-08-10 10:50:22 +00:00
postPatch = ''
substituteInPlace client/CMakeLists.txt \
--replace $\{TSL_URL} file://${tsl}
'';
2018-07-05 12:41:15 +00:00
buildInputs = [
libdigidocpp
opensc
openldap
openssl
pcsclite
qtbase
2018-11-08 11:42:01 +00:00
qtsvg
2018-07-05 12:41:15 +00:00
qttranslations
];
2016-04-26 21:48:13 +00:00
postInstall = ''
2018-11-08 11:42:01 +00:00
wrapProgram $out/bin/qdigidoc4 \
2016-04-26 21:48:13 +00:00
--prefix LD_LIBRARY_PATH : ${opensc}/lib/pkcs11/
'';
meta = with lib; {
2018-07-05 12:41:15 +00:00
description = "Qt-based UI for signing and verifying DigiDoc documents";
2020-01-29 08:14:01 +00:00
homepage = "https://www.id.ee/";
2018-07-05 12:41:15 +00:00
license = licenses.lgpl21Plus;
2016-04-26 21:48:13 +00:00
platforms = platforms.linux;
2020-01-29 08:14:01 +00:00
maintainers = with maintainers; [ yegortimoshenko mmahut ];
2016-04-26 21:48:13 +00:00
};
}