touhou-reimpl/flake.nix

59 lines
1.3 KiB
Nix

{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
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
overlays = [fenix.overlays.default];
pkgs = import nixpkgs {
inherit system overlays;
};
libPath = with pkgs;
lib.makeLibraryPath [
libGL
libxkbcommon
wayland
];
in
with pkgs; {
formatter = alejandra;
devShells.default = mkShell {
buildInputs = [
pkgs.fenix.stable.completeToolchain
cmake
pkg-config
openssl
wayland-scanner
wayland-protocols
alsa-lib
(pkgs.callPackage ./thtk.nix {})
(pkgs.callPackage ./truth.nix {})
xorg.libX11
xorg.libXcursor
xorg.libxcb
xorg.libXi
libxkbcommon
];
LD_LIBRARY_PATH = libPath;
};
packages = {
thtk = pkgs.callPackage ./thtk.nix {};
truth = pkgs.callPackage ./truth.nix {};
};
}
);
}