Merge pull request #241171 from figsoda/wazero

This commit is contained in:
figsoda 2023-07-04 11:39:42 -04:00 committed by GitHub
commit 9501d23683
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 52 additions and 0 deletions

View File

@ -0,0 +1,50 @@
{ lib
, buildGoModule
, fetchFromGitHub
, testers
, wazero
}:
buildGoModule rec {
pname = "wazero";
version = "1.2.1";
src = fetchFromGitHub {
owner = "tetratelabs";
repo = "wazero";
rev = "v${version}";
hash = "sha256-u9VsSV+pdyBnAmT910SOL1I8tpDCYAWFTfWkWTNWQVs=";
};
vendorHash = null;
subPackages = [
"cmd/wazero"
];
ldflags = [
"-s"
"-w"
"-X=github.com/tetratelabs/wazero/internal/version.version=${version}"
];
checkFlags = [
# fails when version is specified
"-skip=TestCompile|TestRun"
];
passthru.tests = {
version = testers.testVersion {
package = wazero;
command = "wazero version";
};
};
meta = with lib; {
description = "A zero dependency WebAssembly runtime for Go developers";
homepage = "https://github.com/tetratelabs/wazero";
changelog = "https://github.com/tetratelabs/wazero/releases/tag/${src.rev}";
license = licenses.asl20;
maintainers = with maintainers; [ figsoda ];
};
}

View File

@ -17061,6 +17061,8 @@ with pkgs;
vyper = with python3Packages; toPythonApplication vyper;
wazero = callPackage ../development/interpreters/wazero { };
wcc = callPackage ../development/compilers/wcc { };
wla-dx = callPackage ../development/compilers/wla-dx { };