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

Build configure fails due to missing Cargo #3772

Closed
itarato opened this issue Feb 28, 2017 · 9 comments
Closed

Build configure fails due to missing Cargo #3772

itarato opened this issue Feb 28, 2017 · 9 comments

Comments

@itarato
Copy link

itarato commented Feb 28, 2017

I've noticed the Cargo documentation seems to require Cargo already installed on the system. Even so that the build instructions have a no-cargo scenario, if I run ./configure it fails with the following error:

configure: processing ./configure args
configure: 
configure: CFG_PREFIX           := /usr/local 
configure: CFG_LOCAL_RUST_ROOT  :=  
configure: CFG_CARGO            := cargo 
configure: CFG_RUSTC            := rustc 
configure: CFG_RUSTDOC          := rustdoc 
configure: CFG_CARGO            :=  
configure: error: needed, but unable to find any of: CFG_CARGO cargo

In my case I compiled Rust from source, which doesn't have Cargo included anymore. Also as far as I know it is a bad practice to have a pre-existing Rust install (such as via rustup) when compiling Rust and Cargo. In any case, I couldn't figure out from the makefile or the docs if I really need to install Cargo before I build the project.
For clarity - my intention is to build Cargo (and Rust) from source.
What do you recommend?

@alexcrichton
Copy link
Member

Indeed yeah Cargo is required to compile Cargo. In future Rust releases we'll have --enable-extended which will compile Cargo as well as Rust.

In general though having an existing Rust install when compiling from source should work just fine, no need to avoid it.

@itarato
Copy link
Author

itarato commented Feb 28, 2017

Thanks @alexcrichton

@itarato itarato closed this as completed Feb 28, 2017
@0joshuaolson1
Copy link

In future Rust releases we'll have --enable-extended

@alexcrichton is there an issue for this?

@alexcrichton
Copy link
Member

@0joshuaolson1 it's currently present on the master branch of rust-lang/rust

@0joshuaolson1
Copy link

That started with this commit, right? I see --enable-extented in beta and stable too.

Can I use the cargo build outside of Docker if my machine is the right arch?

@alexcrichton
Copy link
Member

Sorry I'm not really sure what you're asking? How does this relate to this issue?

@0joshuaolson1
Copy link

0joshuaolson1 commented Jul 18, 2017

--enable-extended which will compile Cargo as well as Rust.

I was interested in learning how to use this to compile Cargo without Cargo.

@alexcrichton
Copy link
Member

Unfortunately that's not really supported right now, if you're looking to port Cargo to a new platform you'll need to do so through cross-compilation.

@0joshuaolson1
Copy link

Thanks.

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

3 participants