After Upgrading to Ubuntu 18.04 build-essential, g++, gcc & cpp held broken packages

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
2
down vote

favorite
3












After Upgrading to Ubuntu 18.04 from 16.04 build-essential, g++, gcc & cpp E: Unable to correct problems, you have held broken packages.



$ sudo apt-get install build-essential
Reading package lists... Done
Building dependency tree
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:
build-essential : Depends: gcc (>= 4:7.2) but it is not going to be installed
Depends: g++ (>= 4:7.2) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.


$ sudo apt-get install gcc
Reading package lists... Done
Building dependency tree
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:
gcc : Depends: gcc-7 (>= 7.3.0-12~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.


The same type of output for g++ & cpp



How to fix this?







share|improve this question


























    up vote
    2
    down vote

    favorite
    3












    After Upgrading to Ubuntu 18.04 from 16.04 build-essential, g++, gcc & cpp E: Unable to correct problems, you have held broken packages.



    $ sudo apt-get install build-essential
    Reading package lists... Done
    Building dependency tree
    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:
    build-essential : Depends: gcc (>= 4:7.2) but it is not going to be installed
    Depends: g++ (>= 4:7.2) but it is not going to be installed
    E: Unable to correct problems, you have held broken packages.


    $ sudo apt-get install gcc
    Reading package lists... Done
    Building dependency tree
    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:
    gcc : Depends: gcc-7 (>= 7.3.0-12~) but it is not going to be installed
    E: Unable to correct problems, you have held broken packages.


    The same type of output for g++ & cpp



    How to fix this?







    share|improve this question
























      up vote
      2
      down vote

      favorite
      3









      up vote
      2
      down vote

      favorite
      3






      3





      After Upgrading to Ubuntu 18.04 from 16.04 build-essential, g++, gcc & cpp E: Unable to correct problems, you have held broken packages.



      $ sudo apt-get install build-essential
      Reading package lists... Done
      Building dependency tree
      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:
      build-essential : Depends: gcc (>= 4:7.2) but it is not going to be installed
      Depends: g++ (>= 4:7.2) but it is not going to be installed
      E: Unable to correct problems, you have held broken packages.


      $ sudo apt-get install gcc
      Reading package lists... Done
      Building dependency tree
      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:
      gcc : Depends: gcc-7 (>= 7.3.0-12~) but it is not going to be installed
      E: Unable to correct problems, you have held broken packages.


      The same type of output for g++ & cpp



      How to fix this?







      share|improve this question














      After Upgrading to Ubuntu 18.04 from 16.04 build-essential, g++, gcc & cpp E: Unable to correct problems, you have held broken packages.



      $ sudo apt-get install build-essential
      Reading package lists... Done
      Building dependency tree
      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:
      build-essential : Depends: gcc (>= 4:7.2) but it is not going to be installed
      Depends: g++ (>= 4:7.2) but it is not going to be installed
      E: Unable to correct problems, you have held broken packages.


      $ sudo apt-get install gcc
      Reading package lists... Done
      Building dependency tree
      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:
      gcc : Depends: gcc-7 (>= 7.3.0-12~) but it is not going to be installed
      E: Unable to correct problems, you have held broken packages.


      The same type of output for g++ & cpp



      How to fix this?









      share|improve this question













      share|improve this question




      share|improve this question








      edited Apr 27 at 14:46









      Melebius

      3,74841636




      3,74841636










      asked Apr 27 at 14:43









      Santhosh Veer

      1316




      1316




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          1
          down vote



          accepted










          I've encountered the same - on Ubuntu 16.04 I had the Toolchain Test Builds PPA for gcc and clang builds, including gcc-7. During the upgrade to 18.04, 3rd party repositories were disabled by the installation process, with this PPA included.



          To fix this, try (re?)adding the toolchain PPA to your apt sources list:



          sudo add-apt-repository ppa:ubuntu-toolchain-r/test
          sudo apt-get update


          Then, when installing build-essential, it should successfully pick gcc-7 from the toolchain PPA.






          share|improve this answer




















          • This didn't work for me, it still says gcc-7 cannot be found.
            – void.pointer
            Jul 18 at 17:38










          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "89"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1028811%2fafter-upgrading-to-ubuntu-18-04-build-essential-g-gcc-cpp-held-broken-pack%23new-answer', 'question_page');

          );

          Post as a guest






























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          1
          down vote



          accepted










          I've encountered the same - on Ubuntu 16.04 I had the Toolchain Test Builds PPA for gcc and clang builds, including gcc-7. During the upgrade to 18.04, 3rd party repositories were disabled by the installation process, with this PPA included.



          To fix this, try (re?)adding the toolchain PPA to your apt sources list:



          sudo add-apt-repository ppa:ubuntu-toolchain-r/test
          sudo apt-get update


          Then, when installing build-essential, it should successfully pick gcc-7 from the toolchain PPA.






          share|improve this answer




















          • This didn't work for me, it still says gcc-7 cannot be found.
            – void.pointer
            Jul 18 at 17:38














          up vote
          1
          down vote



          accepted










          I've encountered the same - on Ubuntu 16.04 I had the Toolchain Test Builds PPA for gcc and clang builds, including gcc-7. During the upgrade to 18.04, 3rd party repositories were disabled by the installation process, with this PPA included.



          To fix this, try (re?)adding the toolchain PPA to your apt sources list:



          sudo add-apt-repository ppa:ubuntu-toolchain-r/test
          sudo apt-get update


          Then, when installing build-essential, it should successfully pick gcc-7 from the toolchain PPA.






          share|improve this answer




















          • This didn't work for me, it still says gcc-7 cannot be found.
            – void.pointer
            Jul 18 at 17:38












          up vote
          1
          down vote



          accepted







          up vote
          1
          down vote



          accepted






          I've encountered the same - on Ubuntu 16.04 I had the Toolchain Test Builds PPA for gcc and clang builds, including gcc-7. During the upgrade to 18.04, 3rd party repositories were disabled by the installation process, with this PPA included.



          To fix this, try (re?)adding the toolchain PPA to your apt sources list:



          sudo add-apt-repository ppa:ubuntu-toolchain-r/test
          sudo apt-get update


          Then, when installing build-essential, it should successfully pick gcc-7 from the toolchain PPA.






          share|improve this answer












          I've encountered the same - on Ubuntu 16.04 I had the Toolchain Test Builds PPA for gcc and clang builds, including gcc-7. During the upgrade to 18.04, 3rd party repositories were disabled by the installation process, with this PPA included.



          To fix this, try (re?)adding the toolchain PPA to your apt sources list:



          sudo add-apt-repository ppa:ubuntu-toolchain-r/test
          sudo apt-get update


          Then, when installing build-essential, it should successfully pick gcc-7 from the toolchain PPA.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Apr 28 at 18:49









          valiano

          782313




          782313











          • This didn't work for me, it still says gcc-7 cannot be found.
            – void.pointer
            Jul 18 at 17:38
















          • This didn't work for me, it still says gcc-7 cannot be found.
            – void.pointer
            Jul 18 at 17:38















          This didn't work for me, it still says gcc-7 cannot be found.
          – void.pointer
          Jul 18 at 17:38




          This didn't work for me, it still says gcc-7 cannot be found.
          – void.pointer
          Jul 18 at 17:38

















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1028811%2fafter-upgrading-to-ubuntu-18-04-build-essential-g-gcc-cpp-held-broken-pack%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          pylint3 and pip3 broken

          Missing snmpget and snmpwalk

          How to enroll fingerprints to Ubuntu 17.10 with VFS491