diff options
Diffstat (limited to 'apt-private')
-rw-r--r-- | apt-private/private-cmndline.cc | 14 | ||||
-rw-r--r-- | apt-private/private-download.cc | 1 | ||||
-rw-r--r-- | apt-private/private-install.cc | 2 | ||||
-rw-r--r-- | apt-private/private-list.cc | 2 | ||||
-rw-r--r-- | apt-private/private-moo.cc | 4 | ||||
-rw-r--r-- | apt-private/private-output.cc | 16 | ||||
-rw-r--r-- | apt-private/private-show.cc | 3 | ||||
-rw-r--r-- | apt-private/private-update.cc | 1 |
8 files changed, 23 insertions, 20 deletions
diff --git a/apt-private/private-cmndline.cc b/apt-private/private-cmndline.cc index b99443210..132da04d5 100644 --- a/apt-private/private-cmndline.cc +++ b/apt-private/private-cmndline.cc @@ -14,7 +14,7 @@ #include <apti18n.h> /*}}}*/ -bool strcmp_match_in_list(char const * const Cmd, ...) /*{{{*/ +static bool strcmp_match_in_list(char const * const Cmd, ...) /*{{{*/ { va_list args; bool found = false; @@ -33,7 +33,7 @@ bool strcmp_match_in_list(char const * const Cmd, ...) /*{{{*/ /*}}}*/ #define addArg(w,x,y,z) Args.push_back(CommandLine::MakeArgs(w,x,y,z)) #define CmdMatches(...) strcmp_match_in_list(Cmd, __VA_ARGS__, NULL) -bool addArgumentsAPTCache(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ +static bool addArgumentsAPTCache(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ { if (CmdMatches("depends", "rdepends", "xvcg", "dotty")) { @@ -82,7 +82,7 @@ bool addArgumentsAPTCache(std::vector<CommandLine::Args> &Args, char const * con return true; } /*}}}*/ -bool addArgumentsAPTCDROM(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ +static bool addArgumentsAPTCDROM(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ { if (CmdMatches("add", "ident") == false) return false; @@ -100,7 +100,7 @@ bool addArgumentsAPTCDROM(std::vector<CommandLine::Args> &Args, char const * con return true; } /*}}}*/ -bool addArgumentsAPTConfig(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ +static bool addArgumentsAPTConfig(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ { if (CmdMatches("dump")) { @@ -115,7 +115,7 @@ bool addArgumentsAPTConfig(std::vector<CommandLine::Args> &Args, char const * co return true; } /*}}}*/ -bool addArgumentsAPTGet(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ +static bool addArgumentsAPTGet(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ { if (CmdMatches("install", "remove", "purge", "upgrade", "dist-upgrade", "dselect-upgrade", "autoremove")) @@ -202,7 +202,7 @@ bool addArgumentsAPTGet(std::vector<CommandLine::Args> &Args, char const * const return true; } /*}}}*/ -bool addArgumentsAPTMark(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ +static bool addArgumentsAPTMark(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ { if (CmdMatches("auto", "manual", "hold", "unhold", "showauto", "showmanual", "showhold", "showholds", "install", @@ -222,7 +222,7 @@ bool addArgumentsAPTMark(std::vector<CommandLine::Args> &Args, char const * cons return true; } /*}}}*/ -bool addArgumentsAPT(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ +static bool addArgumentsAPT(std::vector<CommandLine::Args> &Args, char const * const Cmd)/*{{{*/ { if (CmdMatches("list")) { diff --git a/apt-private/private-download.cc b/apt-private/private-download.cc index f02991cde..80795f964 100644 --- a/apt-private/private-download.cc +++ b/apt-private/private-download.cc @@ -8,6 +8,7 @@ #include <apt-pkg/strutl.h> #include "private-output.h" +#include "private-download.h" #include <locale.h> diff --git a/apt-private/private-install.cc b/apt-private/private-install.cc index 3adb00b23..ff609f567 100644 --- a/apt-private/private-install.cc +++ b/apt-private/private-install.cc @@ -386,7 +386,7 @@ bool InstallPackages(CacheFile &Cache,bool ShwKept,bool Ask, bool Safety) // DoAutomaticRemove - Remove all automatic unused packages /*{{{*/ // --------------------------------------------------------------------- /* Remove unused automatic packages */ -bool DoAutomaticRemove(CacheFile &Cache) +static bool DoAutomaticRemove(CacheFile &Cache) { bool Debug = _config->FindI("Debug::pkgAutoRemove",false); bool doAutoRemove = _config->FindB("APT::Get::AutomaticRemove", false); diff --git a/apt-private/private-list.cc b/apt-private/private-list.cc index 44a766c84..bc4539aeb 100644 --- a/apt-private/private-list.cc +++ b/apt-private/private-list.cc @@ -99,7 +99,7 @@ private: #undef PackageMatcher }; /*}}}*/ -void ListAllVersions(pkgCacheFile &CacheFile, pkgRecords &records, /*{{{*/ +static void ListAllVersions(pkgCacheFile &CacheFile, pkgRecords &records,/*{{{*/ pkgCache::PkgIterator P, std::ostream &outs, bool include_summary=true) diff --git a/apt-private/private-moo.cc b/apt-private/private-moo.cc index 23255db6f..5d247041d 100644 --- a/apt-private/private-moo.cc +++ b/apt-private/private-moo.cc @@ -22,7 +22,7 @@ #include <apti18n.h> /*}}}*/ -std::string getMooLine() { /*{{{*/ +static std::string getMooLine() { /*{{{*/ time_t const timenow = time(NULL); struct tm special; localtime_r(&timenow, &special); @@ -60,7 +60,7 @@ std::string getMooLine() { /*{{{*/ return out.str(); } /*}}}*/ -bool printMooLine() { /*{{{*/ +static bool printMooLine() { /*{{{*/ std::cerr << getMooLine() << std::endl; return true; } diff --git a/apt-private/private-output.cc b/apt-private/private-output.cc index 420ca14d5..dec518392 100644 --- a/apt-private/private-output.cc +++ b/apt-private/private-output.cc @@ -63,7 +63,7 @@ bool InitOutput() /*{{{*/ return true; } /*}}}*/ -std::string GetArchiveSuite(pkgCacheFile &CacheFile, pkgCache::VerIterator ver) /*{{{*/ +static std::string GetArchiveSuite(pkgCacheFile &CacheFile, pkgCache::VerIterator ver) /*{{{*/ { std::string suite = ""; if (ver && ver.FileList() && ver.FileList()) @@ -82,7 +82,7 @@ std::string GetArchiveSuite(pkgCacheFile &CacheFile, pkgCache::VerIterator ver) return suite; } /*}}}*/ -std::string GetFlagsStr(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ +static std::string GetFlagsStr(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ { pkgDepCache *DepCache = CacheFile.GetDepCache(); pkgDepCache::StateCache &state = (*DepCache)[P]; @@ -99,7 +99,7 @@ std::string GetFlagsStr(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ return flags_str; } /*}}}*/ -std::string GetCandidateVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ +static std::string GetCandidateVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ { pkgPolicy *policy = CacheFile.GetPolicy(); pkgCache::VerIterator cand = policy->GetCandidateVer(P); @@ -107,14 +107,14 @@ std::string GetCandidateVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P return cand ? cand.VerStr() : "(none)"; } /*}}}*/ -std::string GetInstalledVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ +static std::string GetInstalledVersion(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ { pkgCache::VerIterator inst = P.CurrentVer(); return inst ? inst.VerStr() : "(none)"; } /*}}}*/ -std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)/*{{{*/ +static std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)/*{{{*/ { pkgCache::PkgIterator P = V.ParentPkg(); if (V == P.CurrentVer()) @@ -134,16 +134,16 @@ std::string GetVersion(pkgCacheFile &CacheFile, pkgCache::VerIterator V)/*{{{*/ return "(none)"; } /*}}}*/ -std::string GetArchitecture(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ +static std::string GetArchitecture(pkgCacheFile &CacheFile, pkgCache::PkgIterator P)/*{{{*/ { pkgPolicy *policy = CacheFile.GetPolicy(); pkgCache::VerIterator inst = P.CurrentVer(); pkgCache::VerIterator cand = policy->GetCandidateVer(P); - + return inst ? inst.Arch() : cand.Arch(); } /*}}}*/ -std::string GetShortDescription(pkgCacheFile &CacheFile, pkgRecords &records, pkgCache::PkgIterator P)/*{{{*/ +static std::string GetShortDescription(pkgCacheFile &CacheFile, pkgRecords &records, pkgCache::PkgIterator P)/*{{{*/ { pkgPolicy *policy = CacheFile.GetPolicy(); diff --git a/apt-private/private-show.cc b/apt-private/private-show.cc index 0a69debbf..94f944af1 100644 --- a/apt-private/private-show.cc +++ b/apt-private/private-show.cc @@ -24,6 +24,7 @@ #include "private-output.h" #include "private-cacheset.h" +#include "private-show.h" /*}}}*/ namespace APT { @@ -31,7 +32,7 @@ namespace APT { // DisplayRecord - Displays the complete record for the package /*{{{*/ // --------------------------------------------------------------------- -bool DisplayRecord(pkgCacheFile &CacheFile, pkgCache::VerIterator V, +static bool DisplayRecord(pkgCacheFile &CacheFile, pkgCache::VerIterator V, ostream &out) { pkgCache *Cache = CacheFile.GetPkgCache(); diff --git a/apt-private/private-update.cc b/apt-private/private-update.cc index f6c12c26a..1f6fb6f79 100644 --- a/apt-private/private-update.cc +++ b/apt-private/private-update.cc @@ -31,6 +31,7 @@ #include "private-cachefile.h" #include "private-output.h" +#include "private-update.h" #include "acqprogress.h" #include <apti18n.h> |