-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathflake.nix
More file actions
61 lines (55 loc) · 1.46 KB
/
Copy pathflake.nix
File metadata and controls
61 lines (55 loc) · 1.46 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
{
inputs = {
naersk = {
url = "github:nix-community/naersk";
inputs.nixpkgs.follows = "nixpkgs";
};
rust-overlay = {
url = "github:oxalica/rust-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
nix-filter.url = "github:numtide/nix-filter";
};
outputs =
{
nixpkgs,
flake-utils,
naersk,
rust-overlay,
nix-filter,
...
}:
flake-utils.lib.eachDefaultSystem (
system:
let
# wasm-bindgen-cli-update = final: prev: {
# wasm-bindgen-cli = prev.wasm-bindgen-cli.override {
# version = "0.2.92";
# hash = "sha256-1VwY8vQy7soKEgbki4LD+v259751kKxSxmo/gqE6yV0=";
# cargoHash = "sha256-aACJ+lYNEU8FFBs158G1/JG8sc6Rq080PeKCMnwdpH0=";
# };
# };
overlays = [ (import rust-overlay) ];
pkgs = import nixpkgs { inherit system overlays; };
toolchain = pkgs.rust-bin.nightly.latest.complete.override {
extensions = [ "rust-src" ];
targets = [ "wasm32-unknown-unknown" ];
};
in
rec {
devShell =
with pkgs;
mkShell {
buildInputs = [
toolchain
iconv
darwin.apple_sdk.frameworks.AppKit
wasm-bindgen-cli
cargo-watch
cargo-expand
];
RUST_SRC_PATH = "${toolchain}/lib/rustlib/src/rust/library";
};
}
);
}