-
Notifications
You must be signed in to change notification settings - Fork 58
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
Workaround for compiling firefox with LTO #297
Comments
I have added an lld and binutils ebuild to my dev overlay, this sets the stacksize to 2MB which means both gcc and clang can build firefox/thunderbird with lto enabled. I have updated 76.0_beta4 ebuild also in my devspace with the changes you have submitted here, so pgo will work as well. I am working with toolchain project to try and get them to add binutils change to tree, if they do not will add to musl overlay. Thanks for the work you have done to help improve the mozilla packages for musl users. |
binutils/lld testing versions are in overlay. I will get stable ebuilds added to overlay in a day or so. |
I have managed to compile firefox with lto.

The keypoint is compile
clang
andlld
with more stack size.As documents from musl say, The default stack size on musl is 80KB, while glibc gives a much more big stack (2MB -10MB).
So stack overflow happend when link
libxul.so
The default stack size of a program can be set on link time use
-Wl,-z,stack-size=N
or use binary patch tool: https://github.com/yaegashi/muslstack.Upstream report: llvm/llvm-project#75
The text was updated successfully, but these errors were encountered: