Closed cpsyctc2 closed 2 months ago
Ah yes, the cargo::whatever
syntax that appeared magically in one release with a "use cargo::whatever
instead of cargo:whatever
" warning, with no deprecation period for cargo:whatever
and old compilers not supporting cargo::whatever
.
FTR,
error: unsupported output in build script of
curl-sys v0.4.76+curl-8.10.1
:cargo::rustc-check-cfg=cfg(libcurl_vendored,link_libnghttp2,link_libz,link_openssl,)
means this is error originates in curl-sys.
The error says
Either change the directive to
cargo:key=value
syntax (note the single:
) or upgrade your version of Rust.
and I am loathe to ask this but what does rustc --version
/cargo --version
say? Did you get your cargo from apt (in general I'm in support of this, but.)?
Many thanks for that.
I am sorry but I don't know whence I got cargo, I would have guessed from apt as that's my preferred option but it's possible that I followed something asking me to get it some other way. (Plea in mitigation: I've been through installing so many things for the rebuild I have only really kept notes on the things that failed immediately, this was OK at first I believe. What I get is:
root@clevorebuilt:/home/chris# rustc --version
rustc 1.75.0 (82e1608df 2023-12-21) (built from a source tarball)
root@clevorebuilt:/home/chris# cargo --version
cargo 1.75.0
I am guessing that says that I have two instances of cargo with the same version number but perhaps from different sources. Or perhaps not! Does it help at all?
Well, you can tell if it's from apt by asking it (dpkg -l rustc cargo
(or apt list rustc cargo
)). If that doesn't say ii cargo
... then command -v cargo
will probably say $HOME/.cargo/bin/cargo and that indicates rustup).
But packages.ubuntu.com says "noble (24.04LTS)" has rustc 1.75.0+dfsg0ubuntu1-0ubuntu7, which aligns with your version, and if it were from rustup you'd have something closer to 1.80. So you probably have cargo from apt.
This is something I personally like to support (well, latest debian stable, but that's a little older than yours). But this is in a dependency, so I can only forward this to curl-sys and hope their compat policy aligns with mine.
If you'd instead like to "just get this to work", you probably want to install rust/cargo from rustup, cf. https://rustup.rs. (You can then apt remove rustc cargo
, and keep using the version from rustup (and rustup update
) in perpetuity. This is not optimal, but the rust ecosystem is unfortunately focused on breaking as much compatibility as often as possible.)
Looks reported in https://github.com/alexcrichton/curl-rust/issues/576 already
Thanks @nabijaczleweli I clearly had the apt install (and thanks to you I have learned useful things about how to find out whether apt is the source of a package/program!) Like you, I would much prefer to stay with the Ubuntu repositories as my primary source of things but I decided that this time I would go for the "just work" and removed the existing installs and pulled rust/cargo from rustup and then cargo install-update
worked. Many thanks, Chris
Should now work on ubuntu cargo by pulling in curl-rust 0.4.77.
I hope this is a sensible place to report this. This has been consistent for me over a few days now on Ubuntu 24.04.1 LTS on two separate machines. I get the error running topgrade
When I run
cargo install-update
I get all of this (giving all in case it is useful, error is at the end)Watching the process I think the error comes up at "103/113" in the processing of cargo-update.
I am just a Linux/Ubuntu end user but happy to report more information about the two systems and do anything that maybe helpful if I am given fairly luser-proof instructions.
TIA,
Chris