scratch-screen-share/flake.nix

42 lines
1.8 KiB
Nix

{
description = "common lisp dbus playground";
inputs.nixpkgs.url = "github:nixos/nixpkgs";
inputs.flake-utils.url = "github:numtide/flake-utils";
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem
(system:
let
pkgs = nixpkgs.legacyPackages.${system};
# https://nixos.org/manual/nixpkgs/stable/#lisp-overriding-package-attributes
# getting version with automatic introspection mixin
dbus' = pkgs.sbcl.pkgs.dbus.overrideLispAttrs (oldAttrs: rec {
version = "1.4";
src = pkgs.fetchFromGitHub {
owner = "death";
repo = "dbus";
rev = "master";
hash = "sha256-xbg3tPYfRNGJo+9F/58w2bDeZqV33Z871+ClSg4ACPk=";
};
});
sbcl' = pkgs.sbcl.withPackages (ps: [ ps.alexandria
dbus'
ps.cl-cffi-gtk
ps.sdl2
ps.cl-opengl
]);
in
{
devShells.default = pkgs.mkShell {
SDL_VIDEODRIVER="wayland";
WAYLAND_DISPLAY="wayland-1";
EGL_PLATFORM="wayland";
buildInputs = [
sbcl'
];
};
}
);
# see https://serokell.io/blog/practical-nix-flakes
}