]> git.saurik.com Git - apt.git/blobdiff - apt-private/private-output.cc
Merge branch 'debian/experimental-no-abi-break' into debian/sid
[apt.git] / apt-private / private-output.cc
index 6fadf7274340348da949af1c6cb25188859f1357..a8bbad9e590c8de9195eafce8dea64fdc3b19b20 100644 (file)
@@ -114,11 +114,13 @@ std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)/*{{{*/
    pkgCache::PkgIterator P = V.ParentPkg();
    if (V == P.CurrentVer())
    {
+      std::string inst_str = DeNull(V.VerStr());
+#if 0 // FIXME: do we want this or something like this?
       pkgDepCache *DepCache = CacheFile.GetDepCache();
       pkgDepCache::StateCache &state = (*DepCache)[P];
-      std::string inst_str = DeNull(V.VerStr());
       if (state.Upgradable())
          return "**"+inst_str;
+#endif
       return inst_str;
    }
 
@@ -158,7 +160,8 @@ std::string GetShortDescription(pkgCacheFile &CacheFile, pkgRecords &records, pk
 }
                                                                        /*}}}*/
 void ListSingleVersion(pkgCacheFile &CacheFile, pkgRecords &records,   /*{{{*/
-                       pkgCache::VerIterator V, std::ostream &out)
+                       pkgCache::VerIterator V, std::ostream &out,
+                       bool include_summary)
 {
    pkgCache::PkgIterator P = V.ParentPkg();
 
@@ -223,10 +226,13 @@ void ListSingleVersion(pkgCacheFile &CacheFile, pkgRecords &records,      /*{{{*/
          else
             out << GetVersion(CacheFile, V);
       }
-      out << " " << GetArchitecture(CacheFile, P) << " ";
-      out << std::endl 
-                << "    " << GetShortDescription(CacheFile, records, P)
-                << std::endl;
+      out << " " << GetArchitecture(CacheFile, P);
+      if (include_summary)
+      {
+         out << std::endl 
+             << "  " << GetShortDescription(CacheFile, records, P)
+             << std::endl;
+      }
    }
 }
                                                                        /*}}}*/