From c8d1798e6fded4ec8a69083f19e47462e69be8fc Mon Sep 17 00:00:00 2001 From: Varun Narravula Date: Sat, 21 Jun 2025 19:38:08 -0700 Subject: [PATCH] wkg: init at 0.11.0 --- pkgs/by-name/wk/wkg/package.nix | 37 +++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 pkgs/by-name/wk/wkg/package.nix diff --git a/pkgs/by-name/wk/wkg/package.nix b/pkgs/by-name/wk/wkg/package.nix new file mode 100644 index 000000000000..c86a691dc165 --- /dev/null +++ b/pkgs/by-name/wk/wkg/package.nix @@ -0,0 +1,37 @@ +{ + lib, + rustPlatform, + fetchFromGitHub, + versionCheckHook, + nix-update-script, +}: + +rustPlatform.buildRustPackage (finalAttrs: { + pname = "wkg"; + version = "0.11.0"; + src = fetchFromGitHub { + owner = "bytecodealliance"; + repo = "wasm-pkg-tools"; + tag = "v${finalAttrs.version}"; + hash = "sha256-l8ArzujFirquSKMDkcoP8KukLFCRB7U8BejzMGUD59Y="; + }; + + cargoHash = "sha256-ngVnF2eLZfa4ziliAaJOmu5YbnetEovH66kWXp2w1gY="; + + # A large number of tests require Internet access in order to function. + doCheck = false; + + nativeInstallCheckInputs = [ versionCheckHook ]; + doInstallCheck = true; + versionCheckProgramArg = "--version"; + + passthru.updateScript = nix-update-script { }; + + meta = { + description = "Tools to package up WASM Components"; + homepage = "https://github.com/bytecodealliance/wasm-pkg-tools"; + license = lib.licenses.asl20; + maintainers = with lib.maintainers; [ water-sucks ]; + mainProgram = "wkg"; + }; +})