-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
build: More sizeopt fixes #23996
build: More sizeopt fixes #23996
Conversation
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
cc @jpsim |
I assume if we did this we could remove release-common in E-M bazelrc and do custom options in build:release-ios and build:release-android, WDYT? |
The other way to do this would be
where we'd only pass the I don't feel strongly here. Doing it the way you're proposing in this PR would probably require the fewest changes to the places where we use |
.bazelrc
Outdated
@@ -160,6 +160,7 @@ build:libc++ --define force_libcpp=enabled | |||
|
|||
# Optimize build for binary size reduction. | |||
build:sizeopt -c opt --copt -Os --linkopt=-Wl,--gc-sections | |||
build:macossizeopt -c opt --copt -Os |
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.
This isn't macOS-specific, it's non-ELF, which is all apple platforms and Windows.
build:macossizeopt -c opt --copt -Os | |
build:nonelfsizeopt -c opt --copt -Os |
Don't love that name either. Naming wise it's definitely easier to flip the defaults with sizeopt
and gcsections
,
ok, let's priotitize unbreak, then I'll work on replacing where we use sizeopt. |
Signed-off-by: Alyssa Wilk alyssar@chromium.org
Commit Message:
Additional Description:
Risk Level:
Testing:
Docs Changes:
Release Notes:
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Fixes commit #PR or SHA]
[Optional Deprecated:]
[Optional API Considerations:]