diff options
Diffstat (limited to 'flake.nix')
-rw-r--r-- | flake.nix | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..a6b50a6 --- /dev/null +++ b/flake.nix @@ -0,0 +1,53 @@ +{ + description = "scenefx development environment"; + + inputs = { + flake-compat = { + url = "github:edolstra/flake-compat"; + flake = false; + }; + + nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable"; + }; + + outputs = { self, nixpkgs, flake-compat, ... }: + let + pkgsFor = system: + import nixpkgs { + inherit system; + overlays = [ ]; + }; + + targetSystems = [ "aarch64-linux" "x86_64-linux" ]; + in + { + devShells = nixpkgs.lib.genAttrs targetSystems (system: + let + pkgs = pkgsFor system; + in + { + default = pkgs.mkShell { + name = "scenefx-shell"; + depsBuildBuild = with pkgs; [ pkg-config ]; + inputsFrom = [ pkgs.wlroots_0_16 ]; + + nativeBuildInputs = with pkgs; [ + cmake + meson + ninja + pkg-config + wayland-scanner + scdoc + hwdata + ]; + +# shellHook = with pkgs; ''( +# mkdir -p "$PWD/subprojects" +# cd "$PWD/subprojects" +# cp -R --no-preserve=mode,ownership ${wlroots_0_16.src} wlroots +# )''; + }; + }); + }; +} + |