diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2010-02-13 01:53:17 +0100 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2010-02-13 01:53:17 +0100 |
commit | 34e8a998eb9e4f75f989acc6f8b9db8010e56b7c (patch) | |
tree | 83c84d6f4b78c658ecaeff4b2763bd964d8db670 /apt-pkg/versionmatch.cc | |
parent | d328fd1a20543192a7ea3eac124f10a5793743e9 (diff) | |
parent | 9a230738b2287dc5316f601ff0b4765eff9d898d (diff) |
[BREAK] merge MultiArch-ABI. We don't support MultiArch,
but we support the usage of the new ABI so libapt users
can start to prepare for MultiArch (Closes: #536029)
MultiArch isn't ready for Primetime usage for now, but the branch has
managed to be a NOP if used in SingleArch-mode so we can start to
promote the use of the new MultiArchable API-extensions.
Diffstat (limited to 'apt-pkg/versionmatch.cc')
-rw-r--r-- | apt-pkg/versionmatch.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/apt-pkg/versionmatch.cc b/apt-pkg/versionmatch.cc index b4d1d4696..e5f0fafd2 100644 --- a/apt-pkg/versionmatch.cc +++ b/apt-pkg/versionmatch.cc @@ -100,6 +100,8 @@ pkgVersionMatch::pkgVersionMatch(string Data,MatchType Type) : Type(Type) RelLabel = Fragments[J]+2; else if (stringcasecmp(Fragments[J],Fragments[J]+2,"c=") == 0) RelComponent = Fragments[J]+2; + else if (stringcasecmp(Fragments[J],Fragments[J]+2,"b=") == 0) + RelArchitecture = Fragments[J]+2; } if (RelVerStr.end()[-1] == '*') @@ -178,7 +180,7 @@ bool pkgVersionMatch::FileMatch(pkgCache::PkgFileIterator File) if (RelVerStr.empty() == true && RelOrigin.empty() == true && RelArchive.empty() == true && RelLabel.empty() == true && RelRelease.empty() == true && RelCodename.empty() == true && - RelComponent.empty() == true) + RelComponent.empty() == true && RelArchitecture.empty() == true) return false; if (RelVerStr.empty() == false) @@ -211,6 +213,10 @@ bool pkgVersionMatch::FileMatch(pkgCache::PkgFileIterator File) if (File->Component == 0 || stringcasecmp(RelComponent,File.Component()) != 0) return false; + if (RelArchitecture.empty() == false) + if (File->Architecture == 0 || + stringcasecmp(RelArchitecture,File.Architecture()) != 0) + return false; return true; } |