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

Add support for powerpc #569

Closed
wants to merge 1 commit into from
Closed

Add support for powerpc #569

wants to merge 1 commit into from

Conversation

vorner
Copy link

@vorner vorner commented Apr 5, 2017

Define the architecture-dependent syscall numbers (taken from the
corresponding powerpc's header file). This allows compiling and using
the crate for powerpc targets (like the builtin
powerpc-unknown-linux-gnu).

This should probably fix #534 (as well as my problem).

I'm a bit unsure about the correct way to update the changelog. It seems the entries contain the number of pull request, but how do I get it in advance before sending the pull request?

@Susurrus
Copy link
Contributor

Susurrus commented Apr 5, 2017

I saw some previous discussion on this and shouldn't these numbers be pulled from the libc crate even if they need to be declared as SysCall types in nix?

Re the changelog, you can guess the PR number as it's just the next available number of issues/PRs for the repo. But I've only ever added them after the fact, so that's a good point.

@vorner
Copy link
Author

vorner commented Apr 5, 2017

@Susurrus I don't know about any discussion. I basically just tried to cross-compile and got an error, looked into the file it complained about, saw how the other the platforms were handled and stuck with the rest. I'm certainly not the right person to rewrite the whole file as my first submission to this project, though it did strike me as somewhat fragile to hard-code the numbers by hand.

@Susurrus
Copy link
Contributor

Susurrus commented Apr 5, 2017

I'm referring to #341 which kind of talks about this. I guess we should push this and sort out how we want to address with the syscall constants. If you're interested, it'd be great if you wanted to look into how we might get these constants added to rust-lang/libc. I think they'd be okay with that, but I guess we should start that discussion.

Define the architecture-dependent syscall numbers (taken from the
corresponding powerpc's header file). This allows compiling and using
the crate for powerpc targets (like the builtin
powerpc-unknown-linux-gnu).
@vorner
Copy link
Author

vorner commented Apr 6, 2017

I'd appreciate that approach (pushing this first, and then starting the discussion ‒ the discussion might take some time).

I might come up with an idea or comment, but again, I don't feel like being the right person to start the discussion ‒ basically, there's nearly no relation between me and either crate.

@kamalmarhubi
Copy link
Member

kamalmarhubi commented Apr 6, 2017

I'd appreciate that approach (pushing this first, and then starting the discussion ‒ the discussion might take some time).

This makes sense to me. The syscall revamp is a lot of tedious work, and will probably be a while coming.

@Susurrus
Copy link
Contributor

Susurrus commented Apr 6, 2017

I'm going to close this in favor of already-existing work done in #553, which covers a few other additional cases as well. If you were willing to look that PR over as well and maybe give it a compilation test locally, @vorner, it'd be most appreciated! Thanks however for filing this PR @vorner!

@Susurrus Susurrus closed this Apr 6, 2017
@vorner
Copy link
Author

vorner commented Apr 7, 2017

OK, that's fine with me. I tested the other PR and it solves my problem with compilation. Thank you.

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.

TRUST CI: powerpc-unknown-linux-gnu Compilation Errors
3 participants