{
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
rust-overlay.url = "github:oxalica/rust-overlay";
};
outputs = { self, nixpkgs, rust-overlay, ... }:
let
rustVersion = "1.76.0";
systems = [ "x86_64-linux" ];
overlays = [ (import rust-overlay) ];
forAllSystems = function:
nixpkgs.lib.genAttrs systems (system:
function (import nixpkgs {
inherit system overlays;
}));
in
{
devShells = forAllSystems (pkgs: {
default = pkgs.mkShell {
buildInputs = with pkgs; [
rust-bin.stable.${rustVersion}.default
rust-analyzer
mold
cmake
pkg-config
fontconfig
];
LD_LIBRARY_PATH = with pkgs; lib.makeLibraryPath [
wayland
libxkbcommon
vulkan-loader
fontconfig
freetype
];
};
});
};
}