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

Example http-client fails to build #21

Closed
tomfitzhenry opened this issue Nov 2, 2023 · 4 comments
Closed

Example http-client fails to build #21

tomfitzhenry opened this issue Nov 2, 2023 · 4 comments

Comments

@tomfitzhenry
Copy link

tomfitzhenry commented Nov 2, 2023

I've tried following https://esp-rs.github.io/no_std-training/ but had troubles compiling the http-client example.

Steps to reproduce (running on NixOS):

$ rustup toolchain install nightly-2023-06-25 --component rust-src --target riscv32imc-unknown-none-elf
$ rustup --version
rustup 1.26.0 (1980-01-01)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active `rustc` version is `rustc 1.72.0-nightly (f7ca9df69 2023-06-24)`
$ git clone https://github.com/esp-rs/no_std-training
$ cd no_std-training/intro/http-client/
$ cargo run --release --example http-client

I have attached the build output: http-client.txt.

I'm not very familiar with Rust, but it looks like dependencies embedded-io and linked_list_allocator failed to build.

I was able to build the hello world, per https://esp-rs.github.io/no_std-training/02_4_hello_world.html .

@tomfitzhenry
Copy link
Author

tomfitzhenry commented Nov 2, 2023

I see Github CI managed to successfully build the http-client example yesterday: https://github.com/esp-rs/no_std-training/actions/runs/6717152244/job/18254507001

This seems like to be PEBKAC? I'll dig more into what the CI is doing differently to me.

@SergioGasquez
Copy link
Member

Just tried reproducing your issue, and I was able to build it successfully, do you mind trying to do cargo clean on the http-client ?

@tomfitzhenry
Copy link
Author

I just managed to get this working, by uninstalling the cargo that I had installed via my OS's package manager.

Per https://nixos.wiki/wiki/Rust, it seems I should just let rustup manage my cargo installation. So be it! :)

Thanks for your help @SergioGasquez

@github-project-automation github-project-automation bot moved this from Todo to Done in esp-rs Nov 2, 2023
@SergioGasquez
Copy link
Member

Oh right, installing Rust via package managers tend to be problematic: https://esp-rs.github.io/book/installation/rust.html

Glad that is now working!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

2 participants