-1

Just tried to do sudo apt-get dist-upgrade today; and I came to this state:

$ sudo apt-get upgrade 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  phablet-tools ubuntu-sdk
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.

Ok, ubuntu-sdk has been kept back/held back, probably there are new packages to install due to dependencies; so I try dist-upgrade:

$ sudo apt-get dist-upgrade 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following NEW packages will be installed:
  intltool
The following packages have been kept back:
  ubuntu-sdk
0 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
Need to get 52.0 kB of archives.
After this operation, 245 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://dk.archive.ubuntu.com/ubuntu/ trusty/main intltool all 0.50.2-2 [52.0 kB]
Fetched 52.0 kB in 0s (872 kB/s)  
Selecting previously unselected package intltool.
(Reading database ... 343935 files and directories currently installed.)
Preparing to unpack .../intltool_0.50.2-2_all.deb ...
Unpacking intltool (0.50.2-2) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up intltool (0.50.2-2) ...

Hmm... so just intltool installed there, not ubuntu-sdk; let's try again:

$ sudo apt-get upgrade 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  phablet-tools ubuntu-sdk
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.

Hmmm... dist-upgrade again?

$ sudo apt-get dist-upgrade 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  ubuntu-sdk
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.

Still kept back... Let's try force a bit more with sudo apt-get install...:

$ sudo apt-get install phablet-tools ubuntu-sdk
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:
 ubuntu-sdk : Depends: ubuntu-device-flash but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Let's try then ubuntu-device-flash:

$ sudo apt-get install ubuntu-device-flash
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:
 ubuntu-device-flash : Depends: click-ubuntu-policy but it is not installable
                       Depends: ubuntu-snappy-cli but it is not installable
E: Unable to correct problems, you have held broken packages.

Let's just try click-ubuntu-policy, although by now I don't have high hopes:

$ sudo apt-get install click-ubuntu-policy
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package click-ubuntu-policy is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'click-ubuntu-policy' has no installation candidate

Great, so apparently click-ubuntu-policy it is not in repos anymore, but it still has a dangling dependency in ubuntu-device-flash package.

What is the recommended course of action I could do in this case?

sdaau
  • 3,056

1 Answers1

0

From apt-get man page

dist-upgrade in addition to performing the function of upgrade, also intelligently handles changing dependencies with new versions of packages; apt-get has a "smart" conflict resolution system, and it will attempt to upgrade the most important packages at the expense of less important ones if necessary. The dist-upgrade command may therefore remove some packages. The /etc/apt/sources.list file contains a list of locations from which to retrieve desired package files

dist-upgrade tries to install new packages to upgrade (contrary to what upgrade do), but it can only do so if that packages is found available from any of the locations listed in /etc/apt/sources.list file. If the repositories miss a package, how can it find it? And if it can't find the package, it will not upgrade it, rather hold-back the package.

This is what happened in your case. click-ubuntu-policy package is not (and was never) available in the trusty official repositories (Check here in packages.ubuntu.com). ubuntu-device-flash is not going to be upgraded because the newer newer version of it depends on click-ubuntu-policy, which is not available in any known repositories to apt.

However, If you add a PPA or repository source that has click-ubuntu-policy for trusty, you can then upgrade ubuntu-device-flash package. But that is not recommended.

My suggestion is since Ubuntu included newer version of ubuntu-device-flash, i think click-ubuntu-policy will too available in the repository soon.

Anwar
  • 76,649