groovylight/flake.nix
saji 0d2719c39f
Some checks failed
Verilator Unit Tests / Test (push) Failing after 1m26s
start working on making flake work
2024-09-24 01:42:11 -05:00

48 lines
1.1 KiB
Nix

{
description = "ECP5 toolchain template project";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
};
outputs = inputs@{ nixpkgs, flake-utils, ... }:
let
python-overlay = import ./python.nix;
systems = [ "x86_64-linux" "aarch64-linux" "aarch64-darwin" "x86_64-darwin" ];
forAllSystems = function:
nixpkgs.lib.genAttrs systems (system: function (
import nixpkgs {
inherit system;
config.allowUnfree = true;
overlays = [
python-overlay
];
}
));
in {
packages = forAllSystems (pkgs: {
sim = import ./sim/package.nix pkgs;
});
devShells = forAllSystems (pkgs: {
default = pkgs.mkShell {
packages = with pkgs; [
(python3.withPackages (ps: with ps; [
amaranth
]))
yosys
nextpnr
# simulators
iverilog
verilator
# support package
trellis
# loader
openfpgaloader
ecpdap # easier to poke probes.
];
};
});
};
}