diff --git a/.bazelci/presubmit.yml b/.bazelci/presubmit.yml index 0890c00e7a..80a461bdcb 100644 --- a/.bazelci/presubmit.yml +++ b/.bazelci/presubmit.yml @@ -332,8 +332,9 @@ tasks: platform: ubuntu2004 working_directory: examples/basic-gazelle build_flags: - - "--incompatible_config_setting_private_default_visibility" - - "--incompatible_enforce_config_setting_visibility" + - "--config=incompatible" + test_flags: + - "--config=incompatible" build_targets: - "//..." test_targets: @@ -343,8 +344,9 @@ tasks: platform: macos working_directory: examples/basic-gazelle build_flags: - - "--incompatible_config_setting_private_default_visibility" - - "--incompatible_enforce_config_setting_visibility" + - "--config=incompatible" + test_flags: + - "--config=incompatible" build_targets: - "//..." test_targets: @@ -354,33 +356,19 @@ tasks: platform: windows working_directory: examples/basic-gazelle build_flags: - - "--incompatible_config_setting_private_default_visibility" - - "--incompatible_enforce_config_setting_visibility" + - "--config=incompatible" # Go requires a C toolchain that accepts options and emits errors like # gcc or clang. The Go SDK does not support MSVC. - - "--cpu=x64_windows" - - "--compiler=mingw-gcc" - '--action_env=PATH=C:\tools\msys64\usr\bin;C:\tools\msys64\bin;C:\tools\msys64\mingw64\bin;C:\python3\Scripts\;C:\python3;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Windows\System32\OpenSSH;C:\ProgramData\GooGet;C:\Program Files\Google\Compute Engine\metadata_scripts;C:\Program Files (x86)\Google\Cloud SDK\google-cloud-sdk\bin;C:\Program Files\Google\Compute Engine\sysprep;C:\ProgramData\chocolatey\bin;C:\Program Files\Git\cmd;C:\tools\msys64\usr\bin;c:\openjdk\bin;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files\CMake\bin;c:\ninja;c:\bazel;c:\buildkite' # NOTE(bazelbuild/bazel#10529): bazel doesn't register the mingw toolchain automatically. # We also need the host and target platforms to have the mingw constraint value. - - "--extra_toolchains=@local_config_cc//:cc-toolchain-x64_windows_mingw" - - "--host_platform=@io_bazel_rules_go//go/toolchain:windows_amd64_cgo" - - "--platforms=@io_bazel_rules_go//go/toolchain:windows_amd64_cgo" - - "--incompatible_enable_cc_toolchain_resolution" build_targets: - "//..." test_targets: - "//..." test_flags: - # Go requires a C toolchain that accepts options and emits errors like - # gcc or clang. The Go SDK does not support MSVC. - - "--cpu=x64_windows" - - "--compiler=mingw-gcc" + - "--config=incompatible" - '--action_env=PATH=C:\tools\msys64\usr\bin;C:\tools\msys64\bin;C:\tools\msys64\mingw64\bin;C:\python3\Scripts\;C:\python3;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Windows\System32\OpenSSH;C:\ProgramData\GooGet;C:\Program Files\Google\Compute Engine\metadata_scripts;C:\Program Files (x86)\Google\Cloud SDK\google-cloud-sdk\bin;C:\Program Files\Google\Compute Engine\sysprep;C:\ProgramData\chocolatey\bin;C:\Program Files\Git\cmd;C:\tools\msys64\usr\bin;c:\openjdk\bin;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files\CMake\bin;c:\ninja;c:\bazel;c:\buildkite' - - "--extra_toolchains=@local_config_cc//:cc-toolchain-x64_windows_mingw" - - "--host_platform=@io_bazel_rules_go//go/toolchain:windows_amd64_cgo" - - "--platforms=@io_bazel_rules_go//go/toolchain:windows_amd64_cgo" - - "--incompatible_enable_cc_toolchain_resolution" # On Windows CI, bazel (bazelisk) needs %LocalAppData% to find the cache directory. # We invoke bazel in tests, so the tests need this, too. - "--test_env=LOCALAPPDATA" diff --git a/examples/basic-gazelle/.bazelrc b/examples/basic-gazelle/.bazelrc new file mode 100644 index 0000000000..eaa91b9ed0 --- /dev/null +++ b/examples/basic-gazelle/.bazelrc @@ -0,0 +1 @@ +import %workspace%/../../.bazelrc diff --git a/examples/basic-gazelle/WORKSPACE b/examples/basic-gazelle/WORKSPACE index 7a914a0931..7a7104c687 100644 --- a/examples/basic-gazelle/WORKSPACE +++ b/examples/basic-gazelle/WORKSPACE @@ -16,10 +16,10 @@ http_archive( # Download the bazel_gazelle ruleset. http_archive( name = "bazel_gazelle", - sha256 = "efbbba6ac1a4fd342d5122cbdfdb82aeb2cf2862e35022c752eaddffada7c3f3", + sha256 = "727f3e4edd96ea20c29e8c2ca9e8d2af724d8c7778e7923a854b2c80952bc405", urls = [ - "https://mirror.bazel.build/github.com/bazelbuild/bazel-gazelle/releases/download/v0.27.0/bazel-gazelle-v0.27.0.tar.gz", - "https://github.com/bazelbuild/bazel-gazelle/releases/download/v0.27.0/bazel-gazelle-v0.27.0.tar.gz", + "https://mirror.bazel.build/github.com/bazelbuild/bazel-gazelle/releases/download/v0.30.0/bazel-gazelle-v0.30.0.tar.gz", + "https://github.com/bazelbuild/bazel-gazelle/releases/download/v0.30.0/bazel-gazelle-v0.30.0.tar.gz", ], )