Age | Commit message (Collapse) | Author |
|
Implementing FileName() works for most cases for us, but other
frontends might need more and even for us its not very stable as
the normal Jump() implementation is pretty bad on a deb file and
produce errors on its own at times.
So, replacing this makeshift with a complete implementation by
mostly just shuffling code around.
|
|
We have a bunch of classes which are of no use for the outside world,
but were still exported and so needed to preserve ABI/API. Marking them
as hidden to not export them any longer is a big API break in theory,
but in practice nobody is using them – as if they would its a bug.
|
|
|
|
Handle Translation-* files exactly like Packages files (with the
expection that it is ok if a download of them fails). Remove all
"guessing" on apts side. This will elimimnate a bunch of errors
releated to captive portals and similar. Its also more correct
and removes another potential attack vector.
|
|
Reimplementing an inline method is opening a can of worms we don't want
to open if we ever want to us a d-pointer in those classes, so we do the
only thing which can save us from hell: move the destructors into the cc
sources and we are good.
Technically not an ABI break as the methods inline or not do the same
(nothing), so a program compiled against the old version still works
with the new version (beside that this version is still in experimental,
so nothing really has been build against this library anyway).
Git-Dch: Ignore
|
|
We are the only possible users of private methods, so we are also the
only users who can potentially export them via using them in inline
methods. The point is: We don't need these symbols exported if we don't
do this, so marking them as hidden removes some methods from the API
without breaking anything as nobody could have used them.
Git-Dch: Ignore
|
|
Conflicts:
apt-pkg/acquire-item.cc
|
|
Strings like Section names or architectures are needed vary often.
Instead of writing them each time we need them, we deploy sharing for
these special strings. Until now, this was done with a linked list of
strings in which we would search, which was stored in the cache.
It turns out we can do this just as well in memory as well with a bunch
of std::map's.
In memory means here that it isn't available anymore if we have a partly
invalid cache, but that isn't much of a problem in practice as the
status file is compared to the other files we parse very small and includes
mostly duplicates, so the space we would gain by storing is more or less
equal to the size of the stored linked list…
|
|
|
|
CLoses: #752327
|
|
We had a wild mixture of (unsigned) int, long and long long here without
much sense, so this commit adds a few typedefs to get some sense in the
typesystem and ensures that a ID isn't sometimes computed as int, stored
as long and compared with a long long… as this could potentially bite us
later on as the size of the archive only increases over time.
|
|
Conflicts:
test/integration/test-bug-747261-arch-specific-conflicts
|
|
Version/Architecture information in a Translation-$lang file is
not allowed, so don't try to parse it. This is a fix for a bugreport
where a Translation-en file contained the content of the regular
Packages file (probably due to local FS corruption). This lead to
strange error messages on file download.
Thanks to Thomas Reusch for the report.
|
|
|
|
debian/experimental
Conflicts:
apt-pkg/deb/debindexfile.cc
apt-pkg/deb/debindexfile.h
apt-pkg/deb/debsrcrecords.cc
|
|
|
|
|
|
|
|
|
|
|
|
Git-Dch: Ignore
Reported-By: gcc -Wsuggest-attribute={pure,const,noreturn}
|
|
Beside being a bit cleaner it hopefully also resolves oddball problems
I have with high levels of parallel jobs.
Git-Dch: Ignore
Reported-By: iwyu (include-what-you-use)
|
|
apt-pkg/deb/deblistparser.cc:
- use OpenMaybeClearSignedFile to be free from detecting and
skipping clearsigning metadata in dsc and Release files
We can't write a "clean" file to disk as not all acquire methods copy
Release files before checking them (e.g. cdrom), so this reverts recombining,
but uses the method we use for dsc files also in the two places we
deal with Release files
|
|
change at the time of writing the strings, so first store it temporary
and then save the index in the (possibily new) pointer location
|
|
|
|
on the FileFd instead
|
|
(and be it if it tries to announce that…)
|
|
- implement a ModificationTime method for FileFd
|
|
to search for compressed silbings of the given filename and use this guessing
instead of hardcoding Gzip compression
|
|
|
|
|
|
done on the mirco-optimazation level, so lets fix them:
(performance) Possible inefficient checking for emptiness.
(performance) Prefer prefix ++/-- operators for non-primitive types.
|
|
that is not needed
|
|
this will break adding translations to the cache if the current environment does not include the language (e.g. LANG=C but german translations). testing for existance of the file is the better approach
|
|
- ignore missing deb-src files in /var/lib/apt/lists, thanks
to Thorsten Spindler (LP: #85590)
|
|
* apt-pkg/deb/deblistparser.cc:
- rewrite LoadReleaseInfo to cope with clearsigned Releasefiles
|
|
|
|
- Use FileFd::Size() instead of stat()ing the sources/binary/translations
indexes directly, so that we have transparent handling of gzipped
indexes.
|
|
- do not query each architecture for flat file archives
|
|
* debian/rules:
- Make DEB_BUILD_OPTIONS=noopt actually work by passing the right
CXXFLAGS.
* apt-pkg/contrib/fileutl.{h,cc}:
- Add support for reading of gzipped files with the new "ReadOnlyGzip"
OpenMode. (Closes: #188407)
- Link against zlib (in apt-pkg/makefile) and add zlib build dependency.
- [ABI BREAK] This adds a new private member to FileFd, but its
initialization is in the public header file.
* configure.in:
- Check for zlib library and headers.
* apt-pkg/acquire-item.cc, apt-pkg/deb/debindexfile.cc,
apt-pkg/deb/debrecords.cc, apt-pkg/deb/debsrcrecords.h,
cmdline/apt-cache.cc:
- Open Packages, Sources, and Translations indexes in "ReadOnlyGzip" mode.
* apt-pkg/deb/debindexfile.cc:
- If we do not find uncompressed package/source/translation indexes, look
for gzip compressed ones.
* apt-pkg/acquire-item.cc:
- If the Acquire::GzipIndexes option is true and we download a gzipped
index file, keep it as it is (and rename to .gz) instead of
uncompressing it.
* doc/apt.conf.5.xml:
- Document the new Acquire::GzipIndexes option.
* doc/po/apt-doc.pot, doc/po/de.po:
- German translation of new Acquire::GzipIndexes option.
* Add test/test-indexes.sh:
- Test behaviour of index retrieval and usage, in particular with
uncompressed and gzip compressed indexes.
* methods/gzip.cc: With FileFd now being able to read gzipped files, there
is no need for the gzip method any more to spawn an external gzip process.
Rewrite it to use FileFd directly, which makes the code a lot simpler, and
also using less memory and overhead.
|
|
- make the used MMap moveable (and therefore dynamic resizeable) by
applying (some) mad pointer magic (Closes: #195018)
|
|
expects the compressed contents to stay (such as the copy backend, or when using file:// repositories. Instead, introduce a new ReadOnlyGzip mode and use that where needed
|
|
indexes, to work with apt-get source as well
|
|
- If we do not find uncompressed package/source/translation indexes, look
for gzip compressed ones.
|
|
- split Open() into submethods to be able to build only parts
- make the OpProgress optional in the Cache buildprocess
|
|
but we support the usage of the new ABI so libapt users
can start to prepare for MultiArch (Closes: #536029)
|
|
- 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)
* abicheck/
- add new abitest tester using the ABI Compliance Checker from
http://ispras.linuxfoundation.org/index.php/ABI_compliance_checker
* Change the package index Info methods to allow apt-cache policy to be
useful when using several different archives on the same host.
(Closes: #329814, LP: #22354)
|
|
useful when using several different archives on the same host.
(Closes: #329814, LP: #22354)
|
|
but we support the usage of the new ABI so libapt users
can start to prepare for MultiArch (Closes: #536029)
MultiArch isn't ready for Primetime usage for now, but the branch has
managed to be a NOP if used in SingleArch-mode so we can start to
promote the use of the new MultiArchable API-extensions.
|
|
|