1{
2 lib,
3 fetchFromGitHub,
4 fetchpatch,
5 buildDunePackage,
6 logs,
7 zarith,
8}:
9
10buildDunePackage rec {
11 pname = "ocplib-simplex";
12 version = "0.5.1";
13
14 src = fetchFromGitHub {
15 owner = "OCamlPro";
16 repo = pname;
17 rev = "v${version}";
18 hash = "sha256-fLTht+TlyJIsIAsRLmmkFKsnbSeW3BgyAyURFdnGfko=";
19 };
20
21 # Fix tests with dune 3.17.0
22 # See https://github.com/OCamlPro/ocplib-simplex/issues/35
23 patches = (
24 fetchpatch {
25 url = "https://github.com/OCamlPro/ocplib-simplex/commit/456a744bddd397daade7959d4a49cfadafdadd33.patch";
26 hash = "sha256-tQUXOoRGe1AIzHcm6j2MopROxn75OE9YUP+CwcKUbVg=";
27 }
28 );
29
30 propagatedBuildInputs = [
31 logs
32 zarith
33 ];
34
35 doCheck = true;
36
37 meta = {
38 description = "OCaml library implementing a simplex algorithm, in a functional style, for solving systems of linear inequalities";
39 homepage = "https://github.com/OCamlPro-Iguernlala/ocplib-simplex";
40 license = lib.licenses.lgpl21Only;
41 maintainers = [ lib.maintainers.vbgl ];
42 };
43}