| # Copyright 2025 The Pigweed Authors |
| # |
| # 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 |
| # |
| # https://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. |
| |
| # Default to C++17 to ensure compatibility. |
| common --@pigweed//pw_toolchain/cc:cxx_standard=17 |
| common:cxx20 --//pw_toolchain/cc:cxx_standard=20 |
| common --per_file_copt=external/.*,.*\.pb\.cc@-w |
| common --host_per_file_copt=external/.*,.*\.pb\.cc@-w |
| |
| # Don't automatically create __init__.py files. |
| # |
| # This prevents spurious package name collisions at import time, and should be |
| # the default (https://github.com/bazelbuild/bazel/issues/7386). Pigweed's |
| # Python libraries break without this. |
| common --incompatible_default_to_explicit_init_py |
| |
| # Do not attempt to configure an autodetected (local) toolchain. We vendor all |
| # our toolchains, and CI VMs may not have any local toolchain to detect. |
| common --repo_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1 |
| |
| test --@pigweed//pw_kernel:enable_tests=true |
| |
| # ── AST1060 QEMU target configuration ── |
| build:k_common --build_tag_filters=-do_not_build,-kernel_doc_test |
| test:k_common --test_tag_filters=-integration,-do_not_build,-do_not_run_test,-kernel_doc_test |
| test:k_common --@pigweed//pw_kernel:enable_tests=true |
| |
| common:k_qemu_ast1060 --config=k_common |
| common:k_qemu_ast1060 --platforms=//target/ast1060 |
| run:k_qemu_ast1060 --run_under="@pigweed//pw_kernel/tooling:qemu \ |
| --cpu cortex-m4 \ |
| --machine ast1030-evb \ |
| --semihosting \ |
| --image " |
| test:k_qemu_ast1060 --run_under="@pigweed//pw_kernel/tooling:qemu \ |
| --cpu cortex-m4 \ |
| --machine ast1030-evb \ |
| --semihosting \ |
| --image " |
| |
| # AST1060-EVB physical board (no QEMU, flash directly) |
| common:k_ast1060_evb --config=k_common |
| common:k_ast1060_evb --platforms=//target/ast1060-evb |
| |
| # AST1060 virtual (QEMU) — semihosting console, no hardware init |
| common:virt_ast1060_evb --config=k_common |
| common:virt_ast1060_evb --platforms=//target/virt-ast1060-evb |
| run:virt_ast1060_evb --run_under="@pigweed//pw_kernel/tooling:qemu \ |
| --cpu cortex-m4 \ |
| --machine ast1030-evb \ |
| --semihosting \ |
| --image " |
| test:virt_ast1060_evb --run_under="@pigweed//pw_kernel/tooling:qemu \ |
| --cpu cortex-m4 \ |
| --machine ast1030-evb \ |
| --semihosting \ |
| --image " |
| |
| # Remote execution config definitions |
| # =================================== |
| # Use the remote cache. This will only work for users who have permission to access it. |
| common:remote_cache --bes_backend="buildeventservice.googleapis.com" |
| common:remote_cache --bes_instance_name=pigweed-rbe-private |
| common:remote_cache --bes_results_url="https://source.cloud.google.com/results/invocations/" |
| common:remote_cache --bes_timeout=600s |
| common:remote_cache --experimental_remote_cache_eviction_retries=5 |
| common:remote_cache --google_default_credentials=true |
| # Required to use buildeventservice on Bazel 8+. |
| # TODO: b/345556899 -- Remove this flag when no longer required. |
| common:remote_cache --legacy_important_outputs |
| common:remote_cache --remote_cache=grpcs://remotebuildexecution.googleapis.com |
| common:remote_cache --remote_instance_name=projects/pigweed-rbe-private/instances/default-instance |
| common:remote_cache --remote_upload_local_results=false |
| # TODO: https://github.com/bazelbuild/bazel/issues/24867 - This flag breaks |
| # runfiles handling with remote caching, and causes a bunch of |
| # java.io.FileNotFoundException when creating runfiles trees. |
| common:remote_cache --experimental_inprocess_symlink_creation=false |