0

I'm trying to install librespot to use along with spotify-qt, which needs cargo to run, but every time I run sudo apt install cargo I get the following problem:

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may
mean that you have requested an impossible situation or if you are
using the unstable distribution that some required packages have not
yet been created or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
rustc : Depends: libc-dev E: Unable to correct problems, you have held broken packages.

And then I tried to use sudo apt install libc-dev but got this error:

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'libc6-dev' instead of 'libc-dev'
Some packages could not be installed. This may
mean that you have requested an impossible situation or if you are
using the unstable distribution that some required packages have not
yet been created or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies: libc6-dev : Depends: libc6 (= 2.35-0ubuntu3) but 2.35-0ubuntu3.1 is to be installed E: Unable to correct problems, you have held broken packages.

I'm new to Ubuntu/Linux and I'm still getting used to it.

Nmath
  • 12,333
zoynus
  • 1
  • Check everything is up to date, ie. start with sudo apt update and read the output. A quick scan of the expected package listed in your paste shows libc6 | 2.35-0ubuntu3.1 | jammy-updates | amd64, arm64, armhf, i386, ppc64el, riscv64, s390x is correct for listed architectures, so whatever you have that wants the older package need upgrading (packages are built for a specific release & you didn't tell us yours; thus I've assumed jammy; if it's not jammy that is another problem!). If all output from sudo apt update is clear with no missing lines, then sudo apt full-upgrade etc... – guiverc May 31 '23 at 02:20
  • FYI: I use terminal commands to explore packages; but you can also look online https://packages.ubuntu.com/search?keywords=libc6&searchon=names&suite=all§ion=all would contain the detail I pasted of what would be expected (my copy/paste being from terminal output thus any differences in the formatting of line detail I pasted) – guiverc May 31 '23 at 02:23
  • 1
    If you still need help, please add the full output of sudo apt update and sudo apt upgrade to your question. This will provide essential details about the state of your package management. But please don't use block quotes-- it will destroy formatting. Instead, use code fences or highlight the text and click the "code sample" button in the editing box -- Here are instructions for how to paste from your terminal: https://meta.askubuntu.com/a/20164. Tag me in a comment @nmath once you're done editing – Nmath May 31 '23 at 02:59

0 Answers0