Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion bazel/.bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ common --noenable_bzlmod
common --repo_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1

common --registry=https://bcr.bazel.build/
common --registry=https://raw.githubusercontent.com/envoyproxy/toolshed/662020165c0c7e12c457f336f3197db378f9461e/bazel-registry
common --registry=https://raw.githubusercontent.com/envoyproxy/toolshed/cd3b5dba31694fdaf285093ef2addcab4021f3aa/bazel-registry


#############################################################################
Expand Down
1 change: 1 addition & 0 deletions bazel/compile/test/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ package(default_visibility = ["//visibility:public"])
cc_binary(
name = "hello_world",
srcs = ["hello_world.cc"],
copts = ["-Werror"],
)

# Cross-compilation architecture check tests.
Expand Down
9 changes: 7 additions & 2 deletions bazel/patches/toolchains_llvm.patch
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ diff --git a/toolchain/internal/configure.bzl b/toolchain/internal/configure.bzl
index e0ad59e..e3b8e71 100644
--- a/toolchain/internal/configure.bzl
+++ b/toolchain/internal/configure.bzl
@@ -150,6 +150,60 @@ def llvm_config_impl(rctx):
@@ -150,6 +150,65 @@ def llvm_config_impl(rctx):
use_absolute_paths_sysroot,
)

Expand All @@ -86,6 +86,8 @@ index e0ad59e..e3b8e71 100644
+ ]
+ cxx_lib_link_flags[target_pair] = [
+ "-L" + cxx_lib_path + "/lib",
+ "-l:libc++.a",
+ "-l:libc++abi.a",
+ ]
+ cxx_lib_cxx_flags[target_pair] = [
+ "-nostdinc++",
Expand Down Expand Up @@ -115,7 +117,10 @@ index e0ad59e..e3b8e71 100644
+ merged_stdlib = dict(rctx.attr.stdlib)
+ for target_pair in rctx.attr.cxx_lib.keys():
+ if target_pair not in merged_stdlib:
+ merged_stdlib[target_pair] = "libc++"
+ if target_pair == exec_pair:
+ merged_stdlib[target_pair] = "libc++"
+ else:
+ merged_stdlib[target_pair] = "libc"
+
workspace_name = rctx.name
toolchain_info = struct(
Expand Down
Loading