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 .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.0.0-pre.20220706.4
6.0.0rc1
9 changes: 3 additions & 6 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,9 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
load(
"//bazel:repositories.bzl",
"docker_dependencies",
"googletest_repositories",
"istioapi_dependencies",
)

googletest_repositories()

istioapi_dependencies()

bind(
Expand All @@ -38,10 +35,10 @@ bind(
# 2. Update .bazelversion, envoy.bazelrc and .bazelrc if needed.
#
# Note: this is needed by release builder to resolve envoy dep sha to tag.
# Commit date: 2022-10-31
ENVOY_SHA = "c854b59e2851f88f813b0b0188253f9671ae8c2b"
# Commit date: 2022-11-02
ENVOY_SHA = "158a28b87cb3dda336392e5ca51941d532cfb8dd"

ENVOY_SHA256 = "c6d3ba6ff7271aa086c27a08a5f2e0811328d12d454c4305f6e33ebd25ead402"
ENVOY_SHA256 = "47278128ed7501d3d95c163f0115134eef129f14ae6b67df1414bbf69e87bdad"

ENVOY_ORG = "envoyproxy"

Expand Down
3 changes: 3 additions & 0 deletions bazel/extension_config/extensions_build_config.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ ENVOY_EXTENSIONS = {
"envoy.clusters.aggregate": "//source/extensions/clusters/aggregate:cluster",
"envoy.clusters.dynamic_forward_proxy": "//source/extensions/clusters/dynamic_forward_proxy:cluster",
"envoy.clusters.redis": "//source/extensions/clusters/redis:redis_cluster",
"envoy.clusters.original_dst": "//source/extensions/clusters/original_dst:original_dst_cluster_lib",

#
# Compression
Expand Down Expand Up @@ -387,3 +388,5 @@ EXTENSIONS = dict([(k,v) for k,v in ENVOY_EXTENSIONS.items() if not k in ISTIO_D
EXTENSION_CONFIG_VISIBILITY = ["//visibility:public"]
EXTENSION_PACKAGE_VISIBILITY = ["//visibility:public"]
CONTRIB_EXTENSION_PACKAGE_VISIBILITY = ["//visibility:public"]

LEGACY_ALWAYSLINK = True
88 changes: 2 additions & 86 deletions bazel/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -16,89 +16,6 @@
#
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

GOOGLETEST = "d225acc90bc3a8c420a9bcd1f033033c1ccd7fe0"
GOOGLETEST_SHA256 = "01508c8f47c99509130f128924f07f3a60be05d039cff571bb11d60bb11a3581"

def googletest_repositories(bind = True):
BUILD = """
# Copyright 2017 Istio Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
################################################################################
#
cc_library(
name = "googletest",
srcs = [
"googletest/src/gtest-all.cc",
"googlemock/src/gmock-all.cc",
],
hdrs = glob([
"googletest/include/**/*.h",
"googlemock/include/**/*.h",
"googletest/src/*.cc",
"googletest/src/*.h",
"googlemock/src/*.cc",
]),
includes = [
"googlemock",
"googletest",
"googletest/include",
"googlemock/include",
],
visibility = ["//visibility:public"],
)
cc_library(
name = "googletest_main",
srcs = ["googlemock/src/gmock_main.cc"],
visibility = ["//visibility:public"],
deps = [":googletest"],
)
cc_library(
name = "googletest_prod",
hdrs = [
"googletest/include/gtest/gtest_prod.h",
],
includes = [
"googletest/include",
],
visibility = ["//visibility:public"],
)
"""
http_archive(
name = "googletest_git",
build_file_content = BUILD,
strip_prefix = "googletest-" + GOOGLETEST,
url = "https://github.com/google/googletest/archive/" + GOOGLETEST + ".tar.gz",
sha256 = GOOGLETEST_SHA256,
)

if bind:
native.bind(
name = "googletest",
actual = "@googletest_git//:googletest",
)

native.bind(
name = "googletest_main",
actual = "@googletest_git//:googletest_main",
)

native.bind(
name = "googletest_prod",
actual = "@googletest_git//:googletest_prod",
)

#
# To update these...
# 1) find the ISTIO_API SHA you want in git
Expand Down Expand Up @@ -208,7 +125,6 @@ def istioapi_dependencies():
def docker_dependencies():
http_archive(
name = "io_bazel_rules_docker",
sha256 = "59d5b42ac315e7eadffa944e86e90c2990110a1c8075f1cd145f487e999d22b3",
strip_prefix = "rules_docker-0.17.0",
urls = ["https://github.com/bazelbuild/rules_docker/releases/download/v0.17.0/rules_docker-v0.17.0.tar.gz"],
sha256 = "b1e80761a8a8243d03ebca8845e9cc1ba6c82ce7c5179ce2b295cd36f7e394bf",
urls = ["https://github.com/bazelbuild/rules_docker/releases/download/v0.25.0/rules_docker-v0.25.0.tar.gz"],
)
5 changes: 5 additions & 0 deletions envoy.bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ build:linux --features=per_object_debug_info
build:linux --action_env=BAZEL_LINKLIBS=-l%:libstdc++.a
build:linux --action_env=BAZEL_LINKOPTS=-lm

# TODO(keith): remove once https://github.com/DataDog/dd-opentracing-cpp/pull/252 is integrated
# this avoids warnings/errors on arm64 Linux builds
build:linux --per_file_copt=external/com_github_datadog_dd_opentracing_cpp/.*.cpp@-Wno-type-limits

# We already have absl in the build, define absl=1 to tell googletest to use absl for backtrace.
build --define absl=1

Expand Down Expand Up @@ -373,6 +377,7 @@ build:windows --define tcmalloc=disabled
build:windows --define wasm=disabled
build:windows --define manual_stamp=manual_stamp
build:windows --cxxopt="/std:c++17"
build:windows --output_groups=+pdb_file

# TODO(wrowe,sunjayBhatia): Resolve bugs upstream in curl and rules_foreign_cc
# See issue https://github.com/bazelbuild/rules_foreign_cc/issues/301
Expand Down
2 changes: 1 addition & 1 deletion scripts/release-binary.sh
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ if [ -n "${DST}" ]; then
cp "${BAZEL_COMPILED_TARGET}" "${WASM_COMPILED_PATH}"
sha256sum "${WASM_PATH}" > "${SHA256_PATH}"
sha256sum "${WASM_COMPILED_PATH}" > "${SHA256_COMPILED_PATH}"

# push wasm files and sha to the given bucket
gsutil stat "${DST}/${WASM_NAME}" \
&& { echo "WASM file ${WASM_NAME} already exist"; continue; } \
Expand Down