diff options
Diffstat (limited to 'pkgs/development/tools/ocaml')
9 files changed, 72 insertions, 25 deletions
diff --git a/pkgs/development/tools/ocaml/camlp5/default.nix b/pkgs/development/tools/ocaml/camlp5/default.nix index 9a69f88c804..7e7c185fbc7 100644 --- a/pkgs/development/tools/ocaml/camlp5/default.nix +++ b/pkgs/development/tools/ocaml/camlp5/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation { - name = "camlp5-7.11"; + name = "camlp5-7.12"; src = fetchzip { - url = "https://github.com/camlp5/camlp5/archive/rel711.tar.gz"; - sha256 = "1s1f9i0r0czxlbnsaz4kvs2ahknmqxcm5ypl75g7scjcbl0an2x4"; + url = "https://github.com/camlp5/camlp5/archive/rel712.tar.gz"; + sha256 = "12ix5g15bys932hyf9gs637iz76m0ji9075d83jfdmx85q30llgf"; }; buildInputs = [ ocaml ]; diff --git a/pkgs/development/tools/ocaml/dune-release/default.nix b/pkgs/development/tools/ocaml/dune-release/default.nix new file mode 100644 index 00000000000..ba8fa4bba6f --- /dev/null +++ b/pkgs/development/tools/ocaml/dune-release/default.nix @@ -0,0 +1,48 @@ +{ lib, buildDunePackage, fetchurl, makeWrapper +, curly, fmt, bos, cmdliner, re, rresult, logs +, odoc, opam-format, opam-core, opam-state +, opam, git, findlib, mercurial, bzip2, gnutar, coreutils +, alcotest, mdx +}: + +# don't include dune as runtime dep, so user can +# choose between dune and dune_2 +let runtimeInputs = [ opam findlib git mercurial bzip2 gnutar coreutils ]; +in buildDunePackage rec { + pname = "dune-release"; + version = "1.3.3"; + + minimumOCamlVersion = "4.06"; + + src = fetchurl { + url = "https://github.com/ocamllabs/${pname}/releases/download/${version}/${pname}-${version}.tbz"; + sha256 = "04qmgvjh1233ri878wi5kifdd1070w5pbfkd8yk3nnqnslz35zlb"; + }; + + nativeBuildInputs = [ makeWrapper ]; + buildInputs = [ curly fmt cmdliner re opam-format opam-state opam-core + rresult logs odoc bos ]; + checkInputs = [ alcotest mdx ]; + doCheck = true; + + useDune2 = true; + + # remove check for curl in PATH, since curly is patched + # to have a fixed path to the binary in nix store + postPatch = '' + sed -i '/must_exist (Cmd\.v "curl"/d' lib/github.ml + ''; + + # tool specific env vars have been deprecated, use PATH + preFixup = '' + wrapProgram $out/bin/dune-release \ + --prefix PATH : "${lib.makeBinPath runtimeInputs}" + ''; + + meta = with lib; { + description = "Release dune packages in opam"; + homepage = "https://github.com/ocamllabs/dune-release"; + license = licenses.isc; + maintainers = with maintainers; [ sternenseemann ]; + }; +} diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/compiler.nix b/pkgs/development/tools/ocaml/js_of_ocaml/compiler.nix index 90e0a7935de..888cc51a99d 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/compiler.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/compiler.nix @@ -1,19 +1,18 @@ -{ lib, fetchFromGitHub, buildDunePackage -, ocaml, findlib, cmdliner, dune, cppo, yojson, ocaml-migrate-parsetree +{ lib, fetchurl, buildDunePackage +, ocaml, findlib, cmdliner, dune_2, cppo, yojson, ocaml-migrate-parsetree }: buildDunePackage rec { pname = "js_of_ocaml-compiler"; - version = "3.5.2"; + version = "3.6.0"; + useDune2 = true; - src = fetchFromGitHub { - owner = "ocsigen"; - repo = "js_of_ocaml"; - rev = version; - sha256 = "1fm855iavljx7rf9hii2qb7ky920zv082d9zlcl504by1bxp1yg8"; + src = fetchurl { + url = "https://github.com/ocsigen/js_of_ocaml/releases/download/${version}/js_of_ocaml-${version}.tbz"; + sha256 = "51eaa89c83ef3168ef270bf7997cbc35a747936d3f51aa6fac58fb0323b4cbb0"; }; - nativeBuildInputs = [ ocaml findlib dune cppo ]; + nativeBuildInputs = [ ocaml findlib dune_2 cppo ]; buildInputs = [ cmdliner ]; configurePlatforms = []; @@ -23,6 +22,6 @@ buildDunePackage rec { description = "Compiler from OCaml bytecode to Javascript"; license = lib.licenses.gpl2; maintainers = [ lib.maintainers.vbgl ]; - inherit (src.meta) homepage; + homepage = "https://ocsigen.org/js_of_ocaml/"; }; } diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/default.nix b/pkgs/development/tools/ocaml/js_of_ocaml/default.nix index 9ca6ca67421..666cda592fb 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/default.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/default.nix @@ -1,4 +1,4 @@ -{ stdenv, ocaml, findlib, dune, js_of_ocaml-compiler +{ stdenv, ocaml, findlib, dune_2, js_of_ocaml-compiler , ocaml-migrate-parsetree, ppx_tools_versioned, uchar }: @@ -8,7 +8,7 @@ stdenv.mkDerivation { inherit (js_of_ocaml-compiler) version src installPhase meta; buildInputs = [ findlib ocaml-migrate-parsetree ppx_tools_versioned ]; - nativeBuildInputs = [ ocaml findlib dune ]; + nativeBuildInputs = [ ocaml findlib dune_2 ]; postPatch = "patchShebangs lib/generate_stubs.sh"; diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/lwt.nix b/pkgs/development/tools/ocaml/js_of_ocaml/lwt.nix index 5c8f4377e8d..2ad8578894f 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/lwt.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/lwt.nix @@ -1,4 +1,4 @@ -{ stdenv, ocaml, findlib, dune, js_of_ocaml-compiler, js_of_ocaml-ppx +{ stdenv, ocaml, findlib, dune_2, js_of_ocaml-compiler, js_of_ocaml-ppx , ocaml-migrate-parsetree, ppx_tools_versioned , js_of_ocaml, ocaml_lwt, lwt_log }: @@ -8,7 +8,7 @@ stdenv.mkDerivation { inherit (js_of_ocaml-compiler) version src installPhase meta; - buildInputs = [ ocaml findlib dune js_of_ocaml-ppx ocaml-migrate-parsetree ppx_tools_versioned ]; + buildInputs = [ ocaml findlib dune_2 js_of_ocaml-ppx ocaml-migrate-parsetree ppx_tools_versioned ]; propagatedBuildInputs = [ js_of_ocaml ocaml_lwt lwt_log ]; diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/ocamlbuild.nix b/pkgs/development/tools/ocaml/js_of_ocaml/ocamlbuild.nix index 344352467e9..50bcd69eb66 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/ocamlbuild.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/ocamlbuild.nix @@ -1,4 +1,4 @@ -{ stdenv, ocaml, findlib, dune, js_of_ocaml-compiler +{ stdenv, ocaml, findlib, dune_2, js_of_ocaml-compiler , ocamlbuild }: @@ -7,7 +7,7 @@ stdenv.mkDerivation { inherit (js_of_ocaml-compiler) version src installPhase meta; - buildInputs = [ ocaml findlib dune ]; + buildInputs = [ ocaml findlib dune_2 ]; propagatedBuildInputs = [ ocamlbuild ]; diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/ppx.nix b/pkgs/development/tools/ocaml/js_of_ocaml/ppx.nix index 3adad22bd9c..69783c7eada 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/ppx.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/ppx.nix @@ -1,4 +1,4 @@ -{ stdenv, ocaml, findlib, dune, js_of_ocaml-compiler +{ stdenv, ocaml, findlib, dune_2, js_of_ocaml-compiler , ocaml-migrate-parsetree, ppx_tools_versioned , js_of_ocaml }: @@ -8,7 +8,7 @@ stdenv.mkDerivation { inherit (js_of_ocaml-compiler) version src installPhase meta; - buildInputs = [ ocaml findlib dune ocaml-migrate-parsetree ppx_tools_versioned js_of_ocaml ]; + buildInputs = [ ocaml findlib dune_2 ocaml-migrate-parsetree ppx_tools_versioned js_of_ocaml ]; buildPhase = "dune build -p js_of_ocaml-ppx"; } diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/ppx_deriving_json.nix b/pkgs/development/tools/ocaml/js_of_ocaml/ppx_deriving_json.nix index 47396829f8a..d3cc4e08787 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/ppx_deriving_json.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/ppx_deriving_json.nix @@ -1,4 +1,4 @@ -{ stdenv, ocaml, findlib, dune, js_of_ocaml-compiler +{ stdenv, ocaml, findlib, dune_2, js_of_ocaml-compiler , js_of_ocaml, ppxlib }: @@ -7,7 +7,7 @@ stdenv.mkDerivation { inherit (js_of_ocaml-compiler) version src installPhase meta; - buildInputs = [ ocaml findlib dune ]; + buildInputs = [ ocaml findlib dune_2 ]; propagatedBuildInputs = [ js_of_ocaml ppxlib ]; diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix b/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix index c39c985183a..fcfeeaf8d99 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix @@ -1,4 +1,4 @@ -{ stdenv, ocaml, findlib, dune, js_of_ocaml-compiler +{ stdenv, ocaml, findlib, dune_2, js_of_ocaml-compiler , js_of_ocaml-ppx, ocaml-migrate-parsetree, ppx_tools_versioned , js_of_ocaml, reactivedata, tyxml }: @@ -8,7 +8,7 @@ stdenv.mkDerivation { inherit (js_of_ocaml-compiler) version src installPhase meta; - buildInputs = [ ocaml findlib dune js_of_ocaml-ppx ocaml-migrate-parsetree ppx_tools_versioned ]; + buildInputs = [ ocaml findlib dune_2 js_of_ocaml-ppx ocaml-migrate-parsetree ppx_tools_versioned ]; propagatedBuildInputs = [ js_of_ocaml reactivedata tyxml ]; |