kpcyrd / sn0int

Semi-automatic OSINT framework and package manager
https://sn0int.readthedocs.io/
GNU General Public License v3.0
2k stars 178 forks source link

error: cargo install: diesel: unable to get packages from source #68

Closed roycewilliams closed 5 years ago

roycewilliams commented 5 years ago

Could this be a transient connectivity issue?

 Downloading diesel v1.4.1                                                                                                                
error: failed to compile `sn0int v0.9.0 (/[redacted]/sn0int)`, intermediate artifacts can be found at `[redacted]/sn0int/target`

Caused by:
  unable to get packages from source

Caused by:
  failed to parse manifest at `/home/[redacted]/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.4.1/Cargo.toml`

Caused by:
  feature `rename-dependency` is required

consider adding `cargo-features = ["rename-dependency"]` to the manifest
Athrekas commented 5 years ago

Same issue here.

kpcyrd commented 5 years ago

Thanks for your report! The problem seems to be failed to parse manifest at /home/[redacted]/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.4.1/Cargo.toml which shouldn't happen and might indicate an outdated cargo version.

How did you install rust (from your distro or rustup) and which version of rust and cargo are you using? You can get these with:

rustc --version
cargo --version

Thanks!

gibbypip commented 5 years ago

removing the apt version of rustc and using rustup fixed the issue for me.

kpcyrd commented 5 years ago

@gibbypip Awesome! Out of interest, which distro are you on if you don't mind me asking? :)

roycewilliams commented 5 years ago

FWIW, my setup is:

$ rustc --version
rustc 1.30.0
$ cargo --version
cargo 1.30.0
$ grep DESC /etc/lsb-release
DISTRIB_DESCRIPTION="Ubuntu 16.04.5 LTS"

I installed both rust and cargo from my distro's package system.

gibbypip commented 5 years ago

@kpcyrd:

Vanilla install of Ubuntu Server 18.04 LTS after a quick apt update/upgrade

scottellis commented 5 years ago

Same with workstation 18.10

I added

cargo-features = ["rename-dependency"]

to

~/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.4.1/Cargo.toml

and then got the following error

~/sn0int$ cargo install -f --path .
  Installing sn0int v0.9.0 (/home/scott/sn0int)
 Downloading caps v0.3.0
 Downloading rand v0.6.5
 Downloading syscallz v0.8.0
 Downloading sloppy-rfc4880 v0.1.2
 ...
   Compiling proc-macro-hack-impl v0.4.1
   Compiling rustc-demangle v0.1.13
   Compiling safemem v0.3.0
   Compiling dtoa v0.4.3
   Compiling num-bigint v0.2.2
   Compiling procedural-masquerade v0.1.6
   Compiling string v0.1.3
   Compiling precomputed-hash v0.1.1
   Compiling data-encoding v2.1.2
error: Edition 2018 is unstable and only available for nightly builds of rustc.

error: Could not compile `data-encoding`.
warning: build failed, waiting for other jobs to finish...
error: failed to compile `sn0int v0.9.0 (/home/scott/sn0int)`, intermediate artifacts can be found at 
`/home/scott/sn0int/target`

Caused by:
  build failed

I don't know whether or not that is useful.

kpcyrd commented 5 years ago

The compiler in ubuntu is too old, sorry. Right now you would need to install a more recent rust version with rustup or use the docker image.

I've documented this in the install instructions: https://sn0int.readthedocs.io/en/latest/install.html#ubuntu-debian-stable

roycewilliams commented 5 years ago

Ah, ok - thanks!

roycewilliams commented 5 years ago

Is this true even for Ubuntu 18.04?

scottellis commented 5 years ago

I get the same error with 18.10 so I would think yes.