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

coord is not actually no_std compatible #12

Open
cbiffle opened this issue Feb 2, 2019 · 3 comments
Open

coord is not actually no_std compatible #12

cbiffle opened this issue Feb 2, 2019 · 3 comments

Comments

@cbiffle
Copy link

cbiffle commented Feb 2, 2019

Despite being tagged on crates.io, coord is not no_std compatible because of a transitive dependency on std through the num-traits crate.

It looks like the continuous build is only building on Travis's default target (which I'm guessing is x86-64 linux?). Crates that set #[no_std] can still access the std crate if available. To test, try a bare metal target. For example:

$ rustup target add thumbv7em-none-eabihf
$ git clone https://github.com/zesterer/coord-rs.git
$ cd coord-rs
$ cargo build --target thumbv7em-none-eabihf

You'll get an error like the following:

    Checking rustc-serialize v0.3.24
    Checking rand v0.4.6
   Compiling num-iter v0.1.37
    Checking num-traits v0.2.6
error[E0463]: can't find crate for `std`
  |
  = note: the `thumbv7em-none-eabihf` target may not be installed

error: aborting due to previous error

For more information about this error, try `rustc --explain E0463`.
error: Could not compile `rand`.
warning: build failed, waiting for other jobs to finish...
error[E0463]: can't find crate for `std`
  |
  = note: the `thumbv7em-none-eabihf` target may not be installed

error: aborting due to previous error

For more information about this error, try `rustc --explain E0463`.
error[E0463]: can't find crate for `std`
  --> /home/cbiffle/.cargo/registry/src/garden.eu.org-1ecc6299db9ec823/num-traits-0.2.6/src/lib.rs:21:1
   |
21 | extern crate std;
   | ^^^^^^^^^^^^^^^^^ can't find crate
   |
   = note: the `thumbv7em-none-eabihf` target may not be installed

error: aborting due to previous error

For more information about this error, try `rustc --explain E0463`.
error: Could not compile `rustc-serialize`.
warning: build failed, waiting for other jobs to finish...
error: Could not compile `num-traits`.
@zesterer
Copy link
Owner

zesterer commented Feb 3, 2019

Whoops! Sorry about that.

I should probably yank this crate and mark it as deprecated (for the time being). Another crate, vek, has a virtually identical API and objectives, while being far further along the development path. I strongly recommend using it!

@cbiffle
Copy link
Author

cbiffle commented Feb 3, 2019

Tried vek first; same issue there. :-)

@zesterer
Copy link
Owner

zesterer commented Feb 3, 2019

The maintainer generally responds rapidly, so hopefully the issue can be resolved there. As for coord... it's now yanked.

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