[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

apt-get doesn't remove dependencies



When installing new packages with apt-get, often other extra packages
are installed because of dependencies, like the following:

    # apt-get install gcc-3.2
    Reading Package Lists... Done
    Building Dependency Tree... Done
    The following extra packages will be installed:
      cpp-3.2
    The following NEW packages will be installed:
    	  cpp-3.2 gcc-3.2
    0 packages upgraded, 2 newly installed, 0 to remove and 0  not upgraded.
    
I'd like, if apt would remember, which packages are installed only
because of such dependencies and remove them automatically when the
package that depends on them is removed, i.e. when I remove gcc-3.2,
cpp-3.2 should also be removed.  But this is not the case:
    
    # apt-get remove gcc-3.2
    Reading Package Lists... Done
    Building Dependency Tree... Done
    The following packages will be REMOVED:
      gcc-3.2
    0 packages upgraded, 0 newly installed, 1 to remove and 0  not upgraded.

This means that after 

    # apt-get install gcc-3.2; apt-get remove gcc-3.2

I don't have the same packages installed as before.

There should be a reference count for each package, that is increased
or decreased, when the package is explicitly installed/removed or when
a package depending on it is installed/removed.  When the reference
count is zero the package should be actually removed.

Is something like this planned or considered?


urs



Reply to: