From 000f19ff08cfaf6ce89b136ea986fde64f750555 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 27 Nov 2019 04:20:00 -0500 Subject: [PATCH 01/12] ocamlPackages.cppo: 1.6.5 -> 1.6.6 --- pkgs/development/tools/ocaml/cppo/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/tools/ocaml/cppo/default.nix b/pkgs/development/tools/ocaml/cppo/default.nix index 27c608fc719..8aa446081b7 100644 --- a/pkgs/development/tools/ocaml/cppo/default.nix +++ b/pkgs/development/tools/ocaml/cppo/default.nix @@ -7,8 +7,8 @@ assert stdenv.lib.versionAtLeast ocaml.version "3.12"; let param = if stdenv.lib.versionAtLeast ocaml.version "4.02" then { - version = "1.6.5"; - sha256 = "03c0amszy28shinvz61hm340jz446zz5763a1pdqlza36kwcj0p0"; + version = "1.6.6"; + sha256 = "1smcc0l6fh2n0y6bp96c69j5nw755jja99w0b206wx3yb2m4w2hs"; buildInputs = [ dune ]; extra = { inherit (dune) installPhase; @@ -31,7 +31,7 @@ stdenv.mkDerivation ({ name = "${pname}-${param.version}"; src = fetchFromGitHub { - owner = "mjambon"; + owner = "ocaml-community"; repo = pname; rev = "v${param.version}"; inherit (param) sha256; From c44fdd592f02b2e8155d73baa4ec41b7ea39d3a7 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 27 Nov 2019 04:21:00 -0500 Subject: [PATCH 02/12] ocamlPackages.dtoa: 0.3.1 -> 0.3.2 --- pkgs/development/ocaml-modules/dtoa/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/ocaml-modules/dtoa/default.nix b/pkgs/development/ocaml-modules/dtoa/default.nix index 87d9ac7a324..16a9f96798c 100644 --- a/pkgs/development/ocaml-modules/dtoa/default.nix +++ b/pkgs/development/ocaml-modules/dtoa/default.nix @@ -2,13 +2,13 @@ buildDunePackage rec { pname = "dtoa"; - version = "0.3.1"; + version = "0.3.2"; minimumOCamlVersion = "4.02"; src = fetchurl { - url = "https://github.com/flowtype/ocaml-${pname}/releases/download/v${version}/${pname}-${version}.tbz"; - sha256 = "0rzysj07z2q6gk0yhjxnjnba01vmdb9x32wwna10qk3rrb8r2pnn"; + url = "https://github.com/flowtype/ocaml-${pname}/releases/download/v${version}/${pname}-v${version}.tbz"; + sha256 = "0zkhn0rdq82g6gamsv6nkx6i44s8104nh6jg5xydazl9jl1704xn"; }; hardeningDisable = stdenv.lib.optional stdenv.isDarwin "strictoverflow"; From ae7a96b10f626694d04736bcd56af430936c3968 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 27 Nov 2019 04:22:00 -0500 Subject: [PATCH 03/12] ocamlPackages.wtf8: 1.0.1 -> 1.0.2 --- pkgs/development/ocaml-modules/wtf8/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/ocaml-modules/wtf8/default.nix b/pkgs/development/ocaml-modules/wtf8/default.nix index 4c820d13808..420cb30bb94 100644 --- a/pkgs/development/ocaml-modules/wtf8/default.nix +++ b/pkgs/development/ocaml-modules/wtf8/default.nix @@ -2,13 +2,13 @@ buildDunePackage rec { pname = "wtf8"; - version = "1.0.1"; + version = "1.0.2"; minimumOCamlVersion = "4.02"; src = fetchurl { - url = "https://github.com/flowtype/ocaml-${pname}/releases/download/v${version}/${pname}-${version}.tbz"; - sha256 = "1msg3vycd3k8qqj61sc23qks541cxpb97vrnrvrhjnqxsqnh6ygq"; + url = "https://github.com/flowtype/ocaml-${pname}/releases/download/v${version}/${pname}-v${version}.tbz"; + sha256 = "09ygcxxd5warkdzz17rgpidrd0pg14cy2svvnvy1hna080lzg7vp"; }; meta = with stdenv.lib; { From 1cda2f99924a9cc495d3c53e0075d43bd38e3c7a Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 27 Nov 2019 04:23:00 -0500 Subject: [PATCH 04/12] ocamlPackages.ppx_gen_rec: 1.0.0 -> 1.1.0 --- pkgs/development/ocaml-modules/ppx_gen_rec/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix b/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix index 5d45ee90c2e..b09ff9c7f22 100644 --- a/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix +++ b/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix @@ -2,13 +2,13 @@ buildDunePackage rec { pname = "ppx_gen_rec"; - version = "1.0.0"; + version = "1.1.0"; minimumOCamlVersion = "4.01"; src = fetchurl { - url = "https://github.com/flowtype/ocaml-${pname}/releases/download/v${version}/${pname}-${version}.tbz"; - sha256 = "0qy0wa3rd5yh1612jijadi1yddfslpsmmmf69phi2dhr3vmkhza7"; + url = "https://github.com/flowtype/ocaml-${pname}/releases/download/v${version}/${pname}-v${version}.tbz"; + sha256 = "0fwi4bknq8h9zgpsarjvnzdm9bm8qlyyw0lz30pihg02aiiljqbh"; }; buildInputs = [ ocaml-migrate-parsetree ]; From 5458a38e61228fe5f1aa12886ed67b467103e78b Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 27 Nov 2019 04:24:00 -0500 Subject: [PATCH 05/12] ocamlPackages.biniou: 1.2.0 -> 1.2.1 --- pkgs/development/ocaml-modules/biniou/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/development/ocaml-modules/biniou/default.nix b/pkgs/development/ocaml-modules/biniou/default.nix index 8f1917d6873..b97c78a399b 100644 --- a/pkgs/development/ocaml-modules/biniou/default.nix +++ b/pkgs/development/ocaml-modules/biniou/default.nix @@ -2,13 +2,13 @@ buildDunePackage rec { pname = "biniou"; - version = "1.2.0"; + version = "1.2.1"; src = fetchFromGitHub { - owner = "mjambon"; + owner = "ocaml-community"; repo = pname; - rev = "v${version}"; - sha256 = "0mjpgwyfq2b2izjw0flmlpvdjgqpq8shs89hxj1np2r50csr8dcb"; + rev = version; + sha256 = "0x2kiy809n1j0yf32l7hj102y628jp5jdrkbi3z7ld8jq04h1790"; }; propagatedBuildInputs = [ easy-format ]; From 48d7d3afed16e8fdccef88e7e255567f443131b1 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:20:00 -0500 Subject: [PATCH 06/12] ocamlPackages.stdint: 0.5.1 -> 0.6.0 --- .../ocaml-modules/stdint/default.nix | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/pkgs/development/ocaml-modules/stdint/default.nix b/pkgs/development/ocaml-modules/stdint/default.nix index 0b8f83a1ea3..a36d84ffa3a 100644 --- a/pkgs/development/ocaml-modules/stdint/default.nix +++ b/pkgs/development/ocaml-modules/stdint/default.nix @@ -1,26 +1,20 @@ -{ stdenv, fetchFromGitHub, ocaml, findlib, dune }: +{ stdenv, fetchFromGitHub, buildDunePackage }: -stdenv.mkDerivation rec { +buildDunePackage rec { pname = "stdint"; - name = "ocaml${ocaml.version}-${pname}-${version}"; - version = "0.5.1"; + version = "0.6.0"; + src = fetchFromGitHub { owner = "andrenth"; repo = "ocaml-stdint"; rev = version; - sha256 = "0z2z77m3clna9m9k0f8fd1400cdlglvy1kr893qs3907b3v0c057"; + sha256 = "19ccxs0vij81vyc9nqc9kbr154ralb9dgc2y2nr71a5xkx6xfn0y"; }; - buildInputs = [ ocaml findlib dune ]; - - buildPhase = "dune build -p ${pname}"; - inherit (dune) installPhase; - meta = { description = "Various signed and unsigned integers for OCaml"; + homepage = "https://github.com/andrenth/ocaml-stdint"; license = stdenv.lib.licenses.mit; maintainers = [ stdenv.lib.maintainers.gebner ]; - inherit (src.meta) homepage; - inherit (ocaml.meta) platforms; }; } From 90b15631714f45dd4b7f9fa192e3bcdd8d07af5a Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:21:00 -0500 Subject: [PATCH 07/12] ocamlPackages.rope: 0.6.1 -> 0.6.2 --- pkgs/development/ocaml-modules/rope/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/development/ocaml-modules/rope/default.nix b/pkgs/development/ocaml-modules/rope/default.nix index b797af0a702..0223d4f59ff 100644 --- a/pkgs/development/ocaml-modules/rope/default.nix +++ b/pkgs/development/ocaml-modules/rope/default.nix @@ -2,10 +2,10 @@ let param = if stdenv.lib.versionAtLeast ocaml.version "4.03" - then { - version = "0.6.1"; - url = " https://github.com/Chris00/ocaml-rope/releases/download/0.6.1/rope-0.6.1.tbz"; - sha256 = "1zqh28jz1zjb0l354wi1046qpkwmk582ssz0gsqh6d44wpspdxk2"; + then rec { + version = "0.6.2"; + url = "https://github.com/Chris00/ocaml-rope/releases/download/${version}/rope-${version}.tbz"; + sha256 = "15cvfa0s1vjx7gjd07d3fkznilishqf4z4h2q5f20wm9ysjh2h2i"; buildInputs = [ dune ]; extra = { buildPhase = "dune build -p rope"; From d07842589d3f8fdfbc8e6170a4673bcbc6bffa6e Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:22:00 -0500 Subject: [PATCH 08/12] ocamlPackages.ocp-index: use buildDunePackage --- .../tools/ocaml/ocp-index/default.nix | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/pkgs/development/tools/ocaml/ocp-index/default.nix b/pkgs/development/tools/ocaml/ocp-index/default.nix index 79be6a8170c..9ea01a8dca7 100644 --- a/pkgs/development/tools/ocaml/ocp-index/default.nix +++ b/pkgs/development/tools/ocaml/ocp-index/default.nix @@ -1,29 +1,24 @@ -{ stdenv, fetchFromGitHub, ocaml, findlib, dune, ocp-build, ocp-indent, cmdliner, re }: - -stdenv.mkDerivation rec { +{ stdenv, fetchFromGitHub, buildDunePackage, ocp-build, ocp-indent, cmdliner, re, }: +buildDunePackage rec { + pname = "ocp-index"; version = "1.1.9"; - name = "ocaml${ocaml.version}-ocp-index-${version}"; src = fetchFromGitHub { owner = "OCamlPro"; - repo = "ocp-index"; + repo = pname; rev = version; sha256 = "0dq1kap16xfajc6gg9hbiadax782winpvxnr3dkm2ncznnxds37p"; }; - buildInputs = [ ocaml findlib dune ocp-build cmdliner re ]; + buildInputs = [ ocp-build cmdliner re ]; + propagatedBuildInputs = [ ocp-indent ]; - buildPhase = "dune build -p ocp-index"; - - inherit (dune) installPhase; - meta = { homepage = http://typerex.ocamlpro.com/ocp-index.html; description = "A simple and light-weight documentation extractor for OCaml"; license = stdenv.lib.licenses.lgpl3; - platforms = ocaml.meta.platforms or []; maintainers = with stdenv.lib.maintainers; [ vbgl ]; }; } From 86d06ee9683bff1821a58a53a70fb7bceff15c51 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:23:00 -0500 Subject: [PATCH 09/12] ocamlPackages.utop: use buildDunePackage --- pkgs/development/tools/ocaml/utop/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/development/tools/ocaml/utop/default.nix b/pkgs/development/tools/ocaml/utop/default.nix index f154b94ae33..c0aa1d16374 100644 --- a/pkgs/development/tools/ocaml/utop/default.nix +++ b/pkgs/development/tools/ocaml/utop/default.nix @@ -1,12 +1,12 @@ { stdenv, fetchurl, ocaml, findlib, dune -, lambdaTerm, cppo, makeWrapper +, lambdaTerm, cppo, makeWrapper, buildDunePackage }: if !stdenv.lib.versionAtLeast ocaml.version "4.03" then throw "utop is not available for OCaml ${ocaml.version}" else -stdenv.mkDerivation rec { +buildDunePackage rec { pname = "utop"; version = "2.4.2"; @@ -16,12 +16,10 @@ stdenv.mkDerivation rec { }; nativeBuildInputs = [ makeWrapper ]; - buildInputs = [ ocaml findlib cppo dune ]; + buildInputs = [ cppo ]; propagatedBuildInputs = [ lambdaTerm ]; - inherit (dune) installPhase; - postFixup = let path = "etc/utop/env"; From 1b1f9584e587978d005ce7f170d381a04778419c Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:24:00 -0500 Subject: [PATCH 10/12] dune_2: init at 2.1.0 Changelog: - https://github.com/ocaml/dune/releases/tag/2.0.0 - https://github.com/ocaml/dune/releases/tag/2.0.1 - https://github.com/ocaml/dune/releases/tag/2.1.0 --- pkgs/development/tools/ocaml/dune/2.nix | 31 +++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 +- pkgs/top-level/ocaml-packages.nix | 4 ++++ 3 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 pkgs/development/tools/ocaml/dune/2.nix diff --git a/pkgs/development/tools/ocaml/dune/2.nix b/pkgs/development/tools/ocaml/dune/2.nix new file mode 100644 index 00000000000..3260068edcd --- /dev/null +++ b/pkgs/development/tools/ocaml/dune/2.nix @@ -0,0 +1,31 @@ +{ stdenv, fetchurl, ocaml, findlib }: + +if stdenv.lib.versionOlder ocaml.version "4.07" +then throw "dune is not available for OCaml ${ocaml.version}" +else + +stdenv.mkDerivation rec { + pname = "dune"; + version = "2.1.0"; + + src = fetchurl { + url = "https://github.com/ocaml/dune/releases/download/${version}/dune-${version}.tbz"; + sha256 = "1hf8c0djx2v1jpjba0z096gw6qdr0igsljrf0qh0ggphg9valsmj"; + }; + + buildInputs = [ ocaml findlib ]; + + buildFlags = "release"; + + dontAddPrefix = true; + + installFlags = [ "PREFIX=${placeholder "out"}" "LIBDIR=$(OCAMLFIND_DESTDIR)" ]; + + meta = { + homepage = "https://dune.build/"; + description = "A composable build system"; + maintainers = [ stdenv.lib.maintainers.vbgl stdenv.lib.maintainers.marsam ]; + license = stdenv.lib.licenses.mit; + inherit (ocaml.meta) platforms; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d71a039199c..508cd842291 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1614,7 +1614,7 @@ in dua = callPackage ../tools/misc/dua { }; - inherit (ocamlPackages) dune; + inherit (ocamlPackages) dune dune_2; duperemove = callPackage ../tools/filesystems/duperemove { }; diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index f46d953fb48..570caccc0b8 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -16,6 +16,8 @@ let buildDunePackage = callPackage ../build-support/ocaml/dune.nix {}; + buildDune2Package = buildDunePackage.override { dune = dune_2; }; + alcotest = callPackage ../development/ocaml-modules/alcotest {}; angstrom = callPackage ../development/ocaml-modules/angstrom { }; @@ -237,6 +239,8 @@ let dune = callPackage ../development/tools/ocaml/dune { }; + dune_2 = callPackage ../development/tools/ocaml/dune/2.nix { }; + earley = callPackage ../development/ocaml-modules/earley { }; earlybird = callPackage ../development/ocaml-modules/earlybird { }; From 6b9504955ff64a355d2c83469ba4f8d5f1520470 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:25:00 -0500 Subject: [PATCH 11/12] ocamlPackages.dune-private-libs: init at 2.1.0 --- .../ocaml-modules/dune-private-libs/default.nix | 15 +++++++++++++++ pkgs/top-level/ocaml-packages.nix | 2 ++ 2 files changed, 17 insertions(+) create mode 100644 pkgs/development/ocaml-modules/dune-private-libs/default.nix diff --git a/pkgs/development/ocaml-modules/dune-private-libs/default.nix b/pkgs/development/ocaml-modules/dune-private-libs/default.nix new file mode 100644 index 00000000000..1c3503f11a1 --- /dev/null +++ b/pkgs/development/ocaml-modules/dune-private-libs/default.nix @@ -0,0 +1,15 @@ +{ lib, buildDunePackage, dune_2 }: + +buildDunePackage rec { + pname = "dune-private-libs"; + + inherit (dune_2) src version; + + dontAddPrefix = true; + + meta = with lib; { + description = "Private libraries of Dune"; + maintainers = [ maintainers.marsam ]; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index 570caccc0b8..d21aec00195 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -241,6 +241,8 @@ let dune_2 = callPackage ../development/tools/ocaml/dune/2.nix { }; + dune-private-libs = callPackage ../development/ocaml-modules/dune-private-libs { buildDunePackage = buildDune2Package; }; + earley = callPackage ../development/ocaml-modules/earley { }; earlybird = callPackage ../development/ocaml-modules/earlybird { }; From 5eb4a2352ef8907913d62555c290e97c67726f08 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Wed, 18 Dec 2019 04:26:00 -0500 Subject: [PATCH 12/12] ocamlPackages.dune-configurator: init at 2.1.0 --- .../ocaml-modules/dune-configurator/default.nix | 17 +++++++++++++++++ pkgs/top-level/ocaml-packages.nix | 2 ++ 2 files changed, 19 insertions(+) create mode 100644 pkgs/development/ocaml-modules/dune-configurator/default.nix diff --git a/pkgs/development/ocaml-modules/dune-configurator/default.nix b/pkgs/development/ocaml-modules/dune-configurator/default.nix new file mode 100644 index 00000000000..d84c21565db --- /dev/null +++ b/pkgs/development/ocaml-modules/dune-configurator/default.nix @@ -0,0 +1,17 @@ +{ lib, buildDunePackage, dune_2, dune-private-libs }: + +buildDunePackage rec { + pname = "dune-configurator"; + + inherit (dune_2) src version; + + dontAddPrefix = true; + + propagatedBuildInputs = [ dune-private-libs ]; + + meta = with lib; { + description = "Helper library for gathering system configuration"; + maintainers = [ maintainers.marsam ]; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index d21aec00195..786c34ab3ab 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -241,6 +241,8 @@ let dune_2 = callPackage ../development/tools/ocaml/dune/2.nix { }; + dune-configurator = callPackage ../development/ocaml-modules/dune-configurator { buildDunePackage = buildDune2Package; }; + dune-private-libs = callPackage ../development/ocaml-modules/dune-private-libs { buildDunePackage = buildDune2Package; }; earley = callPackage ../development/ocaml-modules/earley { };