-
Notifications
You must be signed in to change notification settings - Fork 6
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
Arm support #3
base: master
Are you sure you want to change the base?
Arm support #3
Conversation
I used a new Rust target `armv7-unknown-l4re-uclibceabihf` for compiling the code.
For this I bootstrapped the Rust compiler: https://github.com/Steav005/rust/tree/update-l4re-target
I see. We might want to upstream this once we've merged here.
Ill change this into a proper Pull Request once I created a pull request for [libc](https://github.com/rust-lang/libc) to integrate my changes.
Ok, sounds good. Please upstream libc as you said and hopefully we got your
other change merged until then.
Thanks
|
Can we try to make progress on this? I'm preparing patches for aarch64, depending on your response, you might want to rebase your work on top of this. |
It looks like libc is not going to pull my libc changes, because the libc code of mine would only be relevant for a custom rust-toolchain. |
So unless the rust compiler gets support for l4re on arm and l4bender, they will probably not merge.
I see their point. For my aarch64-specific stuff, I've patched libc, i.e.
replaced `libc =` with a path local in the repo for all Rust crates. Is there
a way to conditionally patch dependencies, i.e. for aarch64/aarch32, use x,
but for everything else y? I'm afraid that this is not possible at the level
of Cargo.toml.
|
I've looked at the code that I wrote recently and I used an abstraction. I'm
currently reworking the code and cleaning it up. Please have a look at the
(temporary feature branch)
[aarch64](https://github.com/humenda/rustl4re/tree/aarch64/src/l4/pkg/l4rust/core-ffi-helpers).
I already reworked l4-sys-rust to rely on core-ffi-helpers which makes it work
for x86_64 (libc) and aarch64 (custom types). What do you think? If you deems
this useful, I'd merge those commits to master and you could rebase your
changes onto master to also use core-ffi-helpers and avoid the patched libc
version.
|
This crate groups a few C FFI related helpers that are lacking in systems without std and libc support.
I've looked at the aarch64 branch and I like the Idea with the core-ffi-helpers. |
Did you already add an aarch64 target for l4re to your rust-toolchain? |
Hi @Steav005 I am aware that after this time, one could have regarded this as abandoned. |
Added Arm support to this project.
I used a new Rust target
armv7-unknown-l4re-uclibceabihf
for compiling the code.For this I bootstrapped the Rust compiler: https://github.com/Steav005/rust/tree/update-l4re-target
using
make setup
, selectingarm-virt-pl2
andmake
works flawlessly.Running
make qemu PLATFORM_TYPE=arm_virt
afterwards inobj/l4/arm-v7
also works.Both examples
basic_ipc
(Rust) andhello_shared
(C) seem to run.(Of course all of this still works for
amd64
as well)Made this into a draft because currently I am using my own patch of libc:
https://github.com/Steav005/libc
Ill change this into a proper Pull Request once I created a pull request for libc to integrate my changes.