Skip to content
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] Make MinGW build on mac generate less noise #2959

Merged
merged 1 commit into from
Apr 11, 2019

Conversation

grendello
Copy link
Contributor

For some reason the Windows cross-build on macOS using MinGW leaves behind a lot
of temporary LTO (Link-Time Optimization) files, the result of passing the
-flto flag to the compilers. The temporary files (*.ltrans*), around 280 of
them, are then included in our vsix packages, increasing their size while being
completely useless for the end user.

This commit fixes the issue by turning off LTO for MinGW targets. The
optimization is not really useful there and such fix is faster than tracking why
MinGW on macOS (installed from Homebrew) is behaving the way it is.

For some reason the Windows cross-build on macOS using MinGW leaves behind a lot
of temporary LTO (Link-Time Optimization) files, the result of passing the
`-flto` flag to the compilers. The temporary files (`*.ltrans*`), around 280 of
them, are then included in our vsix packages, increasing their size while being
completely useless for the end user.

This commit fixes the issue by turning off LTO for MinGW targets. The
optimization is not really useful there and such fix is faster than tracking why
MinGW on macOS (installed from Homebrew) is behaving the way it is.
jonpryor added a commit to jonpryor/xamarin-android that referenced this pull request Apr 11, 2019
@jonpryor
Copy link
Member

Kicked off PR #2962 so we can see what the resulting .vsix on d16-1 would be.

@jonpryor jonpryor merged commit 0f2b590 into dotnet:master Apr 11, 2019
jonpryor pushed a commit that referenced this pull request Apr 11, 2019
For some reason the Windows mingw cross-build on macOS using MinGW
leaves behind a lot of temporary LTO (Link-Time Optimization) files,
the result of passing the `-flto` flag to the compilers.
The temporary files (`*.ltrans*`), around 280 of them, are then
included in our d16-1 `.vsix` packages, increasing their size while
being completely useless for the end user.

This commit fixes the issue by turning off LTO for MinGW targets.
The optimization is not really useful there and such fix is faster
than tracking why MinGW on macOS (installed from Homebrew) is
behaving the way it is.
@grendello grendello deleted the build/lto-off-mingw branch April 11, 2019 20:12
@grendello grendello restored the build/lto-off-mingw branch April 12, 2019 21:10
@grendello grendello deleted the build/lto-off-mingw branch November 8, 2021 16:28
@github-actions github-actions bot locked and limited conversation to collaborators Jan 31, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants