2024-03-18 16:56:54 -05:00
|
|
|
{
|
|
|
|
description = "tsm";
|
|
|
|
inputs = {
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
|
2024-09-05 13:17:50 -05:00
|
|
|
nim2nix.url = "github:daylinmorgan/nim2nix";
|
2024-03-18 16:56:54 -05:00
|
|
|
};
|
|
|
|
|
2024-09-05 13:17:50 -05:00
|
|
|
outputs =
|
|
|
|
{
|
|
|
|
self,
|
|
|
|
nixpkgs,
|
|
|
|
nim2nix,
|
|
|
|
}:
|
|
|
|
let
|
|
|
|
inherit (nixpkgs.lib) genAttrs;
|
|
|
|
supportedSystems = [
|
|
|
|
"x86_64-linux"
|
|
|
|
"x86_64-darwin"
|
|
|
|
"aarch64-linux"
|
|
|
|
"aarch64-darwin"
|
|
|
|
];
|
|
|
|
forAllSystems =
|
|
|
|
f:
|
|
|
|
genAttrs supportedSystems (
|
|
|
|
system:
|
|
|
|
f (import nixpkgs {
|
|
|
|
inherit system;
|
|
|
|
overlays = [nim2nix.overlays.default];
|
|
|
|
}
|
|
|
|
));
|
|
|
|
in
|
|
|
|
{
|
|
|
|
devShells = forAllSystems (pkgs: {
|
|
|
|
default = pkgs.mkShell {
|
|
|
|
packages = with pkgs; [
|
|
|
|
nim
|
|
|
|
nimble
|
|
|
|
];
|
|
|
|
};
|
|
|
|
});
|
|
|
|
packages = forAllSystems (pkgs: {
|
2024-09-16 18:00:44 -05:00
|
|
|
tsm = pkgs.buildNimblePackage rec {
|
2024-03-18 16:56:54 -05:00
|
|
|
pname = "tsm";
|
2024-09-16 18:00:44 -05:00
|
|
|
version = "2024.1001-unstable";
|
2024-03-18 16:56:54 -05:00
|
|
|
src = ../.;
|
2024-11-13 14:08:01 -06:00
|
|
|
nimbleDepsHash = "sha256-5xK3KsLLFZ72qWreIHW0SBL3+5H6Ll6o0spMfW1iPX8=";
|
2024-09-16 18:00:44 -05:00
|
|
|
nimFlags = [
|
|
|
|
"-d:TsmVersion=v${version}"
|
|
|
|
];
|
2024-03-18 16:56:54 -05:00
|
|
|
};
|
|
|
|
default = self.packages.${pkgs.system}.tsm;
|
2024-09-05 13:17:50 -05:00
|
|
|
});
|
|
|
|
};
|
2024-03-18 16:56:54 -05:00
|
|
|
}
|