-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Add new target armv7-unknown-linux-uclibceabihf #79380
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @kennytm (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
This change also required rust-lang/backtrace-rs#396 |
909a8ce
to
a75d773
Compare
I will have to revert the library/backtrace change. |
FYI I think we may not be accepting new targets right now. |
@ykoehler I am working on a libc pull request related to this target. For my use case, I am building my own toolchain via buildroot. The request was made for me to add CI for some uclibc target (e.g. mipsel-unknown-linux-uclibc) but I don't know of a good source for uclibc toolchains, and it's been suggested to me that having CI build its own toolchain may slow the process too much. Do you know of a source for uclibc-based toolchains? |
@skrap I believe that buildroot is a proper way to get such toolchain. Another way would be crosstools-NG, but to my knowledge buildroot is a very popular choice amount the embedded space to generate their toolchain. Otherwise vendors will provides their toolchain but we do not know from which method they selected to build theirs. As such, I think using buildroot or assuming people will use buildroot is a very acceptable decision. |
Regarding this PR, we are not using the last version of uClibc, and I do understand that inside this project we probably should, as such, I may need to adjust its content related to that. For example, the change made to the submodule backtrace would need to be removed since the last version of uClibc has the proper support which I had to disable for our version. |
@camelid sounds totally reasonable, is there are way to mark this PR as dependent on that other one so that this PR gets notified when the other is closed? |
@ykoehler For one, you should add the |
S-blocked can be added with this command: @rustbot label S-blocked |
in terms of being notified, the triage team often checks for s-blocked prs if those are unblocked, |
Ping from triage - |
☔ The latest upstream changes (presumably #81678) made this pull request unmergeable. Please resolve the merge conflicts. |
@JohnCSimon my understanding from the comment from @camelid is that new target are not being accepted at this time. |
I am not certain about that, but that's my understanding. Although I think |
☔ The latest upstream changes (presumably #79608) made this pull request unmergeable. Please resolve the merge conflicts. |
Triage: RFC 2803 has been merged so now it shouldn't block this, right? |
@ykoehler I'm assuming you'll want to be a maintainer of this target (per the new RFC rust-lang/rfcs#2803) . If you want an additional person, I'm happy to be added as well. |
I can confirm that, with rust 1.53.0, this patch allows a full build of rust:
1.52.1 did not build due to missing pwrite64 symbol in libc when building for uclibc targets. (my fault, thx @JohnTitor for the fix!) |
@ykoehler There's an additional commit I'd like to suggest for your branch, which fixes a crash when accessing std::env::args:
|
Ping again from triage: @ykoehler if you can resolve the conflict we can try and push this forward |
@JohnCSimon It seems that this PR's author is not responding. I am interested in pushing this PR forward. Is that possible? If so, how should I proceed? I could file a PR with the same purpose. |
@skrap not sure about the process, maybe contact the reviewer? |
@JohnCSimon The interest for me to pursue this has dropped since our embedded toolchains doesn't have the latest version as it is required in here. From what a gather from this experience, I do not get why rust is not supporting uclibc for all platforms, since basically, it appears to be a matter of building a toolchain with buildroot and enabling the existing exception created for uclibc throughout the code. And the fact that if this PR goes through I suddenly become responsible for this triplet as per rust policy, I found it really strange, since other than compiling this and enabling the uclibc exception there was not much additional work and having the responsibility to then maintain this is outside the time/resources I have available. I will see if I still have this build environment as to fix the conflicts, but if you want to kill this PR and take ownership (and from their policy, responsibility) then I am totally fine with that. |
@ykoehler I'm not affiliated with the Rust project, but I have employer support to maintain this target. If you don't object, I'll submit a new PR based on this one, and I'll be happy to be the contact person for this target triple. (This will still be tier 3 at this point.) |
I am also interested in compiling for First when trying add the target:
So I updated .cargo/config to add it manually:
but when running
I understand the problem is that it needs a crate / source code of uclibc but it's not clear how to supply that. Any help would be appreciated. |
Jonah Petri, please go ahead and proceed.
…On Mon, 13 Sept 2021 at 23:14, Jonah Petri ***@***.***> wrote:
@ykoehler <https://github.com/ykoehler> I'm not affiliated with the Rust
project, but I have employer support to maintain this target. If you don't
object, I'll submit a new PR based on this one, and I'll be happy to be the
contact person for this target triple. (This will still be tier 3 at this
point.)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#79380 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAU45D6PEKKXP6UOC3KAZWTUB24XRANCNFSM4UA7Y4UQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
--
Yannick Koehler
Courriel: ***@***.***
|
Closing in favour of #88952 |
Add new tier-3 target: armv7-unknown-linux-uclibceabihf This change adds a new tier-3 target: armv7-unknown-linux-uclibceabihf This target is primarily used in embedded linux devices where system resources are slim and glibc is deemed too heavyweight. Cross compilation C toolchains are available [here](https://toolchains.bootlin.com/) or via [buildroot](https://buildroot.org). The change is based largely on a previous PR rust-lang#79380 with a few minor modifications. The author of that PR was unable to push the PR forward, and graciously allowed me to take it over. Per the [target tier 3 policy](https://github.com/rust-lang/rfcs/blob/master/text/2803-target-tier-policy.md), I volunteer to be the "target maintainer". This is my first PR to Rust itself, so I apologize if I've missed things!
Add support for armv7 uclibc to rust.
./x.py dist
was successful, testing of toolchains via rustup as well, and binary on platform ldd output was fine and ran properly.
I am unclear how to get the ./x.py test library/std working, would need assistance.