diff options
Diffstat (limited to 'apt-pkg/deb')
-rw-r--r-- | apt-pkg/deb/deblistparser.cc | 20 | ||||
-rw-r--r-- | apt-pkg/deb/deblistparser.h | 1 |
2 files changed, 4 insertions, 17 deletions
diff --git a/apt-pkg/deb/deblistparser.cc b/apt-pkg/deb/deblistparser.cc index df0879641..87aa99c6e 100644 --- a/apt-pkg/deb/deblistparser.cc +++ b/apt-pkg/deb/deblistparser.cc @@ -861,7 +861,7 @@ bool debListParser::ParseProvides(pkgCache::VerIterator &Ver) if (NewProvides(Ver, Package, OtherArch, Version, pkgCache::Flag::ArchSpecific) == false) return false; } else if ((Ver->MultiArch & pkgCache::Version::Foreign) == pkgCache::Version::Foreign) { - if (NewProvidesAllArch(Ver, Package, Version) == false) + if (NewProvidesAllArch(Ver, Package, Version, 0) == false) return false; } else { if (NewProvides(Ver, Package, Arch, Version, 0) == false) @@ -876,26 +876,14 @@ bool debListParser::ParseProvides(pkgCache::VerIterator &Ver) if ((Ver->MultiArch & pkgCache::Version::Allowed) == pkgCache::Version::Allowed) { string const Package = string(Ver.ParentPkg().Name()).append(":").append("any"); - return NewProvidesAllArch(Ver, Package, Ver.VerStr()); + return NewProvidesAllArch(Ver, Package, Ver.VerStr(), pkgCache::Flag::MultiArchImplicit); } else if ((Ver->MultiArch & pkgCache::Version::Foreign) == pkgCache::Version::Foreign) - return NewProvidesAllArch(Ver, Ver.ParentPkg().Name(), Ver.VerStr()); + return NewProvidesAllArch(Ver, Ver.ParentPkg().Name(), Ver.VerStr(), pkgCache::Flag::MultiArchImplicit); return true; } /*}}}*/ -// ListParser::NewProvides - add provides for all architectures /*{{{*/ -bool debListParser::NewProvidesAllArch(pkgCache::VerIterator &Ver, string const &Package, - string const &Version) { - for (std::vector<string>::const_iterator a = Architectures.begin(); - a != Architectures.end(); ++a) - { - if (NewProvides(Ver, Package, *a, Version, pkgCache::Flag::MultiArchImplicit) == false) - return false; - } - return true; -} - /*}}}*/ // ListParser::GrabWord - Matches a word and returns /*{{{*/ // --------------------------------------------------------------------- /* Looks for a word in a list of words - for ParseStatus */ @@ -991,7 +979,7 @@ bool debDebFileParser::UsePackage(pkgCache::PkgIterator &Pkg, 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) + if(NewProvidesAllArch(Ver, DebFile, Ver.VerStr(), 0) == false) return false; return res; } diff --git a/apt-pkg/deb/deblistparser.h b/apt-pkg/deb/deblistparser.h index 3884aafb9..30e52718d 100644 --- a/apt-pkg/deb/deblistparser.h +++ b/apt-pkg/deb/deblistparser.h @@ -53,7 +53,6 @@ class APT_HIDDEN debListParser : public pkgCacheGenerator::ListParser bool ParseDepends(pkgCache::VerIterator &Ver,const char *Tag, unsigned int Type); bool ParseProvides(pkgCache::VerIterator &Ver); - bool NewProvidesAllArch(pkgCache::VerIterator &Ver, std::string const &Package, std::string const &Version); static bool GrabWord(std::string Word,WordList *List,unsigned char &Out); APT_HIDDEN unsigned char ParseMultiArch(bool const showErrors); |