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

gcc: allow stripping gcc libraries #108060

Merged
merged 1 commit into from Jan 22, 2021

Conversation

matthewbauer
Copy link
Member

When cross compiling to the same kernel / arch combination, it is safe
to use strip of libraries. This happens when cross-compiling musl
programs. dontStrip is now set in each gcc compiler instead of in
gcc/builder.sh.

Fixes #75476

@teburd
Copy link
Contributor

teburd commented Jan 11, 2021

As I understand it this doesn't yet fix the issue of inadvertant glibc references when cross compiling to a different arch is that correct? Is that because strip would otherwise mis-interpret the libraries involved?

@teburd
Copy link
Contributor

teburd commented Jan 12, 2021

I can verify this does indeed solve the inclusion of glibc when using pkgsMusl or crossSystem x86_64-unknown-linux-musl. Of course attempting the cross compiled (aarch64-unknown-linux-musl) does not yet remove the glibc dependency as expected given the changes here

When cross compiling to the same kernel / arch combination, it is safe
to use strip of libraries. This happens when cross-compiling musl
programs. dontStrip is now set in each gcc compiler instead of in
gcc/builder.sh.

Fixes NixOS#75476
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Closure size of musl C++ programs bloated due to location of libstdc++
3 participants