From 51114edb8f88d2c2bd46a3667693f18109ef4d31 Mon Sep 17 00:00:00 2001 From: betaboon Date: Fri, 22 Apr 2022 19:21:15 +0200 Subject: [PATCH] bazel_3: fix build with gcc11 --- .../build-managers/bazel/bazel_3/default.nix | 2 ++ .../build-managers/bazel/bazel_3/gcc11.patch | 24 +++++++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 pkgs/development/tools/build-managers/bazel/bazel_3/gcc11.patch diff --git a/pkgs/development/tools/build-managers/bazel/bazel_3/default.nix b/pkgs/development/tools/build-managers/bazel/bazel_3/default.nix index 3a5c9e2e76fd..c5f61e7d25c3 100644 --- a/pkgs/development/tools/build-managers/bazel/bazel_3/default.nix +++ b/pkgs/development/tools/build-managers/bazel/bazel_3/default.nix @@ -186,6 +186,8 @@ stdenv.mkDerivation rec { # we accept this fact because xcode_locator is only a short-lived process used during the build. ./no-arc.patch + ./gcc11.patch + # --experimental_strict_action_env (which may one day become the default # see bazelbuild/bazel#2574) hardcodes the default # action environment to a non hermetic value (e.g. "/usr/local/bin"). diff --git a/pkgs/development/tools/build-managers/bazel/bazel_3/gcc11.patch b/pkgs/development/tools/build-managers/bazel/bazel_3/gcc11.patch new file mode 100644 index 000000000000..450bcd114776 --- /dev/null +++ b/pkgs/development/tools/build-managers/bazel/bazel_3/gcc11.patch @@ -0,0 +1,24 @@ +diff --git a/third_party/ijar/mapped_file_unix.cc b/third_party/ijar/mapped_file_unix.cc +index 6e3a908..030e9ca 100644 +--- a/third_party/ijar/mapped_file_unix.cc ++++ b/third_party/ijar/mapped_file_unix.cc +@@ -19,6 +19,7 @@ + #include + + #include ++#include + + #include "third_party/ijar/mapped_file.h" + +diff --git a/third_party/ijar/zlib_client.h b/third_party/ijar/zlib_client.h +index ed66163..c4b051e 100644 +--- a/third_party/ijar/zlib_client.h ++++ b/third_party/ijar/zlib_client.h +@@ -16,6 +16,7 @@ + #define THIRD_PARTY_IJAR_ZLIB_CLIENT_H_ + + #include ++#include + + #include "third_party/ijar/common.h" +