Files
nixpkgs/pkgs/development/ocaml-modules/wasm/default.nix
2026-08-11 11:09:41 +02:00

37 lines
772 B
Nix

{
lib,
fetchFromGitHub,
menhir,
buildDunePackage,
}:
buildDunePackage (finalAttrs: {
pname = "wasm";
version = "2.0.2";
minimalOCamlVersion = "4.12";
src = fetchFromGitHub {
owner = "WebAssembly";
repo = "spec";
tag = "opam-${finalAttrs.version}";
hash = "sha256-RbVGW6laC3trP6IhtA2tLrAYVbx0Oucox9FgoEvs6LQ=";
};
postUnpack = ''
cd "$sourceRoot/interpreter"
export sourceRoot=$PWD
'';
nativeBuildInputs = [
menhir
];
meta = {
description = "Library to read and write WebAssembly (Wasm) files and manipulate their AST";
mainProgram = "wasm";
license = lib.licenses.asl20;
maintainers = [ lib.maintainers.vbgl ];
homepage = "https://github.com/WebAssembly/spec/tree/main/interpreter";
};
})