Skip to content

Commit c650ea7

Browse files
konkersCQ Bot Account
authored and
CQ Bot Account
committed
build: Use -Oz for Rust toolchains with prebuilt targets
This bring those in line with the non-prebuilt target toolchains. Change-Id: I6e318095f9840e0b6a6878d94ac546f0e1c42388 Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/263096 Commit-Queue: Auto-Submit <auto-submit@pigweed-service-accounts.iam.gserviceaccount.com> Lint: Lint 🤖 <android-build-ayeaye@system.gserviceaccount.com> Presubmit-Verified: CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Ted Pudlik <tpudlik@google.com> Pigweed-Auto-Submit: Erik Gilling <konkers@google.com> Docs-Not-Needed: Erik Gilling <konkers@google.com>
1 parent 702dd6b commit c650ea7

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

MODULE.bazel.lock

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pw_toolchain/rust/templates.bzl

+5
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,11 @@ rust_toolchain(
7979
dylib_ext = "{dylib_ext}",
8080
exec_compatible_with = {exec_compatible_with},
8181
exec_triple = "{exec_triple}",
82+
opt_level = {{
83+
"dbg": "0",
84+
"fastbuild": "0",
85+
"opt": "z",
86+
}},
8287
rust_doc = "{toolchain_repo}//:bin/rustdoc",
8388
rust_std = "{target_repo}//:rust_std",
8489
rustc = "{toolchain_repo}//:bin/rustc",

0 commit comments

Comments
 (0)