Uh oh!
There was an error while loading. Please reload this page.
std: Remove rust_builtin C support library - #30175
Conversation
rust-highfive
commented
Dec 2, 2015
r? @aturon (rust_highfive has picked a reviewer for you, use r? to override) |
alexcrichton
commented
Dec 2, 2015
brson
commented
Dec 2, 2015
@alexcrichton Can you link me to the libc changes this pulls in? I'm curious what was involved. |
alexcrichton
commented
Dec 2, 2015
So far (although this is likely to grow to be a longer list) it required 2 changes: (the latter of which I now realize still needs to land...) |
steveklabnik
commented
Dec 2, 2015
😍 |
a60b4ab to
b40f355Comparesemarie
commented
Dec 3, 2015
@alexcrichton thanks to Cc me. currently, it breaks at least openbsd. I have manually applied the patch (so I could also had done mistakes). I can't check deeper today, but I will take a look tomorrow. |
alexcrichton
commented
Dec 3, 2015
Thanks @semarie! I've added the imports for |
brson
commented
Dec 3, 2015
@alexcrichton I think I would like the source to explicitly separate the cases where the cast is needed there, via cfg with a FIXME - it seems like it must be a bug right? |
cuviper
commented
Dec 3, 2015
It's a bad thing if these functions ever truncate values for I think we should either fake the |
9bc397c to
977d0bdComparealexcrichton
commented
Dec 3, 2015
I've pushed a commit to remove the cast, and I just started updating the That's a little controversial to me, however, as the types in |
alexcrichton
commented
Dec 3, 2015
And to make my concerns a little more concrete, here's what I'm thinking:
Overall I would propose a plan that looks like:
This will separate us from the C names as well as how they may change depending on how C code is compiled, and it means that we are no longer providing types that are "FFI compatible" as it doesn't always work out. For now we can probably leave the basic integer definitions (e.g. |
977d0bd to
408d523Comparecuviper
commented
Dec 3, 2015
👍 for hiding these and going all 64-bit. Keeping fundamental C types ( |
408d523 to
b7b2faeComparealexcrichton
commented
Dec 16, 2015
re-r? @brson I'd like to move forward on this rather than wait for dealing with questions about other types in play here. Along those lines this patch now preserves the same behavior we have today. |
bors
commented
Dec 17, 2015
☔ The latest upstream changes (presumably #30325) made this pull request unmergeable. Please resolve the merge conflicts. |
b7b2fae to
33d0292Comparebors
commented
Dec 19, 2015
☔ The latest upstream changes (presumably #30381) made this pull request unmergeable. Please resolve the merge conflicts. |
33d0292 to
87f5ee1Comparebors
commented
Dec 20, 2015
☔ The latest upstream changes (presumably #30454) made this pull request unmergeable. Please resolve the merge conflicts. |
87f5ee1 to
a8cb016Comparebrson
commented
Dec 22, 2015
r=me |
bors
commented
Dec 22, 2015
⌛ Testing commit 606369f with merge 1e47505... |
bors
commented
Dec 22, 2015
💔 Test failed - auto-linux-64-x-android-t |
606369f to
b1e0f1aComparealexcrichton
commented
Dec 22, 2015
@bors: r=brson b1e0f1a |
bors
commented
Dec 22, 2015
⌛ Testing commit b1e0f1a with merge 727d7a0... |
bors
commented
Dec 22, 2015
💔 Test failed - auto-linux-64-x-android-t |
All these definitions can now be written in Rust, so do so!
b1e0f1a to
2f42ac4Comparealexcrichton
commented
Dec 22, 2015
All these definitions can now be written in Rust, so do so!
bors
commented
Dec 22, 2015
bors
commented
Dec 22, 2015
The corresopnding C file was removed in rust-lang#30175 and looks like I forgot to remove the header as well.
The corresopnding C file was removed in rust-lang#30175 and looks like I forgot to remove the header as well.
dhuseby
commented
Dec 30, 2015
When #30643 lands, i'll take a close look at the BSD builds and fix anything up that is needed. |
larsbergstrom
commented
Jan 14, 2016
FYI, this did end up breaking Android. It broke rust-errno (https://github.com/lfairy/rust-errno), and getting a fix landed for that is currently blocking Servo's rustup. Maybe we should just backport the symbol removed here ( |
alexcrichton
commented
Jan 14, 2016
@larsbergstrom you can probably fix it temporarily by adding this to any crate: #[cfg(target_os = "android")]#[no_mangle]pubunsafeexternfn__errno_location() -> *muti32{extern{fn__errno() -> *muti32;}__errno()} |
larsbergstrom
commented
Jan 14, 2016
@alexcrichton Yeah, thanks! I was thinking of doing just that. Otherwise, we might have to fork errno, add a submodule for it, add a |
dhuseby
commented
Jan 27, 2016
@alexcrichton@semarie when #31230 and rust-lang/libc#157 land, the BSD builds should be green. |
All these definitions can now be written in Rust, so do so!