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

Extract std::libc to its own crate #13315

Merged
merged 4 commits into from
Apr 6, 2014
Merged

Extract std::libc to its own crate #13315

merged 4 commits into from
Apr 6, 2014

Conversation

alexcrichton
Copy link
Member

Rebasing of #12526 with a very obscure bug fixed on windows.

These wrappers are bound to a specific libc, and they don't need to be part of
libstd.
This was quite a curious bug on windows, and the details can be found in the
comment I added to src/librustc/back/link.rs
bors added a commit that referenced this pull request Apr 6, 2014
Rebasing of #12526 with a very obscure bug fixed on windows.
@bors bors closed this Apr 6, 2014
@bors bors merged commit 38f7a1b into rust-lang:master Apr 6, 2014
@alexcrichton alexcrichton deleted the libc branch April 6, 2014 16:49
JohnTitor added a commit to JohnTitor/rust that referenced this pull request Nov 12, 2019
… r=alexcrichton

Drop long-section-names linker workaround for windows-gnu

If we can trust objdump Rust doesn't emit sections loaded at runtime longer than 8 characters on windows-gnu (but still does on linux-gnu), debug sections are not affected by that limit.
I've ran tests and built few crates using exactly the same mingw-w64 version as Rusts CI just fine using **x86_64** toolchain.

The motivation for this change is making LLD work (it doesn't support `--enable-long-section-names`) with this target without hacks.

Bit of history:
The behaviour of LD changed in Binutils 2.20 released on 2009-10-16 and `--enable-long-section-names` was added to return to the old non conformant behaviour. Looking at the comment I can only guess there was a bug fixed in newer versions.

This workaround was added in rust-lang#13315 half a decade ago.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants