Unverified Commit 18e21055 authored by Emily's avatar Emily Committed by GitHub
Browse files

bazel: bazel_6 -> bazel_7; bazel_6: drop (#435096)

parents 0e209ec1 95cfbc33
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -3,7 +3,7 @@
  stdenv,
  buildBazelPackage,
  fetchFromGitHub,
  bazel_6,
  bazel_7,
  jdk,
  nix-update-script,
  cctools,
@@ -39,12 +39,14 @@ buildBazelPackage rec {
    patchShebangs scripts/create-workspace-status.sh
  '';

  removeRulesCC = false;

  fetchAttrs = {
    hash =
      {
        aarch64-linux = "sha256-ibv49Y0VjAvfTUwxRUH4BmzUvz8J/qfYPGnI5Tw51HA=";
        x86_64-linux = "sha256-VHR08FB4G0LlczWtBb8AdU5tNEzBDNUZpHoB6e3HB1M=";
        aarch64-darwin = "sha256-5uKCLDJs0tzOJ7YiKP90RIfIYrken3XFyhT5HHdzft0=";
        aarch64-linux = "sha256-1iy2S0mmXksfwucks+HOZ2/HUGaVBqk7VlR+kO6iYZE=";
        x86_64-linux = "sha256-YOIwwlCYlNINlYbm/vq3Jjhe+/zgrtECdMRl+vE8FgI=";
        aarch64-darwin = "sha256-7g1deAihrjpwAxNbG7rv9dDs3FjOCuRIFieLbENKmbw=";
      }
      .${system} or (throw "No hash for system: ${system}");
  };
@@ -52,7 +54,7 @@ buildBazelPackage rec {
  nativeBuildInputs = [
    jdk
  ];
  bazel = bazel_6;
  bazel = bazel_7;

  bazelBuildFlags = [ "-c opt" ];
  bazelTestTargets = [ "//..." ];
+6 −3
Original line number Diff line number Diff line
{
  bazel_6,
  bazel_7,
  buildBazelPackage,
  fcitx5,
  fetchFromGitHub,
@@ -45,7 +45,7 @@ buildBazelPackage {
    sed -i -e 's|^\(LINUX_MOZC_SERVER_DIR = \).\+|\1"${mozc}/lib/mozc"|' src/config.bzl
  '';

  bazel = bazel_6;
  bazel = bazel_7;
  removeRulesCC = false;
  dontAddBazelOpts = true;

@@ -63,10 +63,13 @@ buildBazelPackage {

  fetchAttrs = {
    preInstall = ''
      # Remove reference to buildInput
      rm -rf $bazelOut/external/fcitx5
      # Remove reference to the host platform
      rm -rv "$bazelOut"/external/host_platform
    '';

    sha256 = "sha256-rrRp/v1pty7Py80/6I8rVVQvkeY72W+nlixUeYkjp+o=";
    hash = "sha256-nFPGhZWvzzBOSeIa35XQbK6dHgJJSYum/5X8eAA0uCY=";
  };

  preConfigure = ''
+9 −5
Original line number Diff line number Diff line
@@ -5,7 +5,7 @@
  qt6,
  pkg-config,
  protobuf_27,
  bazel,
  bazel_7,
  ibus,
  unzip,
  xdg-utils,
@@ -43,14 +43,18 @@ buildBazelPackage rec {
  dontAddBazelOpts = true;
  removeRulesCC = false;

  inherit bazel;
  bazel = bazel_7;

  fetchAttrs = {
    sha256 = "sha256-+N7AhSemcfhq6j0IUeWZ0DyVvr1l5FbAkB+kahTy3pM=";
    hash = "sha256-c+v2vWvTmwJ7MFh3VJlUh+iSINjsX66W9K0UBX5K/1s=";

    # remove references of buildInputs and zip code files
    preInstall = ''
      rm -rv $bazelOut/external/{ibus,qt_linux,zip_code_*}
      # Remove zip code data. It will be replaced with jp-zip-codes from nixpkgs
      rm -rv "$bazelOut"/external/zip_code_{jigyosyo,ken_all}
      # Remove references to buildInputs
      rm -rv "$bazelOut"/external/{ibus,qt_linux}
      # Remove reference to the host platform
      rm -rv "$bazelOut"/external/host_platform
    '';
  };

+4 −4
Original line number Diff line number Diff line
@@ -3,7 +3,7 @@
  stdenv,
  buildBazelPackage,
  fetchFromGitHub,
  bazel_6,
  bazel_7,
  jdk,
  elfutils,
  libcap,
@@ -29,7 +29,7 @@ buildBazelPackage {
    hash = "sha256-AScXL74K0Eiajdib56+7ay3K/MMWbmeUWkRWMaEJRC8=";
  };

  bazel = bazel_6;
  bazel = bazel_7;
  bazelFlags = [
    "--registry"
    "file://${registry}"
@@ -38,8 +38,8 @@ buildBazelPackage {
  fetchAttrs = {
    hash =
      {
        aarch64-linux = "sha256-Ksae4VC2FbkW79N5EGn/rTdj+GFKQsZCdi4LPfnzV7Y=";
        x86_64-linux = "sha256-TYeS1bax7sA0hJLXqtE8Q5FLnIylcWPZynVE2LhvZKc=";
        aarch64-linux = "sha256-GvuOEQfzPF5J75TRlEc4oDiXXUN4G3fMfRhMDmg3FL0=";
        x86_64-linux = "sha256-A47JJg+GUIhR7FhufxEsfsIuSg6dd7sPNzSWiQZXIEE=";
      }
      .${system} or (throw "No hash for system: ${system}");
  };
+11 −5
Original line number Diff line number Diff line
@@ -2,23 +2,23 @@
  stdenv,
  lib,
  buildBazelPackage,
  bazel_6,
  bazel_7,
  fetchFromGitHub,
  cctools,
}:

buildBazelPackage rec {
  pname = "protoc-gen-js";
  version = "3.21.2";
  version = "3.21.4";

  src = fetchFromGitHub {
    owner = "protocolbuffers";
    repo = "protobuf-javascript";
    rev = "v${version}";
    hash = "sha256-TmP6xftUVTD7yML7UEM/DB8bcsL5RFlKPyCpcboD86U=";
    hash = "sha256-eIOtVRnHv2oz4xuVc4aL6JmhpvlODQjXHt1eJHsjnLg=";
  };

  bazel = bazel_6;
  bazel = bazel_7;
  bazelTargets = [ "generator:protoc-gen-js" ];
  bazelBuildFlags = lib.optionals stdenv.cc.isClang [
    "--cxxopt=-x"
@@ -31,7 +31,13 @@ buildBazelPackage rec {

  LIBTOOL = lib.optionalString stdenv.hostPlatform.isDarwin "${cctools}/bin/libtool";

  fetchAttrs.hash = "sha256-WOBlZ0XNrl5UxIaSDxZeOfzS2a8ZkrKdTLKHBDC9UNQ=";
  fetchAttrs = {
    preInstall = ''
      rm -rv "$bazelOut/external/host_platform"
    '';

    hash = "sha256-CekpXINZSr6Hysa4qrVkdchBla9pgBwRtqBiuUGPNq0=";
  };

  buildAttrs.installPhase = ''
    mkdir -p $out/bin
Loading