rust-lang / git2-rs

libgit2 bindings for Rust
https://docs.rs/git2
Apache License 2.0
1.67k stars 384 forks source link

libgit2-sys 0.14.0 cannot be found in crates.io #878

Closed ralucado closed 2 years ago

ralucado commented 2 years ago

When trying to install the latest version of cargo-tarpaulin, which has tre requirement libgit2-sys = "^0.14.0" i get the following error:

> cargo install cargo-tarpaulin
    Updating crates.io index
  Installing cargo-tarpaulin v0.21.0
error: failed to compile `cargo-tarpaulin v0.21.0`, intermediate artifacts can be found at `/tmp/cargo-installQQaGN3`

Caused by:
  failed to select a version for the requirement `libgit2-sys = "^0.14.0"`
  candidate versions found which didn't match: 0.13.2+1.4.2, 0.13.1+1.4.2, 0.13.0+1.4.1, ...
  location searched: crates.io index
  required by package `git2 v0.15.0`
      ... which satisfies dependency `git2 = "^0.15"` of package `cargo-tarpaulin v0.21.0`

And the same error when trying to install libgit2-sys directly:

> cargo install libgit2-sys --version "0.14.0+1.5.0"
    Updating crates.io index
error: could not find `libgit2-sys` in registry `crates-io` with version `=0.14.0`
ralucado commented 2 years ago

Solved, it was an issue of having an older version of rust, fixed with rustup update