summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/semver/default.nix
blob: 15bd02f186872e0fe79d240083d3125481db6f65 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
{ stdenv, lib, fetchzip, ocaml, findlib, ocamlbuild }:

lib.throwIfNot (lib.versionAtLeast ocaml.version "4.02")
  "semver is not available on OCaml older than 4.02"

stdenv.mkDerivation rec {
  pname = "ocaml${ocaml.version}-semver";
  version = "0.1.0";
  src = fetchzip {
    url = "https://github.com/rgrinberg/ocaml-semver/archive/v${version}.tar.gz";
    sha256 = "sha256-0BzeuVTpuRIQjadGg08hTvMzZtKCl2utW2YK269oETk=";
  };

  nativeBuildInputs = [
    ocaml
    findlib
    ocamlbuild
  ];

  strictDeps = true;
  createFindlibDestdir = true;

  meta = {
    homepage = "https://github.com/rgrinberg/ocaml-semver";
    description = "Semantic versioning module";
    platforms = ocaml.meta.platforms;
    license = lib.licenses.bsd3;
    maintainers = [ lib.maintainers.ulrikstrid ];
  };
}