File tree Expand file tree Collapse file tree
development/interpreters/wasmer Expand file tree Collapse file tree Original file line number Diff line number Diff line change 55 llvmPackages ,
66 libffi ,
77 libxml2 ,
8+ makeWrapper ,
9+ bash ,
10+ make ,
811 withLLVM ? true ,
912 withSinglepass ? true ,
1013} :
1114
1215rustPlatform . buildRustPackage rec {
1316 pname = "wasmer" ;
14- version = "5 .0.4 " ;
17+ version = "6 .0.0 " ;
1518
1619 src = fetchFromGitHub {
1720 owner = "wasmerio" ;
1821 repo = pname ;
1922 tag = "v${ version } " ;
20- hash = "sha256-rP0qvSb9PxsTMAq0hpB+zdSTHvridyCVdukLUYxdao8 =" ;
23+ hash = "sha256-Qx5bHCzdh3RqB5r93sa01mPyxN2EQWPWcIXJs1MrUHs =" ;
2124 } ;
2225
2326 useFetchCargoVendor = true ;
24- cargoHash = "sha256-Fympp2A04viibo4U79FiBSJIeGDUWS34OOwebCks6S0 =" ;
27+ cargoHash = "sha256-/Kcd9vZu5QstIEjDYaJ/ddXUIXL1F8Omi+Bm4jtOKcg =" ;
2528
2629 nativeBuildInputs = [
2730 rustPlatform . bindgenHook
31+ makeWrapper
32+ bash
33+ make
2834 ] ;
2935
3036 buildInputs = lib . optionals withLLVM [
@@ -57,6 +63,22 @@ rustPlatform.buildRustPackage rec {
5763 # Tests are failing due to `Cannot allocate memory` and other reasons
5864 doCheck = false ;
5965
66+ postBuild = ''
67+ # Prepare and build the Wasmer C-API
68+ sed -i 's|SHELL=/usr/bin/env bash|SHELL=${ bash } /bin/bash|' Makefile
69+ make build-capi
70+ make package-capi
71+ '' ;
72+
73+ postInstall = ''
74+ # Install the C-API headers, libs, etc.
75+ cp -r package/* $out/
76+
77+ # Ensure the CLI can locate its assets
78+ makeWrapper "$out/bin/wasmer" \
79+ --set WASMER_DIR "$out"
80+ '' ;
81+
6082 meta = {
6183 description = "Universal WebAssembly Runtime" ;
6284 mainProgram = "wasmer" ;
Original file line number Diff line number Diff line change @@ -16751,6 +16751,7 @@ with pkgs;
1675116751
1675216752 wasmer = callPackage ../development/interpreters/wasmer {
1675316753 llvmPackages = llvmPackages_18;
16754+ make = pkgs.make;
1675416755 };
1675516756
1675616757 wavm = callPackage ../development/interpreters/wavm {
You can’t perform that action at this time.
0 commit comments