summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorJörg Thalheim <Mic92@users.noreply.github.com>2018-07-21 15:38:37 +0100
committerGitHub <noreply@github.com>2018-07-21 15:38:37 +0100
commite85db6863a546cfdde0150f03ed0d2db28992575 (patch)
tree8fc545a51a27d8d7bbc7675c4fc24d93e258fcb1 /pkgs
parent1a969d13d9410e49896b47ab40b7bfbe8be7406c (diff)
parentacd100e4b6b86ea7d80554b83879160059a66462 (diff)
downloadnixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.tar
nixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.tar.gz
nixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.tar.bz2
nixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.tar.lz
nixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.tar.xz
nixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.tar.zst
nixpkgs-e85db6863a546cfdde0150f03ed0d2db28992575.zip
Merge pull request #43877 from vbgl/ocaml-ppx_blob-0.4.0
ocamlPackages.ppx_blob: 0.2 -> 0.4.0
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/development/ocaml-modules/ppx_blob/default.nix25
1 files changed, 18 insertions, 7 deletions
diff --git a/pkgs/development/ocaml-modules/ppx_blob/default.nix b/pkgs/development/ocaml-modules/ppx_blob/default.nix
index 9d5f4f4e669..45dd73d4a32 100644
--- a/pkgs/development/ocaml-modules/ppx_blob/default.nix
+++ b/pkgs/development/ocaml-modules/ppx_blob/default.nix
@@ -1,15 +1,26 @@
-{ stdenv, buildOcaml, fetchurl, ppx_tools }:
+{ stdenv, fetchurl, ocaml, findlib, jbuilder, alcotest
+, ocaml-migrate-parsetree
+}:
 
-buildOcaml rec {
-  name = "ppx_blob";
-  version = "0.2";
+stdenv.mkDerivation rec {
+  name = "ocaml${ocaml.version}-ppx_blob-${version}";
+  version = "0.4.0";
 
   src = fetchurl {
-    url = "https://github.com/johnwhitington/ppx_blob/archive/v${version}.tar.gz";
-    sha256 = "0kvqfm47f4xbgz0cl7ayz29myyb24xskm35svqrgakjq12nkpsss";
+    url = "https://github.com/johnwhitington/ppx_blob/releases/download/${version}/ppx_blob-${version}.tbz";
+    sha256 = "1xmslk1mwdzhy1bydgsjlcb7h544c39hvxa8lywp8w72gaggjl16";
   };
 
-  buildInputs = [ ppx_tools ];
+  unpackCmd = "tar xjf $curSrc";
+
+  buildInputs = [ ocaml findlib jbuilder alcotest ocaml-migrate-parsetree ];
+
+  buildPhase = "dune build -p ppx_blob";
+
+  doCheck = true;
+  checkPhase = "dune runtest -p ppx_blob";
+
+  inherit (jbuilder) installPhase;
 
   meta = with stdenv.lib; {
     homepage = https://github.com/johnwhitington/ppx_blob;