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

Error Compiling on tokio-rustls v0.10.2 #46

Closed
Wayc0des-Land opened this issue Nov 26, 2019 · 6 comments
Closed

Error Compiling on tokio-rustls v0.10.2 #46

Wayc0des-Land opened this issue Nov 26, 2019 · 6 comments
Labels
not-a-bug This doesn't seem a software bug.

Comments

@Wayc0des-Land
Copy link

Hi,

I got error when try cargo build --release

error: enum variants on type aliases are experimental
   --> /home/wayc0de/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-rustls-0.10.2/src/lib.rs:260:9
    |
260 |         Self::Client(s)
    |         ^^^^^^^^^^^^

error: enum variants on type aliases are experimental
   --> /home/wayc0de/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-rustls-0.10.2/src/lib.rs:266:9
    |
266 |         Self::Server(s)
    |         ^^^^^^^^^^^^

error: aborting due to 2 previous errors

error: Could not compile `tokio-rustls`.
warning: build failed, waiting for other jobs to finish...
error: build failed

Hope you can help me

Thank you

@Edu4rdSHL
Copy link
Member

You need to update the Rust version to latest stable (1.39.0). What's the output for rustc -V? If you have a version less than 1.39.0 then you need to update it.

@Wayc0des-Land
Copy link
Author

wayc0de@DESKTOP-9C0TVKV:~/.cargo/bin$ ./rustc -V
rustc 1.39.0 (4560ea788 2019-11-04

@Edu4rdSHL
Copy link
Member

Are you sure the cargo command that you are using when building is from $HOME/.cargo/bin ? Use command -v rustc

@Wayc0des-Land
Copy link
Author

wayc0de@DESKTOP-9C0TVKV:~$ command -v rustc
/usr/bin/rustc

@Edu4rdSHL
Copy link
Member

That's the problem, when you run cargo you're using the binary installed in /usr/bin instead of $HOME/.cargo/bin.

Uninstall the package that owns the binary in /usr/bin, add $HOME/.cargo/bin to your PATH and try again or just use a full qualified PATH to call the cargo binary.

@Wayc0des-Land
Copy link
Author

solved

I add this to my .bashrc

export PATH="$HOME/.cargo/bin:$PATH"

thank you sir

@Edu4rdSHL Edu4rdSHL added the not-a-bug This doesn't seem a software bug. label Nov 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
not-a-bug This doesn't seem a software bug.
Projects
None yet
Development

No branches or pull requests

2 participants