diff options
| author | Julian Andres Klode <jak@debian.org> | 2025-10-25 18:42:24 +0000 |
|---|---|---|
| committer | Julian Andres Klode <jak@debian.org> | 2025-10-25 18:42:24 +0000 |
| commit | 2698c1e186accebefa320ebacde7ec3c40c66c29 (patch) | |
| tree | 100d5321f364b389100928e927639e852c52ff48 /apt-pkg/pkgcache.cc | |
| parent | a92a5ecc465055027d9fbb899f359ec7eab110bd (diff) | |
| parent | 9d62eef571ffd1fd2df8b97884d3689fced27fb1 (diff) | |
Merge branch 'variants-submit' into 'main'
Merge Architecture variants from Ubuntu
See merge request apt-team/apt!526
Diffstat (limited to 'apt-pkg/pkgcache.cc')
| -rw-r--r-- | apt-pkg/pkgcache.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/apt-pkg/pkgcache.cc b/apt-pkg/pkgcache.cc index 4101fb4e5..3377facac 100644 --- a/apt-pkg/pkgcache.cc +++ b/apt-pkg/pkgcache.cc @@ -193,6 +193,17 @@ bool pkgCache::ReMap(bool const &Errorchecks) list.append(","); list.append(arch); } + auto const variants = APT::Configuration::getArchitectureVariants(true); + if (not variants.empty()) + { + list.append(";"); + for (auto const &variant : variants) + { + if (list.back() != ';') + list.append(","); + list.append(variant.name); + } + } if (_config->Find("APT::Architecture") != StrP + HeaderP->Architecture || list != StrP + HeaderP->GetArchitectures()) return _error->Error(_("The package cache was built for different architectures: %s vs %s"), StrP + HeaderP->GetArchitectures(), list.c_str()); |
