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

32-bit x86 Linux build fails #84

Closed
MagaTailor opened this issue Oct 1, 2015 · 7 comments
Closed

32-bit x86 Linux build fails #84

MagaTailor opened this issue Oct 1, 2015 · 7 comments
Assignees

Comments

@MagaTailor
Copy link
Contributor

Trying to build the latest exa master with rust-1.3.0 on 32-bit Slackware ends with:

Compiling scoped_threadpool v0.1.6
Build failed, waiting for other jobs to finish...
failed to run custom build command for `scoped_threadpool v0.1.6`
Process didn't exit successfully: `/home/petevine/exa-master/target/release/build/scoped_threadpool-3092426cc5b469bd/build-script-build` (exit code: 101)
--- stderr
thread '<main>' panicked at 'called `Option::unwrap()` on a `None` value', src/libcore/option.rs:363

The rustc used generates pentium2 code by default. (my own build)

@ogham ogham self-assigned this Oct 1, 2015
@ogham
Copy link
Owner

ogham commented Oct 2, 2015

Hey,

This one isn't failing because you're on a 32-bit install, it's because you're on Rust 1.3.0 (stable). exa requires the nightly because it uses features that have only recently been added, and need some time to stabilise.

The reason that your build is failing on scoped_threadpool rather than exa is that the build script for that crate checks the version at compile time. There's a bug that's been fixed in 1.4.0 but still exists in 1.3.0 that makes scoped threads unsound but still compile successfully, so it checks the version manually rather than just relying on a feature flag.

I had a warning in the Readme that said you should use the nightly, but that warning is so old that the version numbers are out of date! Now fixed -- sorry if that was the source of your confusion. I periodically go through all the unstable features I'm using in #64. Right now we're just waiting for features to settle down.

I recommend installing the nightly or using multirust if you also want to use stable (multirust is great)

@ogham ogham closed this as completed Oct 2, 2015
@MagaTailor
Copy link
Contributor Author

Thanks, I thought I was recent enough.

@MagaTailor
Copy link
Contributor Author

So I repeated the whole build from scratch using 1.5.0 from 20151002 and got the same result - where's the catch? Do I have to clean cargo caches too?

@ogham
Copy link
Owner

ogham commented Oct 4, 2015

Hmm, maybe. It's possible that it's cached the failure from when you tried to compile it last time (I'm not too well-versed on which things stick around and which don't). Try a cargo clean?

@MagaTailor
Copy link
Contributor Author

Even though cargo clean didn't help, I managed to build exa using a different CARGO_HOME.

The only surprise comes from the size difference between the stripped arm and x86 binaries - like a 1:2 ratio.
Both were built with --release so why the difference?

@ogham
Copy link
Owner

ogham commented Oct 4, 2015

I'm not sure! Rust uses LLVM, so maybe there's been more work put into the x86 backend than the ARM one.

@MagaTailor
Copy link
Contributor Author

A little strange as e.g. cargo binaries are roughly the same size.

Never mind! Thanks

@ogham ogham mentioned this issue Nov 4, 2015
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

No branches or pull requests

2 participants