add nix-shell file for firmware compilation

pull/1/head
Sebastien Bourdeauducq 2019-06-05 23:08:55 +08:00
parent 6ad1d993c6
commit 52cc7722a0
1 changed files with 8 additions and 0 deletions

8
shell-firmware.nix Normal file
View File

@ -0,0 +1,8 @@
{ pkgs ? import <nixpkgs> {}}:
let
hx = import ./derivations.nix { inherit pkgs; };
in
pkgs.mkShell {
buildInputs = [ hx.rustc hx.rust-riscv32imc-crates hx.cargo ];
RUSTFLAGS="-L ${hx.rust-riscv32imc-crates}/lib/rustlib/riscv32imc-unknown-none-elf/lib";
}