14.04 to 16.04 LTS gcc-5-base downgrade

Solution 1:

In addition to what the OP describes, my do-release-upgrade was interrupted by this issue. Josh.F's comment did the trick for me:

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

That fixed gcc-5 for me and then I still needed to sudo apt-get upgrade

Solution 2:

The comment by @josh-f fixed this for me:

sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install -y r-base-dev