warricksothr / RustBuild

Scripts and patches to auto build Rustc and Cargo on ARM
MIT License
104 stars 8 forks source link

armv7? Not really #11

Closed MagaTailor closed 8 years ago

MagaTailor commented 8 years ago

I've just noticed the armhf target's code generation was actually geared towards v6 for compatibility.

Seeing as you already provide separate armv6 builds it makes sense for the armv7 ones to generate code for v7, incl. at the time of bootstrapping themselves (curiously it's the default on android.)

Literally we're talking about just two commands before the start of the armv7 build:

sed -i s/v6/v7/ src/librustc_back/target/arm_unknown_linux_gnueabihf.rs

and

sed -i s/v6/v7/ mk/cfg/arm-unknown-linux-gnueabihf.mk

To try out the proposed changes anyone can use the scripts from my fork.

warricksothr commented 8 years ago

Good catch! I'll make the changes and kick off a test build tonight and see if I can run a resulting binary on my odroid.

MagaTailor commented 8 years ago

No worries, I never suggested adding +neon to the default set of features :)

MagaTailor commented 8 years ago

Can we close it? There's probably going to be an official armv7 target anyway so you'll simply switch to that once it's available.

warricksothr commented 8 years ago

Sure, Any news on when that's going to be added as a target?

MagaTailor commented 8 years ago

Not clear yet, but you could add your two cents in that open Rpi PR.

MagaTailor commented 8 years ago

It's done, the new target is called:

armv7-unknown-linux-gnueabihf

However switching to it will require a rebuild of the last stage0 snapshot first, after adding the new target to the list.

warricksothr commented 8 years ago

Good to know. I'll try to get a snapshot built.