14 inherit (darwin.apple_sdk.frameworks) CoreServices;
15 pname = "cargo-mobile2";
18 rustPlatform.buildRustPackage {
19 inherit pname version;
20 src = fetchFromGitHub {
23 rev = "cargo-mobile2-v${version}";
24 hash = "sha256-1lrimBdJwur5b4wB8hZVUtJEbgXoib0ytzjzhkqNE6c=";
27 # Manually specify the sourceRoot since this crate depends on other crates in the workspace. Relevant info at
28 # https://discourse.nixos.org/t/difficulty-using-buildrustpackage-with-a-src-containing-multiple-cargo-workspaces/10202
29 # sourceRoot = "${src.name}/tooling/cli";
31 cargoHash = "sha256-vmoR5pA8CNf4eZpQgj0Wn1/FmId4hmpSi7FYxBY5O9M=";
35 # during the install process tauri-mobile puts templates and commit information in CARGO_HOME
36 export CARGO_HOME=$out/share/
39 buildInputs = [ openssl ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ CoreServices ];
47 for bin in $out/bin/cargo-*; do
49 --set CARGO_HOME "$out/share"
54 description = "Rust on mobile made easy!";
55 homepage = "https://tauri.app/";
56 license = with licenses; [
60 maintainers = with maintainers; [ happysalada ];