#include <map>
#include <stdio.h>
#include <apt-pkg/macros.h>
+#include <apt-pkg/init.h>
#ifndef APT_8_CLEANER_HEADERS
using std::vector;
// dpkg log
bool OpenLog();
bool CloseLog();
+
+ // helper
+ void BuildPackagesProgressMap();
+ void StartPtyMagic();
+ void StopPtyMagic();
// input processing
void DoStdin(int master);
void DoTerminalPty(int master);
void DoDpkgStatusFd(int statusfd);
void ProcessDpkgStatusLine(char *line);
+#if (APT_PKG_MAJOR >= 4 && APT_PKG_MINOR < 13)
+ void DoDpkgStatusFd(int statusfd, int unused) {
+ DoDpkgStatusFd(statusfd);
+ }
+ void ProcessDpkgStatusLine(int unused, char *line) {
+ ProcessDpkgStatusLine(line);
+ }
+#endif
+
// The Actuall installation implementation
virtual bool Install(PkgIterator Pkg,std::string File);
virtual bool Configure(PkgIterator Pkg);
virtual bool Remove(PkgIterator Pkg,bool Purge = false);
+#if (APT_PKG_MAJOR >= 4 && APT_PKG_MINOR >= 13)
virtual bool Go(APT::Progress::PackageManager *progress);
+#else
+ virtual bool Go(int StatusFd=-1);
+ bool GoNoABIBreak(APT::Progress::PackageManager *progress);
+#endif
+
virtual void Reset();
public: