Skip to content
This repository was archived by the owner on Oct 23, 2024. It is now read-only.
/ hdx Public archive

Commit 0fb372a

Browse files
committed
amaranth-stdio: add.
1 parent bbe1d8e commit 0fb372a

File tree

4 files changed

+45
-0
lines changed

4 files changed

+45
-0
lines changed

flake.lock

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
url = github:amaranth-lang/amaranth-boards;
1414
flake = false;
1515
};
16+
amaranth-stdio = {
17+
url = github:amaranth-lang/amaranth-stdio;
18+
flake = false;
19+
};
20+
1621
yosys = {
1722
url = github:YosysHQ/yosys;
1823
flake = false;

hdx.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ inputs @ {
8181
// optionalAttrs (hdx-config.amaranth.enable) {
8282
amaranth = callPackage ./pkgs/amaranth.nix {};
8383
amaranth-boards = callPackage ./pkgs/amaranth-boards.nix {};
84+
amaranth-stdio = callPackage ./pkgs/amaranth-stdio.nix {};
8485
}
8586
// optionalAttrs (hdx-config.yosys.enable) {yosys = callPackage ./pkgs/yosys.nix {};}
8687
// optionalAttrs (hdx-config.nextpnr.enable) ({nextpnr = callPackage ./pkgs/nextpnr.nix {inherit nextpnrArchs;};} // nextpnrArchs)

pkgs/amaranth-stdio.nix

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
pkgs,
3+
lib,
4+
amaranth,
5+
python,
6+
hdx-inputs,
7+
leaveDotGitWorkaround,
8+
}: let
9+
pythonPkgs = python.pkgs;
10+
in
11+
pythonPkgs.buildPythonPackage rec {
12+
pname = "amaranth-stdio";
13+
version = "0.1.0dev1+g${lib.substring 0 7 src.rev}";
14+
src = hdx-inputs.amaranth-stdio;
15+
postUnpack = leaveDotGitWorkaround;
16+
17+
nativeBuildInputs = builtins.attrValues {
18+
inherit (pkgs) git;
19+
inherit (pythonPkgs) setuptools-scm;
20+
inherit amaranth;
21+
};
22+
}

0 commit comments

Comments
 (0)