]> git.saurik.com Git - apt.git/commitdiff
Add a option to apt-cache policy to additionally init the DepCache before
authorDavid Kalnischkies <kalnischkies@gmail.com>
Sat, 5 Jun 2010 08:17:10 +0000 (10:17 +0200)
committerDavid Kalnischkies <kalnischkies@gmail.com>
Sat, 5 Jun 2010 08:17:10 +0000 (10:17 +0200)
starting to get the package informations.
This is useful e.g. for debugging the MultiArchKiller.

cmdline/apt-cache.cc

index 227fda4beaf90cfcc11190bf89567fab8b7f896a..b0e70510851da2abfebbe153fe4c91b25f0859d8 100644 (file)
@@ -1555,6 +1555,12 @@ bool Policy(CommandLine &CmdL)
    if (unlikely(Cache == NULL || Plcy == NULL || SrcList == NULL))
       return false;
 
+   /* Should the MultiArchKiller be run to see which pseudo packages for an
+      arch all package are currently installed? Activating it gives a speed
+      penality for no real gain beside enhanced debugging, so in general no. */
+   if (_config->FindB("APT::Cache::Policy::DepCache", false) == true)
+      CacheFile.GetDepCache();
+
    // Print out all of the package files
    if (CmdL.FileList[1] == 0)
    {