-
Notifications
You must be signed in to change notification settings - Fork 31
Expand file tree
/
Copy pathflake.nix
More file actions
39 lines (36 loc) · 939 Bytes
/
flake.nix
File metadata and controls
39 lines (36 loc) · 939 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
{
inputs = {
nixpkgs.url = "nixpkgs/nixos-25.05";
flake-utils.url = "github:numtide/flake-utils";
fenix = {
url = "github:nix-community/fenix";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, nixpkgs, flake-utils, fenix }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
};
lib = pkgs.lib;
rustVersion = "1.74.0";
rustToolchain = fenix.packages.${system}.fromToolchainName {
name = rustVersion;
sha256 = "sha256-U2yfueFohJHjif7anmJB5vZbpP7G6bICH4ZsjtufRoU=";
};
in
{
devShells.default = pkgs.mkShell {
packages = [
rustToolchain.toolchain
rustToolchain.rust-analyzer
pkgs.git
pkgs.llvmPackages.clang
];
LIBCLANG_PATH = "${pkgs.llvmPackages.clang-unwrapped.lib}/lib/";
RUSTDOCS_STDLIB = "${rustToolchain.rust-docs}/share/doc/rust/html/std/index.html";
};
}
);
}