From: Michael Vogt Date: Wed, 17 Feb 2010 21:40:05 +0000 (+0100) Subject: merged from the mvo branch X-Git-Tag: 0.7.25.3ubuntu1~1 X-Git-Url: https://git.saurik.com/apt.git/commitdiff_plain/9fcbe2047293f8ef703439264ed3d35701f51638 merged from the mvo branch --- 9fcbe2047293f8ef703439264ed3d35701f51638 diff --cc cmdline/apt-key index b579e5a53,e45468fd4..73dfe6925 --- a/cmdline/apt-key +++ b/cmdline/apt-key @@@ -5,15 -5,16 +5,13 @@@ unset GREP_OPTION # We don't use a secret keyring, of course, but gpg panics and # implodes if there isn't one available - GPG_CMD="gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /etc/apt/secring.gpg --trustdb-name /etc/apt/trustdb.gpg" - GPG="$GPG_CMD --keyring /etc/apt/trusted.gpg" - + GPG="$GPG_CMD" -MASTER_KEYRING="" -ARCHIVE_KEYRING_URI="" -#MASTER_KEYRING=/usr/share/keyrings/debian-master-keyring.gpg -#ARCHIVE_KEYRING_URI=http://ftp.debian.org/debian/debian-archive-keyring.gpg - -ARCHIVE_KEYRING=/usr/share/keyrings/debian-archive-keyring.gpg -REMOVED_KEYS=/usr/share/keyrings/debian-archive-removed-keys.gpg +MASTER_KEYRING=/usr/share/keyrings/ubuntu-master-keyring.gpg +ARCHIVE_KEYRING=/usr/share/keyrings/ubuntu-archive-keyring.gpg +REMOVED_KEYS=/usr/share/keyrings/ubuntu-archive-removed-keys.gpg +ARCHIVE_KEYRING_URI=http://archive.ubuntu.com/ubuntu/project/ubuntu-archive-keyring.gpg add_keys_with_verify_against_master_keyring() { ADD_KEYRING=$1 diff --cc debian/apt.postinst index df0433057,cc0d8b1fe..773077aa5 --- a/debian/apt.postinst +++ b/debian/apt.postinst @@@ -15,11 -15,7 +15,9 @@@ set - case "$1" in configure) - - apt-key update + if ! test -f /etc/apt/trusted.gpg; then + cp /usr/share/apt/ubuntu-archive.gpg /etc/apt/trusted.gpg + fi - ;; abort-upgrade|abort-remove|abort-deconfigure) diff --cc debian/changelog index 803f0ab0d,c2c3524a6..da4885345 --- a/debian/changelog +++ b/debian/changelog @@@ -1,48 -1,142 +1,185 @@@ -apt (0.7.25.4) UNRELEASED; urgency=low ++apt (0.7.25.4ubuntu1) UNRELEASED; urgency=low + ++ [ Michael Vogt ] ++ * merged from the debian-sid branch ++ + [ Ivan Masár ] + * Slovak translation update. Closes: #568294 - - [ Michael Vogt ] - * merged lp:~mvo/apt/history - - this writes a /var/log/apt/history tagfile that contains details - from the transaction (complements term.log) - * methods/http.cc: - - add cache-control headers even if no cache is given to allow - adding options for intercepting proxies - - add Acquire::http::ProxyAutoDetect configuration that - can be used to call a external helper to figure out the - proxy configuration and return it to apt via stdout - (this is a step towards WPAD and zeroconf/avahi support) + - -- Michael Vogt Fri, 18 Dec 2009 16:54:18 +0100 ++ -- Christian Perrier Wed, 03 Feb 2010 20:08:19 +0100 + + apt (0.7.25.3) unstable; urgency=low + + [ Christian Perrier ] + * Italian translation update. Closes: #567532 + + [ David Kalnischkies ] + * apt-pkg/contrib/macros.h: - - install the header system.h with a new name to be able to use ++ - install the header system.h with a new name to be able to use + it in other headers (Closes: #567662) + * cmdline/acqprogress.cc: + - Set Mode to Medium so that the correct prefix is used. + Thanks Stefan Haller for the patch! (Closes: #567304 LP: #275243) + * ftparchive/writer.cc: + - generate sha1 and sha256 checksums for dsc (Closes: #567343) + * cmdline/apt-get.cc: + - don't mark as manually if in download only (Closes: #468180) - ++ + -- Michael Vogt Mon, 01 Feb 2010 18:41:15 +0100 + + apt (0.7.25.2) unstable; urgency=low + + [ Michael Vogt ] + * apt-pkg/contrib/cdromutl.cc: + - fix UnmountCdrom() fails, give it a bit more time and try + the umount again + * apt-pkg/cdrom.cc: + - fix crash in pkgUdevCdromDevices + * methods/cdrom.cc: + - fixes in multi cdrom setup code (closes: #549312) + - add new "Acquire::cdrom::AutoDetect" config that enables/disables + the dlopen of libudev for automatic cdrom detection. Off by default + currently, feedback/testing welcome + * cmdline/apt-cdrom.cc: + - add new --auto-detect option that uses libudev to figure out + the cdrom/mount-point + * cmdline/apt-mark: + - merge fix from Gene Cash that supports markauto for + packages that are not in the extended_states file yet + (closes: #534920) + * ftparchive/writer.{cc,h}: - - merge crash fix for apt-ftparchive on hurd, thanks to ++ - merge crash fix for apt-ftparchive on hurd, thanks to + Samuel Thibault for the patch (closes: #566664) + + [ David Kalnischkies ] + * apt-pkg/contrib/fileutl.cc: + - Fix the newly introduced method GetListOfFilesInDir to not + accept every file if no extension is enforced + (= restore old behaviour). (Closes: #565213) + * apt-pkg/policy.cc: + - accept also partfiles with "pref" file extension as valid + * apt-pkg/contrib/configuration.cc: + - accept also partfiles with "conf" file extension as valid + * doc/apt.conf.5.xml: + - reorder description and split out syntax + - add partfile name convention (Closes: #558348) + * doc/apt_preferences.conf.5.xml: + - describe partfile name convention also here + * apt-pkg/deb/dpkgpm.cc: + - don't segfault if term.log file can't be opened. + Thanks Sam Brightman for the patch! (Closes: #475770) + * doc/*: + - replace the per language addendum with a global addendum + - add a explanation why translations include (maybe) english + parts to the new global addendum (Closes: #561636) + * apt-pkg/contrib/strutl.cc: + - fix malloc asseration fail with ja_JP.eucJP locale in + apt-cache search. Thanks Kusanagi Kouichi! (Closes: #548884) + + [ Christian Perrier ] + * French translation update + + -- Michael Vogt Wed, 27 Jan 2010 16:16:10 +0100 + + apt (0.7.25.1) unstable; urgency=low + + [ Christian Perrier ] + * French manpage translation update + * Russian translation update by Yuri Kozlov + Closes: #564171 - ++ + [Chris Leick] + * spot & fix various typos in all manpages + * German manpage translation update + + [ David Kalnischkies ] + * cmdline/apt-cache.cc: + - remove translatable marker from the "%4i %s\n" string + * buildlib/po4a_manpage.mak: + - instruct debiandoc to build files with utf-8 encoding + * buildlib/tools.m4: + - fix some warning from the buildtools + * apt-pkg/acquire-item.cc: + - add configuration PDiffs::Limit-options to not download + too many or too big patches (Closes: #554349) + * debian/control: + - let all packages depend on ${misc:Depends} + * share/*-archive.gpg: + - remove the horrible outdated files. We already depend on + the keyring so we don't need to ship our own version + * cmdline/apt-key: + - errors out if wget is not installed (Closes: #545754) + - add --keyring option as we have now possibly many + * methods/gpgv.cc: + - pass all keyrings (TrustedParts) to gpgv instead of + using only one trusted.gpg keyring (Closes: #304846) + * methods/https.cc: + - finally merge the rest of the patchset from Arnaud Ebalard + with the CRL and Issuers options, thanks! (Closes: #485963) + * apt-pkg/deb/debindexfile.cc, apt-pkg/pkgcachegen.cc: + - add debug option Debug::pkgCacheGen + + [ Michael Vogt ] + * cmdline/apt-get.cc: + - merge fix for apt-get source pkg=version regression + (closes: #561971) + * po/ru.po: + - merged updated ru.po, thanks to Yuri Kozlov (closes: #564171) + + -- Michael Vogt Sat, 09 Jan 2010 21:52:36 +0100 + +apt (0.7.25ubuntu4) lucid; urgency=low + + * cmdline/apt-cdrom.cc: + - make Acquire::cdrom::AutoDetect default, this can be + turned off with "--no-auto-detect" + * methods/http.cc: + - add cache-control headers even if no cache is given to allow + adding options for intercepting proxies + + -- Michael Vogt Tue, 02 Feb 2010 16:58:59 -0800 + +apt (0.7.25ubuntu3) lucid; urgency=low + + * cmdline/apt-get.cc: - - fix apt-get source pkg=version regression (closes: #561971) ++ - don't mark as manually if in download only (Closes: #468180) ++ ++ -- Michael Vogt Mon, 01 Feb 2010 18:41:15 +0100 ++ ++apt (0.7.25.2) unstable; urgency=low ++ ++ [ Michael Vogt ] + * apt-pkg/contrib/cdromutl.cc: + - fix UnmountCdrom() fails, give it a bit more time and try + the umount again + * apt-pkg/cdrom.cc: + - fix crash in pkgUdevCdromDevices + * methods/cdrom.cc: - - fixes in multi cdrom setup code - - add new "Acquire::cdrom::AutoDetect" variable that enables/disables - the dlopen of libudev for automatic cdrom detection ++ - fixes in multi cdrom setup code (closes: #549312) ++ - add new "Acquire::cdrom::AutoDetect" config that enables/disables ++ the dlopen of libudev for automatic cdrom detection. Off by default ++ currently, feedback/testing welcome + * cmdline/apt-cdrom.cc: + - add new --auto-detect option that uses libudev to figure out + the cdrom/mount-point + + -- Michael Vogt Wed, 27 Jan 2010 16:11:32 +0100 + +apt (0.7.25ubuntu2) lucid; urgency=low + + * Change history branch so that it does not break the + apt ABI for the pkgPackageManager interface + (can be reverted on the next ABI break) + + -- Michael Vogt Wed, 23 Dec 2009 10:14:16 +0100 + +apt (0.7.25ubuntu1) lucid; urgency=low + + * Merged from the mvo branch + * merged from the lp:~mvo/apt/history branch + + -- Michael Vogt Tue, 22 Dec 2009 09:44:08 +0100 + apt (0.7.25) unstable; urgency=low [ Christian Perrier ] diff --cc debian/control index 9d15d2133,d756871d1..0ba851dc2 --- a/debian/control +++ b/debian/control @@@ -12,11 -11,9 +12,10 @@@ Vcs-Bzr: http://code.launchpad.net/~ubu Package: apt Architecture: any - Depends: ${shlibs:Depends} - Priority: important -Depends: ${shlibs:Depends}, debian-archive-keyring, ${misc:Depends} ++Depends: ${shlibs:Depends}, ${misc:Depends} Replaces: libapt-pkg-doc (<< 0.3.7), libapt-pkg-dev (<< 0.3.7) Provides: ${libapt-pkg:provides} +Recommends: ubuntu-keyring Suggests: aptitude | synaptic | wajig, dpkg-dev, apt-doc, bzip2, lzma, python-apt Description: Advanced front-end for dpkg This is Debian's next generation front-end for the dpkg package manager. diff --cc methods/http.cc index 45804656d,b05444691..904030e0a --- a/methods/http.cc +++ b/methods/http.cc @@@ -1326,5 -1327,59 +1330,48 @@@ int HttpMethod::Loop( return 0; } /*}}}*/ + // HttpMethod::AutoDetectProxy - auto detect proxy /*{{{*/ + // --------------------------------------------------------------------- + /* */ + bool HttpMethod::AutoDetectProxy() + { + if (AutoDetectProxyCmd.empty()) + return true; + + if (Debug) + clog << "Using auto proxy detect command: " << AutoDetectProxyCmd << endl; + + int Pipes[2] = {-1,-1}; + if (pipe(Pipes) != 0) + return _error->Errno("pipe", "Failed to create Pipe"); + + pid_t Process = ExecFork(); + if (Process == 0) + { + dup2(Pipes[1],STDOUT_FILENO); + SetCloseExec(STDOUT_FILENO,false); + + const char *Args[2]; + Args[0] = AutoDetectProxyCmd.c_str(); + Args[1] = 0; + execv(Args[0],(char **)Args); + cerr << "Failed to exec method " << Args[0] << endl; + _exit(100); + } + char buf[512]; + int InFd = Pipes[0]; + if (read(InFd, buf, sizeof(buf)) < 0) + return _error->Errno("read", "Failed to read"); + ExecWait(Process, "ProxyAutoDetect"); + + if (Debug) + clog << "auto detect command returned: '" << buf << "'" << endl; + + if (strstr(buf, "http://") == buf) + _config->Set("Acquire::http::proxy", _strstrip(buf)); + + return true; + } + /*}}}*/ -int main() -{ - setlocale(LC_ALL, ""); - // ignore SIGPIPE, this can happen on write() if the socket - // closes the connection (this is dealt with via ServerDie()) - signal(SIGPIPE, SIG_IGN); - - HttpMethod Mth; - return Mth.Loop(); -} - diff --cc methods/http.h index bc076e1f8,ceee36cbe..bac94e177 --- a/methods/http.h +++ b/methods/http.h @@@ -134,7 -134,9 +134,8 @@@ class HttpMethod : public pkgAcqMetho bool Flush(ServerState *Srv); bool ServerDie(ServerState *Srv); int DealWithHeaders(FetchResult &Res,ServerState *Srv); + bool AutoDetectProxy(); - virtual bool Fetch(FetchItem *); virtual bool Configuration(string Message); // In the event of a fatal signal this file will be closed and timestamped. @@@ -142,11 -144,9 +143,12 @@@ static int FailFd; static time_t FailTime; static void SigTerm(int); + + protected: + virtual bool Fetch(FetchItem *); string NextURI; + string AutoDetectProxyCmd; public: friend class ServerState;