diff options
author | Alyssa Ross <hi@alyssa.is> | 2020-03-26 17:17:48 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2020-03-26 17:36:07 +0000 |
commit | 70e58881128ed8170821840138ab08fc5cdd3c11 (patch) | |
tree | 1bf0d3d977878df5b58493ea02b2e6c79df3ba22 /pkgs/applications/science/logic/mcy/default.nix | |
parent | a9847c36e6aa003998c1ef5518e5710658ca5770 (diff) | |
parent | 90dcc3360327e250536eeeca7fe9d887c9f7a817 (diff) | |
download | nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.tar nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.tar.gz nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.tar.bz2 nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.tar.lz nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.tar.xz nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.tar.zst nixpkgs-70e58881128ed8170821840138ab08fc5cdd3c11.zip |
Merge remote-tracking branch 'nixpkgs/master' into master
Diffstat (limited to 'pkgs/applications/science/logic/mcy/default.nix')
-rw-r--r-- | pkgs/applications/science/logic/mcy/default.nix | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/pkgs/applications/science/logic/mcy/default.nix b/pkgs/applications/science/logic/mcy/default.nix new file mode 100644 index 00000000000..a9366d56058 --- /dev/null +++ b/pkgs/applications/science/logic/mcy/default.nix @@ -0,0 +1,44 @@ +{ stdenv, fetchFromGitHub +, yosys, symbiyosys, python3 +}: + +let + python = python3.withPackages (p: with p; [ flask ]); +in +stdenv.mkDerivation { + pname = "mcy"; + version = "2020.03.21"; + + src = fetchFromGitHub { + owner = "YosysHQ"; + repo = "mcy"; + rev = "bac92b8aad9bf24714fda70d3750bb50d6d96177"; + sha256 = "0mmg6zd5cbn8g0am9c3naamg0lq67yyy117fzn2ydigcyia7vmnp"; + }; + + buildInputs = [ python ]; + patchPhase = '' + substituteInPlace mcy.py \ + --replace yosys '${yosys}/bin/yosys' \ + --replace 'os.execvp("mcy-dash"' "os.execvp(\"$out/bin/mcy-dash\"" + substituteInPlace mcy-dash.py \ + --replace 'app.run(debug=True)' 'app.run(host="0.0.0.0",debug=True)' + ''; + + # the build needs a bit of work... + buildPhase = "true"; + installPhase = '' + mkdir -p $out/bin $out/share/mcy/dash + install mcy.py $out/bin/mcy && chmod +x $out/bin/mcy + install mcy-dash.py $out/bin/mcy-dash && chmod +x $out/bin/mcy-dash + cp -r dash/. $out/share/mcy/dash/. + ''; + + meta = { + description = "Mutation-based coverage testing for hardware designs, with Yosys"; + homepage = "https://github.com/YosysHQ/mcy"; + license = stdenv.lib.licenses.isc; + maintainers = with stdenv.lib.maintainers; [ thoughtpolice ]; + platforms = stdenv.lib.platforms.all; + }; +} |