Skip to content

Commit 992927a

Browse files
add flake.nix file
1 parent b6323aa commit 992927a

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

flake.nix

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
{
2+
description = "eframe 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 = { self, nixpkgs, rust-overlay, flake-utils, ... }:
11+
flake-utils.lib.eachDefaultSystem (system:
12+
let
13+
overlays = [ (import rust-overlay) ];
14+
pkgs = import nixpkgs { inherit system overlays; };
15+
in with pkgs; {
16+
devShells.default = mkShell rec {
17+
buildInputs = [
18+
# Rust
19+
rust-bin.stable.latest.default
20+
trunk
21+
22+
# misc. libraries
23+
openssl
24+
pkg-config
25+
26+
# GUI libs
27+
libxkbcommon
28+
libGL
29+
fontconfig
30+
31+
# wayland libraries
32+
wayland
33+
34+
# x11 libraries
35+
xorg.libXcursor
36+
xorg.libXrandr
37+
xorg.libXi
38+
xorg.libX11
39+
40+
];
41+
42+
LD_LIBRARY_PATH = "${lib.makeLibraryPath buildInputs}";
43+
};
44+
});
45+
}

0 commit comments

Comments
 (0)