mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 23:03:40 +01:00
Merge pull request #20404 from vbgl/alcotest-0.7.0
ocamlPackages.alcotest: 0.4.5 -> 0.7.2
This commit is contained in:
commit
376973a1bb
5 changed files with 44 additions and 21 deletions
|
@ -1,15 +1,21 @@
|
|||
{ stdenv, buildOcaml, fetchzip, cmdliner, stringext }:
|
||||
{ stdenv, fetchzip, ocaml, findlib, ocamlbuild, topkg, opam, cmdliner, astring, fmt, result }:
|
||||
|
||||
buildOcaml rec {
|
||||
name = "alcotest";
|
||||
version = "0.4.5";
|
||||
stdenv.mkDerivation rec {
|
||||
name = "ocaml${ocaml.version}-alcotest-${version}";
|
||||
version = "0.7.2";
|
||||
|
||||
src = fetchzip {
|
||||
url = "https://github.com/mirage/alcotest/archive/${version}.tar.gz";
|
||||
sha256 = "1wcn9hkjf4cbnrz99w940qfjpi0lvd8v63yxwpnafkff871dwk6k";
|
||||
sha256 = "1qgsz2zz5ky6s5pf3j3shc4fjc36rqnjflk8x0wl1fcpvvkr52md";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ cmdliner stringext ];
|
||||
buildInputs = [ ocaml findlib ocamlbuild opam topkg ];
|
||||
|
||||
propagatedBuildInputs = [ cmdliner astring fmt result ];
|
||||
|
||||
inherit (topkg) buildPhase installPhase;
|
||||
|
||||
createFindlibDestdir = true;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = https://github.com/mirage/alcotest;
|
||||
|
|
26
pkgs/development/ocaml-modules/fmt/default.nix
Normal file
26
pkgs/development/ocaml-modules/fmt/default.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, opam, topkg, cmdliner }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "ocaml${ocaml.version}-fmt-0.8.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = http://erratique.ch/software/fmt/releases/fmt-0.8.0.tbz;
|
||||
sha256 = "16y7ibndnairb53j8a6qgipyqwjxncn4pl9jiw5bxjfjm59108px";
|
||||
};
|
||||
|
||||
unpackCmd = "tar xjf $src";
|
||||
|
||||
buildInputs = [ ocaml findlib ocamlbuild opam topkg cmdliner ];
|
||||
|
||||
inherit (topkg) buildPhase installPhase;
|
||||
|
||||
createFindlibDestdir = true;
|
||||
|
||||
meta = {
|
||||
homepage = http://erratique.ch/software/fmt;
|
||||
license = stdenv.lib.licenses.isc;
|
||||
description = "OCaml Format pretty-printer combinators";
|
||||
inherit (ocaml.meta) platforms;
|
||||
maintainers = [ stdenv.lib.maintainers.vbgl ];
|
||||
};
|
||||
}
|
|
@ -1,9 +1,7 @@
|
|||
{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, result, opam }:
|
||||
|
||||
let ocaml-version = stdenv.lib.getVersion ocaml; in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "ocaml${ocaml-version}-topkg-${version}";
|
||||
name = "ocaml${ocaml.version}-topkg-${version}";
|
||||
version = "0.7.8";
|
||||
|
||||
src = fetchurl {
|
||||
|
@ -16,12 +14,9 @@ stdenv.mkDerivation rec {
|
|||
propagatedBuildInputs = [ result ];
|
||||
|
||||
unpackCmd = "tar xjf ${src}";
|
||||
buildPhase = "ocaml -I ${findlib}/lib/ocaml/${ocaml-version}/site-lib/ pkg/pkg.ml build";
|
||||
buildPhase = "ocaml -I ${findlib}/lib/ocaml/${ocaml.version}/site-lib/ pkg/pkg.ml build";
|
||||
createFindlibDestdir = true;
|
||||
installPhase = ''
|
||||
opam-installer --script --prefix=$out topkg.install | sh
|
||||
mv $out/lib/topkg $out/lib/ocaml/${ocaml-version}/site-lib/
|
||||
'';
|
||||
installPhase = "opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR";
|
||||
|
||||
meta = {
|
||||
homepage = http://erratique.ch/software/topkg;
|
||||
|
|
|
@ -19,13 +19,7 @@ stdenv.mkDerivation rec {
|
|||
|
||||
unpackCmd = "tar xjf $src";
|
||||
|
||||
inherit (topkg) buildPhase;
|
||||
|
||||
installPhase = ''
|
||||
opam-installer --script --prefix=$out ${pname}.install > install.sh
|
||||
sh install.sh
|
||||
ln -s $out/lib/${pname} $out/lib/ocaml/${ocaml.version}/site-lib/
|
||||
'';
|
||||
inherit (topkg) buildPhase installPhase;
|
||||
|
||||
propagatedBuildInputs = [ xmlm ];
|
||||
|
||||
|
|
|
@ -176,6 +176,8 @@ let
|
|||
|
||||
fix = callPackage ../development/ocaml-modules/fix { };
|
||||
|
||||
fmt = callPackage ../development/ocaml-modules/fmt { };
|
||||
|
||||
fontconfig = callPackage ../development/ocaml-modules/fontconfig {
|
||||
inherit (pkgs) fontconfig;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue