-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathflake.nix
More file actions
28 lines (26 loc) · 980 Bytes
/
flake.nix
File metadata and controls
28 lines (26 loc) · 980 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{
description = "zkeme80";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
utils.url = "github:numtide/flake-utils";
flake-compat.url = "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz";
};
outputs = { self, nixpkgs, utils, flake-compat }:
utils.lib.eachDefaultSystem (system:
with import nixpkgs { inherit system; }; rec {
packages = rec {
default = pkgs.writeShellScriptBin "runit" ''
exec ${pkgs.tilem}/bin/tilem2 -r ${zkeme80}/zkeme80.rom
'';
zkeme80 = runCommand "zkeme80.rom" { buildInputs = [ guile ]; } ''
cp -r ${./.}/src/* .
chmod -R +w .
echo '(begin (load "zkeme80.scm") (make-rom+map "zkeme80.rom" "zkeme80.ram-labelmap.json"))' | guile
mkdir $out
cp zkeme80.rom zkeme80.ram-labelmap.json $out/
'';
};
defaultPackage = self.packages.${system}.default;
}
);
}