summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjak@debian.org <>2009-06-15 14:57:01 +0200
committerjak@debian.org <>2009-06-15 14:57:01 +0200
commitf8ae7e8b3c5585888cbc0516b35131acec14ff05 (patch)
tree967800f198a9de20ea4ec1c4cd4a6dd1563ff791
parent8aea8c3f51ce84ed8d6d89682c0a989ac99c4796 (diff)
Introduce support for the Enhances field. (Closes: #137583)
-rw-r--r--apt-pkg/deb/deblistparser.cc2
-rw-r--r--apt-pkg/pkgcache.cc4
-rw-r--r--apt-pkg/pkgcache.h2
-rw-r--r--debian/changelog1
4 files changed, 6 insertions, 3 deletions
diff --git a/apt-pkg/deb/deblistparser.cc b/apt-pkg/deb/deblistparser.cc
index 896d4d6d8..74fa6fab4 100644
--- a/apt-pkg/deb/deblistparser.cc
+++ b/apt-pkg/deb/deblistparser.cc
@@ -109,6 +109,8 @@ bool debListParser::NewVersion(pkgCache::VerIterator Ver)
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)
diff --git a/apt-pkg/pkgcache.cc b/apt-pkg/pkgcache.cc
index 4fbf42c4b..7a0d7376d 100644
--- a/apt-pkg/pkgcache.cc
+++ b/apt-pkg/pkgcache.cc
@@ -49,7 +49,7 @@ pkgCache::Header::Header()
/* Whenever the structures change the major version should be bumped,
whenever the generator changes the minor version should be bumped. */
- MajorVersion = 7;
+ MajorVersion = 8;
MinorVersion = 0;
Dirty = false;
@@ -223,7 +223,7 @@ const char *pkgCache::DepType(unsigned char Type)
{
const char *Types[] = {"",_("Depends"),_("PreDepends"),_("Suggests"),
_("Recommends"),_("Conflicts"),_("Replaces"),
- _("Obsoletes"),_("Breaks")};
+ _("Obsoletes"),_("Breaks"), _("Enhances")};
if (Type < sizeof(Types)/sizeof(*Types))
return Types[Type];
return "";
diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h
index 759e9a225..f2c032eb4 100644
--- a/apt-pkg/pkgcache.h
+++ b/apt-pkg/pkgcache.h
@@ -70,7 +70,7 @@ class pkgCache
struct Dep
{
enum DepType {Depends=1,PreDepends=2,Suggests=3,Recommends=4,
- Conflicts=5,Replaces=6,Obsoletes=7,DpkgBreaks=8};
+ Conflicts=5,Replaces=6,Obsoletes=7,DpkgBreaks=8,Enhances=9};
enum DepCompareOp {Or=0x10,NoOp=0,LessEq=0x1,GreaterEq=0x2,Less=0x3,
Greater=0x4,Equals=0x5,NotEquals=0x6};
};
diff --git a/debian/changelog b/debian/changelog
index ea935f144..ecba3f215 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -24,6 +24,7 @@ apt (0.7.22) UNRELEASED; urgency=low
[ Julian Andres Klode ]
* apt-pkg/contrib/configuration.cc: Fix a small memory leak in
ReadConfigFile.
+ * Introduce support for the Enhances field. (Closes: #137583)
-- Christian Perrier <bubulle@debian.org> Wed, 22 Apr 2009 10:13:54 +0200