From ccf6bdb3efc54165c76b42aae94c498a36acbe1b Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Fri, 7 Nov 2014 14:20:36 +0100 Subject: use a abi version check similar to the gcc check Git-Dch: Ignore --- apt-private/private-install.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'apt-private/private-install.cc') diff --git a/apt-private/private-install.cc b/apt-private/private-install.cc index 2a4c3eea5..79a22edf4 100644 --- a/apt-private/private-install.cc +++ b/apt-private/private-install.cc @@ -94,7 +94,7 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask, bool Safety) { pkgSimulate PM(Cache); -#if (APT_PKG_MAJOR >= 4 && APT_PKG_MINOR >= 13) +#if APT_PKG_ABI >= 413 APT::Progress::PackageManager *progress = APT::Progress::PackageManagerProgressFactory(); pkgPackageManager::OrderResult Res = PM.DoInstall(progress); delete progress; @@ -306,8 +306,8 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask, bool Safety) } _system->UnLock(); - -#if (APT_PKG_MAJOR >= 4 && APT_PKG_MINOR >= 13) + +#if APT_PKG_ABI >= 413 APT::Progress::PackageManager *progress = APT::Progress::PackageManagerProgressFactory(); pkgPackageManager::OrderResult Res = PM->DoInstall(progress); delete progress; -- cgit v1.2.3 From dfad5beea77d75983f6ff8a1b8296b74dd48203e Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Sun, 15 Mar 2015 22:34:54 +0100 Subject: add a simple unit test for acquire progress This isn't testing much of the 'complex' parts, but its better than nothing for now. Git-Dch: Ignore --- apt-private/private-install.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'apt-private/private-install.cc') diff --git a/apt-private/private-install.cc b/apt-private/private-install.cc index 79a22edf4..acc6d42c2 100644 --- a/apt-private/private-install.cc +++ b/apt-private/private-install.cc @@ -116,7 +116,7 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask, bool Safety) return false; // Create the download object - AcqTextStatus Stat(ScreenWidth,_config->FindI("quiet",0)); + AcqTextStatus Stat(std::cout, ScreenWidth,_config->FindI("quiet",0)); pkgAcquire Fetcher(&Stat); if (_config->FindB("APT::Get::Print-URIs", false) == true) { -- cgit v1.2.3