diff --git a/pkgs/default.nix b/pkgs/default.nix index 21d053c..d1e116c 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -16,6 +16,7 @@ llvm_cheriot = pkgs.callPackage ./llvm_cheriot.nix {}; xmake = import ./xmake.nix {inherit pkgs;}; cheriot-sim = pkgs.callPackage ./cheriot-sim.nix {}; + verible_ot = pkgs.callPackage ./verible.nix {}; } // pkgs.lib.optionalAttrs (pkgs.system == "x86_64-linux") { lowrisc-toolchain-gcc-rv32imcb = pkgs.callPackage ./lowrisc-toolchain-gcc-rv32imcb.nix {}; diff --git a/pkgs/verible.nix b/pkgs/verible.nix new file mode 100644 index 0000000..37a6e6d --- /dev/null +++ b/pkgs/verible.nix @@ -0,0 +1,35 @@ +# Copyright lowRISC contributors. +# +# SPDX-License-Identifier: MIT +{ + pkgs, + lib, + fetchFromGitHub, + verible, + bazel_6, +}: +verible.override (prev: { + buildBazelPackage = args: + prev.buildBazelPackage (args + // rec { + GIT_DATE = "2024-03-13"; + GIT_VERSION = "v0.0-3622-g07b310a3"; + + version = builtins.concatStringsSep "." (lib.take 3 (lib.drop 1 (builtins.splitVersion GIT_VERSION))); + + src = fetchFromGitHub { + owner = "chipsalliance"; + repo = "verible"; + rev = GIT_VERSION; + sha256 = "sha256-pfFb2tuT7F7SpGMXElsVAHxO6xGQrVC15EyYxPSKaK8="; + }; + + fetchAttrs = { + sha256 = "sha256-mLW7gg0+6W/Lt1/Egg0RTFcHvy+DzlHJ3gGOl4D65jE="; + }; + + patches = []; + + bazel = bazel_6; + }); +})