X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/d183f850e7e3e467e8665d116ffbb238fdcc4ea9..c7c7d3e8f12e68cd14470eec47db516c9b784cbe:/apt-pkg/packagemanager.h diff --git a/apt-pkg/packagemanager.h b/apt-pkg/packagemanager.h index af1476b7a..e1878ce46 100644 --- a/apt-pkg/packagemanager.h +++ b/apt-pkg/packagemanager.h @@ -28,6 +28,7 @@ #include <iostream> #include <apt-pkg/pkgcache.h> #include <apt-pkg/depcache.h> +#include <set> using std::string; @@ -41,14 +42,24 @@ class pkgPackageManager : protected pkgCache::Namespace public: enum OrderResult {Completed,Failed,Incomplete}; + static bool SigINTStop; protected: string *FileNames; pkgDepCache &Cache; pkgOrderList *List; bool Debug; - - bool DepAdd(pkgOrderList &Order,PkgIterator P,int Depth = 0); + bool NoImmConfigure; + bool ImmConfigureAll; + + /** \brief saves packages dpkg let disappear + + This way APT can retreat from trying to configure these + packages later on and a frontend can choose to display a + notice to inform the user about these disappears. + */ + std::set<std::string> disappearedPkgs; + void ImmediateAdd(PkgIterator P, bool UseInstallVer, unsigned const int &Depth = 0); virtual OrderResult OrderInstall(); bool CheckRConflicts(PkgIterator Pkg,DepIterator Dep,const char *Ver); @@ -60,9 +71,11 @@ class pkgPackageManager : protected pkgCache::Namespace // Install helpers bool ConfigureAll(); bool SmartConfigure(PkgIterator Pkg); + //FIXME: merge on abi break bool SmartUnPack(PkgIterator Pkg); + bool SmartUnPack(PkgIterator Pkg, bool const Immediate); bool SmartRemove(PkgIterator Pkg); - bool EarlyRemove(PkgIterator Pkg); + bool EarlyRemove(PkgIterator Pkg); // The Actual installation implementation virtual bool Install(PkgIterator /*Pkg*/,string /*File*/) {return false;}; @@ -93,7 +106,10 @@ class pkgPackageManager : protected pkgCache::Namespace // stuff that needs to be done after the fork OrderResult DoInstallPostFork(int statusFd=-1); bool FixMissing(); - + + /** \brief returns all packages dpkg let disappear */ + inline std::set<std::string> GetDisappearedPackages() { return disappearedPkgs; }; + pkgPackageManager(pkgDepCache *Cache); virtual ~pkgPackageManager(); };