From 897165afb4681cff0e3a4bcb65f21b6d67718fbe Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:04:26 +0100 Subject: * apt-pkg/deb/dpkgpm.cc: - stdin redirected to /dev/null takes all CPU (Closes: #569488) Thanks to Aurelien Jarno for providing (again) a patch! --- apt-pkg/deb/dpkgpm.cc | 2 +- debian/changelog | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index 565f01b84..3dca2b209 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -1005,7 +1005,7 @@ bool pkgDPkgPM::Go(int OutStatusFd) // wait for input or output here FD_ZERO(&rfds); - if (!stdin_is_dev_null) + if (master >= 0 && !stdin_is_dev_null) FD_SET(0, &rfds); FD_SET(_dpkgin, &rfds); if(master >= 0) diff --git a/debian/changelog b/debian/changelog index df16a69dd..baa1fff93 100644 --- a/debian/changelog +++ b/debian/changelog @@ -18,6 +18,9 @@ apt (0.7.26) UNRELEASED; urgency=low - add APT::FTPArchive::AlwaysStat to disable the too aggressive caching if versions are build multiply times (not recommend) Patch by Christoph Goehre, thanks! (Closes: #463260) + * apt-pkg/deb/dpkgpm.cc: + - stdin redirected to /dev/null takes all CPU (Closes: #569488) + Thanks to Aurelien Jarno for providing (again) a patch! [ Ivan Masár ] * Slovak translation update. Closes: #568294 -- cgit v1.2.3-70-g09d2 From 319810767180e5c57c296b06c93e3ebec9f36a8e Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:05:14 +0100 Subject: - add --arch option for apt-ftparchive packages and contents commands - if an arch is given accept only *_all.deb and *_arch.deb instead of *.deb. Thanks Stephan Bosch for the patch! (Closes: #319710) --- debian/changelog | 3 +++ doc/apt-ftparchive.1.xml | 12 ++++++++++-- ftparchive/apt-ftparchive.cc | 7 ++++--- ftparchive/writer.cc | 30 ++++++++++++++---------------- ftparchive/writer.h | 6 +++--- 5 files changed, 34 insertions(+), 24 deletions(-) diff --git a/debian/changelog b/debian/changelog index baa1fff93..10cccda47 100644 --- a/debian/changelog +++ b/debian/changelog @@ -15,6 +15,9 @@ apt (0.7.26) UNRELEASED; urgency=low - allow also to skip the last patch if target is reached, thanks Bernhard R. Link! (Closes: #545699) * ftparchive/writer.{cc,h}: + - add --arch option for packages and contents commands + - if an arch is given accept only *_all.deb and *_arch.deb instead + of *.deb. Thanks Stephan Bosch for the patch! (Closes: #319710) - add APT::FTPArchive::AlwaysStat to disable the too aggressive caching if versions are build multiply times (not recommend) Patch by Christoph Goehre, thanks! (Closes: #463260) diff --git a/doc/apt-ftparchive.1.xml b/doc/apt-ftparchive.1.xml index eb61eae51..f88dbe631 100644 --- a/doc/apt-ftparchive.1.xml +++ b/doc/apt-ftparchive.1.xml @@ -39,6 +39,7 @@ + @@ -542,11 +543,18 @@ for i in Sections do Make the caching databases read only. Configuration Item: APT::FTPArchive::ReadOnlyDB. - + + + + Accept in the packages and contents + commands only package files matching *_arch.deb or + *_all.deb instead of all package files in the given path. + Configuration Item: APT::FTPArchive::Architecture. + - &apt-ftparchive; caches as much as possible of metadata in it is cachedb. If packages + &apt-ftparchive; caches as much as possible of metadata in a cachedb. If packages are recompiled and/or republished with the same version again, this will lead to problems as the now outdated cached metadata like size and checksums will be used. With this option enabled this will no longer happen as it will be checked if the file was changed. diff --git a/ftparchive/apt-ftparchive.cc b/ftparchive/apt-ftparchive.cc index 5b6b3940c..f1a182e52 100644 --- a/ftparchive/apt-ftparchive.cc +++ b/ftparchive/apt-ftparchive.cc @@ -333,7 +333,7 @@ bool PackageMap::GenContents(Configuration &Setup, gettimeofday(&StartTime,0); // Create a package writer object. - ContentsWriter Contents(""); + ContentsWriter Contents("", Arch); if (PkgExt.empty() == false && Contents.SetExts(PkgExt) == false) return _error->Error(_("Package extension list is too long")); if (_error->PendingError() == true) @@ -606,7 +606,7 @@ bool SimpleGenPackages(CommandLine &CmdL) // Create a package writer object. PackagesWriter Packages(_config->Find("APT::FTPArchive::DB"), - Override, ""); + Override, "", _config->Find("APT::FTPArchive::Architecture")); if (_error->PendingError() == true) return false; @@ -629,7 +629,7 @@ bool SimpleGenContents(CommandLine &CmdL) return ShowHelp(CmdL); // Create a package writer object. - ContentsWriter Contents(_config->Find("APT::FTPArchive::DB")); + ContentsWriter Contents(_config->Find("APT::FTPArchive::DB"), _config->Find("APT::FTPArchive::Architecture")); if (_error->PendingError() == true) return false; @@ -910,6 +910,7 @@ int main(int argc, const char *argv[]) {0,"delink","APT::FTPArchive::DeLinkAct",0}, {0,"readonly","APT::FTPArchive::ReadOnlyDB",0}, {0,"contents","APT::FTPArchive::Contents",0}, + {'a',"arch","APT::FTPArchive::Architecture",CommandLine::HasArg}, {'c',"config-file",0,CommandLine::ConfigFile}, {'o',"option",0,CommandLine::ArbItem}, {0,0,0,0}}; diff --git a/ftparchive/writer.cc b/ftparchive/writer.cc index 18a3de0c2..9e5b7d4f3 100644 --- a/ftparchive/writer.cc +++ b/ftparchive/writer.cc @@ -54,7 +54,7 @@ inline void SetTFRewriteData(struct TFRewriteData &tfrd, // FTWScanner::FTWScanner - Constructor /*{{{*/ // --------------------------------------------------------------------- /* */ -FTWScanner::FTWScanner() +FTWScanner::FTWScanner(string const &Arch): Arch(Arch) { ErrorPrinted = false; NoLinkAct = !_config->FindB("APT::FTPArchive::DeLinkAct",true); @@ -299,12 +299,11 @@ bool FTWScanner::Delink(string &FileName,const char *OriginalPath, // --------------------------------------------------------------------- /* */ PackagesWriter::PackagesWriter(string const &DB,string const &Overrides,string const &ExtOverrides, - string const &aArch) : - Db(DB),Stats(Db.Stats), Arch(aArch) + string const &Arch) : + FTWScanner(Arch), Db(DB), Stats(Db.Stats) { Output = stdout; - SetExts(".deb .udeb .foo .bar .baz"); - AddPattern("*.deb"); + SetExts(".deb .udeb"); DeLinkLimit = 0; // Process the command line options @@ -340,17 +339,16 @@ bool FTWScanner::SetExts(string const &Vals) string::size_type Start = 0; while (Start <= Vals.length()-1) { - string::size_type Space = Vals.find(' ',Start); - string::size_type Length; - if (Space == string::npos) + string::size_type const Space = Vals.find(' ',Start); + string::size_type const Length = ((Space == string::npos) ? Vals.length() : Space) - Start; + if ( Arch.empty() == false ) { - Length = Vals.length()-Start; + AddPattern(string("*_") + Arch + Vals.substr(Start, Length)); + AddPattern(string("*_all") + Vals.substr(Start, Length)); } else - { - Length = Space-Start; - } - AddPattern(string("*") + Vals.substr(Start, Length)); + AddPattern(string("*") + Vals.substr(Start, Length)); + Start += Length + 1; } @@ -767,11 +765,11 @@ bool SourcesWriter::DoPackage(string FileName) // ContentsWriter::ContentsWriter - Constructor /*{{{*/ // --------------------------------------------------------------------- /* */ -ContentsWriter::ContentsWriter(string const &DB) : - Db(DB), Stats(Db.Stats) +ContentsWriter::ContentsWriter(string const &DB, string const &Arch) : + FTWScanner(Arch), Db(DB), Stats(Db.Stats) { - AddPattern("*.deb"); + SetExts(".deb"); Output = stdout; } /*}}}*/ diff --git a/ftparchive/writer.h b/ftparchive/writer.h index 520e91dd6..af7ba4edd 100644 --- a/ftparchive/writer.h +++ b/ftparchive/writer.h @@ -34,6 +34,7 @@ class FTWScanner { protected: vector Patterns; + string Arch; const char *OriginalPath; bool ErrorPrinted; @@ -68,7 +69,7 @@ class FTWScanner void AddPattern(string const &Pattern) { Patterns.push_back(Pattern); }; bool SetExts(string const &Vals); - FTWScanner(); + FTWScanner(string const &Arch = string()); }; class PackagesWriter : public FTWScanner @@ -92,7 +93,6 @@ class PackagesWriter : public FTWScanner string DirStrip; FILE *Output; struct CacheDB::Stats &Stats; - string Arch; inline bool ReadOverride(string const &File) {return Over.ReadOverride(File);}; inline bool ReadExtraOverride(string const &File) @@ -125,7 +125,7 @@ class ContentsWriter : public FTWScanner void Finish() {Gen.Print(Output);}; inline bool ReadyDB(string const &DB) {return Db.ReadyDB(DB);}; - ContentsWriter(string const &DB); + ContentsWriter(string const &DB, string const &Arch = string()); virtual ~ContentsWriter() {}; }; -- cgit v1.2.3-70-g09d2 From d7cf5923a093e89ab5aac0bf8cd1c3042997990c Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:30:51 +0100 Subject: dd support for the LANGUAGE environment variable --- apt-pkg/aptconfiguration.cc | 92 ++++++++++++++++++++++++++-------------- apt-pkg/aptconfiguration.h | 2 +- apt-pkg/contrib/strutl.cc | 18 ++++++++ apt-pkg/contrib/strutl.h | 1 + test/libapt/getlanguages_test.cc | 61 ++++++++++++++++++++------ 5 files changed, 127 insertions(+), 47 deletions(-) diff --git a/apt-pkg/aptconfiguration.cc b/apt-pkg/aptconfiguration.cc index 899004d9f..9fd51ad5a 100644 --- a/apt-pkg/aptconfiguration.cc +++ b/apt-pkg/aptconfiguration.cc @@ -8,9 +8,11 @@ ##################################################################### */ /*}}}*/ // Include Files /*{{{*/ -#include #include #include +#include +#include +#include #include #include @@ -96,7 +98,7 @@ const Configuration::getCompressionTypes(bool const &Cached) { will result in "de_DE, de, en". The special word "none" is the stopcode for the not-All code vector */ std::vector const Configuration::getLanguages(bool const &All, - bool const &Cached, char const * const Locale) { + bool const &Cached, char const ** const Locale) { using std::string; // The detection is boring and has a lot of cornercases, @@ -117,27 +119,29 @@ std::vector const Configuration::getLanguages(bool const &All, } } - // get the environment language code + // get the environment language codes: LC_MESSAGES (and later LANGUAGE) // we extract both, a long and a short code and then we will // check if we actually need both (rare) or if the short is enough - string const envMsg = string(Locale == 0 ? std::setlocale(LC_MESSAGES, NULL) : Locale); + string const envMsg = string(Locale == 0 ? std::setlocale(LC_MESSAGES, NULL) : *Locale); size_t const lenShort = (envMsg.find('_') != string::npos) ? envMsg.find('_') : 2; - size_t const lenLong = (envMsg.find('.') != string::npos) ? envMsg.find('.') : (lenShort + 3); + size_t const lenLong = (envMsg.find_first_of(".@") != string::npos) ? envMsg.find_first_of(".@") : (lenShort + 3); string envLong = envMsg.substr(0,lenLong); string const envShort = envLong.substr(0,lenShort); - bool envLongIncluded = true, envShortIncluded = false; + bool envLongIncluded = true; // first cornercase: LANG=C, so we use only "en" Translation if (envLong == "C") { codes.push_back("en"); + allCodes = codes; return codes; } + // to save the servers from unneeded queries, we only try also long codes + // for languages it is realistic to have a long code translation file… + // TODO: Improve translation acquire system to drop them dynamic + char const *needLong[] = { "cs", "en", "pt", "sv", "zh", NULL }; if (envLong != envShort) { - // to save the servers from unneeded queries, we only try also long codes - // for languages it is realistic to have a long code translation file... - char const *needLong[] = { "cs", "en", "pt", "sv", "zh", NULL }; for (char const **l = needLong; *l != NULL; l++) if (envShort.compare(*l) == 0) { envLongIncluded = false; @@ -155,33 +159,64 @@ std::vector const Configuration::getLanguages(bool const &All, if (oldAcquire.empty() == false && oldAcquire != "environment") { if (oldAcquire != "none") codes.push_back(oldAcquire); + allCodes = codes; return codes; } + // It is very likely we will need to environment codes later, + // so let us generate them now from LC_MESSAGES and LANGUAGE + std::vector environment; + // take care of LC_MESSAGES + if (envLongIncluded == false) + environment.push_back(envLong); + environment.push_back(envShort); + // take care of LANGUAGE + string envLang = Locale == 0 ? getenv("LANGUAGE") : *(Locale+1); + if (envLang.empty() == false) { + std::vector env = ExplodeString(envLang,':'); + short addedLangs = 0; // add a maximum of 3 fallbacks from the environment + for (std::vector::const_iterator e = env.begin(); + e != env.end() && addedLangs < 3; ++e) { + if (unlikely(e->empty() == true) || *e == "en") + continue; + if (*e == envLong || *e == envShort) + continue; + if (std::find(environment.begin(), environment.end(), *e) != environment.end()) + continue; + if (e->find('_') != string::npos) { + // Drop LongCodes here - ShortCodes are also included + string const shorty = e->substr(0, e->find('_')); + char const **n = needLong; + for (; *n != NULL; ++n) + if (shorty == *n) + break; + if (*n == NULL) + continue; + } + ++addedLangs; + environment.push_back(*e); + } + } + // Support settings like Acquire::Translation=none on the command line to // override the configuration settings vector of languages. string const forceLang = _config->Find("Acquire::Languages",""); if (forceLang.empty() == false) { if (forceLang == "environment") { - if (envLongIncluded == false) - codes.push_back(envLong); - if (envShortIncluded == false) - codes.push_back(envShort); - return codes; + codes = environment; } else if (forceLang != "none") codes.push_back(forceLang); + allCodes = codes; return codes; } std::vector const lang = _config->FindVector("Acquire::Languages"); // the default setting -> "environment, en" if (lang.empty() == true) { - if (envLongIncluded == false) - codes.push_back(envLong); - if (envShortIncluded == false) - codes.push_back(envShort); + codes = environment; if (envShort != "en") codes.push_back("en"); + allCodes = codes; return codes; } @@ -191,26 +226,19 @@ std::vector const Configuration::getLanguages(bool const &All, for (std::vector::const_iterator l = lang.begin(); l != lang.end(); l++) { if (*l == "environment") { - if (envLongIncluded == true && envShortIncluded == true) - continue; - if (envLongIncluded == false) { - envLongIncluded = true; - if (noneSeen == false) - codes.push_back(envLong); - allCodes.push_back(envLong); - } - if (envShortIncluded == false) { - envShortIncluded = true; + for (std::vector::const_iterator e = environment.begin(); + e != environment.end(); ++e) { + if (std::find(allCodes.begin(), allCodes.end(), *e) != allCodes.end()) + continue; if (noneSeen == false) - codes.push_back(envShort); - allCodes.push_back(envShort); + codes.push_back(*e); + allCodes.push_back(*e); } continue; } else if (*l == "none") { noneSeen = true; continue; - } else if ((envLongIncluded == true && *l == envLong) || - (envShortIncluded == true && *l == envShort)) + } else if (std::find(allCodes.begin(), allCodes.end(), *l) != allCodes.end()) continue; if (noneSeen == false) diff --git a/apt-pkg/aptconfiguration.h b/apt-pkg/aptconfiguration.h index f2f04a39b..2ba1b3825 100644 --- a/apt-pkg/aptconfiguration.h +++ b/apt-pkg/aptconfiguration.h @@ -64,7 +64,7 @@ public: /*{{{*/ * \return a vector of (all) Language Codes in the prefered usage order */ std::vector static const getLanguages(bool const &All = false, - bool const &Cached = true, char const * const Locale = 0); + bool const &Cached = true, char const ** const Locale = 0); /*}}}*/ }; diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc index 2913fbf44..3bbaf5f30 100644 --- a/apt-pkg/contrib/strutl.cc +++ b/apt-pkg/contrib/strutl.cc @@ -1000,6 +1000,24 @@ bool TokSplitString(char Tok,char *Input,char **List, return true; } /*}}}*/ +// ExplodeString - Split a string up into a vector /*{{{*/ +// --------------------------------------------------------------------- +/* This can be used to split a given string up into a vector, so the + propose is the same as in the method above and this one is a bit slower + also, but the advantage is that we an iteratable vector */ +vector ExplodeString(string const &haystack, char const &split) +{ + string::const_iterator start = haystack.begin(); + string::const_iterator end = start; + vector exploded; + do { + for (; end != haystack.end() && *end != split; ++end); + exploded.push_back(string(start, end)); + start = end + 1; + } while (end != haystack.end() && (++end) != haystack.end()); + return exploded; +} + /*}}}*/ // RegexChoice - Simple regex list/list matcher /*{{{*/ // --------------------------------------------------------------------- /* */ diff --git a/apt-pkg/contrib/strutl.h b/apt-pkg/contrib/strutl.h index 2b2e147fb..d65f975d2 100644 --- a/apt-pkg/contrib/strutl.h +++ b/apt-pkg/contrib/strutl.h @@ -59,6 +59,7 @@ bool StrToNum(const char *Str,unsigned long &Res,unsigned Len,unsigned Base = 0) bool Hex2Num(const string &Str,unsigned char *Num,unsigned int Length); bool TokSplitString(char Tok,char *Input,char **List, unsigned long ListMax); +vector ExplodeString(string const &haystack, char const &split); void ioprintf(ostream &out,const char *format,...) APT_FORMAT2; void strprintf(string &out,const char *format,...) APT_FORMAT2; char *safe_snprintf(char *Buffer,char *End,const char *Format,...) APT_FORMAT3; diff --git a/test/libapt/getlanguages_test.cc b/test/libapt/getlanguages_test.cc index fd3c8269f..fb7afb4ef 100644 --- a/test/libapt/getlanguages_test.cc +++ b/test/libapt/getlanguages_test.cc @@ -16,75 +16,108 @@ void dumpVector(std::vector vec) { int main(int argc,char *argv[]) { - std::vector vec = APT::Configuration::getLanguages(false, false, "de_DE.UTF-8"); + char const* env[2]; + env[0] = "de_DE.UTF-8"; + env[1] = ""; + std::vector vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 2); equals(vec[0], "de"); equals(vec[1], "en"); // Special: Check if the cache is actually in use - vec = APT::Configuration::getLanguages(false, true, "en_GB.UTF-8"); + env[0] = "en_GB.UTF-8"; + vec = APT::Configuration::getLanguages(false, true, env); equals(vec.size(), 2); equals(vec[0], "de"); equals(vec[1], "en"); - vec = APT::Configuration::getLanguages(false, false, "en_GB.UTF-8"); + env[0] = "en_GB.UTF-8"; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 2); equals(vec[0], "en_GB"); equals(vec[1], "en"); - vec = APT::Configuration::getLanguages(false, false, "pt_PR.UTF-8"); + env[0] = "tr_DE@euro"; + vec = APT::Configuration::getLanguages(false, false, env); + equals(vec.size(), 2); + equals(vec[0], "tr"); + equals(vec[1], "en"); + + env[0] = "de_NO"; + env[1] = "se_NO:en_GB:nb_NO:nb:no_NO:no:nn_NO:nn:da:sv:en"; + vec = APT::Configuration::getLanguages(false, false, env); + equals(vec.size(), 5); + equals(vec[0], "de"); + equals(vec[1], "en_GB"); + equals(vec[2], "nb"); + equals(vec[3], "no"); + equals(vec[4], "en"); + + env[0] = "pt_PR.UTF-8"; + env[1] = ""; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 3); equals(vec[0], "pt_PR"); equals(vec[1], "pt"); equals(vec[2], "en"); - vec = APT::Configuration::getLanguages(false, false, "ast_DE.UTF-8"); // bogus, but syntactical correct + env[0] = "ast_DE.UTF-8"; + vec = APT::Configuration::getLanguages(false, false, env); // bogus, but syntactical correct equals(vec.size(), 2); equals(vec[0], "ast"); equals(vec[1], "en"); - vec = APT::Configuration::getLanguages(false, false, "C"); + env[0] = "C"; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 1); equals(vec[0], "en"); _config->Set("Acquire::Languages::1", "environment"); _config->Set("Acquire::Languages::2", "en"); - vec = APT::Configuration::getLanguages(false, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 2); equals(vec[0], "de"); equals(vec[1], "en"); _config->Set("Acquire::Languages::3", "de"); - vec = APT::Configuration::getLanguages(false, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 2); equals(vec[0], "de"); equals(vec[1], "en"); _config->Set("Acquire::Languages::1", "none"); - vec = APT::Configuration::getLanguages(false, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 0); - vec = APT::Configuration::getLanguages(true, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(true, false, env); equals(vec[0], "en"); equals(vec[1], "de"); _config->Set("Acquire::Languages::1", "fr"); _config->Set("Acquire::Languages", "de_DE"); - vec = APT::Configuration::getLanguages(false, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 1); equals(vec[0], "de_DE"); _config->Set("Acquire::Languages", "none"); - vec = APT::Configuration::getLanguages(true, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(true, false, env); equals(vec.size(), 0); _config->Set("Acquire::Languages", ""); //FIXME: Remove support for this deprecated setting _config->Set("APT::Acquire::Translation", "ast_DE"); - vec = APT::Configuration::getLanguages(true, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(true, false, env); equals(vec.size(), 1); equals(vec[0], "ast_DE"); _config->Set("APT::Acquire::Translation", "none"); - vec = APT::Configuration::getLanguages(true, false, "de_DE.UTF-8"); + env[0] = "de_DE.UTF-8"; + vec = APT::Configuration::getLanguages(true, false, env); equals(vec.size(), 0); return 0; -- cgit v1.2.3-70-g09d2 From f0f2f956957af36389790fd47899a1f65302b21c Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:31:49 +0100 Subject: * buildlib/apti18n.h.in, po/makefile: - add ngettext support with P_() --- buildlib/apti18n.h.in | 3 +++ cmdline/apt-get.cc | 12 +++++++----- debian/changelog | 2 ++ po/makefile | 1 + 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/buildlib/apti18n.h.in b/buildlib/apti18n.h.in index e7beceb09..6928d626c 100644 --- a/buildlib/apti18n.h.in +++ b/buildlib/apti18n.h.in @@ -11,8 +11,10 @@ # include # ifdef APT_DOMAIN # define _(x) dgettext(APT_DOMAIN,x) +# define P_(msg,plural,n) dngettext(APT_DOMAIN,msg,plural,n) # else # define _(x) gettext(x) +# define P_(msg,plural,n) ngettext(msg,plural,n) # endif # define N_(x) x #else @@ -21,5 +23,6 @@ # define textdomain(a) # define bindtextdomain(a, b) # define _(x) x +# define P_(msg,plural,n) (n == 1 ? msg : plural) # define N_(x) x #endif diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc index 34ae2fed9..5a814e255 100644 --- a/cmdline/apt-get.cc +++ b/cmdline/apt-get.cc @@ -1504,10 +1504,9 @@ bool DoAutomaticRemove(CacheFile &Cache) // only show stuff in the list that is not yet marked for removal if(Cache[Pkg].Delete() == false) { + ++autoRemoveCount; // we don't need to fill the strings if we don't need them - if (smallList == true) - ++autoRemoveCount; - else + if (smallList == false) { autoremovelist += string(Pkg.Name()) + " "; autoremoveversions += string(Cache[Pkg].CandVersion) + "\n"; @@ -1520,9 +1519,12 @@ bool DoAutomaticRemove(CacheFile &Cache) if (doAutoRemove == false && (autoremovelist.empty() == false || autoRemoveCount != 0)) { if (smallList == false) - ShowList(c1out, _("The following packages were automatically installed and are no longer required:"), autoremovelist, autoremoveversions); + ShowList(c1out, P_("The following package is automatically installed and is no longer required:", + "The following packages were automatically installed and are no longer required:", + autoRemoveCount), autoremovelist, autoremoveversions); else - ioprintf(c1out, _("%lu packages were automatically installed and are no longer required.\n"), autoRemoveCount); + ioprintf(c1out, P_("%lu package was automatically installed and is no longer required.\n", + "%lu packages were automatically installed and are no longer required.\n", autoRemoveCount), autoRemoveCount); c1out << _("Use 'apt-get autoremove' to remove them.") << std::endl; } // Now see if we had destroyed anything (if we had done anything) diff --git a/debian/changelog b/debian/changelog index 10cccda47..47fe7adf9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -24,6 +24,8 @@ apt (0.7.26) UNRELEASED; urgency=low * apt-pkg/deb/dpkgpm.cc: - stdin redirected to /dev/null takes all CPU (Closes: #569488) Thanks to Aurelien Jarno for providing (again) a patch! + * buildlib/apti18n.h.in, po/makefile: + - add ngettext support with P_() [ Ivan Masár ] * Slovak translation update. Closes: #568294 diff --git a/po/makefile b/po/makefile index 07dc51c07..9f8b7b22e 100644 --- a/po/makefile +++ b/po/makefile @@ -37,6 +37,7 @@ $(POTFILES) : $(PO)/%.pot : cat $(PO)/domains/$*/*.srclist > $(PO)/POTFILES_$*.in $(XGETTEXT) --default-domain=$* --directory=$(BASE) \ --add-comments --foreign --keyword=_ --keyword=N_ \ + --keyword=P_:1,2 \ --files-from=$(PO)/POTFILES_$*.in -o $(PO)/domains/$*/c.pot rm -f $(PO)/POTFILES_$*.in $(MSGCOMM) --more-than=0 $(PO)/domains/$*/c.pot $(PO)/domains/$*/sh.pot --output=$@ -- cgit v1.2.3-70-g09d2 From 3f2d77b5e02c5749a78ad9852c01cfad4ce0fda1 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:35:25 +0100 Subject: * aptconfiguration.cc: - include all existing Translation files in the Cache (Closes: 564137) Previously if APT was executed with a different LC_* all these invocations needed to rebuild the Cache as too many files were included or missing: Now the lists-directory is checked for Translation-files and all these will be included in getLanguages() regardless of the environment setting (after a "none" so APT will not use them for displaying information). --- apt-pkg/aptconfiguration.cc | 78 ++++++++++++++++++++++++++++++++++++---- apt-pkg/deb/debmetaindex.cc | 5 ++- debian/changelog | 2 ++ test/libapt/getlanguages_test.cc | 22 ++++++++++-- test/libapt/run-tests.sh | 7 ++++ 5 files changed, 105 insertions(+), 9 deletions(-) diff --git a/apt-pkg/aptconfiguration.cc b/apt-pkg/aptconfiguration.cc index 9fd51ad5a..b5f29472d 100644 --- a/apt-pkg/aptconfiguration.cc +++ b/apt-pkg/aptconfiguration.cc @@ -14,9 +14,12 @@ #include #include -#include -#include +#include +#include + #include +#include +#include /*}}}*/ namespace APT { // getCompressionTypes - Return Vector of usbale compressiontypes /*{{{*/ @@ -119,6 +122,37 @@ std::vector const Configuration::getLanguages(bool const &All, } } + // Include all Language codes we have a Translation file for in /var/lib/apt/lists + // so they will be all included in the Cache. + std::vector builtin; + DIR *D = opendir(_config->FindDir("Dir::State::lists").c_str()); + if (D != 0) { + builtin.push_back("none"); + for (struct dirent *Ent = readdir(D); Ent != 0; Ent = readdir(D)) { + string const name = Ent->d_name; + size_t const foundDash = name.rfind("-"); + size_t const foundUnderscore = name.rfind("_"); + if (foundDash == string::npos || foundUnderscore == string::npos || + foundDash <= foundUnderscore || + name.substr(foundUnderscore+1, foundDash-(foundUnderscore+1)) != "Translation") + continue; + string const c = name.substr(foundDash+1); + if (unlikely(c.empty() == true) || c == "en") + continue; + // Skip unusual files, like backups or that alike + string::const_iterator s = c.begin(); + for (;s != c.end(); ++s) { + if (isalpha(*s) == 0) + break; + } + if (s != c.end()) + continue; + if (std::find(builtin.begin(), builtin.end(), c) != builtin.end()) + continue; + builtin.push_back(c); + } + } + // get the environment language codes: LC_MESSAGES (and later LANGUAGE) // we extract both, a long and a short code and then we will // check if we actually need both (rare) or if the short is enough @@ -134,7 +168,11 @@ std::vector const Configuration::getLanguages(bool const &All, if (envLong == "C") { codes.push_back("en"); allCodes = codes; - return codes; + allCodes.insert(allCodes.end(), builtin.begin(), builtin.end()); + if (All == true) + return allCodes; + else + return codes; } // to save the servers from unneeded queries, we only try also long codes @@ -159,8 +197,16 @@ std::vector const Configuration::getLanguages(bool const &All, if (oldAcquire.empty() == false && oldAcquire != "environment") { if (oldAcquire != "none") codes.push_back(oldAcquire); + codes.push_back("en"); allCodes = codes; - return codes; + for (std::vector::const_iterator b = builtin.begin(); + b != builtin.end(); ++b) + if (std::find(allCodes.begin(), allCodes.end(), *b) == allCodes.end()) + allCodes.push_back(*b); + if (All == true) + return allCodes; + else + return codes; } // It is very likely we will need to environment codes later, @@ -207,7 +253,14 @@ std::vector const Configuration::getLanguages(bool const &All, } else if (forceLang != "none") codes.push_back(forceLang); allCodes = codes; - return codes; + for (std::vector::const_iterator b = builtin.begin(); + b != builtin.end(); ++b) + if (std::find(allCodes.begin(), allCodes.end(), *b) == allCodes.end()) + allCodes.push_back(*b); + if (All == true) + return allCodes; + else + return codes; } std::vector const lang = _config->FindVector("Acquire::Languages"); @@ -217,7 +270,14 @@ std::vector const Configuration::getLanguages(bool const &All, if (envShort != "en") codes.push_back("en"); allCodes = codes; - return codes; + for (std::vector::const_iterator b = builtin.begin(); + b != builtin.end(); ++b) + if (std::find(allCodes.begin(), allCodes.end(), *b) == allCodes.end()) + allCodes.push_back(*b); + if (All == true) + return allCodes; + else + return codes; } // the configs define the order, so add the environment @@ -245,6 +305,12 @@ std::vector const Configuration::getLanguages(bool const &All, codes.push_back(*l); allCodes.push_back(*l); } + + for (std::vector::const_iterator b = builtin.begin(); + b != builtin.end(); ++b) + if (std::find(allCodes.begin(), allCodes.end(), *b) == allCodes.end()) + allCodes.push_back(*b); + if (All == true) return allCodes; else diff --git a/apt-pkg/deb/debmetaindex.cc b/apt-pkg/deb/debmetaindex.cc index 8f28f053b..520e94a80 100644 --- a/apt-pkg/deb/debmetaindex.cc +++ b/apt-pkg/deb/debmetaindex.cc @@ -181,6 +181,7 @@ bool debReleaseIndex::GetIndexes(pkgAcquire *Owner, bool GetAll) const for (vector::const_iterator l = lang.begin(); l != lang.end(); l++) { + if (*l == "none") continue; debTranslationsIndex i = debTranslationsIndex(URI,Dist,(*I)->Section,(*l).c_str()); i.GetIndexes(Owner); } @@ -219,8 +220,10 @@ vector *debReleaseIndex::GetIndexFiles() Indexes->push_back(new debPackagesIndex (URI, Dist, (*I)->Section, IsTrusted())); for (vector::const_iterator l = lang.begin(); - l != lang.end(); l++) + l != lang.end(); l++) { + if (*l == "none") continue; Indexes->push_back(new debTranslationsIndex(URI,Dist,(*I)->Section,(*l).c_str())); + } } } diff --git a/debian/changelog b/debian/changelog index 47fe7adf9..d929fc18b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -26,6 +26,8 @@ apt (0.7.26) UNRELEASED; urgency=low Thanks to Aurelien Jarno for providing (again) a patch! * buildlib/apti18n.h.in, po/makefile: - add ngettext support with P_() + * aptconfiguration.cc: + - include all existing Translation files in the Cache (Closes: 564137) [ Ivan Masár ] * Slovak translation update. Closes: #568294 diff --git a/test/libapt/getlanguages_test.cc b/test/libapt/getlanguages_test.cc index fb7afb4ef..0db190b50 100644 --- a/test/libapt/getlanguages_test.cc +++ b/test/libapt/getlanguages_test.cc @@ -16,9 +16,15 @@ void dumpVector(std::vector vec) { int main(int argc,char *argv[]) { + if (argc != 2) { + std::cout << "One parameter expected - given " << argc << std::endl; + return 100; + } + char const* env[2]; env[0] = "de_DE.UTF-8"; env[1] = ""; + std::vector vec = APT::Configuration::getLanguages(false, false, env); equals(vec.size(), 2); equals(vec[0], "de"); @@ -87,6 +93,16 @@ int main(int argc,char *argv[]) equals(vec[0], "de"); equals(vec[1], "en"); + _config->Set("Dir::State::lists", argv[1]); + vec = APT::Configuration::getLanguages(true, false, env); + equals(vec.size(), 5); + equals(vec[0], "de"); + equals(vec[1], "en"); + equals(vec[2], "none"); + equals(vec[3], "pt"); + equals(vec[4], "tr"); + + _config->Set("Dir::State::lists", "/non-existing-dir"); _config->Set("Acquire::Languages::1", "none"); env[0] = "de_DE.UTF-8"; vec = APT::Configuration::getLanguages(false, false, env); @@ -113,12 +129,14 @@ int main(int argc,char *argv[]) _config->Set("APT::Acquire::Translation", "ast_DE"); env[0] = "de_DE.UTF-8"; vec = APT::Configuration::getLanguages(true, false, env); - equals(vec.size(), 1); + equals(vec.size(), 2); equals(vec[0], "ast_DE"); + equals(vec[1], "en"); _config->Set("APT::Acquire::Translation", "none"); env[0] = "de_DE.UTF-8"; vec = APT::Configuration::getLanguages(true, false, env); - equals(vec.size(), 0); + equals(vec.size(), 1); + equals(vec[0], "en"); return 0; } diff --git a/test/libapt/run-tests.sh b/test/libapt/run-tests.sh index 1fcfb6861..f9df1af5f 100755 --- a/test/libapt/run-tests.sh +++ b/test/libapt/run-tests.sh @@ -39,6 +39,13 @@ do "${tmppath}/01invalíd" ln -s "${tmppath}/anormalfile" "${tmppath}/linkedfile.list" ln -s "${tmppath}/non-existing-file" "${tmppath}/brokenlink.list" + elif [ $name = "getLanguages${EXT}" ]; then + echo "Prepare Testarea for \033[1;35m$name\033[0m ..." + tmppath=$(mktemp -d) + touch "${tmppath}/ftp.de.debian.org_debian_dists_sid_main_i18n_Translation-tr" \ + "${tmppath}/ftp.de.debian.org_debian_dists_sid_main_i18n_Translation-pt" \ + "${tmppath}/ftp.de.debian.org_debian_dists_sid_main_i18n_Translation-se~" \ + "${tmppath}/ftp.de.debian.org_debian_dists_sid_main_i18n_Translation-st.bak" fi echo -n "Testing with \033[1;35m${name}\033[0m ... " -- cgit v1.2.3-70-g09d2 From 4a0cfd1573a4fd9e26f08b8c6929a27303611bcb Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:37:00 +0100 Subject: * debian/control: - update with no changes to debian policy 3.8.4 --- debian/changelog | 2 ++ debian/control | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index d929fc18b..b91bbdfd3 100644 --- a/debian/changelog +++ b/debian/changelog @@ -28,6 +28,8 @@ apt (0.7.26) UNRELEASED; urgency=low - add ngettext support with P_() * aptconfiguration.cc: - include all existing Translation files in the Cache (Closes: 564137) + * debian/control: + - update with no changes to debian policy 3.8.4 [ Ivan Masár ] * Slovak translation update. Closes: #568294 diff --git a/debian/control b/debian/control index d756871d1..de2bf6544 100644 --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: APT Development Team Uploaders: Michael Vogt , Otavio Salvador , Christian Perrier , Daniel Burrows , Luca Bruno , Julian Andres Klode -Standards-Version: 3.8.3 +Standards-Version: 3.8.4 Build-Depends: debhelper (>= 5.0), libdb-dev, gettext (>= 0.12), libcurl4-gnutls-dev | libcurl3-gnutls-dev (>= 7.15.5), debiandoc-sgml, xsltproc, docbook-xsl, po4a (>= 0.34-2), autotools-dev Vcs-Bzr: http://bzr.debian.org/apt/debian-sid/ -- cgit v1.2.3-70-g09d2 From d9dedf304b384763278f5b39aa0dc29e112185c3 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 00:37:52 +0100 Subject: * doc/apt_preferences.5.xml: - explicitly warn against careless use (Closes: #567669) --- debian/changelog | 2 ++ doc/apt_preferences.5.xml | 10 +++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index b91bbdfd3..f0ab5025b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -30,6 +30,8 @@ apt (0.7.26) UNRELEASED; urgency=low - include all existing Translation files in the Cache (Closes: 564137) * debian/control: - update with no changes to debian policy 3.8.4 + * doc/apt_preferences.5.xml: + - explicitly warn against careless use (Closes: #567669) [ Ivan Masár ] * Slovak translation update. Closes: #568294 diff --git a/doc/apt_preferences.5.xml b/doc/apt_preferences.5.xml index 9a4791c08..3d7896226 100644 --- a/doc/apt_preferences.5.xml +++ b/doc/apt_preferences.5.xml @@ -14,7 +14,7 @@ &apt-email; &apt-product; - 04 May 2009 + 16 February 2010 @@ -53,6 +53,14 @@ earliest in the &sources-list; file. The APT preferences file does not affect the choice of instance, only the choice of version. +Preferences are a strong power in the hands of a system administrator +but they can become also their biggest nightmare if used without care! +APT will not questioning the preferences so wrong settings will therefore +lead to uninstallable packages or wrong decisions while upgrading packages. +Even more problems will arise if multiply distribution releases are mixed +without a good understanding of the following paragraphs. +You have been warned. + Note that the files in the /etc/apt/preferences.d directory are parsed in alphanumeric ascending order and need to obey the following naming convention: The files have no or "pref" -- cgit v1.2.3-70-g09d2 From 44c8b5dff8871485d071f92cd154dc1c14c3c015 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 01:37:59 +0100 Subject: we break the ABI, so let use increase the ABI number :) (This is the revert of the glibc-abi-compatibility-hack) --- apt-inst/makefile | 2 +- apt-pkg/init.h | 2 +- buildlib/library.mak | 14 +++++++------- buildlib/libversion.mak | 7 ------- debian/rules | 14 +++++++------- 5 files changed, 16 insertions(+), 23 deletions(-) diff --git a/apt-inst/makefile b/apt-inst/makefile index abc8c3fd9..785dc62ba 100644 --- a/apt-inst/makefile +++ b/apt-inst/makefile @@ -14,7 +14,7 @@ include ../buildlib/libversion.mak # The library name LIBRARY=apt-inst -MAJOR=1.1 +MAJOR=1.2 MINOR=0 SLIBS=$(PTHREADLIB) -lapt-pkg APT_DOMAIN:=libapt-inst$(MAJOR) diff --git a/apt-pkg/init.h b/apt-pkg/init.h index f0757f644..b3e4b147f 100644 --- a/apt-pkg/init.h +++ b/apt-pkg/init.h @@ -22,7 +22,7 @@ // Non-ABI-Breaks should only increase RELEASE number. // See also buildlib/libversion.mak #define APT_PKG_MAJOR 4 -#define APT_PKG_MINOR 8 +#define APT_PKG_MINOR 9 #define APT_PKG_RELEASE 0 extern const char *pkgVersion; diff --git a/buildlib/library.mak b/buildlib/library.mak index 2a4bb782a..029e87463 100644 --- a/buildlib/library.mak +++ b/buildlib/library.mak @@ -16,11 +16,11 @@ # See defaults.mak for information about LOCAL # Some local definitions -LOCAL := lib$(LIBRARY)$(LIBEXT).so.$(MAJOR).$(MINOR) +LOCAL := lib$(LIBRARY).so.$(MAJOR).$(MINOR) $(LOCAL)-OBJS := $(addprefix $(OBJ)/,$(addsuffix .opic,$(notdir $(basename $(SOURCE))))) $(LOCAL)-DEP := $(addprefix $(DEP)/,$(addsuffix .opic.d,$(notdir $(basename $(SOURCE))))) $(LOCAL)-HEADERS := $(addprefix $(INCLUDE)/,$(HEADERS)) -$(LOCAL)-SONAME := lib$(LIBRARY)$(LIBEXT).so.$(MAJOR) +$(LOCAL)-SONAME := lib$(LIBRARY).so.$(MAJOR) $(LOCAL)-SLIBS := $(SLIBS) $(LOCAL)-LIBRARY := $(LIBRARY) @@ -29,7 +29,7 @@ include $(PODOMAIN_H) # Install the command hooks headers: $($(LOCAL)-HEADERS) -library: $(LIB)/lib$(LIBRARY).so $(LIB)/lib$(LIBRARY)$(LIBEXT).so.$(MAJOR) +library: $(LIB)/lib$(LIBRARY).so $(LIB)/lib$(LIBRARY).so.$(MAJOR) clean: clean/$(LOCAL) veryclean: veryclean/$(LOCAL) @@ -44,14 +44,14 @@ veryclean/$(LOCAL): clean/$(LOCAL) -rm -f $($(@F)-HEADERS) $(LIB)/lib$($(@F)-LIBRARY)*.so* # Build rules for the two symlinks -.PHONY: $(LIB)/lib$(LIBRARY)$(LIBEXT).so.$(MAJOR) $(LIB)/lib$(LIBRARY).so -$(LIB)/lib$(LIBRARY)$(LIBEXT).so.$(MAJOR): $(LIB)/lib$(LIBRARY)$(LIBEXT).so.$(MAJOR).$(MINOR) +.PHONY: $(LIB)/lib$(LIBRARY).so.$(MAJOR) $(LIB)/lib$(LIBRARY).so +$(LIB)/lib$(LIBRARY).so.$(MAJOR): $(LIB)/lib$(LIBRARY).so.$(MAJOR).$(MINOR) ln -sf $( /dev/null echo Building shared library $@ $(CXX) $(CXXFLAGS) $(LDFLAGS) $(PICFLAGS) $(LFLAGS) $(LFLAGS_SO)\ diff --git a/buildlib/libversion.mak b/buildlib/libversion.mak index 26ca86ced..796c956e7 100644 --- a/buildlib/libversion.mak +++ b/buildlib/libversion.mak @@ -12,10 +12,3 @@ LIBAPTPKG_RELEASE=$(shell grep -E '^\#define APT_PKG_RELEASE' $(BASE)/apt-pkg/in # The versionnumber is extracted from apt-inst/makefile - see also there. LIBAPTINST_MAJOR=$(shell egrep '^MAJOR=' $(BASE)/apt-inst/makefile |cut -d '=' -f 2) LIBAPTINST_MINOR=$(shell egrep '^MINOR=' $(BASE)/apt-inst/makefile |cut -d '=' -f 2) - -# FIXME: In previous releases this lovely variable includes -# the detected libc and libdc++ version. As this is bogus we -# want to drop this, but this a ABI break. -# And we don't want to do this now. So we hardcode a value here, -# and drop it later on (hopefully as fast as possible). -LIBEXT=-libc6.9-6 diff --git a/debian/rules b/debian/rules index 37c96ef20..f179baa37 100755 --- a/debian/rules +++ b/debian/rules @@ -78,21 +78,21 @@ APT_UTILS=ftparchive sortpkgs extracttemplates include buildlib/libversion.mak # Determine which package we should provide in the control files -LIBAPTPKG_PROVIDE=libapt-pkg$(LIBEXT)-$(LIBAPTPKG_MAJOR) -LIBAPTINST_PROVIDE=libapt-inst$(LIBEXT)-$(LIBAPTINST_MAJOR) +LIBAPTPKG_PROVIDE=libapt-pkg-$(LIBAPTPKG_MAJOR) +LIBAPTINST_PROVIDE=libapt-inst-$(LIBAPTINST_MAJOR) debian/shlibs.local: apt-pkg/makefile # We have 3 shlibs.local files.. One for 'apt', one for 'apt-utils' and # one for the rest of the packages. This ensures that each package gets # the right overrides.. rm -rf $@ $@.apt $@.apt-utils - echo "libapt-pkg$(LIBEXT) $(LIBAPTPKG_MAJOR)" > $@.apt + echo "libapt-pkg $(LIBAPTPKG_MAJOR)" > $@.apt - echo "libapt-pkg$(LIBEXT) $(LIBAPTPKG_MAJOR) $(LIBAPTPKG_PROVIDE)" > $@.apt-utils - echo "libapt-inst$(LIBEXT) $(LIBAPTINST_MAJOR)" >> $@.apt-utils + echo "libapt-pkg $(LIBAPTPKG_MAJOR) $(LIBAPTPKG_PROVIDE)" > $@.apt-utils + echo "libapt-inst $(LIBAPTINST_MAJOR)" >> $@.apt-utils - echo "libapt-pkg$(LIBEXT) $(LIBAPTPKG_MAJOR) $(LIBAPTPKG_PROVIDE)" > $@ - echo "libapt-inst$(LIBEXT) $(LIBAPTINST_MAJOR) $(LIBAPTINST_PROVIDE)" >> $@ + echo "libapt-pkg $(LIBAPTPKG_MAJOR) $(LIBAPTPKG_PROVIDE)" > $@ + echo "libapt-inst $(LIBAPTINST_MAJOR) $(LIBAPTINST_PROVIDE)" >> $@ build: build/build-stamp build-doc: build/build-doc-stamp -- cgit v1.2.3-70-g09d2 From 503a2291469474f1af94e79931e3b00c24240cb0 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 01:59:50 +0100 Subject: * debian/rules: - remove creation of empty dir /usr/share/apt --- debian/changelog | 2 ++ debian/rules | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index f0ab5025b..856e356b7 100644 --- a/debian/changelog +++ b/debian/changelog @@ -32,6 +32,8 @@ apt (0.7.26) UNRELEASED; urgency=low - update with no changes to debian policy 3.8.4 * doc/apt_preferences.5.xml: - explicitly warn against careless use (Closes: #567669) + * debian/rules: + - remove creation of empty dir /usr/share/apt [ Ivan Masár ] * Slovak translation update. Closes: #568294 diff --git a/debian/rules b/debian/rules index f179baa37..ab384b123 100755 --- a/debian/rules +++ b/debian/rules @@ -190,7 +190,7 @@ apt: build build-doc debian/shlibs.local dh_testdir -p$@ dh_testroot -p$@ dh_clean -p$@ -k - dh_installdirs -p$@ /usr/share/bug/$@ /usr/share/$@ + dh_installdirs -p$@ # # apt install # -- cgit v1.2.3-70-g09d2 From 3c5a611808e7af5aec4c2ab12ce0bce79f74928d Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 18 Feb 2010 02:15:23 +0100 Subject: * doc/apt-cdrom.8.xml: - fix typo spotted by lintian: proc(c)eed --- debian/changelog | 2 ++ doc/apt-cdrom.8.xml | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 856e356b7..dbeed4502 100644 --- a/debian/changelog +++ b/debian/changelog @@ -34,6 +34,8 @@ apt (0.7.26) UNRELEASED; urgency=low - explicitly warn against careless use (Closes: #567669) * debian/rules: - remove creation of empty dir /usr/share/apt + * doc/apt-cdrom.8.xml: + - fix typo spotted by lintian: proc(c)eed [ Ivan Masár ] * Slovak translation update. Closes: #568294 diff --git a/doc/apt-cdrom.8.xml b/doc/apt-cdrom.8.xml index e57942610..423569fc1 100644 --- a/doc/apt-cdrom.8.xml +++ b/doc/apt-cdrom.8.xml @@ -65,7 +65,7 @@ add add is used to add a new disc to the source list. It will unmount the - CDROM device, prompt for a disk to be inserted and then procceed to + CDROM device, prompt for a disk to be inserted and then proceed to scan it and copy the index files. If the disc does not have a proper disk directory you will be prompted for a descriptive title. -- cgit v1.2.3-70-g09d2