From f77bf408f3f7ae650bac2a967f28610737acf1ab Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 5 Aug 2005 11:59:11 +0000 Subject: * merged with apt@packages.debian.org/apt--main--0 Patches applied: * apt@packages.debian.org/apt--main--0--patch-100 Use debian.org address in mainline * apt@packages.debian.org/apt--main--0--patch-101 Update pot file * apt@packages.debian.org/apt--main--0--patch-102 Open 0.6.40 * apt@packages.debian.org/apt--main--0--patch-103 Patch from Jordi Mallach to mark some additional strings for translation * apt@packages.debian.org/apt--main--0--patch-104 Updated Catalan translation from Jordi Mallach * apt@packages.debian.org/apt--main--0--patch-105 Merge from bubulle@debian.org--2005/apt--main--0 * apt@packages.debian.org/apt--main--0--patch-106 Restore lost changelog entries * apt@packages.debian.org/apt--main--0--patch-107 Merge michael.vogt@ubuntu.com--2005/apt--progress-reporting--0 * apt@packages.debian.org/apt--main--0--patch-108 Merge michael.vogt@ubuntu.com--2005/apt--progress-reporting--0 * bubulle@debian.org--2005/apt--main--0--patch-90 Merge with Matt * bubulle@debian.org--2005/apt--main--0--patch-91 Updated Slovak translation * bubulle@debian.org--2005/apt--main--0--patch-92 Add apt-key French man page * bubulle@debian.org--2005/apt--main--0--patch-93 Update Greek translations * bubulle@debian.org--2005/apt--main--0--patch-94 Merge with Matt * bubulle@debian.org--2005/apt--main--0--patch-95 Sync PO files with the POT file/French translation update * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--base-0 tag of apt@packages.debian.org/apt--main--0--patch-85 * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-1 * inital proof of concept code, understands what dpkg tells it already * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-2 * progress reporting works now * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-3 * added "APT::Status-Fd" variable * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-4 * do i18n now too * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-5 * define N_(x) if it is not defined already * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-6 * PackageManager::DoInstall(int status_fd) added (does not break the ABI) * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-7 * merged with apt--fixes--0 to make it build again * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-8 * added support for "error" and "conffile-prompt" messages from dpkg * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-9 merge with main * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-10 * use sizeof() for all snprintf() uses; fix a potential line break problem in the status reading code; changed the N_() to _() calls * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-11 * added APT::KeepFDs configuration list for file descriptors that apt should leave open (needed for various frontends like debconf, synaptic) * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-12 * fixed a API breakage * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-13 * doc added, should be releasable now * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-14 * merged with apt--main--0 * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-15 * more source comments, added Debug::DpkgPM debug code to inspect the dpkg<->apt communication, broke the abi (ok with matt) * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-16 * the progress reporting has it's own "Debug::pkgDPkgProgressReporting" debug variable now * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-17 * merged PackageOps and TranslatedPackageOps into a single Map with the new DpkgState struct * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-18 * clear the APT::Keep-Fds configuration when it's no longer needed * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-19 * rewrote the reading from dpkg so that it never blocks * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-20 * merged the two status arrays into one * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-21 * added support for download progress reporting too (for Kamion and base-config) * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-22 * ABI break; added Configuration::Clear(string List, {int,string} value) added (to remove a single Value from a list); test/conf_clear.cc added --- apt-pkg/acquire.cc | 21 ++++ apt-pkg/contrib/configuration.cc | 46 ++++++++- apt-pkg/contrib/configuration.h | 7 +- apt-pkg/contrib/fileutl.cc | 24 ++++- apt-pkg/contrib/fileutl.h | 2 +- apt-pkg/deb/dpkgpm.cc | 213 ++++++++++++++++++++++++++++++++++----- apt-pkg/deb/dpkgpm.h | 9 +- apt-pkg/packagemanager.cc | 4 +- apt-pkg/packagemanager.h | 2 +- 9 files changed, 291 insertions(+), 37 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/acquire.cc b/apt-pkg/acquire.cc index 70dce4f54..62209e65b 100644 --- a/apt-pkg/acquire.cc +++ b/apt-pkg/acquire.cc @@ -26,6 +26,7 @@ #include #include +#include #include #include @@ -803,6 +804,26 @@ bool pkgAcquireStatus::Pulse(pkgAcquire *Owner) Time = NewTime; } + int fd = _config->FindI("APT::Status-Fd",-1); + if(fd > 0) + { + ostringstream status; + + char msg[200]; + long i = CurrentItems < TotalItems ? CurrentItems + 1 : CurrentItems; + unsigned long ETA = + (unsigned long)((TotalBytes - CurrentBytes) / CurrentCPS); + + snprintf(msg,sizeof(msg), _("Downloading file %li of %li (%s remaining)"), i, TotalItems, TimeToStr(ETA).c_str()); + + // build the status str + status << "dlstatus:" << i + << ":" << (CurrentBytes/float(TotalBytes)*100.0) + << ":" << msg + << endl; + write(fd, status.str().c_str(), status.str().size()); + } + return true; } /*}}}*/ diff --git a/apt-pkg/contrib/configuration.cc b/apt-pkg/contrib/configuration.cc index 69f8d1dca..4b2c0fbb5 100644 --- a/apt-pkg/contrib/configuration.cc +++ b/apt-pkg/contrib/configuration.cc @@ -325,6 +325,47 @@ void Configuration::Set(const char *Name,int Value) char S[300]; snprintf(S,sizeof(S),"%i",Value); Itm->Value = S; +} + /*}}}*/ +// Configuration::Clear - Clear an single value from a list /*{{{*/ +// --------------------------------------------------------------------- +/* */ +void Configuration::Clear(string Name, int Value) +{ + char S[300]; + snprintf(S,sizeof(S),"%i",Value); + Clear(Name, S); +} + /*}}}*/ +// Configuration::Clear - Clear an single value from a list /*{{{*/ +// --------------------------------------------------------------------- +/* */ +void Configuration::Clear(string Name, string Value) +{ + Item *Top = Lookup(Name.c_str(),false); + if (Top == 0 || Top->Child == 0) + return; + + Item *Tmp, *Prev, *I; + Prev = I = Top->Child; + + while(I != NULL) + { + if(I->Value == Value) + { + Tmp = I; + // was first element, point parent to new first element + if(Top->Child == Tmp) + Top->Child = I->Next; + I = I->Next; + Prev->Next = I; + delete Tmp; + } else { + Prev = I; + I = I->Next; + } + } + } /*}}}*/ // Configuration::Clear - Clear an entire tree /*{{{*/ @@ -333,9 +374,10 @@ void Configuration::Set(const char *Name,int Value) void Configuration::Clear(string Name) { Item *Top = Lookup(Name.c_str(),false); - if (Top == 0) + if (Top == 0) { + cout << "config item: " << Name << " not found" << endl; return; - + } Top->Value = string(); Item *Stop = Top; Top = Top->Child; diff --git a/apt-pkg/contrib/configuration.h b/apt-pkg/contrib/configuration.h index 0ed8f59d3..789bc82cf 100644 --- a/apt-pkg/contrib/configuration.h +++ b/apt-pkg/contrib/configuration.h @@ -87,8 +87,13 @@ class Configuration bool Exists(const char *Name) const; bool ExistsAny(const char *Name) const; + // clear a whole tree void Clear(string Name); - + + // remove a certain value from a list (e.g. the list of "APT::Keep-Fds") + void Clear(string List, string Value); + void Clear(string List, int Value); + inline const Item *Tree(const char *Name) const {return Lookup(Name);}; inline void Dump() { Dump(std::clog); }; diff --git a/apt-pkg/contrib/fileutl.cc b/apt-pkg/contrib/fileutl.cc index 0ce0c9b9d..9fd71728e 100644 --- a/apt-pkg/contrib/fileutl.cc +++ b/apt-pkg/contrib/fileutl.cc @@ -20,6 +20,7 @@ #include #include #include +#include #include @@ -32,6 +33,7 @@ #include #include #include +#include /*}}}*/ using namespace std; @@ -306,7 +308,7 @@ bool WaitFd(int Fd,bool write,unsigned long timeout) /* This is used if you want to cleanse the environment for the forked child, it fixes up the important signals and nukes all of the fds, otherwise acts like normal fork. */ -pid_t ExecFork(int dontCloseThisFd) +pid_t ExecFork() { // Fork off the process pid_t Process = fork(); @@ -326,11 +328,27 @@ pid_t ExecFork(int dontCloseThisFd) signal(SIGWINCH,SIG_DFL); signal(SIGCONT,SIG_DFL); signal(SIGTSTP,SIG_DFL); - + + set KeepFDs; + Configuration::Item const *Opts = _config->Tree("APT::Keep-Fds"); + if (Opts != 0 && Opts->Child != 0) + { + Opts = Opts->Child; + for (; Opts != 0; Opts = Opts->Next) + { + if (Opts->Value.empty() == true) + continue; + int fd = atoi(Opts->Value.c_str()); + KeepFDs.insert(fd); + } + } + // Close all of our FDs - just in case for (int K = 3; K != 40; K++) - if(K != dontCloseThisFd) + { + if(KeepFDs.find(K) == KeepFDs.end()) fcntl(K,F_SETFD,FD_CLOEXEC); + } } return Process; diff --git a/apt-pkg/contrib/fileutl.h b/apt-pkg/contrib/fileutl.h index 4716e261e..041aa3309 100644 --- a/apt-pkg/contrib/fileutl.h +++ b/apt-pkg/contrib/fileutl.h @@ -87,7 +87,7 @@ string SafeGetCWD(); void SetCloseExec(int Fd,bool Close); void SetNonBlock(int Fd,bool Block); bool WaitFd(int Fd,bool write = false,unsigned long timeout = 0); -pid_t ExecFork(int dontCloseThisFd=-1); +pid_t ExecFork(); bool ExecWait(pid_t Pid,const char *Name,bool Reap = false); // File string manipulators diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index 61c48dcbb..2e85fc14e 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -25,7 +25,11 @@ #include #include #include -#include +#include +#include + +#include +#include /*}}}*/ using namespace std; @@ -325,8 +329,14 @@ bool pkgDPkgPM::RunScriptsWithPkgs(const char *Cnf) /*}}}*/ // DPkgPM::Go - Run the sequence /*{{{*/ // --------------------------------------------------------------------- -/* This globs the operations and calls dpkg */ -bool pkgDPkgPM::Go(int status_fd) +/* This globs the operations and calls dpkg + * + * If it is called with "OutStatusFd" set to a valid file descriptor + * apt will report the install progress over this fd. It maps the + * dpkg states a package goes through to human readable (and i10n-able) + * names and calculates a percentage for each step. +*/ +bool pkgDPkgPM::Go(int OutStatusFd) { unsigned int MaxArgs = _config->FindI("Dpkg::MaxArgs",8*1024); unsigned int MaxArgBytes = _config->FindI("Dpkg::MaxArgBytes",32*1024); @@ -336,7 +346,66 @@ bool pkgDPkgPM::Go(int status_fd) if (RunScriptsWithPkgs("DPkg::Pre-Install-Pkgs") == false) return false; + + // prepare the progress reporting + int Done = 0; + int Total = 0; + // map the dpkg states to the operations that are performed + // (this is sorted in the same way as Item::Ops) + static const struct DpkgState DpkgStatesOpMap[][5] = { + // Install operation + { + {"half-installed", _("Preparing %s")}, + {"unpacked", _("Unpacking %s") }, + NULL + }, + // Configure operation + { + {"unpacked",_("Preparing to configure %s") }, + {"half-configured", _("Configuring %s") }, + { "installed", _("Installed %s")}, + NULL + }, + // Remove operation + { + {"half-configured", _("Preparing for removal of %s")}, + {"half-installed", _("Removing %s")}, + {"config-files", _("Removed %s")}, + NULL + }, + // Purge operation + { + {"config-files", _("Preparing for remove with config %s")}, + {"not-installed", _("Removed with config %s")}, + NULL + }, + }; + + // the dpkg states that the pkg will run through, the string is + // the package, the vector contains the dpkg states that the package + // will go through + map > PackageOps; + // the dpkg states that are already done; the string is the package + // the int is the state that is already done (e.g. a package that is + // going to be install is already in state "half-installed") + map PackageOpsDone; + // init the PackageOps map, go over the list of packages that + // that will be [installed|configured|removed|purged] and add + // them to the PackageOps map (the dpkg states it goes through) + // and the PackageOpsTranslations (human readable strings) + for (vector::iterator I = List.begin(); I != List.end();I++) + { + string name = (*I).Pkg.Name(); + PackageOpsDone[name] = 0; + for(int i=0; (DpkgStatesOpMap[(*I).Op][i]).state != NULL; i++) + { + PackageOps[name].push_back(DpkgStatesOpMap[(*I).Op][i]); + Total++; + } + } + + // this loop is runs once per operation for (vector::iterator I = List.begin(); I != List.end();) { vector::iterator J = I; @@ -367,16 +436,15 @@ bool pkgDPkgPM::Go(int status_fd) } } - // if we got a status_fd argument, we pass it to apt char status_fd_buf[20]; - if(status_fd > 0) - { - Args[n++] = "--status-fd"; - Size += strlen(Args[n-1]); - snprintf(status_fd_buf,20,"%i",status_fd); - Args[n++] = status_fd_buf; - Size += strlen(Args[n-1]); - } + int fd[2]; + pipe(fd); + + Args[n++] = "--status-fd"; + Size += strlen(Args[n-1]); + snprintf(status_fd_buf,sizeof(status_fd_buf),"%i", fd[1]); + Args[n++] = status_fd_buf; + Size += strlen(Args[n-1]); switch (I->Op) { @@ -449,17 +517,17 @@ bool pkgDPkgPM::Go(int status_fd) it doesn't die but we do! So we must also ignore it */ sighandler_t old_SIGQUIT = signal(SIGQUIT,SIG_IGN); sighandler_t old_SIGINT = signal(SIGINT,SIG_IGN); - - // Fork dpkg + + // Fork dpkg pid_t Child; - if(status_fd > 0) - Child = ExecFork(status_fd); - else - Child = ExecFork(); + _config->Set("APT::Keep-Fds::",fd[1]); + Child = ExecFork(); // This is the child if (Child == 0) { + close(fd[0]); // close the read end of the pipe + if (chdir(_config->FindDir("DPkg::Run-Directory","/").c_str()) != 0) _exit(100); @@ -487,19 +555,112 @@ bool pkgDPkgPM::Go(int status_fd) _exit(100); } + // clear the Keep-Fd again + _config->Clear("APT::Keep-Fds",fd[1]); + // Wait for dpkg int Status = 0; - while (waitpid(Child,&Status,0) != Child) - { - if (errno == EINTR) + + // we read from dpkg here + int _dpkgin = fd[0]; + fcntl(_dpkgin, F_SETFL, O_NONBLOCK); + close(fd[1]); // close the write end of the pipe + + // the read buffers for the communication with dpkg + char line[1024] = {0,}; + char buf[2] = {0,0}; + + // the result of the waitpid call + int res; + + while ((res=waitpid(Child,&Status, WNOHANG)) != Child) { + if(res < 0) { + // FIXME: move this to a function or something, looks ugly here + // error handling, waitpid returned -1 + if (errno == EINTR) + continue; + RunScripts("DPkg::Post-Invoke"); + + // Restore sig int/quit + signal(SIGQUIT,old_SIGQUIT); + signal(SIGINT,old_SIGINT); + return _error->Errno("waitpid","Couldn't wait for subprocess"); + } + + // read a single char, make sure that the read can't block + // (otherwise we may leave zombies) + int len = read(_dpkgin, buf, 1); + + // nothing to read, wait a bit for more + if(len <= 0) + { + usleep(1000); continue; - RunScripts("DPkg::Post-Invoke"); + } + + // sanity check (should never happen) + if(strlen(line) >= sizeof(line)-10) + { + _error->Error("got a overlong line from dpkg: '%s'",line); + line[0]=0; + } + // append to line, check if we got a complete line + strcat(line, buf); + if(buf[0] != '\n') + continue; + + if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) + std::clog << "got from dpkg '" << line << "'" << std::endl; + + // pass "error" and "conffile-prompt" messages from dpkg verbatim + if((strncmp(line,"error",strlen("error")) == 0) || + (strncmp(line,"conffile-prompt",strlen("conffile-prompt")) == 0)) + { + write(OutStatusFd, line, strlen(line)); + line[0]=0; + continue; + } + // line contains the dpkg status info now. it has the form: + // 'status: : ' (see dpkg(1) for details) + char* list[5]; + TokSplitString(':', line, list, 5); + char *pkg = list[1]; + char *action = list[2]; + vector &states = PackageOps[pkg]; + const char *next_action = states[PackageOpsDone[pkg]].state; + const char *translation = states[PackageOpsDone[pkg]].str; + char s[200]; + snprintf(s, sizeof(s), translation, pkg); + // check if the package moved to the next dpkg state + if(next_action && (strcmp(action, next_action) == 0)) + { + // we moved from one dpkg state to a new one, report that + PackageOpsDone[pkg]++; + Done++; + ostringstream status; + // build the status str + status << "pmstatus:" << pkg + << ":" << (Done/float(Total)*100.0) + << ":" << s + << endl; + if(OutStatusFd > 0) + write(OutStatusFd, status.str().c_str(), status.str().size()); + if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) + { + std::clog << "send to fd: '" << status.str() + << "'" << std::endl; + + } + + } + if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) + std::clog << "(parsed from dpkg) pkg: " << pkg + << " action: " << action << endl; - // Restore sig int/quit - signal(SIGQUIT,old_SIGQUIT); - signal(SIGINT,old_SIGINT); - return _error->Errno("waitpid","Couldn't wait for subprocess"); + // reset the line buffer + line[0]=0; } + close(_dpkgin); // Restore sig int/quit signal(SIGQUIT,old_SIGQUIT); diff --git a/apt-pkg/deb/dpkgpm.h b/apt-pkg/deb/dpkgpm.h index b59b9dc93..2ff8a9ac7 100644 --- a/apt-pkg/deb/dpkgpm.h +++ b/apt-pkg/deb/dpkgpm.h @@ -23,6 +23,13 @@ using std::vector; class pkgDPkgPM : public pkgPackageManager { protected: + + // used for progress reporting + struct DpkgState + { + const char *state; // the dpkg state (e.g. "unpack") + const char *str; // the human readable translation of the state + }; struct Item { @@ -45,7 +52,7 @@ class pkgDPkgPM : public pkgPackageManager virtual bool Install(PkgIterator Pkg,string File); virtual bool Configure(PkgIterator Pkg); virtual bool Remove(PkgIterator Pkg,bool Purge = false); - virtual bool Go(int status_fd=-1); + virtual bool Go(int StatusFd=-1); virtual void Reset(); public: diff --git a/apt-pkg/packagemanager.cc b/apt-pkg/packagemanager.cc index a08ccd602..155408bb4 100644 --- a/apt-pkg/packagemanager.cc +++ b/apt-pkg/packagemanager.cc @@ -631,11 +631,11 @@ pkgPackageManager::OrderResult pkgPackageManager::OrderInstall() // --------------------------------------------------------------------- /* This uses the filenames in FileNames and the information in the DepCache to perform the installation of packages.*/ -pkgPackageManager::OrderResult pkgPackageManager::DoInstall() +pkgPackageManager::OrderResult pkgPackageManager::DoInstall(int status_fd) { OrderResult Res = OrderInstall(); if (Res != Failed) - if (Go() == false) + if (Go(status_fd) == false) return Failed; return Res; } diff --git a/apt-pkg/packagemanager.h b/apt-pkg/packagemanager.h index 43f2c4ace..f64637d03 100644 --- a/apt-pkg/packagemanager.h +++ b/apt-pkg/packagemanager.h @@ -76,7 +76,7 @@ class pkgPackageManager : protected pkgCache::Namespace // Main action members bool GetArchives(pkgAcquire *Owner,pkgSourceList *Sources, pkgRecords *Recs); - OrderResult DoInstall(); + OrderResult DoInstall(int statusFd=-1); bool FixMissing(); pkgPackageManager(pkgDepCache *Cache); -- cgit v1.2.3-70-g09d2 From dfa11ecc05d342af77f86120c123a3ea618544b6 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 5 Aug 2005 12:04:22 +0000 Subject: * merged the fixes from apt--progress-reporting Patches applied: * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-23 * remvoed a debug string * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-24 * soname changed, fixed a bug in the parsing code when dpkg send the same state more than once (at the end) * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-25 * merged with apt@packages.debian.org/apt--main--0, added changelog entry for the 0.6.40.1 upload * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-26 * fix a bug when out-of-order states are send from dpkg * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-27 * changelog update * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-28 * a real changelog entry now --- apt-pkg/contrib/configuration.cc | 5 ++--- apt-pkg/deb/dpkgpm.cc | 21 +++++++++++++-------- apt-pkg/init.h | 2 +- apt-pkg/makefile | 2 +- debian/changelog | 9 +++++++++ methods/makefile | 2 +- 6 files changed, 27 insertions(+), 14 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/contrib/configuration.cc b/apt-pkg/contrib/configuration.cc index 4b2c0fbb5..09e454be9 100644 --- a/apt-pkg/contrib/configuration.cc +++ b/apt-pkg/contrib/configuration.cc @@ -374,10 +374,9 @@ void Configuration::Clear(string Name, string Value) void Configuration::Clear(string Name) { Item *Top = Lookup(Name.c_str(),false); - if (Top == 0) { - cout << "config item: " << Name << " not found" << endl; + if (Top == 0) return; - } + Top->Value = string(); Item *Stop = Top; Top = Top->Child; diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index 2e85fc14e..79a8c312b 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -357,27 +357,27 @@ bool pkgDPkgPM::Go(int OutStatusFd) { {"half-installed", _("Preparing %s")}, {"unpacked", _("Unpacking %s") }, - NULL + {NULL, NULL} }, // Configure operation { {"unpacked",_("Preparing to configure %s") }, {"half-configured", _("Configuring %s") }, { "installed", _("Installed %s")}, - NULL + {NULL, NULL} }, // Remove operation { {"half-configured", _("Preparing for removal of %s")}, {"half-installed", _("Removing %s")}, {"config-files", _("Removed %s")}, - NULL + {NULL, NULL} }, // Purge operation { {"config-files", _("Preparing for remove with config %s")}, {"not-installed", _("Removed with config %s")}, - NULL + {NULL, NULL} }, }; @@ -627,13 +627,18 @@ bool pkgDPkgPM::Go(int OutStatusFd) char *pkg = list[1]; char *action = list[2]; vector &states = PackageOps[pkg]; - const char *next_action = states[PackageOpsDone[pkg]].state; - const char *translation = states[PackageOpsDone[pkg]].str; - char s[200]; - snprintf(s, sizeof(s), translation, pkg); + const char *next_action = NULL; + if(PackageOpsDone[pkg] < states.size()) + next_action = states[PackageOpsDone[pkg]].state; // check if the package moved to the next dpkg state if(next_action && (strcmp(action, next_action) == 0)) { + // only read the translation if there is actually a next + // action + const char *translation = states[PackageOpsDone[pkg]].str; + char s[200]; + snprintf(s, sizeof(s), translation, pkg); + // we moved from one dpkg state to a new one, report that PackageOpsDone[pkg]++; Done++; diff --git a/apt-pkg/init.h b/apt-pkg/init.h index 74ac3a7ca..e21351797 100644 --- a/apt-pkg/init.h +++ b/apt-pkg/init.h @@ -18,7 +18,7 @@ // See the makefile #define APT_PKG_MAJOR 3 -#define APT_PKG_MINOR 5 +#define APT_PKG_MINOR 10 #define APT_PKG_RELEASE 0 extern const char *pkgVersion; diff --git a/apt-pkg/makefile b/apt-pkg/makefile index 5f48f0f52..8de7d945e 100644 --- a/apt-pkg/makefile +++ b/apt-pkg/makefile @@ -13,7 +13,7 @@ include ../buildlib/defaults.mak # methods/makefile - FIXME LIBRARY=apt-pkg LIBEXT=$(GLIBC_VER)$(LIBSTDCPP_VER) -MAJOR=3.9 +MAJOR=3.10 MINOR=0 SLIBS=$(PTHREADLIB) $(INTLLIBS) APT_DOMAIN:=libapt-pkg$(MAJOR) diff --git a/debian/changelog b/debian/changelog index a01e1491b..7194dd328 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,12 @@ +apt (0.6.40.1) unstable; urgency=low + + * bugfix in the parsing code for the apt<->dpkg communication. apt + crashed when dpkg sends the same state more than once under certain + conditions + * 0.6.40 breaks the ABI but I accidentally didn't change the soname :/ + + -- + apt (0.6.40) unstable; urgency=low * Patch from Jordi Mallach to mark some additional strings for translation diff --git a/methods/makefile b/methods/makefile index 089300570..06fd2a6fc 100644 --- a/methods/makefile +++ b/methods/makefile @@ -7,7 +7,7 @@ include ../buildlib/defaults.mak BIN := $(BIN)/methods # FIXME.. -LIB_APT_PKG_MAJOR = 3.5 +LIB_APT_PKG_MAJOR = 3.10 APT_DOMAIN := libapt-pkg$(LIB_APT_PKG_MAJOR) # The file method -- cgit v1.2.3-70-g09d2 From 64995601ae9335dedd180d634940f1426598f7f0 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 9 Aug 2005 08:48:41 +0000 Subject: * merged with apt--main Patches applied: * apt@packages.debian.org/apt--main--0--patch-109 Merge michael.vogt@ubuntu.com--2005/apt--progress-reporting--0 * apt@packages.debian.org/apt--main--0--patch-110 Merge michael.vogt@ubuntu.com--2005/apt--progress-reporting--0 * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-29 * changelog finalized * michael.vogt@ubuntu.com--2005/apt--progress-reporting--0--patch-30 * propper (and sane) support for pmerror and pmconffile added --- README.progress-reporting | 13 ++++++++++ apt-pkg/deb/dpkgpm.cc | 60 +++++++++++++++++++++++++++++++++-------------- configure.in | 2 +- debian/apt-doc.docs | 1 + debian/changelog | 8 +++++++ 5 files changed, 65 insertions(+), 19 deletions(-) create mode 100644 debian/apt-doc.docs (limited to 'apt-pkg') diff --git a/README.progress-reporting b/README.progress-reporting index 7ae514929..73fbd8c08 100644 --- a/README.progress-reporting +++ b/README.progress-reporting @@ -34,6 +34,19 @@ pmstatus:3dchess:60:Preparing to configure 3dchess pmstatus:3dchess:80:Configuring 3dchess pmstatus:3dchess:100:Installed 3dchess +pmerror +------- +pmerror:deb:TotalPercentage:error string + +Example: +pmerror: /var/cache/apt/archives/krecipes_0.8.1-0ubuntu1_i386.deb : 75% : trying to overwrite `/usr/share/doc/kde/HTML/en/krecipes/krectip.png', which is also in package krecipes-data + + +pmconffile +---------- +pmconffile:conffile:percent:'current-conffile' 'new-conffile' useredited distedited + + dlstatus -------- diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index 79a8c312b..fe8fbca74 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -612,20 +612,49 @@ bool pkgDPkgPM::Go(int OutStatusFd) if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) std::clog << "got from dpkg '" << line << "'" << std::endl; - // pass "error" and "conffile-prompt" messages from dpkg verbatim - if((strncmp(line,"error",strlen("error")) == 0) || - (strncmp(line,"conffile-prompt",strlen("conffile-prompt")) == 0)) - { - write(OutStatusFd, line, strlen(line)); - line[0]=0; - continue; - } - // line contains the dpkg status info now. it has the form: - // 'status: : ' (see dpkg(1) for details) - char* list[5]; + // the status we output + ostringstream status; + + /* dpkg sends strings like this: + 'status: : ' + errors look like this: + 'status: /var/cache/apt/archives/krecipes_0.8.1-0ubuntu1_i386.deb : error : trying to overwrite `/usr/share/doc/kde/HTML/en/krecipes/krectip.png', which is also in package krecipes-data + and conffile-prompt like this + 'status: conffile-prompt: conffile : 'current-conffile' 'new-conffile' useredited distedited + + */ + char* list[4]; TokSplitString(':', line, list, 5); char *pkg = list[1]; - char *action = list[2]; + char *action = _strstrip(list[2]); + + if(strncmp(action,"error",strlen("error")) == 0) + { + status << "pmerror:" << list[1] + << ":" << (Done/float(Total)*100.0) + << ":" << list[3] + << endl; + if(OutStatusFd > 0) + write(OutStatusFd, status.str().c_str(), status.str().size()); + line[0]=0; + if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) + std::clog << "send: '" << status.str() << "'" << endl; + continue; + } + if(strncmp(action,"conffile",strlen("conffile")) == 0) + { + status << "pmconffile:" << list[1] + << ":" << (Done/float(Total)*100.0) + << ":" << list[3] + << endl; + if(OutStatusFd > 0) + write(OutStatusFd, status.str().c_str(), status.str().size()); + line[0]=0; + if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) + std::clog << "send: '" << status.str() << "'" << endl; + continue; + } + vector &states = PackageOps[pkg]; const char *next_action = NULL; if(PackageOpsDone[pkg] < states.size()) @@ -642,7 +671,6 @@ bool pkgDPkgPM::Go(int OutStatusFd) // we moved from one dpkg state to a new one, report that PackageOpsDone[pkg]++; Done++; - ostringstream status; // build the status str status << "pmstatus:" << pkg << ":" << (Done/float(Total)*100.0) @@ -651,11 +679,7 @@ bool pkgDPkgPM::Go(int OutStatusFd) if(OutStatusFd > 0) write(OutStatusFd, status.str().c_str(), status.str().size()); if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) - { - std::clog << "send to fd: '" << status.str() - << "'" << std::endl; - - } + std::clog << "send: '" << status.str() << "'" << endl; } if (_config->FindB("Debug::pkgDPkgProgressReporting",false) == true) diff --git a/configure.in b/configure.in index 7e3aba331..1ee7e168b 100644 --- a/configure.in +++ b/configure.in @@ -18,7 +18,7 @@ AC_CONFIG_AUX_DIR(buildlib) AC_CONFIG_HEADER(include/config.h:buildlib/config.h.in include/apti18n.h:buildlib/apti18n.h.in) dnl -- SET THIS TO THE RELEASE VERSION -- -AC_DEFINE_UNQUOTED(VERSION,"0.6.40") +AC_DEFINE_UNQUOTED(VERSION,"0.6.40.2") PACKAGE="apt" AC_DEFINE_UNQUOTED(PACKAGE,"$PACKAGE") AC_SUBST(PACKAGE) diff --git a/debian/apt-doc.docs b/debian/apt-doc.docs new file mode 100644 index 000000000..a7507f4e7 --- /dev/null +++ b/debian/apt-doc.docs @@ -0,0 +1 @@ +README.progress-reporting \ No newline at end of file diff --git a/debian/changelog b/debian/changelog index 8bad1ba96..35cba6007 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +apt (0.6.40.2) unstable; urgency=low + + * improved the support for "error" and "conffile" reporting from + dpkg, added the format to README.progress-reporting + * added README.progress-reporting to the apt-doc package + + -- + apt (0.6.40.1ubuntu1) breezy; urgency=low * Synchronize with Debian -- cgit v1.2.3-70-g09d2 From 5d4aff08accfd096d50d99a24df1437a2fa41c8d Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 23 Aug 2005 17:45:11 +0000 Subject: * merged the trust-cdrom branch Patches applied: * michael.vogt@ubuntu.com--2005/apt--trust-cdrom--0--base-0 tag of apt@packages.debian.org/apt--main--0--patch-79 * michael.vogt@ubuntu.com--2005/apt--trust-cdrom--0--patch-1 * implemented "TrustCDROM" mode * michael.vogt@ubuntu.com--2005/apt--trust-cdrom--0--patch-2 * added APT::Authentication::TrustCDROM to the configure-index --- apt-pkg/deb/debmetaindex.cc | 4 ++++ configure.in | 2 +- debian/changelog | 15 ++++++++------- doc/examples/configure-index | 5 +++++ 4 files changed, 18 insertions(+), 8 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/deb/debmetaindex.cc b/apt-pkg/deb/debmetaindex.cc index 526c8c0b2..85e5b16b3 100644 --- a/apt-pkg/deb/debmetaindex.cc +++ b/apt-pkg/deb/debmetaindex.cc @@ -165,6 +165,10 @@ bool debReleaseIndex::IsTrusted() const string VerifiedSigFile = _config->FindDir("Dir::State::lists") + URItoFileName(MetaIndexURI("Release")) + ".gpg"; + if(_config->FindB("APT::Authentication::TrustCDROM", false)) + if(URI.substr(0,strlen("cdrom:")) == "cdrom:") + return true; + if (FileExists(VerifiedSigFile)) return true; return false; diff --git a/configure.in b/configure.in index 1ee7e168b..6158933ee 100644 --- a/configure.in +++ b/configure.in @@ -18,7 +18,7 @@ AC_CONFIG_AUX_DIR(buildlib) AC_CONFIG_HEADER(include/config.h:buildlib/config.h.in include/apti18n.h:buildlib/apti18n.h.in) dnl -- SET THIS TO THE RELEASE VERSION -- -AC_DEFINE_UNQUOTED(VERSION,"0.6.40.2") +AC_DEFINE_UNQUOTED(VERSION,"0.6.40.1ubuntu2") PACKAGE="apt" AC_DEFINE_UNQUOTED(PACKAGE,"$PACKAGE") AC_SUBST(PACKAGE) diff --git a/debian/changelog b/debian/changelog index 61f5be622..a5f4f11ec 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -apt (0.6.40.2) unstable; urgency=low +apt (0.6.40.1ubuntu2) breezy; urgency=low * improved the support for "error" and "conffile" reporting from dpkg, added the format to README.progress-reporting @@ -11,14 +11,15 @@ apt (0.6.40.2) unstable; urgency=low * apt-pkg/acquire-item.cc: - fail early if a FailReason is TmpResolveFailure (avoids hangs during the install when no network is available) + * merged michael.vogt@ubuntu.com--2005/apt--trust-cdrom--0 - -- + -- Michael Vogt Tue, 23 Aug 2005 19:44:55 +0200 apt (0.6.40.1ubuntu1) breezy; urgency=low - * Synchronize with Debian + * Synchronize with Debian - -- Michael Vogt Fri, 5 Aug 2005 14:20:56 +0200 + -- Michael Vogt Fri, 5 Aug 2005 14:20:56 +0200 apt (0.6.40.1) unstable; urgency=low @@ -27,13 +28,13 @@ apt (0.6.40.1) unstable; urgency=low conditions * 0.6.40 breaks the ABI but I accidentally didn't change the soname :/ - -- Michael Vogt Fri, 5 Aug 2005 13:24:58 +0200 + -- Michael Vogt Fri, 5 Aug 2005 13:24:58 +0200 apt (0.6.40ubuntu1) breezy; urgency=low - * Synchronize with Debian + * Synchronize with Debian - -- Matt Zimmerman Thu, 4 Aug 2005 15:53:22 -0700 + -- Matt Zimmerman Thu, 4 Aug 2005 15:53:22 -0700 apt (0.6.40) unstable; urgency=low diff --git a/doc/examples/configure-index b/doc/examples/configure-index index dee0c06ff..a93b74349 100644 --- a/doc/examples/configure-index +++ b/doc/examples/configure-index @@ -72,6 +72,11 @@ APT NoAct "false"; }; + Authentication + { + TrustCDROM "false"; // consider the CDROM always trusted + }; + GPGV { TrustedKeyring "/etc/apt/trusted.gpg"; -- cgit v1.2.3-70-g09d2 From 7a6058744badb38d2ccac0158d6ed1359cfb0239 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 8 Dec 2005 17:29:42 +0000 Subject: * merged with the current debian version Patches applied: * bubulle@debian.org--2005/apt--main--0--patch-132 Completed Simplified Chinese translation * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-94 * pkgDirStream has (slightly) better extract support now * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-95 * merge fix for #339533 * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-96 * merged with bubulle * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-97 * some more debug output * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-98 * ABI change: merged more flexible pkgAcquireFile code * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-99 * merged http download limit for apt (#146877) * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-100 * applied parts of the string speedup patch from debian #319377 (ABI change) * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-101 * fix for #340448 --- apt-pkg/acquire-item.cc | 15 +++++++------ apt-pkg/acquire-item.h | 5 +++-- apt-pkg/algorithms.h | 3 ++- apt-pkg/cacheiterators.h | 4 +++- apt-pkg/cdrom.cc | 3 +++ apt-pkg/deb/debsystem.cc | 7 +++++- cmdline/apt-get.cc | 1 + debian/apt.manpages | 1 + debian/rules | 1 + doc/apt-key.8.xml | 47 +++++++++++++++++++++++++++++++++++++---- doc/apt.conf.5.xml | 2 +- doc/fr/apt-config.fr.8.xml | 4 ++-- doc/fr/apt-key.fr.8.xml | 44 +++++++++++++++++++++++++++++++++----- doc/fr/apt_preferences.fr.5.xml | 4 ++-- doc/fr/makefile | 12 +++++++++-- doc/makefile | 3 ++- 16 files changed, 127 insertions(+), 29 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc index 09f25c0dd..88c25de43 100644 --- a/apt-pkg/acquire-item.cc +++ b/apt-pkg/acquire-item.cc @@ -142,20 +142,21 @@ pkgAcqIndex::pkgAcqIndex(pkgAcquire *Owner, { Decompression = false; Erase = false; - + DestFile = _config->FindDir("Dir::State::lists") + "partial/"; DestFile += URItoFileName(URI); if(comprExt.empty()) { - // autoselect - if(FileExists("/usr/bin/bzip2")) - Desc.URI = URI + ".bz2"; - else - Desc.URI = URI + ".gz"; + // autoselect the compression method + if(FileExists("/usr/bin/bzip2")) + CompressionExtension = ".bz2"; + else + CompressionExtension = ".gz"; } else { - Desc.URI = URI + comprExt; + CompressionExtension = comprExt; } + Desc.URI = URI + CompressionExtension; Desc.Description = URIDesc; Desc.Owner = this; diff --git a/apt-pkg/acquire-item.h b/apt-pkg/acquire-item.h index 9e7198d8d..c34b5ef69 100644 --- a/apt-pkg/acquire-item.h +++ b/apt-pkg/acquire-item.h @@ -92,7 +92,8 @@ class pkgAcqIndex : public pkgAcquire::Item pkgAcquire::ItemDesc Desc; string RealURI; string ExpectedMD5; - + string CompressionExtension; + public: // Specialized action members @@ -100,7 +101,7 @@ class pkgAcqIndex : public pkgAcquire::Item virtual void Done(string Message,unsigned long Size,string Md5Hash, pkgAcquire::MethodConfig *Cnf); virtual string Custom600Headers(); - virtual string DescURI() {return RealURI + ".gz";}; + virtual string DescURI() {return RealURI + CompressionExtension;}; pkgAcqIndex(pkgAcquire *Owner,string URI,string URIDesc, string ShortDesct, string ExpectedMD5, string compressExt=""); diff --git a/apt-pkg/algorithms.h b/apt-pkg/algorithms.h index 174a7f58d..b95218061 100644 --- a/apt-pkg/algorithms.h +++ b/apt-pkg/algorithms.h @@ -118,7 +118,8 @@ class pkgProblemResolver // Try to resolve problems only by using keep bool ResolveByKeep(); - + + // Install all protected packages void InstallProtect(); pkgProblemResolver(pkgDepCache *Cache); diff --git a/apt-pkg/cacheiterators.h b/apt-pkg/cacheiterators.h index 7c6f43351..2b326bd65 100644 --- a/apt-pkg/cacheiterators.h +++ b/apt-pkg/cacheiterators.h @@ -222,7 +222,7 @@ class pkgCache::PrvIterator void operator ++(int) {if (Prv != Owner->ProvideP) Prv = Owner->ProvideP + (Type == PrvVer?Prv->NextPkgProv:Prv->NextProvides);}; inline void operator ++() {operator ++(0);}; - inline bool end() const {return Prv == Owner->ProvideP?true:false;}; + inline bool end() const {return Owner == 0 || Prv == Owner->ProvideP?true:false;}; // Comparison inline bool operator ==(const PrvIterator &B) const {return Prv == B.Prv;}; @@ -244,6 +244,8 @@ class pkgCache::PrvIterator inline PkgIterator OwnerPkg() {return PkgIterator(*Owner,Owner->PkgP + Owner->VerP[Prv->Version].ParentPkg);}; inline unsigned long Index() const {return Prv - Owner->ProvideP;}; + inline PrvIterator() : Prv(0), Type(PrvVer), Owner(0) {}; + inline PrvIterator(pkgCache &Owner,Provides *Trg,Version *) : Prv(Trg), Type(PrvVer), Owner(&Owner) { diff --git a/apt-pkg/cdrom.cc b/apt-pkg/cdrom.cc index d7ef844a2..ce1beb39b 100644 --- a/apt-pkg/cdrom.cc +++ b/apt-pkg/cdrom.cc @@ -422,6 +422,9 @@ bool pkgCdrom::WriteSourceList(string Name,vector &List,bool Source) { F.getline(Buffer,sizeof(Buffer)); CurLine++; + if (F.fail() && !F.eof()) + return _error->Error(_("Line %u too long in source list %s."), + CurLine,File.c_str()); _strtabexpand(Buffer,sizeof(Buffer)); _strstrip(Buffer); diff --git a/apt-pkg/deb/debsystem.cc b/apt-pkg/deb/debsystem.cc index 0b3a4f742..2d805ea6f 100644 --- a/apt-pkg/deb/debsystem.cc +++ b/apt-pkg/deb/debsystem.cc @@ -164,7 +164,12 @@ bool debSystem::Initialize(Configuration &Cnf) Cnf.CndSet("Dir::State::userstatus","status.user"); // Defunct Cnf.CndSet("Dir::State::status","/var/lib/dpkg/status"); Cnf.CndSet("Dir::Bin::dpkg","/usr/bin/dpkg"); - + + if (StatusFile) { + delete StatusFile; + StatusFile = 0; + } + return true; } /*}}}*/ diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc index 356d36b48..48b21a31f 100644 --- a/cmdline/apt-get.cc +++ b/cmdline/apt-get.cc @@ -2040,6 +2040,7 @@ bool DoSource(CommandLine &CmdL) if (system(S) != 0) { fprintf(stderr,_("Unpack command '%s' failed.\n"),S); + fprintf(stderr,_("Check if the 'dpkg-dev' package is installed.\n")); _exit(1); } } diff --git a/debian/apt.manpages b/debian/apt.manpages index e621e1c49..b52ea3d3d 100644 --- a/debian/apt.manpages +++ b/debian/apt.manpages @@ -3,6 +3,7 @@ doc/apt-cdrom.8 doc/apt-config.8 doc/apt-get.8 doc/apt-key.8 +doc/apt-secure.8 doc/apt.8 doc/apt.conf.5 doc/apt_preferences.5 diff --git a/debian/rules b/debian/rules index 1e339aade..6c0a24fd9 100755 --- a/debian/rules +++ b/debian/rules @@ -274,6 +274,7 @@ apt-utils: build debian/shlibs.local cp $(addprefix $(BLD)/bin/apt-,$(APT_UTILS)) debian/$@/usr/bin/ dh_installdocs -p$@ + dh_installexamples -p$@ # Install the man pages.. dh_installman -p$@ diff --git a/doc/apt-key.8.xml b/doc/apt-key.8.xml index 62686618a..eac61307d 100644 --- a/doc/apt-key.8.xml +++ b/doc/apt-key.8.xml @@ -68,17 +68,56 @@ List trusted keys. + + + update + + + + Update the local keyring with the keyring of Debian archive + keys and removes from the keyring the archive keys which are no + longer valid. + + + + + + + + + Files + + /etc/apt/trusted.gpg + Keyring of local trusted keys, new keys will be added here. + + + /etc/apt/trustdb.gpg + Local trust database of archive keys. + + + /usr/share/keyrings/debian-archive-keyring.gpg + Keyring of Debian archive trusted keys. + + + /usr/share/keyrings/debian-archive-removed-keys.gpg + Keyring of Debian archive removed trusted keys. + + + + + - - - - +See Also + +&apt-get;, &apt-secure; + + &manbugs; &manauthor; diff --git a/doc/apt.conf.5.xml b/doc/apt.conf.5.xml index 69e212243..43f33681f 100644 --- a/doc/apt.conf.5.xml +++ b/doc/apt.conf.5.xml @@ -284,7 +284,7 @@ DPkg::Pre-Install-Pkgs {"/usr/sbin/dpkg-preconfigure --apt";}; sourcelist gives the location of the sourcelist and main is the default configuration file (setting has no effect, unless it is done from the config file specified by - APT_CONFIG. + APT_CONFIG). The Dir::Parts setting reads in all the config fragments in lexical order from the directory specified. After this is done then the diff --git a/doc/fr/apt-config.fr.8.xml b/doc/fr/apt-config.fr.8.xml index ac9143066..043c58686 100644 --- a/doc/fr/apt-config.fr.8.xml +++ b/doc/fr/apt-config.fr.8.xml @@ -57,7 +57,7 @@ des commandes suivantes doit Le terme shell est utilisé pour accéder aux informations de configuration depuis un script shell. Deux arguments doivent lui être donnés ; le -premier est une variable de shell et le second une valeur de configuration à +premier est une variable du shell et le second une valeur de configuration à demander. La sortie standard consiste en une liste de commandes d'assignation de shell pour chaque valeur présente. Dans un script shell, cette commande devrait @@ -69,7 +69,7 @@ RES=`apt-config shell OPTS MyApp::Options` eval $RES -La variable d'environnement de shell $OPTS sera définie par la valeur de +La variable d'environnement du shell $OPTS sera définie par la valeur de MyApp::Options ou, par défaut, la valeur -f. diff --git a/doc/fr/apt-key.fr.8.xml b/doc/fr/apt-key.fr.8.xml index a31fb7855..29ba237e2 100644 --- a/doc/fr/apt-key.fr.8.xml +++ b/doc/fr/apt-key.fr.8.xml @@ -34,7 +34,7 @@ apt-key gère les clés dont se sert apt pour authentifier les paquets. Les paquets authentifiés par ces clés seront -réputés +réputés fiables. @@ -73,13 +73,47 @@ Afficher la liste des cl + + update + + +Mettre à jour le trousseau de clés local avec le trousseau de clés de l'archive +Debian et supprimer les clés qui sont périmées. + + + + - - - - + Fichiers + + /etc/apt/trusted.gpg +Trousseau de clés locales fiables, les nouvelles clés sont ajoutées ici. + + + + /etc/apt/trustdb.gpg + Base de données locale fiable des clés de l'archive. + + + /usr/share/keyrings/debian-archive-keyring.gpg + Trousseau des clés fiables de l'archive Debian. + + + /usr/share/keyrings/debian-archive-removed-keys.gpg + + >Trousseau des clés fiables supprimées de l'archive Debian. + + + + + +Voir aussi + +&apt-get;, &apt-secure; + + &manbugs; &manauthor; diff --git a/doc/fr/apt_preferences.fr.5.xml b/doc/fr/apt_preferences.fr.5.xml index c6b2c8794..6e1d2043e 100644 --- a/doc/fr/apt_preferences.fr.5.xml +++ b/doc/fr/apt_preferences.fr.5.xml @@ -7,7 +7,7 @@ ]> - + &apt-author.team; @@ -208,7 +208,7 @@ d' Package: * Pin: release a=unstable -Pin-Priority: 50 +Pin-Priority: 500 L'entrée suivante affecte une priorité haute à toutes les versions diff --git a/doc/fr/makefile b/doc/fr/makefile index c0e7fa7ed..596de7b09 100644 --- a/doc/fr/makefile +++ b/doc/fr/makefile @@ -5,11 +5,16 @@ SUBDIR=doc/fr # Bring in the default rules include ../../buildlib/defaults.mak +# Do not use XMLTO, build the manpages directly with XSLTPROC +XSLTPROC=/usr/bin/xsltproc +STYLESHEET=/usr/share/xml/docbook/stylesheet/nwalsh/manpages/docbook.xsl + + # Man pages SOURCE = apt-cache.fr.8 apt-get.fr.8 apt-cdrom.fr.8 apt.conf.fr.5 \ sources.list.fr.5 apt-config.fr.8 apt-sortpkgs.fr.1 \ apt-ftparchive.fr.1 apt_preferences.fr.5 apt-extracttemplates.fr.1 \ - apt-key.fr.8 + apt-key.fr.8 apt-secure.fr.8 INCLUDES = apt.ent.fr @@ -17,7 +22,7 @@ doc: $(SOURCE) $(SOURCE) :: % : %.xml $(INCLUDES) echo Creating man page $@ - $(XMLTO) man $< + $(XSLTPROC) -o $@ $(STYLESHEET) $< apt-cache.fr.8:: apt-cache.8 cp $< $@ @@ -52,4 +57,7 @@ apt-extracttemplates.fr.1:: apt-extracttemplates.1 apt-key.fr.8:: apt-key.8 cp $< $@ +apt-secure.fr.8:: apt-secure.8 + cp $< $@ + diff --git a/doc/makefile b/doc/makefile index f34b3f6e5..31ee061fb 100644 --- a/doc/makefile +++ b/doc/makefile @@ -14,7 +14,8 @@ include $(DEBIANDOC_H) # XML man pages SOURCE = apt-cache.8 apt-get.8 apt-cdrom.8 apt.conf.5 sources.list.5 \ apt-config.8 apt_preferences.5 \ - apt-sortpkgs.1 apt-ftparchive.1 apt-extracttemplates.1 apt-key.8 + apt-sortpkgs.1 apt-ftparchive.1 apt-extracttemplates.1 \ + apt-key.8 apt-secure.8 INCLUDES = apt.ent include $(XML_MANPAGE_H) -- cgit v1.2.3-70-g09d2 From 47eb38f452c7477aab782dce56e85a0a85e22764 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 21 Feb 2006 12:23:22 +0000 Subject: * handle network failures more gracefully (default apt sources spec) apt-pkg/acquire-item.cc: - on network failures (Timeout,ResolveFailure,ConnectionRefused) move the old (known good) sigfile back and don't touch the indexfiles cmdline/apt-get.cc: - don't fail on apt-get update problems but issue a warning instead --- apt-pkg/acquire-item.cc | 10 +++++++--- cmdline/apt-get.cc | 2 +- configure.in | 2 +- debian/changelog | 23 +++++++++++++++++++++-- 4 files changed, 30 insertions(+), 7 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc index 1fa929aad..dee00c63e 100644 --- a/apt-pkg/acquire-item.cc +++ b/apt-pkg/acquire-item.cc @@ -321,8 +321,9 @@ pkgAcqMetaSig::pkgAcqMetaSig(pkgAcquire *Owner, DestFile = _config->FindDir("Dir::State::lists") + "partial/"; DestFile += URItoFileName(URI); - // remove any partial downloaded sig-file. it may confuse proxies - // and is too small to warrant a partial download anyway + // remove any partial downloaded sig-file in partial/. + // it may confuse proxies and is too small to warrant a + // partial download anyway unlink(DestFile.c_str()); // Create the item @@ -389,17 +390,20 @@ void pkgAcqMetaSig::Done(string Message,unsigned long Size,string MD5, /*}}}*/ void pkgAcqMetaSig::Failed(string Message,pkgAcquire::MethodConfig *Cnf) { + string Final = _config->FindDir("Dir::State::lists") + URItoFileName(RealURI); // if we get a network error we fail gracefully if(LookupTag(Message,"FailReason") == "Timeout" || LookupTag(Message,"FailReason") == "TmpResolveFailure" || LookupTag(Message,"FailReason") == "ConnectionRefused") { Item::Failed(Message,Cnf); + // move the sigfile back on network failures (and re-authenticated?) + if(FileExists(DestFile)) + Rename(DestFile,Final); return; } // Delete any existing sigfile when the acquire failed - string Final = _config->FindDir("Dir::State::lists") + URItoFileName(RealURI); unlink(Final.c_str()); // queue a pkgAcqMetaIndex with no sigfile diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc index 92051f8ff..99a51c9b8 100644 --- a/cmdline/apt-get.cc +++ b/cmdline/apt-get.cc @@ -1381,7 +1381,7 @@ bool DoUpdate(CommandLine &CmdL) return false; if (Failed == true) - return _error->Warning(_("Some index files failed to download, they have been ignored, or old ones used instead.")); + _error->Warning(_("Some index files failed to download, they have been ignored, or old ones used instead.")); return true; } diff --git a/configure.in b/configure.in index 2e92bd0a9..6cd00f9de 100644 --- a/configure.in +++ b/configure.in @@ -18,7 +18,7 @@ AC_CONFIG_AUX_DIR(buildlib) AC_CONFIG_HEADER(include/config.h:buildlib/config.h.in include/apti18n.h:buildlib/apti18n.h.in) dnl -- SET THIS TO THE RELEASE VERSION -- -AC_DEFINE_UNQUOTED(VERSION,"0.6.43.3ubuntu1") +AC_DEFINE_UNQUOTED(VERSION,"0.6.43.2ubuntu1") PACKAGE="apt" AC_DEFINE_UNQUOTED(PACKAGE,"$PACKAGE") AC_SUBST(PACKAGE) diff --git a/debian/changelog b/debian/changelog index 3490fba7c..8c53d7a5c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -apt (0.6.43.3) unstable; urgency=low +apt (0.6.43.2ubuntu1) dapper; urgency=low * Merge bubulle@debian.org--2005/apt--main--0 up to patch-182: * ca.po: Completed to 512t. Closes: #351592 @@ -26,8 +26,9 @@ apt (0.6.43.3) unstable; urgency=low * cmdline/apt-get.cc: only run the list-cleaner if a update was successfull * apt-get update errors are only warnings nowdays + * be more careful with the signature file on network failures - -- + -- Michael Vogt Mon, 20 Feb 2006 22:27:48 +0100 apt (0.6.43.2) unstable; urgency=low @@ -54,6 +55,24 @@ apt (0.6.43.2) unstable; urgency=low -- Michael Vogt Thu, 19 Jan 2006 00:06:33 +0100 +apt (0.6.43.1ubuntu1) dapper; urgency=low + + * Merge bubulle@debian.org--2005/apt--main--0 up to patch-159: + - en_GB.po, de.po: fix spaces errors in "Ign " translations + Closes: #347258 + - makefile: make update-po a pre-requisite of clean target so + that POT and PO files are always up-to-date + - sv.po: Completed to 511t. Closes: #346450 + - sk.po: Completed to 511t. Closes: #346369 + - fr.po: Completed to 511t + - *.po: Updated from sources (511 strings) + * add patch to fix http download corruption problem (thanks to + Petr Vandrovec, closes: #280844, #290694) + * added APT::Periodic::Unattended-Upgrade (requires the package + "unattended-upgrade") + + -- Michael Vogt Tue, 10 Jan 2006 17:09:31 +0100 + apt (0.6.43.1) unstable; urgency=low * Merge bubulle@debian.org--2005/apt--main--0 up to patch-148: -- cgit v1.2.3-70-g09d2 From a791a45008c6fb5d85061da5f7c90b9ef7d28f81 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 21 Feb 2006 13:04:57 +0000 Subject: * don't print a "can't stat " message for missing index files (DefaultSourcesSpec) --- apt-pkg/pkgcachegen.cc | 2 ++ 1 file changed, 2 insertions(+) (limited to 'apt-pkg') diff --git a/apt-pkg/pkgcachegen.cc b/apt-pkg/pkgcachegen.cc index de854bee5..de5ba5ea6 100644 --- a/apt-pkg/pkgcachegen.cc +++ b/apt-pkg/pkgcachegen.cc @@ -571,8 +571,10 @@ static bool CheckValidity(const string &CacheFile, FileIterator Start, if ((*Start)->Exists() == false) { +#if 0 // mvo: we no longer give a message here (Default Sources spec) _error->WarningE("stat",_("Couldn't stat source package list %s"), (*Start)->Describe().c_str()); +#endif continue; } -- cgit v1.2.3-70-g09d2 From 7e5f33eb8a0f224b938f17236f684ba5cadb9c7f Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 21 Feb 2006 16:39:25 +0000 Subject: * more work for the DefaultAptSources spec apt-pkg/acquire-item.h: - add new pkgAcquire::Item::StatTransientNetworkError status apt-pkg/acquire-item.cc: - if we get a StatTransientNetworkError use old sigfile and indexfiles apt-pkg/acquire-worker.cc: - set StatTransientNetworkError on "Timeout", "TmpResolveFailure", "ConnectionRefused" cmdline/apt-get.cc: - handle a StatTransientNetworkError different than a normal error (warning instead of error) --- apt-pkg/acquire-item.cc | 10 ++-- apt-pkg/acquire-item.h | 3 +- apt-pkg/acquire-worker.cc | 7 +++ cmdline/apt-get.cc | 19 ++++-- po/apt-all.pot | 144 +++++++++++++++++++++++----------------------- 5 files changed, 102 insertions(+), 81 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc index dee00c63e..da9becc44 100644 --- a/apt-pkg/acquire-item.cc +++ b/apt-pkg/acquire-item.cc @@ -75,7 +75,7 @@ void pkgAcquire::Item::Failed(string Message,pkgAcquire::MethodConfig *Cnf) Dequeue(); return; } - + Status = StatError; Dequeue(); } @@ -393,13 +393,15 @@ void pkgAcqMetaSig::Failed(string Message,pkgAcquire::MethodConfig *Cnf) string Final = _config->FindDir("Dir::State::lists") + URItoFileName(RealURI); // if we get a network error we fail gracefully - if(LookupTag(Message,"FailReason") == "Timeout" || - LookupTag(Message,"FailReason") == "TmpResolveFailure" || - LookupTag(Message,"FailReason") == "ConnectionRefused") { + if(Status == StatTransientNetworkError) + { Item::Failed(Message,Cnf); // move the sigfile back on network failures (and re-authenticated?) if(FileExists(DestFile)) Rename(DestFile,Final); + + // set the status back to , Item::Failed likes to reset it + Status = pkgAcquire::Item::StatTransientNetworkError; return; } diff --git a/apt-pkg/acquire-item.h b/apt-pkg/acquire-item.h index da1bea801..1c83f8d2e 100644 --- a/apt-pkg/acquire-item.h +++ b/apt-pkg/acquire-item.h @@ -48,7 +48,8 @@ class pkgAcquire::Item public: // State of the item - enum {StatIdle, StatFetching, StatDone, StatError, StatAuthError} Status; + enum {StatIdle, StatFetching, StatDone, StatError, + StatAuthError, StatTransientNetworkError} Status; string ErrorText; unsigned long FileSize; unsigned long PartialSize; diff --git a/apt-pkg/acquire-worker.cc b/apt-pkg/acquire-worker.cc index d06024178..8ab67778b 100644 --- a/apt-pkg/acquire-worker.cc +++ b/apt-pkg/acquire-worker.cc @@ -307,6 +307,13 @@ bool pkgAcquire::Worker::RunMessages() pkgAcquire::Item *Owner = Itm->Owner; pkgAcquire::ItemDesc Desc = *Itm; OwnerQ->ItemDone(Itm); + + // set some status + if(LookupTag(Message,"FailReason") == "Timeout" || + LookupTag(Message,"FailReason") == "TmpResolveFailure" || + LookupTag(Message,"FailReason") == "ConnectionRefused") + Owner->Status = pkgAcquire::Item::StatTransientNetworkError; + Owner->Failed(Message,Config); ItemDone(); diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc index 99a51c9b8..e98d4fec5 100644 --- a/cmdline/apt-get.cc +++ b/cmdline/apt-get.cc @@ -1355,20 +1355,29 @@ bool DoUpdate(CommandLine &CmdL) return false; bool Failed = false; + bool TransientNetworkFailure = false; for (pkgAcquire::ItemIterator I = Fetcher.ItemsBegin(); I != Fetcher.ItemsEnd(); I++) { if ((*I)->Status == pkgAcquire::Item::StatDone) continue; (*I)->Finished(); - + fprintf(stderr,_("Failed to fetch %s %s\n"),(*I)->DescURI().c_str(), (*I)->ErrorText.c_str()); + + if ((*I)->Status == pkgAcquire::Item::StatTransientNetworkError) + { + TransientNetworkFailure = true; + continue; + } + Failed = true; } // Clean out any old list files - if (!Failed && _config->FindB("APT::Get::List-Cleanup",true) == true) + if (!TransientNetworkFailure && + _config->FindB("APT::Get::List-Cleanup",true) == true) { if (Fetcher.Clean(_config->FindDir("Dir::State::lists")) == false || Fetcher.Clean(_config->FindDir("Dir::State::lists") + "partial/") == false) @@ -1380,9 +1389,11 @@ bool DoUpdate(CommandLine &CmdL) if (Cache.BuildCaches() == false) return false; - if (Failed == true) + if (TransientNetworkFailure == true) _error->Warning(_("Some index files failed to download, they have been ignored, or old ones used instead.")); - + else if (Failed == true) + return _error->Error(_("Some index files failed to download, they have been ignored, or old ones used instead.")); + return true; } /*}}}*/ diff --git a/po/apt-all.pot b/po/apt-all.pot index 23de34b5c..c1edb1c79 100644 --- a/po/apt-all.pot +++ b/po/apt-all.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2006-01-20 14:06+0100\n" +"POT-Creation-Date: 2006-02-21 15:07+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -146,14 +146,14 @@ msgstr "" msgid " %4i %s\n" msgstr "" -#: cmdline/apt-cache.cc:1651 cmdline/apt-cdrom.cc:138 cmdline/apt-config.cc:70 +#: cmdline/apt-cache.cc:1652 cmdline/apt-cdrom.cc:138 cmdline/apt-config.cc:70 #: cmdline/apt-extracttemplates.cc:225 ftparchive/apt-ftparchive.cc:550 -#: cmdline/apt-get.cc:2378 cmdline/apt-sortpkgs.cc:144 +#: cmdline/apt-get.cc:2380 cmdline/apt-sortpkgs.cc:144 #, c-format msgid "%s %s for %s %s compiled on %s %s\n" msgstr "" -#: cmdline/apt-cache.cc:1658 +#: cmdline/apt-cache.cc:1659 msgid "" "Usage: apt-cache [options] command\n" " apt-cache [options] add file1 [file2 ...]\n" @@ -243,7 +243,7 @@ msgid "" " -o=? Set an arbitrary configuration option, eg -o dir::cache=/tmp\n" msgstr "" -#: cmdline/apt-extracttemplates.cc:267 apt-pkg/pkgcachegen.cc:710 +#: cmdline/apt-extracttemplates.cc:267 apt-pkg/pkgcachegen.cc:712 #, c-format msgid "Unable to write to %s" msgstr "" @@ -535,7 +535,7 @@ msgstr "" msgid "Y" msgstr "" -#: cmdline/apt-get.cc:142 cmdline/apt-get.cc:1515 +#: cmdline/apt-get.cc:142 cmdline/apt-get.cc:1517 #, c-format msgid "Regex compilation error - %s" msgstr "" @@ -694,11 +694,11 @@ msgstr "" msgid "Internal error, Ordering didn't finish" msgstr "" -#: cmdline/apt-get.cc:791 cmdline/apt-get.cc:1809 cmdline/apt-get.cc:1842 +#: cmdline/apt-get.cc:791 cmdline/apt-get.cc:1811 cmdline/apt-get.cc:1844 msgid "Unable to lock the download directory" msgstr "" -#: cmdline/apt-get.cc:801 cmdline/apt-get.cc:1890 cmdline/apt-get.cc:2126 +#: cmdline/apt-get.cc:801 cmdline/apt-get.cc:1892 cmdline/apt-get.cc:2128 #: apt-pkg/cachefile.cc:67 msgid "The list of sources could not be read." msgstr "" @@ -727,7 +727,7 @@ msgstr "" msgid "After unpacking %sB disk space will be freed.\n" msgstr "" -#: cmdline/apt-get.cc:846 cmdline/apt-get.cc:1980 +#: cmdline/apt-get.cc:846 cmdline/apt-get.cc:1982 #, c-format msgid "Couldn't determine free space in %s" msgstr "" @@ -761,7 +761,7 @@ msgstr "" msgid "Do you want to continue [Y/n]? " msgstr "" -#: cmdline/apt-get.cc:961 cmdline/apt-get.cc:1365 cmdline/apt-get.cc:2023 +#: cmdline/apt-get.cc:961 cmdline/apt-get.cc:1366 cmdline/apt-get.cc:2025 #, c-format msgid "Failed to fetch %s %s\n" msgstr "" @@ -770,7 +770,7 @@ msgstr "" msgid "Some files failed to download" msgstr "" -#: cmdline/apt-get.cc:980 cmdline/apt-get.cc:2032 +#: cmdline/apt-get.cc:980 cmdline/apt-get.cc:2034 msgid "Download complete and in download only mode" msgstr "" @@ -866,41 +866,41 @@ msgstr "" msgid "The update command takes no arguments" msgstr "" -#: cmdline/apt-get.cc:1326 cmdline/apt-get.cc:1420 +#: cmdline/apt-get.cc:1326 msgid "Unable to lock the list directory" msgstr "" -#: cmdline/apt-get.cc:1384 +#: cmdline/apt-get.cc:1393 cmdline/apt-get.cc:1395 msgid "" "Some index files failed to download, they have been ignored, or old ones " "used instead." msgstr "" -#: cmdline/apt-get.cc:1403 +#: cmdline/apt-get.cc:1414 msgid "Internal error, AllUpgrade broke stuff" msgstr "" -#: cmdline/apt-get.cc:1502 cmdline/apt-get.cc:1538 +#: cmdline/apt-get.cc:1504 cmdline/apt-get.cc:1540 #, c-format msgid "Couldn't find package %s" msgstr "" -#: cmdline/apt-get.cc:1525 +#: cmdline/apt-get.cc:1527 #, c-format msgid "Note, selecting %s for regex '%s'\n" msgstr "" -#: cmdline/apt-get.cc:1555 +#: cmdline/apt-get.cc:1557 msgid "You might want to run `apt-get -f install' to correct these:" msgstr "" -#: cmdline/apt-get.cc:1558 +#: cmdline/apt-get.cc:1560 msgid "" "Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a " "solution)." msgstr "" -#: cmdline/apt-get.cc:1570 +#: cmdline/apt-get.cc:1572 msgid "" "Some packages could not be installed. This may mean that you have\n" "requested an impossible situation or if you are using the unstable\n" @@ -908,163 +908,163 @@ msgid "" "or been moved out of Incoming." msgstr "" -#: cmdline/apt-get.cc:1578 +#: cmdline/apt-get.cc:1580 msgid "" "Since you only requested a single operation it is extremely likely that\n" "the package is simply not installable and a bug report against\n" "that package should be filed." msgstr "" -#: cmdline/apt-get.cc:1583 +#: cmdline/apt-get.cc:1585 msgid "The following information may help to resolve the situation:" msgstr "" -#: cmdline/apt-get.cc:1586 +#: cmdline/apt-get.cc:1588 msgid "Broken packages" msgstr "" -#: cmdline/apt-get.cc:1612 +#: cmdline/apt-get.cc:1614 msgid "The following extra packages will be installed:" msgstr "" -#: cmdline/apt-get.cc:1683 +#: cmdline/apt-get.cc:1685 msgid "Suggested packages:" msgstr "" -#: cmdline/apt-get.cc:1684 +#: cmdline/apt-get.cc:1686 msgid "Recommended packages:" msgstr "" -#: cmdline/apt-get.cc:1704 +#: cmdline/apt-get.cc:1706 msgid "Calculating upgrade... " msgstr "" -#: cmdline/apt-get.cc:1707 methods/ftp.cc:702 methods/connect.cc:101 +#: cmdline/apt-get.cc:1709 methods/ftp.cc:702 methods/connect.cc:101 msgid "Failed" msgstr "" -#: cmdline/apt-get.cc:1712 +#: cmdline/apt-get.cc:1714 msgid "Done" msgstr "" -#: cmdline/apt-get.cc:1777 cmdline/apt-get.cc:1785 +#: cmdline/apt-get.cc:1779 cmdline/apt-get.cc:1787 msgid "Internal error, problem resolver broke stuff" msgstr "" -#: cmdline/apt-get.cc:1885 +#: cmdline/apt-get.cc:1887 msgid "Must specify at least one package to fetch source for" msgstr "" -#: cmdline/apt-get.cc:1915 cmdline/apt-get.cc:2144 +#: cmdline/apt-get.cc:1917 cmdline/apt-get.cc:2146 #, c-format msgid "Unable to find a source package for %s" msgstr "" -#: cmdline/apt-get.cc:1959 +#: cmdline/apt-get.cc:1961 #, c-format msgid "Skipping already downloaded file '%s'\n" msgstr "" -#: cmdline/apt-get.cc:1983 +#: cmdline/apt-get.cc:1985 #, c-format msgid "You don't have enough free space in %s" msgstr "" -#: cmdline/apt-get.cc:1988 +#: cmdline/apt-get.cc:1990 #, c-format msgid "Need to get %sB/%sB of source archives.\n" msgstr "" -#: cmdline/apt-get.cc:1991 +#: cmdline/apt-get.cc:1993 #, c-format msgid "Need to get %sB of source archives.\n" msgstr "" -#: cmdline/apt-get.cc:1997 +#: cmdline/apt-get.cc:1999 #, c-format msgid "Fetch source %s\n" msgstr "" -#: cmdline/apt-get.cc:2028 +#: cmdline/apt-get.cc:2030 msgid "Failed to fetch some archives." msgstr "" -#: cmdline/apt-get.cc:2056 +#: cmdline/apt-get.cc:2058 #, c-format msgid "Skipping unpack of already unpacked source in %s\n" msgstr "" -#: cmdline/apt-get.cc:2068 +#: cmdline/apt-get.cc:2070 #, c-format msgid "Unpack command '%s' failed.\n" msgstr "" -#: cmdline/apt-get.cc:2069 +#: cmdline/apt-get.cc:2071 #, c-format msgid "Check if the 'dpkg-dev' package is installed.\n" msgstr "" -#: cmdline/apt-get.cc:2086 +#: cmdline/apt-get.cc:2088 #, c-format msgid "Build command '%s' failed.\n" msgstr "" -#: cmdline/apt-get.cc:2105 +#: cmdline/apt-get.cc:2107 msgid "Child process failed" msgstr "" -#: cmdline/apt-get.cc:2121 +#: cmdline/apt-get.cc:2123 msgid "Must specify at least one package to check builddeps for" msgstr "" -#: cmdline/apt-get.cc:2149 +#: cmdline/apt-get.cc:2151 #, c-format msgid "Unable to get build-dependency information for %s" msgstr "" -#: cmdline/apt-get.cc:2169 +#: cmdline/apt-get.cc:2171 #, c-format msgid "%s has no build depends.\n" msgstr "" -#: cmdline/apt-get.cc:2221 +#: cmdline/apt-get.cc:2223 #, c-format msgid "" "%s dependency for %s cannot be satisfied because the package %s cannot be " "found" msgstr "" -#: cmdline/apt-get.cc:2273 +#: cmdline/apt-get.cc:2275 #, c-format msgid "" "%s dependency for %s cannot be satisfied because no available versions of " "package %s can satisfy version requirements" msgstr "" -#: cmdline/apt-get.cc:2308 +#: cmdline/apt-get.cc:2310 #, c-format msgid "Failed to satisfy %s dependency for %s: Installed package %s is too new" msgstr "" -#: cmdline/apt-get.cc:2333 +#: cmdline/apt-get.cc:2335 #, c-format msgid "Failed to satisfy %s dependency for %s: %s" msgstr "" -#: cmdline/apt-get.cc:2347 +#: cmdline/apt-get.cc:2349 #, c-format msgid "Build-dependencies for %s could not be satisfied." msgstr "" -#: cmdline/apt-get.cc:2351 +#: cmdline/apt-get.cc:2353 msgid "Failed to process build dependencies" msgstr "" -#: cmdline/apt-get.cc:2383 +#: cmdline/apt-get.cc:2385 msgid "Supported modules:" msgstr "" -#: cmdline/apt-get.cc:2424 +#: cmdline/apt-get.cc:2426 msgid "" "Usage: apt-get [options] command\n" " apt-get [options] install|remove pkg1 [pkg2 ...]\n" @@ -1349,9 +1349,9 @@ msgid "The info and temp directories need to be on the same filesystem" msgstr "" #. Build the status cache -#: apt-inst/deb/dpkgdb.cc:139 apt-pkg/pkgcachegen.cc:643 -#: apt-pkg/pkgcachegen.cc:712 apt-pkg/pkgcachegen.cc:717 -#: apt-pkg/pkgcachegen.cc:840 +#: apt-inst/deb/dpkgdb.cc:139 apt-pkg/pkgcachegen.cc:645 +#: apt-pkg/pkgcachegen.cc:714 apt-pkg/pkgcachegen.cc:719 +#: apt-pkg/pkgcachegen.cc:842 msgid "Reading package lists" msgstr "" @@ -1666,34 +1666,34 @@ msgstr "" msgid "Could not connect to %s:%s (%s), connection timed out" msgstr "" -#: methods/connect.cc:106 +#: methods/connect.cc:108 #, c-format msgid "Could not connect to %s:%s (%s)." msgstr "" #. We say this mainly because the pause here is for the #. ssh connection that is still going -#: methods/connect.cc:134 methods/rsh.cc:425 +#: methods/connect.cc:136 methods/rsh.cc:425 #, c-format msgid "Connecting to %s" msgstr "" -#: methods/connect.cc:165 +#: methods/connect.cc:167 #, c-format msgid "Could not resolve '%s'" msgstr "" -#: methods/connect.cc:171 +#: methods/connect.cc:173 #, c-format msgid "Temporary failure resolving '%s'" msgstr "" -#: methods/connect.cc:174 +#: methods/connect.cc:176 #, c-format msgid "Something wicked happened resolving '%s:%s' (%i)" msgstr "" -#: methods/connect.cc:221 +#: methods/connect.cc:223 #, c-format msgid "Unable to connect to %s %s:" msgstr "" @@ -2218,7 +2218,7 @@ msgstr "" msgid "Method %s did not start correctly" msgstr "" -#: apt-pkg/acquire-worker.cc:377 +#: apt-pkg/acquire-worker.cc:384 #, c-format msgid "Please insert the disc labeled: '%s' in the drive '%s' and press enter." msgstr "" @@ -2328,16 +2328,16 @@ msgstr "" msgid "Package %s %s was not found while processing file dependencies" msgstr "" -#: apt-pkg/pkgcachegen.cc:574 +#: apt-pkg/pkgcachegen.cc:575 #, c-format msgid "Couldn't stat source package list %s" msgstr "" -#: apt-pkg/pkgcachegen.cc:658 +#: apt-pkg/pkgcachegen.cc:660 msgid "Collecting File Provides" msgstr "" -#: apt-pkg/pkgcachegen.cc:785 apt-pkg/pkgcachegen.cc:792 +#: apt-pkg/pkgcachegen.cc:787 apt-pkg/pkgcachegen.cc:794 msgid "IO Error saving source cache" msgstr "" @@ -2346,35 +2346,35 @@ msgstr "" msgid "rename failed, %s (%s -> %s)." msgstr "" -#: apt-pkg/acquire-item.cc:236 apt-pkg/acquire-item.cc:950 +#: apt-pkg/acquire-item.cc:236 apt-pkg/acquire-item.cc:951 msgid "MD5Sum mismatch" msgstr "" -#: apt-pkg/acquire-item.cc:645 +#: apt-pkg/acquire-item.cc:646 msgid "There are no public key available for the following key IDs:\n" msgstr "" -#: apt-pkg/acquire-item.cc:758 +#: apt-pkg/acquire-item.cc:759 #, c-format msgid "" "I wasn't able to locate a file for the %s package. This might mean you need " "to manually fix this package. (due to missing arch)" msgstr "" -#: apt-pkg/acquire-item.cc:817 +#: apt-pkg/acquire-item.cc:818 #, c-format msgid "" "I wasn't able to locate file for the %s package. This might mean you need to " "manually fix this package." msgstr "" -#: apt-pkg/acquire-item.cc:853 +#: apt-pkg/acquire-item.cc:854 #, c-format msgid "" "The package index files are corrupted. No Filename: field for package %s." msgstr "" -#: apt-pkg/acquire-item.cc:940 +#: apt-pkg/acquire-item.cc:941 msgid "Size mismatch" msgstr "" -- cgit v1.2.3-70-g09d2 From 6627bdccce46a9acdae09d37e6e1444a5f7384e1 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 18 Apr 2006 13:25:13 +0200 Subject: * wording fixes (cherry picked from apt--mvo) --- apt-pkg/deb/dpkgpm.cc | 4 ++-- debian/changelog | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index fe8fbca74..3b7b2238a 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -375,8 +375,8 @@ bool pkgDPkgPM::Go(int OutStatusFd) }, // Purge operation { - {"config-files", _("Preparing for remove with config %s")}, - {"not-installed", _("Removed with config %s")}, + {"config-files", _("Preparing to completely remove %s")}, + {"not-installed", _("Completely removed %s")}, {NULL, NULL} }, }; diff --git a/debian/changelog b/debian/changelog index 81e4acf0d..e8962595f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +apt (0.6.43.3ubuntu2) dapper; urgency=low + + * apt-pkg/deb/dpkgpm.cc: wording fixes (thanks to Matt Zimmerman) + + -- Michael Vogt Tue, 18 Apr 2006 13:24:40 +0200 + apt (0.6.43.3ubuntu1) dapper; urgency=low * apt-pkg/acquire.cc: don't show ETA if it is 0 or absurdely large in -- cgit v1.2.3-70-g09d2 From 8953292ef197b80c16d08b31830945fb7ac9ff8d Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 21 Jul 2006 11:01:59 +0200 Subject: * merged changes from Kamions upload (thanks!) --- apt-pkg/depcache.cc | 1 + debian/changelog | 6 ++++++ 2 files changed, 7 insertions(+) (limited to 'apt-pkg') diff --git a/apt-pkg/depcache.cc b/apt-pkg/depcache.cc index 25a4372bf..369eae70b 100644 --- a/apt-pkg/depcache.cc +++ b/apt-pkg/depcache.cc @@ -251,6 +251,7 @@ bool pkgDepCache::writeStateFile(OpProgress *prog) fprintf(OutFile,"\n"); } } + fclose(OutFile); // move the outfile over the real file rename(outfile.c_str(), state.c_str()); diff --git a/debian/changelog b/debian/changelog index e88ec1e37..297ce020b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +apt (0.6.44.2ubuntu3) edgy; urgency=low + + * Close extended_states file after writing it. + + -- Colin Watson Tue, 18 Jul 2006 00:12:13 +0100 + apt (0.6.44.2ubuntu2) edgy; urgency=low * create a empty extended_states file if none exists already -- cgit v1.2.3-70-g09d2 From a498783013497735fb9fa484be60f6148289b0bb Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 15 Aug 2006 12:08:36 +0200 Subject: * apt-pkg/pkgcachegen.cc: - increased the cache limit --- apt-pkg/pkgcachegen.cc | 4 ++-- debian/changelog | 8 ++++++++ 2 files changed, 10 insertions(+), 2 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/pkgcachegen.cc b/apt-pkg/pkgcachegen.cc index b2725a99d..8ec6a1719 100644 --- a/apt-pkg/pkgcachegen.cc +++ b/apt-pkg/pkgcachegen.cc @@ -785,7 +785,7 @@ static bool BuildCache(pkgCacheGenerator &Gen, bool pkgMakeStatusCache(pkgSourceList &List,OpProgress &Progress, MMap **OutMap,bool AllowMem) { - unsigned long MapSize = _config->FindI("APT::Cache-Limit",12*1024*1024); + unsigned long MapSize = _config->FindI("APT::Cache-Limit",16*1024*1024); vector Files; for (vector::const_iterator i = List.begin(); @@ -932,7 +932,7 @@ bool pkgMakeStatusCache(pkgSourceList &List,OpProgress &Progress, /* */ bool pkgMakeOnlyStatusCache(OpProgress &Progress,DynamicMMap **OutMap) { - unsigned long MapSize = _config->FindI("APT::Cache-Limit",8*1024*1024); + unsigned long MapSize = _config->FindI("APT::Cache-Limit",12*1024*1024); vector Files; unsigned long EndOfSource = Files.size(); if (_system->AddStatusFiles(Files) == false) diff --git a/debian/changelog b/debian/changelog index 0bb679c5a..55c88c4c8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +apt (0.6.45ubuntu5) edgy; urgency=low + + * apt-pkg/pkgcachegen.cc: + - increase the APT::Cache-Limit to deal with the increased demand due + to the translated descriptions + + -- Michael Vogt Tue, 15 Aug 2006 12:06:26 +0200 + apt (0.6.45ubuntu4) edgy; urgency=low * cmdline/apt-get.cc: -- cgit v1.2.3-70-g09d2 From 857a1d4aafc7fd4cc9d1f22c7ef4d274b09c2906 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 15 Aug 2006 12:59:52 +0200 Subject: * apt-pkg/deb/dpkgpm.cc: - pass --auto-deconfigure to dpkg (-B) * debian/control: - depend on a dpkg with support for breaks --- apt-pkg/deb/dpkgpm.cc | 2 ++ configure.in | 2 +- debian/changelog | 5 +++++ debian/control | 2 +- 4 files changed, 9 insertions(+), 2 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc index bf0434ccc..93dff390d 100644 --- a/apt-pkg/deb/dpkgpm.cc +++ b/apt-pkg/deb/dpkgpm.cc @@ -474,6 +474,8 @@ bool pkgDPkgPM::Go(int OutStatusFd) case Item::Install: Args[n++] = "--unpack"; Size += strlen(Args[n-1]); + Args[n++] = "--auto-deconfigure"; + Size += strlen(Args[n-1]); break; } diff --git a/configure.in b/configure.in index 202a15dc0..a0cd8080c 100644 --- a/configure.in +++ b/configure.in @@ -18,7 +18,7 @@ AC_CONFIG_AUX_DIR(buildlib) AC_CONFIG_HEADER(include/config.h:buildlib/config.h.in include/apti18n.h:buildlib/apti18n.h.in) dnl -- SET THIS TO THE RELEASE VERSION -- -AC_DEFINE_UNQUOTED(VERSION,"0.6.45ubuntu4") +AC_DEFINE_UNQUOTED(VERSION,"0.6.45ubuntu5") PACKAGE="apt" AC_DEFINE_UNQUOTED(PACKAGE,"$PACKAGE") AC_SUBST(PACKAGE) diff --git a/debian/changelog b/debian/changelog index 55c88c4c8..da396e755 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,11 @@ apt (0.6.45ubuntu5) edgy; urgency=low * apt-pkg/pkgcachegen.cc: - increase the APT::Cache-Limit to deal with the increased demand due to the translated descriptions + * apt-pkg/deb/dpkgpm.cc: + - pass "--auto-deconfigure" to dpkg on install to support the + new "breaks" in dpkg + * debian/control: + - depend on a dpkg with "breaks" support -- Michael Vogt Tue, 15 Aug 2006 12:06:26 +0200 diff --git a/debian/control b/debian/control index dfcebf41e..62ca713f1 100644 --- a/debian/control +++ b/debian/control @@ -14,7 +14,7 @@ Priority: important Replaces: libapt-pkg-doc (<< 0.3.7), libapt-pkg-dev (<< 0.3.7) Provides: ${libapt-pkg:provides} Recommends: ubuntu-keyring -Suggests: aptitude | synaptic | gnome-apt | wajig, dpkg-dev, apt-doc, bzip2, gnupg +Suggests: aptitude | synaptic | gnome-apt | wajig, dpkg-dev (>= 1.13.22ubuntu4), apt-doc, bzip2, gnupg Section: admin Description: Advanced front-end for dpkg This is Debian's next generation front-end for the dpkg package manager. -- cgit v1.2.3-70-g09d2 From 308c7d30ed2e937cde65e5fed8cbf717fba113c3 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Fri, 25 Aug 2006 15:39:15 +0100 Subject: initial Breaks implementation --- apt-pkg/algorithms.cc | 23 +- apt-pkg/deb/deblistparser.cc | 3 + apt-pkg/depcache.cc | 40 ++- apt-pkg/orderlist.cc | 17 +- apt-pkg/pkgcache.cc | 9 +- apt-pkg/pkgcache.h | 6 +- apt-pkg/tagfile.cc | 1 + cmdline/apt-cache.cc | 10 +- debian/changelog | 7 + doc/apt-cache.8.xml | 2 +- doc/cache.sgml | 3 +- doc/dpkg-tech.sgml | 2 + po/apt-all.pot | 760 ++++++++++++++----------------------------- 13 files changed, 344 insertions(+), 539 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc index ac9d3be0b..f50c52a32 100644 --- a/apt-pkg/algorithms.cc +++ b/apt-pkg/algorithms.cc @@ -102,6 +102,7 @@ bool pkgSimulate::Install(PkgIterator iPkg,string /*File*/) DepIterator End; D.GlobOr(Start,End); if (Start->Type == pkgCache::Dep::Conflicts || + Start->Type == pkgCache::Dep::DpkgBreaks || Start->Type == pkgCache::Dep::Obsoletes || End->Type == pkgCache::Dep::PreDepends) { @@ -151,6 +152,8 @@ bool pkgSimulate::Configure(PkgIterator iPkg) cout << " Obsoletes:" << D.TargetPkg().Name(); else if (D->Type == pkgCache::Dep::Conflicts) cout << " Conflicts:" << D.TargetPkg().Name(); + else if (D->Type == pkgCache::Dep::DpkgBreaks) + cout << " Breaks:" << D.TargetPkg().Name(); else cout << " Depends:" << D.TargetPkg().Name(); } @@ -651,6 +654,7 @@ bool pkgProblemResolver::DoUpgrade(pkgCache::PkgIterator Pkg) /* We let the algorithm deal with conflicts on its next iteration, it is much smarter than us */ if (Start->Type == pkgCache::Dep::Conflicts || + Start->Type == pkgCache::Dep::DpkgBreaks || Start->Type == pkgCache::Dep::Obsoletes) break; @@ -873,6 +877,7 @@ bool pkgProblemResolver::Resolve(bool BrokenFix) SPtrArray VList = Start.AllTargets(); if (*VList == 0 && (Flags[I->ID] & Protected) != Protected && Start->Type != pkgCache::Dep::Conflicts && + Start->Type != pkgCache::Dep::DpkgBreaks && Start->Type != pkgCache::Dep::Obsoletes && Cache[I].NowBroken() == false) { @@ -903,6 +908,7 @@ bool pkgProblemResolver::Resolve(bool BrokenFix) if (Scores[I->ID] <= Scores[Pkg->ID] || ((Cache[Start] & pkgDepCache::DepNow) == 0 && End->Type != pkgCache::Dep::Conflicts && + End->Type != pkgCache::Dep::DpkgBreaks && End->Type != pkgCache::Dep::Obsoletes)) { // Try a little harder to fix protected packages.. @@ -968,7 +974,21 @@ bool pkgProblemResolver::Resolve(bool BrokenFix) (Start->Type == pkgCache::Dep::Conflicts || Start->Type == pkgCache::Dep::Obsoletes)) continue; - + + if (Start->Type == pkgCache::Dep::DpkgBreaks) + { + /* Would it help if we upgraded? */ + if (Cache[End] & pkgDepCache::DepGCVer) { + if (Debug) + clog << " Upgrading " << Pkg.Name() << " due to Breaks field in " << I.Name() << endl; + Cache.MarkInstall(Pkg, false, 0, false); + continue; + } + if (Debug) + clog << " Will not break " << Pkg.Name() << " as stated in Breaks field in " << I.Name() <ID] & Protected) != 0) continue; @@ -989,6 +1009,7 @@ bool pkgProblemResolver::Resolve(bool BrokenFix) // Hm, nothing can possibly satisify this dep. Nuke it. if (VList[0] == 0 && Start->Type != pkgCache::Dep::Conflicts && + Start->Type != pkgCache::Dep::DpkgBreaks && Start->Type != pkgCache::Dep::Obsoletes && (Flags[I->ID] & Protected) != Protected) { diff --git a/apt-pkg/deb/deblistparser.cc b/apt-pkg/deb/deblistparser.cc index c2b26b5eb..074abea6d 100644 --- a/apt-pkg/deb/deblistparser.cc +++ b/apt-pkg/deb/deblistparser.cc @@ -105,6 +105,8 @@ bool debListParser::NewVersion(pkgCache::VerIterator Ver) return false; if (ParseDepends(Ver,"Conflicts",pkgCache::Dep::Conflicts) == false) return false; + if (ParseDepends(Ver,"Breaks",pkgCache::Dep::DpkgBreaks) == false) + return false; if (ParseDepends(Ver,"Replaces",pkgCache::Dep::Replaces) == false) return false; @@ -193,6 +195,7 @@ unsigned short debListParser::VersionHash() // "Suggests", // "Recommends", "Conflicts", + "Breaks", "Replaces",0}; unsigned long Result = INIT_FCS; char S[1024]; diff --git a/apt-pkg/depcache.cc b/apt-pkg/depcache.cc index 78c929d62..4d193dc2e 100644 --- a/apt-pkg/depcache.cc +++ b/apt-pkg/depcache.cc @@ -273,7 +273,7 @@ bool pkgDepCache::CheckDep(DepIterator Dep,int Type,PkgIterator &Res) we allow it anyhow because dpkg does. Technically it is a packaging bug. Conflicts may never self match */ if (Dep.TargetPkg() != Dep.ParentPkg() || - (Dep->Type != Dep::Conflicts && Dep->Type != Dep::Obsoletes)) + (Dep->Type != Dep::Conflicts && Dep->Type != Dep::DpkgBreaks && Dep->Type != Dep::Obsoletes)) { PkgIterator Pkg = Dep.TargetPkg(); // Check the base package @@ -303,7 +303,8 @@ bool pkgDepCache::CheckDep(DepIterator Dep,int Type,PkgIterator &Res) { /* Provides may never be applied against the same package if it is a conflicts. See the comment above. */ - if (P.OwnerPkg() == Pkg && Dep->Type == Dep::Conflicts) + if (P.OwnerPkg() == Pkg && + (Dep->Type == Dep::Conflicts || Dep->Type == Dep::DpkgBreaks)) continue; // Check if the provides is a hit @@ -457,7 +458,9 @@ void pkgDepCache::BuildGroupOrs(VerIterator const &V) /* Invert for Conflicts. We have to do this twice to get the right sense for a conflicts group */ - if (D->Type == Dep::Conflicts || D->Type == Dep::Obsoletes) + if (D->Type == Dep::Conflicts || + D->Type == Dep::DpkgBreaks || + D->Type == Dep::Obsoletes) State = ~State; // Add to the group if we are within an or.. @@ -468,7 +471,9 @@ void pkgDepCache::BuildGroupOrs(VerIterator const &V) Group = 0; // Invert for Conflicts - if (D->Type == Dep::Conflicts || D->Type == Dep::Obsoletes) + if (D->Type == Dep::Conflicts || + D->Type == Dep::DpkgBreaks || + D->Type == Dep::Obsoletes) State = ~State; } } @@ -601,7 +606,9 @@ void pkgDepCache::Update(OpProgress *Prog) Group = 0; // Invert for Conflicts - if (D->Type == Dep::Conflicts || D->Type == Dep::Obsoletes) + if (D->Type == Dep::Conflicts || + D->Type == Dep::DpkgBreaks || + D->Type == Dep::Obsoletes) State = ~State; } } @@ -631,7 +638,9 @@ void pkgDepCache::Update(DepIterator D) State = DependencyState(D); // Invert for Conflicts - if (D->Type == Dep::Conflicts || D->Type == Dep::Obsoletes) + if (D->Type == Dep::Conflicts || + D->Type == Dep::DpkgBreaks || + D->Type == Dep::Obsoletes) State = ~State; RemoveStates(D.ParentPkg()); @@ -894,7 +903,8 @@ void pkgDepCache::MarkInstall(PkgIterator const &Pkg,bool AutoInst, /* This bit is for processing the possibilty of an install/upgrade fixing the problem */ SPtrArray List = Start.AllTargets(); - if ((DepState[Start->ID] & DepCVer) == DepCVer) + if (Start->Type != Dep::DpkgBreaks && + (DepState[Start->ID] & DepCVer) == DepCVer) { // Right, find the best version to install.. Version **Cur = List; @@ -939,17 +949,23 @@ void pkgDepCache::MarkInstall(PkgIterator const &Pkg,bool AutoInst, } continue; } - + /* For conflicts we just de-install the package and mark as auto, - Conflicts may not have or groups */ - if (Start->Type == Dep::Conflicts || Start->Type == Dep::Obsoletes) + Conflicts may not have or groups. For dpkg's Breaks we try to + upgrade the package. */ + if (Start->Type == Dep::Conflicts || Start->Type == Dep::Obsoletes || + Start->Type == Dep::DpkgBreaks) { for (Version **I = List; *I != 0; I++) { VerIterator Ver(*this,*I); PkgIterator Pkg = Ver.ParentPkg(); - - MarkDelete(Pkg); + + if (Start->Type != Dep::DpkgBreaks) + MarkDelete(Pkg); + else + if (PkgState[Pkg->ID].CandidateVer != *I) + MarkInstall(Pkg,true,Depth + 1, false, ForceImportantDeps); } continue; } diff --git a/apt-pkg/orderlist.cc b/apt-pkg/orderlist.cc index 8d3a97983..61d8d914e 100644 --- a/apt-pkg/orderlist.cc +++ b/apt-pkg/orderlist.cc @@ -491,11 +491,13 @@ bool pkgOrderList::VisitProvides(DepIterator D,bool Critical) continue; if (D->Type != pkgCache::Dep::Conflicts && + D->Type != pkgCache::Dep::DpkgBreaks && D->Type != pkgCache::Dep::Obsoletes && Cache[Pkg].InstallVer != *I) continue; if ((D->Type == pkgCache::Dep::Conflicts || + D->Type == pkgCache::Dep::DpkgBreaks || D->Type == pkgCache::Dep::Obsoletes) && (Version *)Pkg.CurrentVer() != *I) continue; @@ -630,6 +632,7 @@ bool pkgOrderList::DepUnPackCrit(DepIterator D) /* Forward critical dependencies MUST be correct before the package can be unpacked. */ if (D->Type != pkgCache::Dep::Conflicts && + D->Type != pkgCache::Dep::DpkgBreaks && D->Type != pkgCache::Dep::Obsoletes && D->Type != pkgCache::Dep::PreDepends) continue; @@ -668,7 +671,7 @@ bool pkgOrderList::DepUnPackCrit(DepIterator D) } return true; } - /*}}}*/ + // OrderList::DepUnPackPreD - Critical UnPacking ordering with depends /*{{{*/ // --------------------------------------------------------------------- /* Critical PreDepends (also configure immediate and essential) strives to @@ -803,9 +806,20 @@ bool pkgOrderList::DepUnPackDep(DepIterator D) return false; } else + { if (D->Type == pkgCache::Dep::Depends) if (VisitProvides(D,false) == false) return false; + + if (D->Type == pkgCache::Dep::DpkgBreaks) + { + if (CheckDep(D) == true) + continue; + + if (VisitNode(D.TargetPkg()) == false) + return false; + } + } } return true; } @@ -953,6 +967,7 @@ bool pkgOrderList::CheckDep(DepIterator D) /* Conflicts requires that all versions are not present, depends just needs one */ if (D->Type != pkgCache::Dep::Conflicts && + D->Type != pkgCache::Dep::DpkgBreaks && D->Type != pkgCache::Dep::Obsoletes) { /* Try to find something that does not have the after flag set diff --git a/apt-pkg/pkgcache.cc b/apt-pkg/pkgcache.cc index 162ab4f27..35eb23dfa 100644 --- a/apt-pkg/pkgcache.cc +++ b/apt-pkg/pkgcache.cc @@ -228,8 +228,8 @@ const char *pkgCache::DepType(unsigned char Type) { const char *Types[] = {"",_("Depends"),_("PreDepends"),_("Suggests"), _("Recommends"),_("Conflicts"),_("Replaces"), - _("Obsoletes")}; - if (Type < 8) + _("Obsoletes"),_("Breaks")}; + if (Type < sizeof(Types)/sizeof(*Types)) return Types[Type]; return ""; } @@ -292,10 +292,11 @@ pkgCache::PkgIterator::OkState pkgCache::PkgIterator::State() const // DepIterator::IsCritical - Returns true if the dep is important /*{{{*/ // --------------------------------------------------------------------- /* Currently critical deps are defined as depends, predepends and - conflicts. */ + conflicts (including dpkg's Breaks fields). */ bool pkgCache::DepIterator::IsCritical() { if (Dep->Type == pkgCache::Dep::Conflicts || + Dep->Type == pkgCache::Dep::DpkgBreaks || Dep->Type == pkgCache::Dep::Obsoletes || Dep->Type == pkgCache::Dep::Depends || Dep->Type == pkgCache::Dep::PreDepends) @@ -381,6 +382,7 @@ pkgCache::Version **pkgCache::DepIterator::AllTargets() continue; if ((Dep->Type == pkgCache::Dep::Conflicts || + Dep->Type == pkgCache::Dep::DpkgBreaks || Dep->Type == pkgCache::Dep::Obsoletes) && ParentPkg() == I.ParentPkg()) continue; @@ -397,6 +399,7 @@ pkgCache::Version **pkgCache::DepIterator::AllTargets() continue; if ((Dep->Type == pkgCache::Dep::Conflicts || + Dep->Type == pkgCache::Dep::DpkgBreaks || Dep->Type == pkgCache::Dep::Obsoletes) && ParentPkg() == I.OwnerPkg()) continue; diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h index c7a3172cc..970759492 100644 --- a/apt-pkg/pkgcache.h +++ b/apt-pkg/pkgcache.h @@ -66,10 +66,14 @@ class pkgCache class Namespace; // These are all the constants used in the cache structures + + // WARNING - if you change these lists you must also edit + // the stringification in pkgcache.cc and also consider whether + // the cache file will become incompatible. struct Dep { enum DepType {Depends=1,PreDepends=2,Suggests=3,Recommends=4, - Conflicts=5,Replaces=6,Obsoletes=7}; + Conflicts=5,Replaces=6,Obsoletes=7,DpkgBreaks=8}; enum DepCompareOp {Or=0x10,NoOp=0,LessEq=0x1,GreaterEq=0x2,Less=0x3, Greater=0x4,Equals=0x5,NotEquals=0x6}; }; diff --git a/apt-pkg/tagfile.cc b/apt-pkg/tagfile.cc index 8fcbeb23b..146829566 100644 --- a/apt-pkg/tagfile.cc +++ b/apt-pkg/tagfile.cc @@ -422,6 +422,7 @@ static const char *iTFRewritePackageOrder[] = { "Recommends", "Suggests", "Conflicts", + "Breaks", "Conffiles", "Filename", "Size", diff --git a/cmdline/apt-cache.cc b/cmdline/apt-cache.cc index 74fa71cba..cc4c1559e 100644 --- a/cmdline/apt-cache.cc +++ b/cmdline/apt-cache.cc @@ -102,13 +102,15 @@ bool UnMet(CommandLine &CmdL) if (End->Type != pkgCache::Dep::PreDepends && End->Type != pkgCache::Dep::Depends && End->Type != pkgCache::Dep::Suggests && - End->Type != pkgCache::Dep::Recommends) + End->Type != pkgCache::Dep::Recommends && + End->Type != pkgCache::Dep::DpkgBreaks) continue; // Important deps only if (Important == true) if (End->Type != pkgCache::Dep::PreDepends && - End->Type != pkgCache::Dep::Depends) + End->Type != pkgCache::Dep::Depends && + End->Type != pkgCache::Dep::DpkgBreaks) continue; // Verify the or group @@ -869,6 +871,7 @@ bool XVcg(CommandLine &CmdL) then show the relation but do not recurse */ if (Hit == false && (D->Type == pkgCache::Dep::Conflicts || + D->Type == pkgCache::Dep::DpkgBreaks || D->Type == pkgCache::Dep::Obsoletes)) { if (Show[D.TargetPkg()->ID] == None && @@ -890,6 +893,9 @@ bool XVcg(CommandLine &CmdL) case pkgCache::Dep::Conflicts: printf("label: \"conflicts\" color: lightgreen }\n"); break; + case pkgCache::Dep::DpkgBreaks: + printf("label: \"breaks\" color: lightgreen }\n"); + break; case pkgCache::Dep::Obsoletes: printf("label: \"obsoletes\" color: lightgreen }\n"); break; diff --git a/debian/changelog b/debian/changelog index da396e755..9c6232a6c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +apt (0.6.45ubuntu6~iwj) unstable; urgency=low + + * Initial draft of `Breaks' implementation. Appears to compile, + but as yet *completely untested*. + + -- Ian Jackson Fri, 25 Aug 2006 15:39:07 +0100 + apt (0.6.45ubuntu5) edgy; urgency=low * apt-pkg/pkgcachegen.cc: diff --git a/doc/apt-cache.8.xml b/doc/apt-cache.8.xml index 2779f2501..c1e65332d 100644 --- a/doc/apt-cache.8.xml +++ b/doc/apt-cache.8.xml @@ -151,7 +151,7 @@ Reverse Provides: a dependency but were not provided by any package. Missing packages may be in evidence if a full distribution is not accessed, or if a package (real or virtual) has been dropped from the distribution. Usually they - are referenced from Conflicts statements. + are referenced from Conflicts or Breaks statements. Total distinct versions is the number of package versions diff --git a/doc/cache.sgml b/doc/cache.sgml index aa87db986..e257dcd81 100644 --- a/doc/cache.sgml +++ b/doc/cache.sgml @@ -492,7 +492,7 @@ This is the parsed priority value of the package. Dependency contains the information for a single dependency record. The records are split up like this to ease processing by the client. The base of list linked list is Version.DependsList. All forms of dependencies are recorded -here including Conflicts, Suggests and Recommends. +here including Conflicts, Breaks, Suggests and Recommends.

