Introduce support for the Enhances field. (Closes: #137583)
[ntk/apt.git] / apt-pkg / pkgcache.h
index 5ae611b..f2c032e 100644 (file)
@@ -63,10 +63,14 @@ class pkgCache
    class Namespace;
    
    // These are all the constants used in the cache structures
+
+   // WARNING - if you change these lists you must also edit
+   // the stringification in pkgcache.cc and also consider whether
+   // the cache file will become incompatible.
    struct Dep
    {
       enum DepType {Depends=1,PreDepends=2,Suggests=3,Recommends=4,
-        Conflicts=5,Replaces=6,Obsoletes=7};
+        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};
    };
@@ -77,7 +81,8 @@ class pkgCache
       enum PkgSelectedState {Unknown=0,Install=1,Hold=2,DeInstall=3,Purge=4};
       enum PkgInstState {Ok=0,ReInstReq=1,HoldInst=2,HoldReInstReq=3};
       enum PkgCurrentState {NotInstalled=0,UnPacked=1,HalfConfigured=2,
-          HalfInstalled=4,ConfigFiles=5,Installed=6};
+          HalfInstalled=4,ConfigFiles=5,Installed=6,
+           TriggersAwaited=7,TriggersPending=8};
    };
    
    struct Flag
@@ -209,7 +214,7 @@ struct pkgCache::Package
    unsigned char InstState;         // Flags
    unsigned char CurrentState;      // State
    
-   unsigned short ID;
+   unsigned int ID;
    unsigned long Flags;
 };
 
@@ -230,7 +235,7 @@ struct pkgCache::PackageFile
    
    // Linked list
    map_ptrloc NextFile;        // PackageFile
-   unsigned short ID;
+   unsigned int ID;
    time_t mtime;                  // Modification time for the file
 };
 
@@ -267,7 +272,7 @@ struct pkgCache::Version
    map_ptrloc Size;              // These are the .deb size
    map_ptrloc InstalledSize;
    unsigned short Hash;
-   unsigned short ID;
+   unsigned int ID;
    unsigned char Priority;
 };
 
@@ -284,7 +289,7 @@ struct pkgCache::Description
    map_ptrloc NextDesc;          // Description
    map_ptrloc ParentPkg;         // Package
 
-   unsigned short ID;
+   unsigned int ID;
 };
 
 struct pkgCache::Dependency