-
Notifications
You must be signed in to change notification settings - Fork 114
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
Support PowerPC: mrustc itself builds fine, rust tries to build for x86 and fails #300
Comments
The compiler defaults to compiling for the architecture it's running on... but that error does seem to imply that there's a different architecture involved (and or something even stranger, given the very large array size). What platform are you running on, and what is the output of |
This is natively on PowerPC. I tried building it in emulation via Rosetta, it failed earlier and I gave up on that (no specific value it having it in Rosetta anyway besides extra testing).
I need to build it again, will try that tonight and update you. |
@thepowersgang This was insightful: while it builds on PPC as a ppc binary, target settings are totally off:
How to fix this? Obviously, target should be Big-endian and ppc (32-bit). |
Ah, just looked at the source - the default for apple is x86. |
@thepowersgang
I.e. it is the OS default for languages it uses. I am not sure about Rust here. |
@thepowersgang
|
With fixed target, x86 is no longer pulled, but
Given it refers to VSX, that has to be disabled, it is not supported before ISA 2.06 or so. |
Yeah, this code in
|
Altivec code appears broken, so I disabled it together with VSX in Build still fails though here:
@thepowersgang What to do about this |
Re |
Re |
Then leave it as is. |
@thepowersgang Could you please advise more specifically here, what and where to fix? |
If you search for that message, you will find three locations for it - |
Big-endian support added in b57ddbf |
@thepowersgang Awesome, thank you! I should be able to test it in a few days (been away from my PPC hardware for a while, returning now). P. S. @catap FYI. |
@thepowersgang Ok, building from master 38c9db2 and setting Rust arch to
What should I do about this? |
Besides, we will need something like this to avoid VSX on Darwin:
|
Cannot reproduce with |
If it expects the target in this exotic way, then I should try using |
uhh... my bad on the command I said I ran. This implies that the error is caused by something about running on PPC (or the compiler you're using) |
@thepowersgang Thank you for clarifying. The problem may well be on Macports set-up side: either incompatibility of some of our patches with Compiler should be good: GCC upstream supports Darwin PowerPC, and |
I'm not saying that it's not a mrustc bug - it very likely is - but it's not happening on the test setups I have, so is probably some bug that is being exposed by being run on ppc. |
What is needed to support building for PowerPC? Currently
mrustc
builds, butrust
tries to build for x86:See also: https://trac.macports.org/ticket/65942
The text was updated successfully, but these errors were encountered: