From f68ec22dcc7bf8289c06c6f74ced87b91b31dd2e Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 27 Sep 2019 15:07:14 +0100 Subject: [PATCH] python3Packages.nmigen: unstable-2019-08-31 -> unstable-2019-09-28 --- .../python-modules/nmigen/default.nix | 22 ++++++++++++------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/nmigen/default.nix b/pkgs/development/python-modules/nmigen/default.nix index 345ba982b0bc..02569e0a81bf 100644 --- a/pkgs/development/python-modules/nmigen/default.nix +++ b/pkgs/development/python-modules/nmigen/default.nix @@ -2,6 +2,8 @@ , buildPythonPackage , pythonOlder , fetchFromGitHub +, setuptools +, setuptools_scm , pyvcd , bitarray , jinja2 @@ -19,19 +21,22 @@ buildPythonPackage rec { pname = "nmigen"; - version = "unstable-2019-08-31"; - realVersion = lib.substring 0 7 src.rev; + version = "unstable-2019-09-28"; + # python setup.py --version + realVersion = "0.1.dev689+g${lib.substring 0 7 src.rev}"; src = fetchFromGitHub { owner = "m-labs"; repo = "nmigen"; - rev = "2e206220462c67aa6ae97f7515a2191440fd61b3"; - sha256 = "0y3w6vd493jqm9b8ppgwzs02v1al8w1n5gylljlsw70ci7fyk4qa"; + rev = "a02e3750bfeba44bcaad4c5de8d9eb0ef055d9c6"; + sha256 = "0m399c2nm7y54q2f0fbkmi4h35csbc2llckm6k9kqdf5qc6355wd"; }; disabled = pythonOlder "3.6"; - propagatedBuildInputs = [ pyvcd bitarray jinja2 ]; + nativeBuildInputs = [ setuptools_scm ]; + + propagatedBuildInputs = [ setuptools pyvcd bitarray jinja2 ]; checkInputs = [ yosys yices ]; @@ -48,14 +53,15 @@ buildPythonPackage rec { tool icestorm "icepack" // tool trellis "ecppack"; in '' - substituteInPlace setup.py \ - --replace 'versioneer.get_version()' '"${realVersion}"' - substituteInPlace nmigen/_toolchain.py \ --replace 'overrides = {}' \ 'overrides = ${builtins.toJSON toolchainOverrides}' ''; + preBuild = '' + export SETUPTOOLS_SCM_PRETEND_VERSION="${realVersion}" + ''; + meta = with lib; { description = "A refreshed Python toolbox for building complex digital hardware"; homepage = https://github.com/m-labs/nmigen;