File tree Expand file tree Collapse file tree 2 files changed +61
-0
lines changed
Expand file tree Collapse file tree 2 files changed +61
-0
lines changed Original file line number Diff line number Diff line change 1+ {
2+ description = "WoWs Toolkit devShell" ;
3+
4+ inputs = {
5+ nixpkgs . url = "github:NixOS/nixpkgs/nixos-unstable" ;
6+ rust-overlay . url = "github:oxalica/rust-overlay" ;
7+ flake-utils . url = "github:numtide/flake-utils" ;
8+ } ;
9+
10+ outputs = {
11+ self ,
12+ nixpkgs ,
13+ rust-overlay ,
14+ flake-utils ,
15+ ...
16+ } :
17+ flake-utils . lib . eachDefaultSystem ( system : let
18+ overlays = [ ( import rust-overlay ) ] ;
19+ pkgs = import nixpkgs { inherit system overlays ; } ;
20+
21+ rustToolchainToml = fromTOML ( builtins . readFile ./rust-toolchain ) ;
22+ inherit ( rustToolchainToml . toolchain ) channel targets components ;
23+
24+ rustToolchain = pkgs . rust-bin . stable . ${ channel } . default . override {
25+ extensions = components ;
26+ inherit targets ;
27+ } ;
28+ in
29+ with pkgs ; {
30+ devShells . default = mkShell rec {
31+ buildInputs = [
32+ # Rust
33+ rust-bin . stable . latest . default
34+ rustToolchain
35+
36+ # misc. libraries
37+ openssl
38+ pkg-config
39+
40+ # GUI libs
41+ libxkbcommon
42+ libGL
43+ fontconfig
44+
45+ # wayland libraries
46+ wayland
47+
48+ # x11 libraries
49+ xorg . libXcursor
50+ xorg . libXrandr
51+ xorg . libXi
52+ xorg . libX11
53+ ] ;
54+
55+ LD_LIBRARY_PATH = "${ lib . makeLibraryPath buildInputs } " ;
56+ } ;
57+ } ) ;
58+ }
Original file line number Diff line number Diff line change 1+ [toolchain]
2+ channel = "1.89.0" # Avoid specifying a patch version here; see https://github.com/emilk/eframe_template/issues/145
3+ components = [ "rustfmt", "clippy" ]
You can’t perform that action at this time.
0 commit comments