summary refs log tree commit diff
path: root/pkgs/development/tools/rust/cargo-component/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/tools/rust/cargo-component/default.nix')
-rw-r--r--pkgs/development/tools/rust/cargo-component/default.nix19
1 files changed, 8 insertions, 11 deletions
diff --git a/pkgs/development/tools/rust/cargo-component/default.nix b/pkgs/development/tools/rust/cargo-component/default.nix
index d1a1b4a49f0..b17c6e8adc7 100644
--- a/pkgs/development/tools/rust/cargo-component/default.nix
+++ b/pkgs/development/tools/rust/cargo-component/default.nix
@@ -7,23 +7,18 @@
 , darwin
 }:
 
-rustPlatform.buildRustPackage {
+rustPlatform.buildRustPackage rec {
   pname = "cargo-component";
-  version = "unstable-2023-09-20";
+  version = "0.4.0";
 
   src = fetchFromGitHub {
     owner = "bytecodealliance";
     repo = "cargo-component";
-    rev = "9bfbdeabee2e91894059c1f061f0c18931428823";
-    hash = "sha256-ZLhW2aIpibU4YX5f40BqQ0tKENY4row+FIl3d/hi3dY=";
+    rev = "v${version}";
+    hash = "sha256-XJKychPpBYMzFlW9jUPaBWuNAlcbqUQwxy+cMW2Ivyg=";
   };
 
-  cargoLock = {
-    lockFile = ./Cargo.lock;
-    outputHashes = {
-      "warg-api-0.1.0" = "sha256-kzxvGZUMUOueR8t1tiCpGJlPxqEHQMb1m1jhPYoatbA=";
-    };
-  };
+  cargoHash = "sha256-cEmbXitYGztfBS5M9uczgmFPKRktP4skFETx8SJah2A=";
 
   nativeBuildInputs = [
     pkg-config
@@ -32,7 +27,7 @@ rustPlatform.buildRustPackage {
   buildInputs = [
     openssl
   ] ++ lib.optionals stdenv.isDarwin [
-    darwin.apple_sdk.frameworks.Security
+    darwin.apple_sdk.frameworks.SystemConfiguration
   ];
 
   # requires the wasm32-wasi target
@@ -41,7 +36,9 @@ rustPlatform.buildRustPackage {
   meta = with lib; {
     description = "A Cargo subcommand for creating WebAssembly components based on the component model proposal";
     homepage = "https://github.com/bytecodealliance/cargo-component";
+    changelog = "https://github.com/bytecodealliance/cargo-component/releases/tag/${src.rev}";
     license = licenses.asl20;
     maintainers = with maintainers; [ figsoda ];
+    mainProgram = "cargo-component";
   };
 }