a19cd4ffb1
This reverts commit65a333600d. This wasn't tested for correctness with something like fodwatch [0], and should not have been (self-)merged so quickly, especially without further review. It also resulted in the breakage of at least one package [1] (and that's the one we know of and was caught). A few packages that were updated in between this commit and this revert were not reverted back to using `rev`, but other than that, this is a 1:1 revert. [0]: https://codeberg.org/raphaelr/fodwatch [1]: https://github.com/NixOS/nixpkgs/pull/396904 /758551e458
50 lines
983 B
Nix
50 lines
983 B
Nix
{
|
|
stdenv,
|
|
lib,
|
|
fetchFromGitHub,
|
|
ocaml,
|
|
findlib,
|
|
ocamlbuild,
|
|
opaline,
|
|
}:
|
|
|
|
if lib.versionOlder ocaml.version "4.07" then
|
|
throw "lua-ml is not available for OCaml ${ocaml.version}"
|
|
else
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "lua-ml";
|
|
name = "ocaml${ocaml.version}-${pname}-${version}";
|
|
version = "0.9.2";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "lindig";
|
|
repo = pname;
|
|
rev = version;
|
|
sha256 = "sha256-xkjsjKD89W7Y5XK8kfL/ZErYKS14z0u0QCARN0DbTC8=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
opaline
|
|
ocaml
|
|
findlib
|
|
ocamlbuild
|
|
];
|
|
|
|
strictDeps = true;
|
|
|
|
buildFlags = [ "lib" ];
|
|
|
|
installPhase = ''
|
|
opaline -prefix $out -libdir $OCAMLFIND_DESTDIR
|
|
'';
|
|
|
|
meta = {
|
|
description = "Embeddable Lua 2.5 interpreter implemented in OCaml";
|
|
inherit (src.meta) homepage;
|
|
inherit (ocaml.meta) platforms;
|
|
license = lib.licenses.bsd2;
|
|
maintainers = [ lib.maintainers.vbgl ];
|
|
};
|
|
}
|