ecp5-template/flake.nix

39 lines
887 B
Nix
Raw Normal View History

2024-04-14 06:16:22 +00:00
{
description = "ECP5 toolchain template project";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
};
outputs = inputs@{ nixpkgs, ... }:
let
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 = []; # patches, version pins here.
}
));
in {
devShells = forAllSystems (pkgs: {
default = pkgs.mkShell {
packages = with pkgs; [
yosys
nextpnr
# simulators
verilog
verilator
# support package
trellis
# loader
openfpgaloader
];
};
});
};
}