]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/deb/deblistparser.cc
Merge remote-tracking branch 'mvo/bugfix/update-progress-reporting' into debian/exper...
[apt.git] / apt-pkg / deb / deblistparser.cc
index a1bcfb710432cc44facf49fd394cb231f8b4c319..d5e3ccb655db9cfccbfdb4da64350c9845d6f5c7 100644 (file)
@@ -959,3 +959,23 @@ bool debListParser::SameVersion(unsigned short const Hash,         /*{{{*/
 }
                                                                        /*}}}*/
 #endif
+
+
+debDebFileParser::debDebFileParser(FileFd *File, std::string const &DebFile)
+   : debListParser(File, ""), DebFile(DebFile)
+{
+}
+
+bool debDebFileParser::UsePackage(pkgCache::PkgIterator &Pkg,
+                                  pkgCache::VerIterator &Ver)
+{
+   bool res = debListParser::UsePackage(Pkg, Ver);
+   // we use the full file path as a provides so that the file is found
+   // by its name
+   if(NewProvidesAllArch(Ver, DebFile, Ver.VerStr()) == false)
+      return false;
+   return res;
+}
+
+
+