|
| 1 | +# Copyright lowRISC Contributors. |
| 2 | +# SPDX-License-Identifier: MIT |
| 3 | +{pkgs}: let |
| 4 | + inherit (pkgs) python3Packages fetchFromGitHub lib; |
| 5 | + |
| 6 | + systemrdl-compiler = python3Packages.buildPythonPackage { |
| 7 | + name = "systemrdl-compiler"; |
| 8 | + version = "1.27.3"; |
| 9 | + src = fetchFromGitHub { |
| 10 | + owner = "SystemRDL"; |
| 11 | + repo = "systemrdl-compiler"; |
| 12 | + rev = "191f4dd9bc093920720ddd47e8a15be97e6c5a25"; |
| 13 | + hash = "sha256-HEDN2VeYEA5ZJFCzk4ifhr8VVd8G+NVa/y/kK4ux2BY="; |
| 14 | + }; |
| 15 | + propagatedBuildInputs = with python3Packages; [ |
| 16 | + antlr4-python3-runtime |
| 17 | + colorama |
| 18 | + ]; |
| 19 | + enableParallelBuilding = true; |
| 20 | + doCheck = false; |
| 21 | + meta = { |
| 22 | + description = "SystemRDL 2.0 language compiler front-end "; |
| 23 | + homepage = "https://systemrdl-compiler.readthedocs.io"; |
| 24 | + license = lib.licenses.mit; |
| 25 | + }; |
| 26 | + }; |
| 27 | + |
| 28 | + peakRdlPackage = { |
| 29 | + name, |
| 30 | + version, |
| 31 | + rev, |
| 32 | + hash, |
| 33 | + description, |
| 34 | + additionalInputs ? [], |
| 35 | + }: |
| 36 | + python3Packages.buildPythonPackage { |
| 37 | + inherit name version; |
| 38 | + src = fetchFromGitHub { |
| 39 | + owner = "SystemRDL"; |
| 40 | + repo = name; |
| 41 | + inherit rev hash; |
| 42 | + }; |
| 43 | + propagatedBuildInputs = with python3Packages; |
| 44 | + [ |
| 45 | + setuptools |
| 46 | + setuptools-scm |
| 47 | + systemrdl-compiler |
| 48 | + ] |
| 49 | + ++ additionalInputs; |
| 50 | + format = "pyproject"; |
| 51 | + meta = { |
| 52 | + inherit description; |
| 53 | + homepage = "https://github.com/SystemRDL/${name}"; |
| 54 | + license = lib.licenses.gpl3; |
| 55 | + mainProgram = name; |
| 56 | + }; |
| 57 | + }; |
| 58 | +in rec { |
| 59 | + inherit systemrdl-compiler; |
| 60 | + |
| 61 | + peakrdl = peakRdlPackage { |
| 62 | + name = "peakrdl"; |
| 63 | + version = "1.1.0"; |
| 64 | + rev = "8b22af7771d595eb8619790492e0482a80a0196e"; |
| 65 | + hash = "sha256-8bft0RmKfFmQedPc2wEojss3iyGs3uSrEflriqlu+tY="; |
| 66 | + description = "Control and status register code generator toolchain."; |
| 67 | + additionalInputs = [ |
| 68 | + peakrdl-html |
| 69 | + peakrdl-ipxact |
| 70 | + peakrdl-regblock |
| 71 | + peakrdl-systemrdl |
| 72 | + peakrdl-uvm |
| 73 | + peakrdl-cheader |
| 74 | + ]; |
| 75 | + }; |
| 76 | + peakrdl-regblock = peakRdlPackage { |
| 77 | + name = "peakrdl-regblock"; |
| 78 | + version = "0.22.0"; |
| 79 | + rev = "ceb1f9b0c112798b32ded3c4a42f037c1130b1dc"; |
| 80 | + hash = "sha256-WYMHLz8pVlEaoKIjlB23eKMU/kxEVvQy144rgvv1XN4="; |
| 81 | + description = "Control and status register code generator toolchain"; |
| 82 | + additionalInputs = with python3Packages; [jinja2]; |
| 83 | + }; |
| 84 | + peakrdl-html = peakRdlPackage { |
| 85 | + name = "peakrdl-html"; |
| 86 | + version = "2.10.1"; |
| 87 | + rev = "2204134e6442c526bf158bbf51bcc24085c22b5a"; |
| 88 | + hash = "sha256-tFTvzug1dUhd6D1nr0wWpkEBYHW4erkW4zQJBRDm1SY="; |
| 89 | + description = "Generate address space documentation HTML from compiled SystemRDL input"; |
| 90 | + additionalInputs = with python3Packages; [ |
| 91 | + jinja2 |
| 92 | + markdown |
| 93 | + git-me-the-url |
| 94 | + python-markdown-math |
| 95 | + ]; |
| 96 | + }; |
| 97 | + peakrdl-systemrdl = peakRdlPackage { |
| 98 | + name = "peakrdl-systemrdl"; |
| 99 | + version = "0.3.0"; |
| 100 | + rev = "92036db0faafb49c5809a5e8b22d697816d96c5f"; |
| 101 | + hash = "sha256-pnq7Ak0QXjTC+/TswNd0g8orYj0dpgh81iXHqdVO2JE="; |
| 102 | + description = "Convert a compiled register model into SystemRDL code."; |
| 103 | + }; |
| 104 | + peakrdl-uvm = peakRdlPackage { |
| 105 | + name = "peakrdl-uvm"; |
| 106 | + version = "2.3.0"; |
| 107 | + rev = "fbb1dde704f8259fc2072d939bad3b0e1ecfa9b2"; |
| 108 | + hash = "sha256-NLPsJZDQ2d3oezOLB+pWU2x9m12gS5MKZ5rUSCrBqt4="; |
| 109 | + description = "Generate UVM register model from compiled SystemRDL input."; |
| 110 | + additionalInputs = with python3Packages; [jinja2]; |
| 111 | + }; |
| 112 | + peakrdl-cheader = peakRdlPackage { |
| 113 | + name = "peakrdl-cheader"; |
| 114 | + version = "1.0.0"; |
| 115 | + rev = "db696fc95a657168de7ee8ecec8d92e0cb696adc"; |
| 116 | + hash = "sha256-BaGlgnU0EJj40Z9+fwVStVpgfM0ja0EQDCoHLXPGM28="; |
| 117 | + description = "Generate C Headers from compiled SystemRDL input."; |
| 118 | + additionalInputs = with python3Packages; [jinja2]; |
| 119 | + }; |
| 120 | + peakrdl-ipxact = peakRdlPackage { |
| 121 | + name = "peakrdl-ipxact"; |
| 122 | + version = "3.4.4"; |
| 123 | + rev = "cf961d8d172de1f1f7b9adca95ffda08a71b167b"; |
| 124 | + hash = "sha256-UxdW8tudFKiD5FP4smKePt3IJxYCweVyOXj8LL978RE="; |
| 125 | + description = "Import and export IP-XACT XML register models "; |
| 126 | + }; |
| 127 | + |
| 128 | + git-me-the-url = python3Packages.buildPythonPackage { |
| 129 | + name = "git-me-the-url"; |
| 130 | + version = "2.1.0"; |
| 131 | + src = fetchFromGitHub { |
| 132 | + owner = "amykyta3"; |
| 133 | + repo = "git-me-the-url"; |
| 134 | + rev = "ec468a26e1de9cbbe037132aefbbee4ca479474a"; |
| 135 | + hash = "sha256-k9oTCrsgG8Nqe3AJJSUkEJaljzQldSSg36k5oWz5fXU="; |
| 136 | + }; |
| 137 | + propagatedBuildInputs = with python3Packages; [ |
| 138 | + setuptools |
| 139 | + setuptools-scm |
| 140 | + gitpython |
| 141 | + ]; |
| 142 | + format = "pyproject"; |
| 143 | + meta = { |
| 144 | + description = "Create shareable URLs to your Git files"; |
| 145 | + homepage = "https://github.com/amykyta3/git-me-the-url"; |
| 146 | + license = lib.licenses.gpl3; |
| 147 | + }; |
| 148 | + }; |
| 149 | +} |
0 commit comments