]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/deb/deblistparser.cc
merged from mvo
[apt.git] / apt-pkg / deb / deblistparser.cc
index c2b26b5eb5322a8f4543a89bea742bf65004ef6c..517b771a5adb27db816073b07531834b33d429dd 100644 (file)
@@ -105,8 +105,12 @@ bool debListParser::NewVersion(pkgCache::VerIterator Ver)
       return false;
    if (ParseDepends(Ver,"Conflicts",pkgCache::Dep::Conflicts) == false)
       return false;
+   if (ParseDepends(Ver,"Breaks",pkgCache::Dep::DpkgBreaks) == false)
+      return false;
    if (ParseDepends(Ver,"Replaces",pkgCache::Dep::Replaces) == false)
       return false;
+   if (ParseDepends(Ver,"Enhances",pkgCache::Dep::Enhances) == false)
+      return false;
 
    // Obsolete.
    if (ParseDepends(Ver,"Optional",pkgCache::Dep::Suggests) == false)
@@ -193,6 +197,7 @@ unsigned short debListParser::VersionHash()
 //                            "Suggests",
 //                            "Recommends",
                             "Conflicts",
+                            "Breaks",
                             "Replaces",0};
    unsigned long Result = INIT_FCS;
    char S[1024];
@@ -210,7 +215,7 @@ unsigned short debListParser::VersionHash()
       for (; Start != End; Start++)
       {
         if (isspace(*Start) == 0)
-           *I++ = tolower(*Start);
+           *I++ = tolower_ascii(*Start);
         if (*Start == '<' && Start[1] != '<' && Start[1] != '=')
            *I++ = '=';
         if (*Start == '>' && Start[1] != '>' && Start[1] != '=')
@@ -290,6 +295,8 @@ bool debListParser::ParseStatus(pkgCache::PkgIterator Pkg,
                             {"installed",pkgCache::State::Installed},
                             {"half-installed",pkgCache::State::HalfInstalled},
                             {"config-files",pkgCache::State::ConfigFiles},
+                            {"triggers-awaited",pkgCache::State::TriggersAwaited},
+                            {"triggers-pending",pkgCache::State::TriggersPending},
                             {"post-inst-failed",pkgCache::State::HalfConfigured},
                             {"removal-failed",pkgCache::State::HalfInstalled},
                             {}};
@@ -632,6 +639,8 @@ bool debListParser::LoadReleaseInfo(pkgCache::PkgFileIterator FileI,
       FileI->Version = WriteUniqString(Start,Stop - Start);
    if (Section.Find("Origin",Start,Stop) == true)
       FileI->Origin = WriteUniqString(Start,Stop - Start);
+   if (Section.Find("Codename",Start,Stop) == true)
+      FileI->Codename = WriteUniqString(Start,Stop - Start);
    if (Section.Find("Label",Start,Stop) == true)
       FileI->Label = WriteUniqString(Start,Stop - Start);
    if (Section.Find("Architecture",Start,Stop) == true)