depot/third_party/nixpkgs/pkgs/development/tools/wasm-bindgen-cli/default.nix
Default email c7cb07f092 Project import generated by Copybara.
GitOrigin-RevId: 1536926ef5621b09bba54035ae2bb6d806d72ac8
2024-02-29 21:09:43 +01:00

42 lines
1 KiB
Nix

{ lib
, rustPlatform
, fetchCrate
, nix-update-script
, nodejs
, pkg-config
, openssl
, stdenv
, curl
, Security
, version ? "0.2.91"
, hash ? "sha256-f/RK6s12ItqKJWJlA2WtOXtwX4Y0qa8bq/JHlLTAS3c="
, cargoHash ? "sha256-3vxVI0BhNz/9m59b+P2YEIrwGwlp7K3pyPKt4VqQuHE="
}:
rustPlatform.buildRustPackage rec {
pname = "wasm-bindgen-cli";
inherit version hash cargoHash;
src = fetchCrate {
inherit pname version hash;
};
nativeBuildInputs = [ pkg-config ];
buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ curl Security ];
nativeCheckInputs = [ nodejs ];
# tests require it to be ran in the wasm-bindgen monorepo
doCheck = false;
meta = with lib; {
homepage = "https://rustwasm.github.io/docs/wasm-bindgen/";
license = with licenses; [ asl20 /* or */ mit ];
description = "Facilitating high-level interactions between wasm modules and JavaScript";
maintainers = with maintainers; [ rizary ];
mainProgram = "wasm-bindgen";
};
passthru.updateScript = nix-update-script { };
}