Skip to content

Commit

Permalink
tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
plebhash committed Jan 15, 2025
1 parent 4ad657a commit eaa9e51
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions roles/flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
description = "Cross-compiling Rust crate to aarch64-unknown-linux-gnu";

inputs.nixpkgs.url = "github:NixOS/nixpkgs";

outputs = { self, nixpkgs }: let
pkgs = import nixpkgs {
system = "x86_64-darwin"; # Host system (macOS)
crossSystem = {
config = "aarch64-unknown-linux-gnu"; # Target system (Raspberry Pi 64-bit)
};
};
in {
defaultPackage.x86_64-darwin = pkgs.rustPlatform.buildRustPackage {
pname = "my-crate";
version = "0.1.0";

src = ./.; # Replace with the path to your Rust crate

cargoPatches = [ ];

# Optionally define dependencies here if needed
};
};
}

0 comments on commit eaa9e51

Please sign in to comment.