Created
February 26, 2022 11:29
-
-
Save mankyKitty/2f6cbe94a3d4b450cc995ac5b2d910e9 to your computer and use it in GitHub Desktop.
nix shell for building picosystem-rs things (https://github.com/rlane/picosystem-rs)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ srcs ? import ./nix/sources.nix }: | |
let | |
pkgs = import srcs.nixpkgs { | |
crossSystem = (import "${srcs.nixpkgs}/lib").systems.examples.raspberryPi // { | |
rustc.config = "thumbv6m-none-eabi"; | |
}; | |
}; | |
in | |
pkgs.mkShell { | |
buildInputs = with pkgs; [ | |
cargo | |
cargo-watch | |
clippy | |
rustc | |
rustfmt | |
pkg-config | |
libudev | |
]; | |
# For openssl-sys crate | |
PKG_CONFIG_PATH = "${pkgs.libudev.dev}/lib/pkgconfig"; | |
# See https://discourse.nixos.org/t/rust-src-not-found-and-other-misadventures-of-developing-rust-on-nixos/11570/3?u=samuela. | |
RUST_SRC_PATH = "${pkgs.rust.packages.stable.rustPlatform.rustLibSrc}"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Unfortunately this builds
rustc
from source :/