summaryrefslogtreecommitdiff
path: root/apt-pkg/aptconfiguration.cc
Commit message (Collapse)AuthorAgeFilesLines
* mark private methods as hiddenDavid Kalnischkies2014-09-301-29/+29
| | | | | | | | | | 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
* invalid cache if architecture set doesn't matchDavid Kalnischkies2014-05-101-1/+1
| | | | | | | | | | | | | | The cache heavily depends on the architecture(s) it is build for, especially if you move from single- to multiarch. Adding a new architecture to dpkg therefore has to be detected and must invalidate the cache so that we don't operate on incorrect data. The incorrect data will prevent us from doing otherwise sensible actions (it doesn't allow bad things to happen) and the recovery is simple and automatic in most cases, so this hides pretty well and is also not as serious as it might sound at first. Closes: 745036
* do not create an (additional) empty compressorDavid Kalnischkies2014-04-111-1/+1
| | | | | | | | FileFd code knows how to deal with such a compressor, so it isn't a problem, but it is absolutely not needed as we already have an (matching) identity compressor with '.' earlier in the list. Git-Dch: Ignore
* use liblzma-dev to provide xz/lzma supportDavid Kalnischkies2014-03-131-0/+8
| | | | | | | | | | | | We have xz/lzma support for a while, but only via an external binary provided by xz-utils. Now that the Debian archive provides xz by default and dpkg pre-depends on the library provided by liblzma-dev we can switch now to use this library as well to avoid requiring an external binary. For now the binary is in a prio:required package, but this might change in the future. API wise it is quiet similar to bz2 code expect that it doesn't provide file I/O methods, so we piece this together on our own.
* cleanup headers and especially #includes everywhereDavid Kalnischkies2014-03-131-2/+7
| | | | | | | | 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)
* warning: type qualifiers ignored on function return type [-Wignored-qualifiers]David Kalnischkies2014-03-131-2/+2
| | | | | Reported-By: gcc -Wignored-qualifiers Git-Dch: Ignore
* support DEB_BUILD_PROFILES and -P for build profilesDavid Kalnischkies2014-03-131-1/+25
| | | | | | | | | | Inspired by the rest of the patch in 661537, but abstract the parsing of various ways of setting the build profiles more so it can potentially be reused and all apt parts have the same behaviour. Especially config options, cmdline options and environment will not be combined as proposed as this isn't APTs usual behaviour and dpkg doesn't do it either, so one overrides the other as it normally does.
* add default and override handling for Cnf::FindVectorDavid Kalnischkies2014-03-131-61/+11
| | | | | | Automatically handle the override of list options via its parent value which can even be a comma-separated list of values. It also adds an easy way of providing a default for the list.
* Fix typos in documentation (codespell)Michael Vogt2014-02-221-4/+4
|
* rework some code to fix some scan-build warningsDavid Kalnischkies2014-01-161-2/+2
| | | | | | | | No visible functional changes, just code moved around and additional checks to eliminate impossible branches Reported-By: scan-build Git-Dch: Ignore
* fix lzma-support detection via xz binaryDavid Kalnischkies2013-10-031-1/+1
| | | | | | Clear() only clears a config option, not removing it and an empty setting still exists. Hence we set the option instead to the xz path so that the later existance check can find a binary for the test
* do chdir("/") after chroot()Michael Vogt2013-08-221-1/+1
|
* fix some coverity chroot() releated warningsMichael Vogt2013-07-261-2/+2
|
* various simple changes to fix cppcheck warningsDavid Kalnischkies2013-03-101-1/+1
|
* * apt-pkg/cdrom.cc:David Kalnischkies2012-09-031-0/+11
| | | | | | | - copy only configured translation files from a CD-ROM and not all available translation files preventing new installs with d-i from being initialized with all translations (Closes: #678227) - handle Components in the reduction for the source.list as multi-arch CDs otherwise create duplicated source entries (e.g. "wheezy main main")
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2012-06-101-11/+15
| | | | - if APT::Languages=none save "none" in allCodes so that the detected configuration is cached as intended (Closes: #674690, LP: #1004947)
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2012-05-201-1/+1
| | | | - longcode Translation files are saved with encoded underscore, so make sure to pick these files up as well for Acquire::Languages
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2012-05-091-3/+3
| | | - use NULL instead of "" for no (un)compress parameters
* fix a bug uncovered by the previous commit which checks if a CompressorDavid Kalnischkies2012-04-201-2/+4
| | | | | preference given by the Order setting is really available before adding it as possible CompressionType.
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2012-04-201-12/+13
| | | | - if the compressor is not installed, but we link against it's library accept it as a CompressionType (Closes: #669328)
* use xz-utils in the testcases instead of lzma and ensure that we reallyDavid Kalnischkies2012-04-111-1/+1
| | | | ignore the presents (or absence) of lzma if we decided to use xz
* - add libbz2-dev as new build-dependencyDavid Kalnischkies2012-04-051-1/+5
| | | | | | | | - remove the libz-dev alternative from zlib1g-dev build-dependency - do the same for bz2 builtin if available * apt-pkg/contrib/fileutl.cc: - use libz2 library for (de)compression instead of the bzip2 binary as the first is a dependency of dpkg and the later just priority:optional so we gain 'easier' access to bz2-compressed Translation files this way
* if we have zlib builtin insert add a dummy gzip compressor for FileFDDavid Kalnischkies2012-04-051-0/+4
|
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2012-04-051-6/+27
| | | - if present, prefer xz binary over lzma
* ensure that architectures are not added multiple timesDavid Kalnischkies2012-02-101-1/+3
|
* call dpkg --assert-multi-arch with execvp instead of execvDavid Kalnischkies2012-02-091-1/+1
|
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2012-01-301-8/+57
| | | - chroot if needed before calling dpkg --print-foreign-architectures
* * apt-pkg/aptconfiguration.cc:Michael Vogt2012-01-181-1/+1
|\ | | | | | | | | | | | | | | - parse dpkg --print-foreign-architectures correctly in case archs are separated by newline instead of space, too. (Closes: #655590) * Slovak (Ivan Masar). Closes: #652985 * Russian (Yuri Kozlov). Closes: #654844 * Hungarian (Gabor Kelemen). Closes: #655238
| * * apt-pkg/aptconfiguration.cc:David Kalnischkies2011-12-141-1/+1
| | | | | | | | - parse dpkg --print-foreign-architectures correctly in case archs are separated by newline instead of space, too.
| * cherrypick from my apt/experimental branchDavid Kalnischkies2011-10-051-2/+4
| | | | | | | | | | | | * apt-pkg/deb/debmetaindex.cc: - none is a separator, not a language: no need for Index (Closes: #624218) * apt-pkg/aptconfiguration.cc: - do not builtin languages only if none is forced (Closes: #643787)
* | * apt-pkg/deb/debmetaindex.cc:David Kalnischkies2011-10-051-2/+4
| | | | | | | | | | - none is a separator, not a language: no need for Index (Closes: #624218) * apt-pkg/aptconfiguration.cc: - do not builtin languages only if none is forced (Closes: #643787)
* | do not pollute namespace in the headers with using (Closes: #500198)David Kalnischkies2011-09-191-5/+5
| |
* | merge with debian/experimentalDavid Kalnischkies2011-09-131-3/+3
|\|
| * cppcheck complains about some possible speed improvements which could beDavid Kalnischkies2011-08-111-2/+2
| | | | | | | | | | | | done on the mirco-optimazation level, so lets fix them: (performance) Possible inefficient checking for emptiness. (performance) Prefer prefix ++/-- operators for non-primitive types.
| * * apt-pkg/aptconfiguration.cc:David Kalnischkies2011-07-251-1/+1
| | | | | | | | - ensure that native architecture is if not specified otherwise the first architecture in the Architectures vector
* | reorder includes: add <config.h> if needed and include it at firstDavid Kalnischkies2011-09-131-0/+2
|/
* use the correct option name in comment for Acquire::LanguagesJörg Sommer2011-05-281-1/+1
|
* * apt-pkg/aptconfiguration.cc:Michael Vogt2011-04-051-1/+1
| | | - fix comparing for a empty string
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2011-03-261-1/+32
| | | | - use dpkg --print-foreign-architectures to get multiarch configuration if non is specified with APT::Architectures (Closes: #612958)
* support every compression we have a compressor configuredDavid Kalnischkies2011-02-271-0/+13
|
* - load the supported compressors from configurationDavid Kalnischkies2011-02-271-4/+70
| | | - support adding new compressors by configuration
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2011-02-221-0/+2
| | | - support download of xz-compressed indexes files
* - download and use i18n/Index to choose which Translations to downloadDavid Kalnischkies2011-01-281-39/+12
| | | | * apt-pkg/aptconfiguration.cc: - remove the inbuilt Translation files whitelist
* - change the internal handling of Extensions in pkgAcqIndexDavid Kalnischkies2011-01-261-0/+8
| | | | | - add a special uncompressed compression type to prefer those files * methods/{gzip,bzip}.cc: - print a good error message if FileSize() is zero
* evaluate Acquire::Languages= before LANG= (Closes: #602573)David Kalnischkies2010-11-091-40/+42
|
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2010-11-061-1/+2
| | | - respect the none-force even in LANG=C (Closes: #602573)
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2010-06-261-0/+4
| | | - show a deprecation notice for APT::Acquire::Translation
* * apt-pkg/aptconfiguration.cc:David Kalnischkies2010-05-281-1/+14
| | | - remove duplicate architectures in getArchitectures()
* rename ExplodeString to VectorizeStringDavid Kalnischkies2010-03-301-1/+1
|
* merge MultiArch-ABI. We don't support MultiArch yet (as most other tools),David Kalnischkies2010-03-181-0/+24
|\ | | | | | | | | but we support the usage of the new ABI so libapt users can start to prepare for MultiArch (Closes: #536029)