02dab4ab5c
Long term we should move everything over to `pyproject = true`, but in the mean time we can work towards deprecating the implicit `format` paremeter. cc https://github.com/NixOS/nixpkgs/issues/253154 cc @mweinelt @figsoda
37 lines
920 B
Nix
37 lines
920 B
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, amaranth
|
|
, setuptools
|
|
, setuptools-scm
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "amaranth-soc";
|
|
version = "unstable-2023-09-15";
|
|
format = "setuptools";
|
|
# python setup.py --version
|
|
realVersion = "0.1.dev70+g${lib.substring 0 7 src.rev}";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "amaranth-lang";
|
|
repo = "amaranth-soc";
|
|
rev = "cce8a79a37498f4d5900be21a295ba77e51e6c9d";
|
|
sha256 = "sha256-hfkJaqICuy3iSTwLM9lbUPvSMDBLW8GdxqswyAOsowo=";
|
|
};
|
|
|
|
nativeBuildInputs = [ setuptools-scm ];
|
|
propagatedBuildInputs = [ setuptools amaranth ];
|
|
|
|
preBuild = ''
|
|
export SETUPTOOLS_SCM_PRETEND_VERSION="${realVersion}"
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "System on Chip toolkit for Amaranth HDL";
|
|
homepage = "https://github.com/amaranth-lang/amaranth-soc";
|
|
license = licenses.bsd2;
|
|
maintainers = with maintainers; [ emily thoughtpolice ];
|
|
};
|
|
}
|