0

I am using Ubuntu 20.04.1. The output of apt-cache policy gcc:

gcc:
  Installed: (none)
  Candidate: 4:9.2.1-3.1ubuntu1
  Version table:
     4:9.2.1-3.1ubuntu1 500
        500 http://repos.del.extreme-ix.org/ubuntu focal/main amd64 Packages

I have installed Codeblocks just before this and now it shows this message:

The following packages have unmet dependencies:
 gcc : Depends: cpp (= 4:9.2.1-3.1ubuntu1) but 4:9.3.0-1ubuntu2 is to be installed
       Depends: gcc-9 (>= 9.2.1-1~) but it is not going to be installed
       Recommends: libc6-dev but it is not going to be installed or
                   libc-dev
E: Unable to correct problems, you have held broken packages.
Kulfy
  • 17,696
  • What OS & release are you running? I see one match with focal but without knowing your release, this maybe the problem or a solution. – guiverc Oct 15 '20 at 05:02
  • I am using ubuntu latest 20.04.1 – Arpit Chugh Oct 15 '20 at 05:08
  • 1
    Your messages don't make sense for focal. What do you get with apt-cache policy gcc ? (please add extra detail to your question, not reply via comments). cpp | 4:9.3.0-1ubuntu2 is what should be available for Ubuntu 20.04/focal as it reports is to be installed. You've got a inappropriate source for Ubuntu/focal most likely. – guiverc Oct 15 '20 at 05:20
  • The update server that you are using doesn't even respond to a ping. That might be causing the problem as mentioned in the preceding comment. If the answers to the linked questions don't fix the error, the next thing to try would be restoring the default repositories: How do I restore the default repositories?. – karel Oct 15 '20 at 19:40

0 Answers0