-
Notifications
You must be signed in to change notification settings - Fork 83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migrate to Bazel 5.0.0 #2034
Merged
Merged
Migrate to Bazel 5.0.0 #2034
Changes from all commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
93b9c63
envoy: 71248e512
jpsim 435a068
Intercept stream idle timeout events and propagate to errors
jpsim 662a6af
Empty commit to re-run CI
jpsim fdb8fa1
format
jpsim 6fff489
Empty commit to re-run CI
jpsim ee8ff64
fixup! Empty commit to re-run CI
jpsim 174239c
Merge branch 'main' into envoy-71248e512
jpsim 7408ccf
Fix rules_android-0.1.1 checksum
jpsim 13ab5bf
Revert rules_android checksum
jpsim 4841c33
Bump Envoy to 49f3d95
jpsim 63d56e5
WIP: Use Bazel 5
jpsim 5804bed
Migrate EngFlow configurations from rbe_autoconfig to rbe_configs_gen
jpsim a8987be
Merge remote-tracking branch 'origin/main' into bazel-5
jpsim 006da8f
Add tmate session to python_tests CI job
jpsim 2327a92
WIP: Remove android_sdk_repository references in WORKSPACE
jpsim b16319b
Fix toolchain
jpsim 4f6c9f8
Set Pool in exec_properties
jpsim ee9d209
Add workaround for https://github.com/bazelbuild/bazel/issues/2722
jpsim a77a0e7
fixup! Add workaround for https://github.com/bazelbuild/bazel/issues/…
jpsim cba9d40
Merge branch 'main' into bazel-5
jpsim 00a0557
Comment out android_ndk_repository line in WORKSPACE file
jpsim b11cd4d
fixup! Comment out android_ndk_repository line in WORKSPACE file
jpsim a97ba24
bazel: Add androidndk fetching workaround
keith 3047dae
Revert "Comment out android_ndk_repository line in WORKSPACE file"
jpsim File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
"""Repository rule for Android SDK and NDK autoconfiguration. | ||
|
||
This rule is a no-op unless the required android environment variables are set. | ||
""" | ||
|
||
# Based on https://github.com/tensorflow/tensorflow/tree/34c03ed67692eb76cb3399cebca50ea8bcde064c/third_party/android | ||
# Workaround for https://github.com/bazelbuild/bazel/issues/14260 | ||
|
||
_ANDROID_NDK_HOME = "ANDROID_NDK_HOME" | ||
_ANDROID_SDK_HOME = "ANDROID_HOME" | ||
|
||
def _android_autoconf_impl(repository_ctx): | ||
sdk_home = repository_ctx.os.environ.get(_ANDROID_SDK_HOME) | ||
ndk_home = repository_ctx.os.environ.get(_ANDROID_NDK_HOME) | ||
|
||
sdk_rule = "" | ||
if sdk_home: | ||
sdk_rule = """ | ||
native.android_sdk_repository( | ||
name="androidsdk", | ||
path="{}", | ||
api_level=30, | ||
build_tools_version="30.0.2", | ||
) | ||
""".format(sdk_home) | ||
|
||
ndk_rule = "" | ||
if ndk_home: | ||
ndk_rule = """ | ||
native.android_ndk_repository( | ||
name="androidndk", | ||
path="{}", | ||
api_level=21, | ||
) | ||
""".format(ndk_home) | ||
|
||
if ndk_rule == "" and sdk_rule == "": | ||
sdk_rule = "pass" | ||
|
||
repository_ctx.file("BUILD.bazel", "") | ||
repository_ctx.file("android_configure.bzl", """ | ||
def android_workspace(): | ||
{} | ||
{} | ||
""".format(sdk_rule, ndk_rule)) | ||
|
||
android_configure = repository_rule( | ||
implementation = _android_autoconf_impl, | ||
environ = [ | ||
_ANDROID_NDK_HOME, | ||
_ANDROID_SDK_HOME, | ||
], | ||
) |
Submodule envoy
updated
49 files
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a new way to provide these values on Bazel 5.0 if you want to preserve this. At minimum you might want to provide the
java_language_version
andtool_java_language_version
just to make sure that it's consistent moving forward.Ex:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are actually defined in Envoy now, and we import that
.bazelrc
file: https://github.com/envoyproxy/envoy/blob/708742e9e8ec44e634a02d16eee0dce826130298/.bazelrc#L19-L20