1{ lib, buildDunePackage, fetchurl
2, ppx_sexp_conv
3, mirage-crypto, mirage-crypto-ec, mirage-crypto-rng, mirage-crypto-pk
4, x509, cstruct, cstruct-unix, cstruct-sexp, sexplib, eqaf-cstruct
5, mtime, logs, fmt, cmdliner, base64
6, zarith
7}:
8
9buildDunePackage rec {
10 pname = "awa";
11 version = "0.3.1";
12
13 minimalOCamlVersion = "4.10";
14
15 src = fetchurl {
16 url = "https://github.com/mirage/awa-ssh/releases/download/v${version}/awa-${version}.tbz";
17 hash = "sha256-VejHFn07B/zoEG4LjLaen24ig9kAXtERl/pRo6UZCQk=";
18 };
19
20 postPatch = ''
21 substituteInPlace lib/dune --replace-warn eqaf.cstruct eqaf-cstruct
22 '';
23
24 propagatedBuildInputs = [
25 mirage-crypto mirage-crypto-ec mirage-crypto-rng mirage-crypto-pk x509
26 cstruct cstruct-sexp sexplib mtime
27 logs base64 zarith
28 ppx_sexp_conv eqaf-cstruct
29 ];
30
31 doCheck = true;
32 checkInputs = [ cstruct-unix cmdliner fmt ];
33
34 meta = with lib; {
35 description = "SSH implementation in OCaml";
36 homepage = "https://github.com/mirage/awa-ssh";
37 changelog = "https://github.com/mirage/awa-ssh/raw/v${version}/CHANGES.md";
38 license = licenses.isc;
39 maintainers = [ maintainers.sternenseemann ];
40 };
41}