Multiple depends on the same package must be grouped together in @@ -671,6 +671,7 @@ of them. #define pkgDEP_Recommends 4 #define pkgDEP_Conflicts 5 #define pkgDEP_Replaces 6 +#define pkgDEP_Breaks 8 diff --git a/doc/dpkg-tech.sgml b/doc/dpkg-tech.sgml index 23372d71f..7c6e023dd 100644 --- a/doc/dpkg-tech.sgml +++ b/doc/dpkg-tech.sgml @@ -46,6 +46,8 @@ The basic dpkg package control file supports the following major features:- productivity of the package Conflicts, to specify a package which must NOT be installed in order for the package to be configured + Breaks, to specify a package which is broken by the + package and which should therefore not be configured while broken Each of these dependencies can specify a version and a depedency on that version, for example "<= 0.5-1", "== 2.7.2-1", etc. The comparators available diff --git a/po/apt-all.pot b/po/apt-all.pot index 586f9e545..978b0c191 100644 --- a/po/apt-all.pot +++ b/po/apt-all.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2006-08-09 23:46+0200\n" +"POT-Creation-Date: 2006-08-25 15:34+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -15,145 +15,153 @@ msgstr "" "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" -#: cmdline/apt-cache.cc:135 +#: cmdline/apt-cache.cc:143 #, c-format msgid "Package %s version %s has an unmet dep:\n" msgstr "" -#: cmdline/apt-cache.cc:175 cmdline/apt-cache.cc:527 cmdline/apt-cache.cc:615 -#: cmdline/apt-cache.cc:771 cmdline/apt-cache.cc:989 cmdline/apt-cache.cc:1357 -#: cmdline/apt-cache.cc:1508 +#: cmdline/apt-cache.cc:183 cmdline/apt-cache.cc:552 cmdline/apt-cache.cc:640 +#: cmdline/apt-cache.cc:796 cmdline/apt-cache.cc:1018 +#: cmdline/apt-cache.cc:1419 cmdline/apt-cache.cc:1570 #, c-format msgid "Unable to locate package %s" msgstr "" -#: cmdline/apt-cache.cc:232 +#: cmdline/apt-cache.cc:247 msgid "Total package names : " msgstr "" -#: cmdline/apt-cache.cc:272 +#: cmdline/apt-cache.cc:287 msgid " Normal packages: " msgstr "" -#: cmdline/apt-cache.cc:273 +#: cmdline/apt-cache.cc:288 msgid " Pure virtual packages: " msgstr "" -#: cmdline/apt-cache.cc:274 +#: cmdline/apt-cache.cc:289 msgid " Single virtual packages: " msgstr "" -#: cmdline/apt-cache.cc:275 +#: cmdline/apt-cache.cc:290 msgid " Mixed virtual packages: " msgstr "" -#: cmdline/apt-cache.cc:276 +#: cmdline/apt-cache.cc:291 msgid " Missing: " msgstr "" -#: cmdline/apt-cache.cc:278 +#: cmdline/apt-cache.cc:293 msgid "Total distinct versions: " msgstr "" -#: cmdline/apt-cache.cc:280 +#: cmdline/apt-cache.cc:295 +msgid "Total Distinct Descriptions: " +msgstr "" + +#: cmdline/apt-cache.cc:297 msgid "Total dependencies: " msgstr "" -#: cmdline/apt-cache.cc:283 +#: cmdline/apt-cache.cc:300 msgid "Total ver/file relations: " msgstr "" -#: cmdline/apt-cache.cc:285 +#: cmdline/apt-cache.cc:302 +msgid "Total Desc/File relations: " +msgstr "" + +#: cmdline/apt-cache.cc:304 msgid "Total Provides mappings: " msgstr "" -#: cmdline/apt-cache.cc:297 +#: cmdline/apt-cache.cc:316 msgid "Total globbed strings: " msgstr "" -#: cmdline/apt-cache.cc:311 +#: cmdline/apt-cache.cc:330 msgid "Total dependency version space: " msgstr "" -#: cmdline/apt-cache.cc:316 +#: cmdline/apt-cache.cc:335 msgid "Total slack space: " msgstr "" -#: cmdline/apt-cache.cc:324 +#: cmdline/apt-cache.cc:343 msgid "Total space accounted for: " msgstr "" -#: cmdline/apt-cache.cc:446 cmdline/apt-cache.cc:1189 +#: cmdline/apt-cache.cc:471 cmdline/apt-cache.cc:1218 #, c-format msgid "Package file %s is out of sync." msgstr "" -#: cmdline/apt-cache.cc:1231 +#: cmdline/apt-cache.cc:1293 msgid "You must give exactly one pattern" msgstr "" -#: cmdline/apt-cache.cc:1385 +#: cmdline/apt-cache.cc:1447 msgid "No packages found" msgstr "" -#: cmdline/apt-cache.cc:1462 +#: cmdline/apt-cache.cc:1524 msgid "Package files:" msgstr "" -#: cmdline/apt-cache.cc:1469 cmdline/apt-cache.cc:1555 +#: cmdline/apt-cache.cc:1531 cmdline/apt-cache.cc:1617 msgid "Cache is out of sync, can't x-ref a package file" msgstr "" -#: cmdline/apt-cache.cc:1470 +#: cmdline/apt-cache.cc:1532 #, c-format msgid "%4i %s\n" msgstr "" #. Show any packages have explicit pins -#: cmdline/apt-cache.cc:1482 +#: cmdline/apt-cache.cc:1544 msgid "Pinned packages:" msgstr "" -#: cmdline/apt-cache.cc:1494 cmdline/apt-cache.cc:1535 +#: cmdline/apt-cache.cc:1556 cmdline/apt-cache.cc:1597 msgid "(not found)" msgstr "" #. Installed version -#: cmdline/apt-cache.cc:1515 +#: cmdline/apt-cache.cc:1577 msgid " Installed: " msgstr "" -#: cmdline/apt-cache.cc:1517 cmdline/apt-cache.cc:1525 +#: cmdline/apt-cache.cc:1579 cmdline/apt-cache.cc:1587 msgid "(none)" msgstr "" #. Candidate Version -#: cmdline/apt-cache.cc:1522 +#: cmdline/apt-cache.cc:1584 msgid " Candidate: " msgstr "" -#: cmdline/apt-cache.cc:1532 +#: cmdline/apt-cache.cc:1594 msgid " Package pin: " msgstr "" #. Show the priority tables -#: cmdline/apt-cache.cc:1541 +#: cmdline/apt-cache.cc:1603 msgid " Version table:" msgstr "" -#: cmdline/apt-cache.cc:1556 +#: cmdline/apt-cache.cc:1618 #, c-format msgid " %4i %s\n" msgstr "" -#: cmdline/apt-cache.cc:1652 cmdline/apt-cdrom.cc:138 cmdline/apt-config.cc:70 -#: cmdline/apt-extracttemplates.cc:225 ftparchive/apt-ftparchive.cc:550 -#: cmdline/apt-get.cc:2462 cmdline/apt-sortpkgs.cc:144 +#: cmdline/apt-cache.cc:1714 cmdline/apt-cdrom.cc:138 cmdline/apt-config.cc:70 +#: cmdline/apt-extracttemplates.cc:225 cmdline/apt-get.cc:2476 +#: cmdline/apt-sortpkgs.cc:144 #, c-format msgid "%s %s for %s %s compiled on %s %s\n" msgstr "" -#: cmdline/apt-cache.cc:1659 +#: cmdline/apt-cache.cc:1721 msgid "" "Usage: apt-cache [options] command\n" " apt-cache [options] add file1 [file2 ...]\n" @@ -243,8 +251,7 @@ msgid "" " -o=? Set an arbitrary configuration option, eg -o dir::cache=/tmp\n" msgstr "" -#: cmdline/apt-extracttemplates.cc:267 apt-pkg/pkgcachegen.cc:714 -#: apt-pkg/pkgcachegen.cc:819 +#: cmdline/apt-extracttemplates.cc:267 apt-pkg/pkgcachegen.cc:819 #, c-format msgid "Unable to write to %s" msgstr "" @@ -253,301 +260,11 @@ msgstr "" msgid "Cannot get debconf version. Is debconf installed?" msgstr "" -#: ftparchive/apt-ftparchive.cc:167 ftparchive/apt-ftparchive.cc:341 -msgid "Package extension list is too long" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:169 ftparchive/apt-ftparchive.cc:183 -#: ftparchive/apt-ftparchive.cc:206 ftparchive/apt-ftparchive.cc:256 -#: ftparchive/apt-ftparchive.cc:270 ftparchive/apt-ftparchive.cc:292 -#, c-format -msgid "Error processing directory %s" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:254 -msgid "Source extension list is too long" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:371 -msgid "Error writing header to contents file" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:401 -#, c-format -msgid "Error processing contents %s" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:556 -msgid "" -"Usage: apt-ftparchive [options] command\n" -"Commands: packages binarypath [overridefile [pathprefix]]\n" -" sources srcpath [overridefile [pathprefix]]\n" -" contents path\n" -" release path\n" -" generate config [groups]\n" -" clean config\n" -"\n" -"apt-ftparchive generates index files for Debian archives. It supports\n" -"many styles of generation from fully automated to functional replacements\n" -"for dpkg-scanpackages and dpkg-scansources\n" -"\n" -"apt-ftparchive generates Package files from a tree of .debs. The\n" -"Package file contains the contents of all the control fields from\n" -"each package as well as the MD5 hash and filesize. An override file\n" -"is supported to force the value of Priority and Section.\n" -"\n" -"Similarly apt-ftparchive generates Sources files from a tree of .dscs.\n" -"The --source-override option can be used to specify a src override file\n" -"\n" -"The 'packages' and 'sources' command should be run in the root of the\n" -"tree. BinaryPath should point to the base of the recursive search and \n" -"override file should contain the override flags. Pathprefix is\n" -"appended to the filename fields if present. Example usage from the \n" -"Debian archive:\n" -" apt-ftparchive packages dists/potato/main/binary-i386/ > \\\n" -" dists/potato/main/binary-i386/Packages\n" -"\n" -"Options:\n" -" -h This help text\n" -" --md5 Control MD5 generation\n" -" -s=? Source override file\n" -" -q Quiet\n" -" -d=? Select the optional caching database\n" -" --no-delink Enable delinking debug mode\n" -" --contents Control contents file generation\n" -" -c=? Read this configuration file\n" -" -o=? Set an arbitrary configuration option" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:762 -msgid "No selections matched" -msgstr "" - -#: ftparchive/apt-ftparchive.cc:835 -#, c-format -msgid "Some files are missing in the package file group `%s'" -msgstr "" - -#: ftparchive/cachedb.cc:47 -#, c-format -msgid "DB was corrupted, file renamed to %s.old" -msgstr "" - -#: ftparchive/cachedb.cc:65 -#, c-format -msgid "DB is old, attempting to upgrade %s" -msgstr "" - -#: ftparchive/cachedb.cc:76 -msgid "" -"DB format is invalid. If you upgraded from a older version of apt, please " -"remove and re-create the database." -msgstr "" - -#: ftparchive/cachedb.cc:81 -#, c-format -msgid "Unable to open DB file %s: %s" -msgstr "" - -#: ftparchive/cachedb.cc:127 apt-inst/extract.cc:181 apt-inst/extract.cc:193 -#: apt-inst/extract.cc:210 apt-inst/deb/dpkgdb.cc:121 methods/gpgv.cc:272 -#, c-format -msgid "Failed to stat %s" -msgstr "" - -#: ftparchive/cachedb.cc:242 -msgid "Archive has no control record" -msgstr "" - -#: ftparchive/cachedb.cc:448 -msgid "Unable to get a cursor" -msgstr "" - -#: ftparchive/writer.cc:79 -#, c-format -msgid "W: Unable to read directory %s\n" -msgstr "" - -#: ftparchive/writer.cc:84 -#, c-format -msgid "W: Unable to stat %s\n" -msgstr "" - -#: ftparchive/writer.cc:135 -msgid "E: " -msgstr "" - -#: ftparchive/writer.cc:137 -msgid "W: " -msgstr "" - -#: ftparchive/writer.cc:144 -msgid "E: Errors apply to file " -msgstr "" - -#: ftparchive/writer.cc:161 ftparchive/writer.cc:191 -#, c-format -msgid "Failed to resolve %s" -msgstr "" - -#: ftparchive/writer.cc:173 -msgid "Tree walking failed" -msgstr "" - -#: ftparchive/writer.cc:198 -#, c-format -msgid "Failed to open %s" -msgstr "" - -#: ftparchive/writer.cc:257 -#, c-format -msgid " DeLink %s [%s]\n" -msgstr "" - -#: ftparchive/writer.cc:265 -#, c-format -msgid "Failed to readlink %s" -msgstr "" - -#: ftparchive/writer.cc:269 -#, c-format -msgid "Failed to unlink %s" -msgstr "" - -#: ftparchive/writer.cc:276 -#, c-format -msgid "*** Failed to link %s to %s" -msgstr "" - -#: ftparchive/writer.cc:286 -#, c-format -msgid " DeLink limit of %sB hit.\n" -msgstr "" - -#: ftparchive/writer.cc:390 -msgid "Archive had no package field" -msgstr "" - -#: ftparchive/writer.cc:398 ftparchive/writer.cc:613 -#, c-format -msgid " %s has no override entry\n" -msgstr "" - -#: ftparchive/writer.cc:443 ftparchive/writer.cc:701 -#, c-format -msgid " %s maintainer is %s not %s\n" -msgstr "" - -#: ftparchive/writer.cc:623 -#, c-format -msgid " %s has no source override entry\n" -msgstr "" - -#: ftparchive/writer.cc:627 -#, c-format -msgid " %s has no binary override entry either\n" -msgstr "" - -#: ftparchive/contents.cc:317 -#, c-format -msgid "Internal error, could not locate member %s" -msgstr "" - -#: ftparchive/contents.cc:353 ftparchive/contents.cc:384 -msgid "realloc - Failed to allocate memory" -msgstr "" - -#: ftparchive/override.cc:38 ftparchive/override.cc:146 -#, c-format -msgid "Unable to open %s" -msgstr "" - -#: ftparchive/override.cc:64 ftparchive/override.cc:170 -#, c-format -msgid "Malformed override %s line %lu #1" -msgstr "" - -#: ftparchive/override.cc:78 ftparchive/override.cc:182 -#, c-format -msgid "Malformed override %s line %lu #2" -msgstr "" - -#: ftparchive/override.cc:92 ftparchive/override.cc:195 -#, c-format -msgid "Malformed override %s line %lu #3" -msgstr "" - -#: ftparchive/override.cc:131 ftparchive/override.cc:205 -#, c-format -msgid "Failed to read the override file %s" -msgstr "" - -#: ftparchive/multicompress.cc:75 -#, c-format -msgid "Unknown compression algorithm '%s'" -msgstr "" - -#: ftparchive/multicompress.cc:105 -#, c-format -msgid "Compressed output %s needs a compression set" -msgstr "" - -#: ftparchive/multicompress.cc:172 methods/rsh.cc:91 -msgid "Failed to create IPC pipe to subprocess" -msgstr "" - -#: ftparchive/multicompress.cc:198 -msgid "Failed to create FILE*" -msgstr "" - -#: ftparchive/multicompress.cc:201 -msgid "Failed to fork" -msgstr "" - -#: ftparchive/multicompress.cc:215 -msgid "Compress child" -msgstr "" - -#: ftparchive/multicompress.cc:238 -#, c-format -msgid "Internal error, failed to create %s" -msgstr "" - -#: ftparchive/multicompress.cc:289 -msgid "Failed to create subprocess IPC" -msgstr "" - -#: ftparchive/multicompress.cc:324 -msgid "Failed to exec compressor " -msgstr "" - -#: ftparchive/multicompress.cc:363 -msgid "decompressor" -msgstr "" - -#: ftparchive/multicompress.cc:406 -msgid "IO to subprocess/file failed" -msgstr "" - -#: ftparchive/multicompress.cc:458 -msgid "Failed to read while computing MD5" -msgstr "" - -#: ftparchive/multicompress.cc:475 -#, c-format -msgid "Problem unlinking %s" -msgstr "" - -#: ftparchive/multicompress.cc:490 apt-inst/extract.cc:188 -#, c-format -msgid "Failed to rename %s to %s" -msgstr "" - #: cmdline/apt-get.cc:121 msgid "Y" msgstr "" -#: cmdline/apt-get.cc:143 cmdline/apt-get.cc:1574 +#: cmdline/apt-get.cc:143 cmdline/apt-get.cc:1588 #, c-format msgid "Regex compilation error - %s" msgstr "" @@ -646,118 +363,118 @@ msgstr "" msgid "%lu not fully installed or removed.\n" msgstr "" -#: cmdline/apt-get.cc:650 +#: cmdline/apt-get.cc:664 msgid "Correcting dependencies..." msgstr "" -#: cmdline/apt-get.cc:653 +#: cmdline/apt-get.cc:667 msgid " failed." msgstr "" -#: cmdline/apt-get.cc:656 +#: cmdline/apt-get.cc:670 msgid "Unable to correct dependencies" msgstr "" -#: cmdline/apt-get.cc:659 +#: cmdline/apt-get.cc:673 msgid "Unable to minimize the upgrade set" msgstr "" -#: cmdline/apt-get.cc:661 +#: cmdline/apt-get.cc:675 msgid " Done" msgstr "" -#: cmdline/apt-get.cc:665 +#: cmdline/apt-get.cc:679 msgid "You might want to run `apt-get -f install' to correct these." msgstr "" -#: cmdline/apt-get.cc:668 +#: cmdline/apt-get.cc:682 msgid "Unmet dependencies. Try using -f." msgstr "" -#: cmdline/apt-get.cc:690 +#: cmdline/apt-get.cc:704 msgid "WARNING: The following packages cannot be authenticated!" msgstr "" -#: cmdline/apt-get.cc:694 +#: cmdline/apt-get.cc:708 msgid "Authentication warning overridden.\n" msgstr "" -#: cmdline/apt-get.cc:701 +#: cmdline/apt-get.cc:715 msgid "Install these packages without verification [y/N]? " msgstr "" -#: cmdline/apt-get.cc:703 +#: cmdline/apt-get.cc:717 msgid "Some packages could not be authenticated" msgstr "" -#: cmdline/apt-get.cc:712 cmdline/apt-get.cc:859 +#: cmdline/apt-get.cc:726 cmdline/apt-get.cc:873 msgid "There are problems and -y was used without --force-yes" msgstr "" -#: cmdline/apt-get.cc:756 +#: cmdline/apt-get.cc:770 msgid "Internal error, InstallPackages was called with broken packages!" msgstr "" -#: cmdline/apt-get.cc:765 +#: cmdline/apt-get.cc:779 msgid "Packages need to be removed but remove is disabled." msgstr "" -#: cmdline/apt-get.cc:776 +#: cmdline/apt-get.cc:790 msgid "Internal error, Ordering didn't finish" msgstr "" -#: cmdline/apt-get.cc:792 cmdline/apt-get.cc:1893 cmdline/apt-get.cc:1926 +#: cmdline/apt-get.cc:806 cmdline/apt-get.cc:1907 cmdline/apt-get.cc:1940 msgid "Unable to lock the download directory" msgstr "" -#: cmdline/apt-get.cc:802 cmdline/apt-get.cc:1974 cmdline/apt-get.cc:2210 +#: cmdline/apt-get.cc:816 cmdline/apt-get.cc:1988 cmdline/apt-get.cc:2224 #: apt-pkg/cachefile.cc:67 msgid "The list of sources could not be read." msgstr "" -#: cmdline/apt-get.cc:817 +#: cmdline/apt-get.cc:831 msgid "How odd.. The sizes didn't match, email apt@packages.debian.org" msgstr "" -#: cmdline/apt-get.cc:822 +#: cmdline/apt-get.cc:836 #, c-format msgid "Need to get %sB/%sB of archives.\n" msgstr "" -#: cmdline/apt-get.cc:825 +#: cmdline/apt-get.cc:839 #, c-format msgid "Need to get %sB of archives.\n" msgstr "" -#: cmdline/apt-get.cc:830 +#: cmdline/apt-get.cc:844 #, c-format msgid "After unpacking %sB of additional disk space will be used.\n" msgstr "" -#: cmdline/apt-get.cc:833 +#: cmdline/apt-get.cc:847 #, c-format msgid "After unpacking %sB disk space will be freed.\n" msgstr "" -#: cmdline/apt-get.cc:847 cmdline/apt-get.cc:2064 +#: cmdline/apt-get.cc:861 cmdline/apt-get.cc:2078 #, c-format msgid "Couldn't determine free space in %s" msgstr "" -#: cmdline/apt-get.cc:850 +#: cmdline/apt-get.cc:864 #, c-format msgid "You don't have enough free space in %s." msgstr "" -#: cmdline/apt-get.cc:865 cmdline/apt-get.cc:885 +#: cmdline/apt-get.cc:879 cmdline/apt-get.cc:899 msgid "Trivial Only specified but this is not a trivial operation." msgstr "" -#: cmdline/apt-get.cc:867 +#: cmdline/apt-get.cc:881 msgid "Yes, do as I say!" msgstr "" -#: cmdline/apt-get.cc:869 +#: cmdline/apt-get.cc:883 #, c-format msgid "" "You are about to do something potentially harmful.\n" @@ -765,74 +482,74 @@ msgid "" " ?] " msgstr "" -#: cmdline/apt-get.cc:875 cmdline/apt-get.cc:894 +#: cmdline/apt-get.cc:889 cmdline/apt-get.cc:908 msgid "Abort." msgstr "" -#: cmdline/apt-get.cc:890 +#: cmdline/apt-get.cc:904 msgid "Do you want to continue [Y/n]? " msgstr "" -#: cmdline/apt-get.cc:962 cmdline/apt-get.cc:1369 cmdline/apt-get.cc:2107 +#: cmdline/apt-get.cc:976 cmdline/apt-get.cc:1383 cmdline/apt-get.cc:2121 #, c-format msgid "Failed to fetch %s %s\n" msgstr "" -#: cmdline/apt-get.cc:980 +#: cmdline/apt-get.cc:994 msgid "Some files failed to download" msgstr "" -#: cmdline/apt-get.cc:981 cmdline/apt-get.cc:2116 +#: cmdline/apt-get.cc:995 cmdline/apt-get.cc:2130 msgid "Download complete and in download only mode" msgstr "" -#: cmdline/apt-get.cc:987 +#: cmdline/apt-get.cc:1001 msgid "" "Unable to fetch some archives, maybe run apt-get update or try with --fix-" "missing?" msgstr "" -#: cmdline/apt-get.cc:991 +#: cmdline/apt-get.cc:1005 msgid "--fix-missing and media swapping is not currently supported" msgstr "" -#: cmdline/apt-get.cc:996 +#: cmdline/apt-get.cc:1010 msgid "Unable to correct missing packages." msgstr "" -#: cmdline/apt-get.cc:997 +#: cmdline/apt-get.cc:1011 msgid "Aborting install." msgstr "" -#: cmdline/apt-get.cc:1031 +#: cmdline/apt-get.cc:1045 #, c-format msgid "Note, selecting %s instead of %s\n" msgstr "" -#: cmdline/apt-get.cc:1041 +#: cmdline/apt-get.cc:1055 #, c-format msgid "Skipping %s, it is already installed and upgrade is not set.\n" msgstr "" -#: cmdline/apt-get.cc:1059 +#: cmdline/apt-get.cc:1073 #, c-format msgid "Package %s is not installed, so not removed\n" msgstr "" -#: cmdline/apt-get.cc:1070 +#: cmdline/apt-get.cc:1084 #, c-format msgid "Package %s is a virtual package provided by:\n" msgstr "" -#: cmdline/apt-get.cc:1082 +#: cmdline/apt-get.cc:1096 msgid " [Installed]" msgstr "" -#: cmdline/apt-get.cc:1087 +#: cmdline/apt-get.cc:1101 msgid "You should explicitly select one to install." msgstr "" -#: cmdline/apt-get.cc:1092 +#: cmdline/apt-get.cc:1106 #, c-format msgid "" "Package %s is not available, but is referred to by another package.\n" @@ -840,97 +557,97 @@ msgid "" "is only available from another source\n" msgstr "" -#: cmdline/apt-get.cc:1111 +#: cmdline/apt-get.cc:1125 msgid "However the following packages replace it:" msgstr "" -#: cmdline/apt-get.cc:1114 +#: cmdline/apt-get.cc:1128 #, c-format msgid "Package %s has no installation candidate" msgstr "" -#: cmdline/apt-get.cc:1134 +#: cmdline/apt-get.cc:1148 #, c-format msgid "Reinstallation of %s is not possible, it cannot be downloaded.\n" msgstr "" -#: cmdline/apt-get.cc:1142 +#: cmdline/apt-get.cc:1156 #, c-format msgid "%s is already the newest version.\n" msgstr "" -#: cmdline/apt-get.cc:1171 +#: cmdline/apt-get.cc:1185 #, c-format msgid "Release '%s' for '%s' was not found" msgstr "" -#: cmdline/apt-get.cc:1173 +#: cmdline/apt-get.cc:1187 #, c-format msgid "Version '%s' for '%s' was not found" msgstr "" -#: cmdline/apt-get.cc:1179 +#: cmdline/apt-get.cc:1193 #, c-format msgid "Selected version %s (%s) for %s\n" msgstr "" -#: cmdline/apt-get.cc:1316 +#: cmdline/apt-get.cc:1330 msgid "The update command takes no arguments" msgstr "" -#: cmdline/apt-get.cc:1329 +#: cmdline/apt-get.cc:1343 msgid "Unable to lock the list directory" msgstr "" -#: cmdline/apt-get.cc:1396 cmdline/apt-get.cc:1398 +#: cmdline/apt-get.cc:1410 cmdline/apt-get.cc:1412 msgid "" "Some index files failed to download, they have been ignored, or old ones " "used instead." msgstr "" -#: cmdline/apt-get.cc:1412 +#: cmdline/apt-get.cc:1426 msgid "We are not supposed to delete stuff, can't start AutoRemover" msgstr "" -#: cmdline/apt-get.cc:1437 +#: cmdline/apt-get.cc:1451 msgid "" "Hmm, seems like the AutoRemover destroyed something which really\n" "shouldn't happen. Please file a bug report against apt." msgstr "" -#: cmdline/apt-get.cc:1440 cmdline/apt-get.cc:1642 +#: cmdline/apt-get.cc:1454 cmdline/apt-get.cc:1656 msgid "The following information may help to resolve the situation:" msgstr "" -#: cmdline/apt-get.cc:1444 +#: cmdline/apt-get.cc:1458 msgid "Internal Error, AutoRemover broke stuff" msgstr "" -#: cmdline/apt-get.cc:1463 +#: cmdline/apt-get.cc:1477 msgid "Internal error, AllUpgrade broke stuff" msgstr "" -#: cmdline/apt-get.cc:1561 cmdline/apt-get.cc:1597 +#: cmdline/apt-get.cc:1575 cmdline/apt-get.cc:1611 #, c-format msgid "Couldn't find package %s" msgstr "" -#: cmdline/apt-get.cc:1584 +#: cmdline/apt-get.cc:1598 #, c-format msgid "Note, selecting %s for regex '%s'\n" msgstr "" -#: cmdline/apt-get.cc:1614 +#: cmdline/apt-get.cc:1628 msgid "You might want to run `apt-get -f install' to correct these:" msgstr "" -#: cmdline/apt-get.cc:1617 +#: cmdline/apt-get.cc:1631 msgid "" "Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a " "solution)." msgstr "" -#: cmdline/apt-get.cc:1629 +#: cmdline/apt-get.cc:1643 msgid "" "Some packages could not be installed. This may mean that you have\n" "requested an impossible situation or if you are using the unstable\n" @@ -938,159 +655,159 @@ msgid "" "or been moved out of Incoming." msgstr "" -#: cmdline/apt-get.cc:1637 +#: cmdline/apt-get.cc:1651 msgid "" "Since you only requested a single operation it is extremely likely that\n" "the package is simply not installable and a bug report against\n" "that package should be filed." msgstr "" -#: cmdline/apt-get.cc:1645 +#: cmdline/apt-get.cc:1659 msgid "Broken packages" msgstr "" -#: cmdline/apt-get.cc:1676 +#: cmdline/apt-get.cc:1690 msgid "The following extra packages will be installed:" msgstr "" -#: cmdline/apt-get.cc:1765 +#: cmdline/apt-get.cc:1779 msgid "Suggested packages:" msgstr "" -#: cmdline/apt-get.cc:1766 +#: cmdline/apt-get.cc:1780 msgid "Recommended packages:" msgstr "" -#: cmdline/apt-get.cc:1786 +#: cmdline/apt-get.cc:1800 msgid "Calculating upgrade... " msgstr "" -#: cmdline/apt-get.cc:1789 methods/ftp.cc:702 methods/connect.cc:101 +#: cmdline/apt-get.cc:1803 methods/ftp.cc:702 methods/connect.cc:101 msgid "Failed" msgstr "" -#: cmdline/apt-get.cc:1794 +#: cmdline/apt-get.cc:1808 msgid "Done" msgstr "" -#: cmdline/apt-get.cc:1861 cmdline/apt-get.cc:1869 +#: cmdline/apt-get.cc:1875 cmdline/apt-get.cc:1883 msgid "Internal error, problem resolver broke stuff" msgstr "" -#: cmdline/apt-get.cc:1969 +#: cmdline/apt-get.cc:1983 msgid "Must specify at least one package to fetch source for" msgstr "" -#: cmdline/apt-get.cc:1999 cmdline/apt-get.cc:2228 +#: cmdline/apt-get.cc:2013 cmdline/apt-get.cc:2242 #, c-format msgid "Unable to find a source package for %s" msgstr "" -#: cmdline/apt-get.cc:2043 +#: cmdline/apt-get.cc:2057 #, c-format msgid "Skipping already downloaded file '%s'\n" msgstr "" -#: cmdline/apt-get.cc:2067 +#: cmdline/apt-get.cc:2081 #, c-format msgid "You don't have enough free space in %s" msgstr "" -#: cmdline/apt-get.cc:2072 +#: cmdline/apt-get.cc:2086 #, c-format msgid "Need to get %sB/%sB of source archives.\n" msgstr "" -#: cmdline/apt-get.cc:2075 +#: cmdline/apt-get.cc:2089 #, c-format msgid "Need to get %sB of source archives.\n" msgstr "" -#: cmdline/apt-get.cc:2081 +#: cmdline/apt-get.cc:2095 #, c-format msgid "Fetch source %s\n" msgstr "" -#: cmdline/apt-get.cc:2112 +#: cmdline/apt-get.cc:2126 msgid "Failed to fetch some archives." msgstr "" -#: cmdline/apt-get.cc:2140 +#: cmdline/apt-get.cc:2154 #, c-format msgid "Skipping unpack of already unpacked source in %s\n" msgstr "" -#: cmdline/apt-get.cc:2152 +#: cmdline/apt-get.cc:2166 #, c-format msgid "Unpack command '%s' failed.\n" msgstr "" -#: cmdline/apt-get.cc:2153 +#: cmdline/apt-get.cc:2167 #, c-format msgid "Check if the 'dpkg-dev' package is installed.\n" msgstr "" -#: cmdline/apt-get.cc:2170 +#: cmdline/apt-get.cc:2184 #, c-format msgid "Build command '%s' failed.\n" msgstr "" -#: cmdline/apt-get.cc:2189 +#: cmdline/apt-get.cc:2203 msgid "Child process failed" msgstr "" -#: cmdline/apt-get.cc:2205 +#: cmdline/apt-get.cc:2219 msgid "Must specify at least one package to check builddeps for" msgstr "" -#: cmdline/apt-get.cc:2233 +#: cmdline/apt-get.cc:2247 #, c-format msgid "Unable to get build-dependency information for %s" msgstr "" -#: cmdline/apt-get.cc:2253 +#: cmdline/apt-get.cc:2267 #, c-format msgid "%s has no build depends.\n" msgstr "" -#: cmdline/apt-get.cc:2305 +#: cmdline/apt-get.cc:2319 #, c-format msgid "" "%s dependency for %s cannot be satisfied because the package %s cannot be " "found" msgstr "" -#: cmdline/apt-get.cc:2357 +#: cmdline/apt-get.cc:2371 #, c-format msgid "" "%s dependency for %s cannot be satisfied because no available versions of " "package %s can satisfy version requirements" msgstr "" -#: cmdline/apt-get.cc:2392 +#: cmdline/apt-get.cc:2406 #, c-format msgid "Failed to satisfy %s dependency for %s: Installed package %s is too new" msgstr "" -#: cmdline/apt-get.cc:2417 +#: cmdline/apt-get.cc:2431 #, c-format msgid "Failed to satisfy %s dependency for %s: %s" msgstr "" -#: cmdline/apt-get.cc:2431 +#: cmdline/apt-get.cc:2445 #, c-format msgid "Build-dependencies for %s could not be satisfied." msgstr "" -#: cmdline/apt-get.cc:2435 +#: cmdline/apt-get.cc:2449 msgid "Failed to process build dependencies" msgstr "" -#: cmdline/apt-get.cc:2467 +#: cmdline/apt-get.cc:2481 msgid "Supported modules:" msgstr "" -#: cmdline/apt-get.cc:2508 +#: cmdline/apt-get.cc:2522 msgid "" "Usage: apt-get [options] command\n" " apt-get [options] install|remove pkg1 [pkg2 ...]\n" @@ -1320,6 +1037,17 @@ msgstr "" msgid "The diversion path is too long" msgstr "" +#: apt-inst/extract.cc:181 apt-inst/extract.cc:193 apt-inst/extract.cc:210 +#: apt-inst/deb/dpkgdb.cc:121 methods/gpgv.cc:272 +#, c-format +msgid "Failed to stat %s" +msgstr "" + +#: apt-inst/extract.cc:188 +#, c-format +msgid "Failed to rename %s to %s" +msgstr "" + #: apt-inst/extract.cc:243 #, c-format msgid "The directory %s is being replaced by a non-directory" @@ -1375,9 +1103,7 @@ msgid "The info and temp directories need to be on the same filesystem" msgstr "" #. Build the status cache -#: apt-inst/deb/dpkgdb.cc:139 apt-pkg/pkgcachegen.cc:647 -#: apt-pkg/pkgcachegen.cc:716 apt-pkg/pkgcachegen.cc:721 -#: apt-pkg/pkgcachegen.cc:844 apt-pkg/pkgcachegen.cc:752 +#: apt-inst/deb/dpkgdb.cc:139 apt-pkg/pkgcachegen.cc:752 #: apt-pkg/pkgcachegen.cc:821 apt-pkg/pkgcachegen.cc:826 #: apt-pkg/pkgcachegen.cc:949 msgid "Reading package lists" @@ -1851,7 +1577,7 @@ msgstr "" msgid "Couldn't make mmap of %lu bytes" msgstr "" -#: apt-pkg/contrib/strutl.cc:938 apt-pkg/contrib/strutl.cc:981 +#: apt-pkg/contrib/strutl.cc:981 #, c-format msgid "Selection %s not found" msgstr "" @@ -2048,72 +1774,76 @@ msgstr "" msgid "Problem syncing the file" msgstr "" -#: apt-pkg/pkgcache.cc:126 apt-pkg/pkgcache.cc:137 +#: apt-pkg/pkgcache.cc:137 msgid "Empty package cache" msgstr "" -#: apt-pkg/pkgcache.cc:132 apt-pkg/pkgcache.cc:143 +#: apt-pkg/pkgcache.cc:143 msgid "The package cache file is corrupted" msgstr "" -#: apt-pkg/pkgcache.cc:137 apt-pkg/pkgcache.cc:148 +#: apt-pkg/pkgcache.cc:148 msgid "The package cache file is an incompatible version" msgstr "" -#: apt-pkg/pkgcache.cc:142 apt-pkg/pkgcache.cc:153 +#: apt-pkg/pkgcache.cc:153 #, c-format msgid "This APT does not support the versioning system '%s'" msgstr "" -#: apt-pkg/pkgcache.cc:147 apt-pkg/pkgcache.cc:158 +#: apt-pkg/pkgcache.cc:158 msgid "The package cache was built for a different architecture" msgstr "" -#: apt-pkg/pkgcache.cc:218 apt-pkg/pkgcache.cc:229 +#: apt-pkg/pkgcache.cc:229 msgid "Depends" msgstr "" -#: apt-pkg/pkgcache.cc:218 apt-pkg/pkgcache.cc:229 +#: apt-pkg/pkgcache.cc:229 msgid "PreDepends" msgstr "" -#: apt-pkg/pkgcache.cc:218 apt-pkg/pkgcache.cc:229 +#: apt-pkg/pkgcache.cc:229 msgid "Suggests" msgstr "" -#: apt-pkg/pkgcache.cc:219 apt-pkg/pkgcache.cc:230 +#: apt-pkg/pkgcache.cc:230 msgid "Recommends" msgstr "" -#: apt-pkg/pkgcache.cc:219 apt-pkg/pkgcache.cc:230 +#: apt-pkg/pkgcache.cc:230 msgid "Conflicts" msgstr "" -#: apt-pkg/pkgcache.cc:219 apt-pkg/pkgcache.cc:230 +#: apt-pkg/pkgcache.cc:230 msgid "Replaces" msgstr "" -#: apt-pkg/pkgcache.cc:220 apt-pkg/pkgcache.cc:231 +#: apt-pkg/pkgcache.cc:231 msgid "Obsoletes" msgstr "" -#: apt-pkg/pkgcache.cc:231 apt-pkg/pkgcache.cc:242 +#: apt-pkg/pkgcache.cc:231 +msgid "Breaks" +msgstr "" + +#: apt-pkg/pkgcache.cc:242 msgid "important" msgstr "" -#: apt-pkg/pkgcache.cc:231 apt-pkg/pkgcache.cc:242 +#: apt-pkg/pkgcache.cc:242 msgid "required" msgstr "" -#: apt-pkg/pkgcache.cc:231 apt-pkg/pkgcache.cc:242 +#: apt-pkg/pkgcache.cc:242 msgid "standard" msgstr "" -#: apt-pkg/pkgcache.cc:232 apt-pkg/pkgcache.cc:243 +#: apt-pkg/pkgcache.cc:243 msgid "optional" msgstr "" -#: apt-pkg/pkgcache.cc:232 apt-pkg/pkgcache.cc:243 +#: apt-pkg/pkgcache.cc:243 msgid "extra" msgstr "" @@ -2183,7 +1913,7 @@ msgstr "" msgid "Opening %s" msgstr "" -#: apt-pkg/sourcelist.cc:220 apt-pkg/cdrom.cc:426 apt-pkg/cdrom.cc:450 +#: apt-pkg/sourcelist.cc:220 apt-pkg/cdrom.cc:450 #, c-format msgid "Line %u too long in source list %s." msgstr "" @@ -2216,19 +1946,19 @@ msgstr "" msgid "Index file type '%s' is not supported" msgstr "" -#: apt-pkg/algorithms.cc:245 +#: apt-pkg/algorithms.cc:248 #, c-format msgid "" "The package %s needs to be reinstalled, but I can't find an archive for it." msgstr "" -#: apt-pkg/algorithms.cc:1075 +#: apt-pkg/algorithms.cc:1096 msgid "" "Error, pkgProblemResolver::Resolve generated breaks, this may be caused by " "held packages." msgstr "" -#: apt-pkg/algorithms.cc:1077 +#: apt-pkg/algorithms.cc:1098 msgid "Unable to correct problems, you have held broken packages." msgstr "" @@ -2269,12 +1999,12 @@ msgstr "" msgid "Please insert the disc labeled: '%s' in the drive '%s' and press enter." msgstr "" -#: apt-pkg/init.cc:122 apt-pkg/init.cc:125 +#: apt-pkg/init.cc:125 #, c-format msgid "Packaging system '%s' is not supported" msgstr "" -#: apt-pkg/init.cc:138 apt-pkg/init.cc:141 +#: apt-pkg/init.cc:141 msgid "Unable to determine a suitable packaging system type" msgstr "" @@ -2317,73 +2047,86 @@ msgstr "" msgid "Error occurred while processing %s (NewPackage)" msgstr "" -#: apt-pkg/pkgcachegen.cc:131 apt-pkg/pkgcachegen.cc:134 +#: apt-pkg/pkgcachegen.cc:134 #, c-format msgid "Error occurred while processing %s (UsePackage1)" msgstr "" -#: apt-pkg/pkgcachegen.cc:152 apt-pkg/pkgcachegen.cc:182 +#: apt-pkg/pkgcachegen.cc:157 +#, c-format +msgid "Error occured while processing %s (NewFileDesc1)" +msgstr "" + +#: apt-pkg/pkgcachegen.cc:182 #, c-format msgid "Error occurred while processing %s (UsePackage2)" msgstr "" -#: apt-pkg/pkgcachegen.cc:156 apt-pkg/pkgcachegen.cc:186 +#: apt-pkg/pkgcachegen.cc:186 #, c-format msgid "Error occurred while processing %s (NewFileVer1)" msgstr "" -#: apt-pkg/pkgcachegen.cc:186 apt-pkg/pkgcachegen.cc:217 +#: apt-pkg/pkgcachegen.cc:217 #, c-format msgid "Error occurred while processing %s (NewVersion1)" msgstr "" -#: apt-pkg/pkgcachegen.cc:190 apt-pkg/pkgcachegen.cc:221 +#: apt-pkg/pkgcachegen.cc:221 #, c-format msgid "Error occurred while processing %s (UsePackage3)" msgstr "" -#: apt-pkg/pkgcachegen.cc:194 apt-pkg/pkgcachegen.cc:225 +#: apt-pkg/pkgcachegen.cc:225 #, c-format msgid "Error occurred while processing %s (NewVersion2)" msgstr "" -#: apt-pkg/pkgcachegen.cc:209 apt-pkg/pkgcachegen.cc:255 +#: apt-pkg/pkgcachegen.cc:249 +#, c-format +msgid "Error occured while processing %s (NewFileDesc2)" +msgstr "" + +#: apt-pkg/pkgcachegen.cc:255 msgid "Wow, you exceeded the number of package names this APT is capable of." msgstr "" -#: apt-pkg/pkgcachegen.cc:212 apt-pkg/pkgcachegen.cc:258 +#: apt-pkg/pkgcachegen.cc:258 msgid "Wow, you exceeded the number of versions this APT is capable of." msgstr "" -#: apt-pkg/pkgcachegen.cc:215 apt-pkg/pkgcachegen.cc:264 +#: apt-pkg/pkgcachegen.cc:261 +msgid "Wow, you exceeded the number of descriptions this APT is capable of." +msgstr "" + +#: apt-pkg/pkgcachegen.cc:264 msgid "Wow, you exceeded the number of dependencies this APT is capable of." msgstr "" -#: apt-pkg/pkgcachegen.cc:243 apt-pkg/pkgcachegen.cc:292 +#: apt-pkg/pkgcachegen.cc:292 #, c-format msgid "Error occurred while processing %s (FindPkg)" msgstr "" -#: apt-pkg/pkgcachegen.cc:256 apt-pkg/pkgcachegen.cc:305 +#: apt-pkg/pkgcachegen.cc:305 #, c-format msgid "Error occurred while processing %s (CollectFileProvides)" msgstr "" -#: apt-pkg/pkgcachegen.cc:262 apt-pkg/pkgcachegen.cc:311 +#: apt-pkg/pkgcachegen.cc:311 #, c-format msgid "Package %s %s was not found while processing file dependencies" msgstr "" -#: apt-pkg/pkgcachegen.cc:577 apt-pkg/pkgcachegen.cc:682 +#: apt-pkg/pkgcachegen.cc:682 #, c-format msgid "Couldn't stat source package list %s" msgstr "" -#: apt-pkg/pkgcachegen.cc:662 apt-pkg/pkgcachegen.cc:767 +#: apt-pkg/pkgcachegen.cc:767 msgid "Collecting File Provides" msgstr "" -#: apt-pkg/pkgcachegen.cc:789 apt-pkg/pkgcachegen.cc:796 #: apt-pkg/pkgcachegen.cc:894 apt-pkg/pkgcachegen.cc:901 msgid "IO Error saving source cache" msgstr "" @@ -2393,36 +2136,35 @@ msgstr "" msgid "rename failed, %s (%s -> %s)." msgstr "" -#: apt-pkg/acquire-item.cc:236 apt-pkg/acquire-item.cc:951 -#: apt-pkg/acquire-item.cc:980 +#: apt-pkg/acquire-item.cc:236 apt-pkg/acquire-item.cc:980 msgid "MD5Sum mismatch" msgstr "" -#: apt-pkg/acquire-item.cc:646 apt-pkg/acquire-item.cc:675 +#: apt-pkg/acquire-item.cc:675 msgid "There are no public key available for the following key IDs:\n" msgstr "" -#: apt-pkg/acquire-item.cc:759 apt-pkg/acquire-item.cc:788 +#: apt-pkg/acquire-item.cc:788 #, c-format msgid "" "I wasn't able to locate a file for the %s package. This might mean you need " "to manually fix this package. (due to missing arch)" msgstr "" -#: apt-pkg/acquire-item.cc:818 apt-pkg/acquire-item.cc:847 +#: apt-pkg/acquire-item.cc:847 #, c-format msgid "" "I wasn't able to locate file for the %s package. This might mean you need to " "manually fix this package." msgstr "" -#: apt-pkg/acquire-item.cc:854 apt-pkg/acquire-item.cc:883 +#: apt-pkg/acquire-item.cc:883 #, c-format msgid "" "The package index files are corrupted. No Filename: field for package %s." msgstr "" -#: apt-pkg/acquire-item.cc:941 apt-pkg/acquire-item.cc:970 +#: apt-pkg/acquire-item.cc:970 msgid "Size mismatch" msgstr "" @@ -2431,93 +2173,94 @@ msgstr "" msgid "Vendor block %s contains no fingerprint" msgstr "" -#: apt-pkg/cdrom.cc:507 apt-pkg/cdrom.cc:531 +#: apt-pkg/cdrom.cc:531 #, c-format msgid "" "Using CD-ROM mount point %s\n" "Mounting CD-ROM\n" msgstr "" -#: apt-pkg/cdrom.cc:516 apt-pkg/cdrom.cc:598 apt-pkg/cdrom.cc:540 -#: apt-pkg/cdrom.cc:622 +#: apt-pkg/cdrom.cc:540 apt-pkg/cdrom.cc:622 msgid "Identifying.. " msgstr "" -#: apt-pkg/cdrom.cc:541 apt-pkg/cdrom.cc:565 +#: apt-pkg/cdrom.cc:565 #, c-format msgid "Stored label: %s \n" msgstr "" -#: apt-pkg/cdrom.cc:561 apt-pkg/cdrom.cc:585 +#: apt-pkg/cdrom.cc:585 #, c-format msgid "Using CD-ROM mount point %s\n" msgstr "" -#: apt-pkg/cdrom.cc:579 apt-pkg/cdrom.cc:603 +#: apt-pkg/cdrom.cc:603 msgid "Unmounting CD-ROM\n" msgstr "" -#: apt-pkg/cdrom.cc:583 apt-pkg/cdrom.cc:607 +#: apt-pkg/cdrom.cc:607 msgid "Waiting for disc...\n" msgstr "" #. Mount the new CDROM -#: apt-pkg/cdrom.cc:591 apt-pkg/cdrom.cc:615 +#: apt-pkg/cdrom.cc:615 msgid "Mounting CD-ROM...\n" msgstr "" -#: apt-pkg/cdrom.cc:609 apt-pkg/cdrom.cc:633 +#: apt-pkg/cdrom.cc:633 msgid "Scanning disc for index files..\n" msgstr "" -#: apt-pkg/cdrom.cc:647 +#: apt-pkg/cdrom.cc:673 #, c-format -msgid "Found %i package indexes, %i source indexes and %i signatures\n" +msgid "" +"Found %i package indexes, %i source indexes, %i translation indexes and %i " +"signatures\n" msgstr "" -#: apt-pkg/cdrom.cc:710 apt-pkg/cdrom.cc:737 +#: apt-pkg/cdrom.cc:737 msgid "That is not a valid name, try again.\n" msgstr "" -#: apt-pkg/cdrom.cc:726 apt-pkg/cdrom.cc:753 +#: apt-pkg/cdrom.cc:753 #, c-format msgid "" "This disc is called: \n" "'%s'\n" msgstr "" -#: apt-pkg/cdrom.cc:730 apt-pkg/cdrom.cc:757 +#: apt-pkg/cdrom.cc:757 msgid "Copying package lists..." msgstr "" -#: apt-pkg/cdrom.cc:754 apt-pkg/cdrom.cc:783 +#: apt-pkg/cdrom.cc:783 msgid "Writing new source list\n" msgstr "" -#: apt-pkg/cdrom.cc:763 apt-pkg/cdrom.cc:792 +#: apt-pkg/cdrom.cc:792 msgid "Source list entries for this disc are:\n" msgstr "" -#: apt-pkg/cdrom.cc:803 apt-pkg/cdrom.cc:832 +#: apt-pkg/cdrom.cc:832 msgid "Unmounting CD-ROM..." msgstr "" -#: apt-pkg/indexcopy.cc:261 apt-pkg/indexcopy.cc:263 apt-pkg/indexcopy.cc:830 +#: apt-pkg/indexcopy.cc:263 apt-pkg/indexcopy.cc:830 #, c-format msgid "Wrote %i records.\n" msgstr "" -#: apt-pkg/indexcopy.cc:263 apt-pkg/indexcopy.cc:265 apt-pkg/indexcopy.cc:832 +#: apt-pkg/indexcopy.cc:265 apt-pkg/indexcopy.cc:832 #, c-format msgid "Wrote %i records with %i missing files.\n" msgstr "" -#: apt-pkg/indexcopy.cc:266 apt-pkg/indexcopy.cc:268 apt-pkg/indexcopy.cc:835 +#: apt-pkg/indexcopy.cc:268 apt-pkg/indexcopy.cc:835 #, c-format msgid "Wrote %i records with %i mismatched files\n" msgstr "" -#: apt-pkg/indexcopy.cc:269 apt-pkg/indexcopy.cc:271 apt-pkg/indexcopy.cc:838 +#: apt-pkg/indexcopy.cc:271 apt-pkg/indexcopy.cc:838 #, c-format msgid "Wrote %i records with %i missing files and %i mismatched files\n" msgstr "" @@ -2572,27 +2315,10 @@ msgstr "" msgid "Completely removed %s" msgstr "" -#: methods/rsh.cc:330 -msgid "Connection closed prematurely" -msgstr "" - -#: apt-pkg/pkgcachegen.cc:157 -#, c-format -msgid "Error occured while processing %s (NewFileDesc1)" -msgstr "" - -#: apt-pkg/pkgcachegen.cc:249 -#, c-format -msgid "Error occured while processing %s (NewFileDesc2)" -msgstr "" - -#: apt-pkg/pkgcachegen.cc:261 -msgid "Wow, you exceeded the number of descriptions this APT is capable of." +#: methods/rsh.cc:91 +msgid "Failed to create IPC pipe to subprocess" msgstr "" -#: apt-pkg/cdrom.cc:673 -#, c-format -msgid "" -"Found %i package indexes, %i source indexes, %i translation indexes and %i " -"signatures\n" +#: methods/rsh.cc:330 +msgid "Connection closed prematurely" msgstr "" -- cgit v1.2.3-70-g09d2 From d242b9e788311e7f19ceaa9dc24f5e426005ae4c Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Tue, 5 Sep 2006 19:51:17 +0100 Subject: bump cache version --- apt-pkg/pkgcache.cc | 2 +- debian/changelog | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) (limited to 'apt-pkg') diff --git a/apt-pkg/pkgcache.cc b/apt-pkg/pkgcache.cc index 35eb23dfa..93ad56641 100644 --- a/apt-pkg/pkgcache.cc +++ b/apt-pkg/pkgcache.cc @@ -54,7 +54,7 @@ pkgCache::Header::Header() /* Whenever the structures change the major version should be bumped, whenever the generator changes the minor version should be bumped. */ - MajorVersion = 5; + MajorVersion = 6; MinorVersion = 0; Dirty = false; diff --git a/debian/changelog b/debian/changelog index 9c6232a6c..96b752424 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +apt (0.6.45ubuntu6~iwj2) unstable; urgency=low + + * Tests pass without code changes! Except that we need this: + * Bump cache file major version to force rebuild so that Breaks + dependencies are included. + + -- Ian Jackson Tue, 5 Sep 2006 19:50:02 +0100 + apt (0.6.45ubuntu6~iwj) unstable; urgency=low * Initial draft of `Breaks' implementation. Appears to compile, -- cgit v1.2.3-70-g09d2 From 19ec5723caa6ea6ab196a9e960c769ded4ee0d28 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 1 Dec 2006 17:03:43 +0100 Subject: * apt-pkg/deb/debsrcrecords.{cc,h}: - cast correct --- apt-pkg/deb/debsrcrecords.cc | 2 +- apt-pkg/deb/debsrcrecords.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/deb/debsrcrecords.cc b/apt-pkg/deb/debsrcrecords.cc index e1c6427e8..7d5dab747 100644 --- a/apt-pkg/deb/debsrcrecords.cc +++ b/apt-pkg/deb/debsrcrecords.cc @@ -40,7 +40,7 @@ const char **debSrcRecordParser::Binaries() { delete [] Buffer; // allocate new size based on buffer (but never smaller than 4000) - BufSize = max((unsigned long)4000, max(Bins.length()+1,2*BufSize)); + BufSize = max((unsigned int)4000, max((unsigned int)Bins.length()+1,2*BufSize)); Buffer = new char[BufSize]; } diff --git a/apt-pkg/deb/debsrcrecords.h b/apt-pkg/deb/debsrcrecords.h index f4e2cb46c..7645dc564 100644 --- a/apt-pkg/deb/debsrcrecords.h +++ b/apt-pkg/deb/debsrcrecords.h @@ -27,7 +27,7 @@ class debSrcRecordParser : public pkgSrcRecords::Parser char *StaticBinList[400]; unsigned long iOffset; char *Buffer; - unsigned long BufSize; + unsigned int BufSize; public: -- cgit v1.2.3-70-g09d2 From 07494f6580dd689c1d82d8dc2f7dbbcfedaf6e52 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Fri, 8 Dec 2006 18:21:59 +0000 Subject: 0.6.46.3ubuntu2 change as uploaded: fix dist-upgrade --- apt-pkg/algorithms.cc | 1 + debian/changelog | 7 +++++++ 2 files changed, 8 insertions(+) (limited to 'apt-pkg') diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc index f50c52a32..723c8ea3a 100644 --- a/apt-pkg/algorithms.cc +++ b/apt-pkg/algorithms.cc @@ -986,6 +986,7 @@ bool pkgProblemResolver::Resolve(bool BrokenFix) } if (Debug) clog << " Will not break " << Pkg.Name() << " as stated in Breaks field in " << I.Name() < Thu, 7 Dec 2006 15:46:52 +0000 + apt (0.6.45ubuntu6) edgy; urgency=low * Tests pass without code changes! Except that we need this: -- cgit v1.2.3-70-g09d2