forked from M-Labs/zynq-rs
1
0
Fork 0
zynq-rs/shell.nix

25 lines
696 B
Nix
Raw Normal View History

2019-05-05 20:56:23 +08:00
let
pkgs = import <nixpkgs> { overlays = [ (import ./nix/mozilla-overlay.nix) ]; };
rustPlatform = (import ./nix/rust-platform.nix { inherit pkgs; });
2019-05-05 20:56:23 +08:00
in
pkgs.stdenv.mkDerivation {
name = "zynq-env";
buildInputs = [
rustPlatform.rust.rustc
rustPlatform.rust.cargo
pkgs.cacert
(pkgs.cargo-xbuild.overrideAttrs(oa: { patches = oa.patches ++ [ ./xbuild_writable_lockfile.diff ]; } ))
pkgs.openocd pkgs.gdb
pkgs.openssh pkgs.rsync
(import ./nix/mkbootimage.nix { inherit pkgs; })
];
2019-05-05 20:56:23 +08:00
XARGO_RUST_SRC = "${rustPlatform.rust.rustc.src}/library";
2019-05-05 20:56:23 +08:00
shellHook = ''
echo "Run 'cargo xbuild --release -p ...' to build."
'';
}