summaryrefslogtreecommitdiff
path: root/CMake/config.h.in
Commit message (Collapse)AuthorAgeFilesLines
* Only define likely/unlikely if APT_COMPILING_APT setJulian Andres Klode2020-01-071-0/+3
| | | | This ensures that we do not leak simple words like that.
* Run unifdef -DAPT_{8,9,10,15}_CLEANER_HEADERSJulian Andres Klode2019-06-121-5/+0
|
* Prevent shutdown while running dpkgJulian Andres Klode2019-05-031-0/+3
| | | | | | | As long as we are running dpkg, keep an inhibitor that blocks us from shutting down. LP: #1820886
* Correctly handle feature detection for sse4.2 and crc32Julian Andres Klode2019-02-041-4/+4
| | | | Mistakingly used #define instead of #cmakedefine
* Detect function multiversioning and sse4.2/crc32, enables i386Julian Andres Klode2019-02-041-0/+4
| | | | | This fixes the build on kfreebsd-amd64, and due to the detection of sse4.2, should also enable the sse4.2 on i386.
* apt-pkg: Add support for zstdJulian Andres Klode2018-03-121-0/+3
| | | | | | | zstd is a compression algorithm developed by facebook. At level 19, it is about 6% worse in size than xz -6, but decompression is multiple times faster, saving about 40% install time, especially with eatmydata on cloud instances.
* Sandbox methods with seccomp-BPF; except cdrom, gpgv, rshJulian Andres Klode2017-10-221-0/+3
| | | | | | | | | | | | This reduces the number of syscalls to about 140 from about 350 or so, significantly reducing security risks. Also change prepare-release to ignore the architecture lists in the build dependencies when generating the build-depends package for travis. We might want to clean up things a bit more and/or move it somewhere else.
* Directly link against libudev on Linux systemsJulian Andres Klode2017-09-091-0/+3
| | | | | | | | | | | | | | | | | | | We previously dlopen()ed it, but it seems painful to do that without any real gain, except for possibly not having libudev in the address space and not having code #ifdefed for Linux. The latter means that we are a bit more likely to break stuff for non-Linux systems now if we play with udev, but at least we don't end up with it silently breaking because of a libudev ABI break. The existing function pointers in the struct were renamed and kept for compat purposes. Fixes Debian/apt#48 Also adjust prepare-release to strip [linux-any] from build-depends for travis.
* reimplement and document auth.confDavid Kalnischkies2017-07-261-0/+1
| | | | | | | | | | | | | | | | | | We have support for an netrc-like auth.conf file since 0.7.25 (closing 518473), but it was never documented in apt that it even exists and netrc seems to have fallen out of usage as a manpage for it no longer exists making the feature even more arcane. On top of that the code was a bit of a mess (as it is written in c-style) and as a result the matching of machine tokens to URIs also a bit strange by checking for less specific matches (= without path) first. We now do a single pass over the stanzas. In practice early adopters of the undocumented implementation will not really notice the differences and the 'new' behaviour is simpler to document and more usual for an apt user. Closes: #811181
* Use C++11 threading support instead of pthreadJulian Andres Klode2017-07-201-3/+0
| | | | This makes the code easier to read.
* Read dpkg tables to handle architecture wildcardsJulian Andres Klode2017-01-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our implementation of wildcards was rudimentary. It worked for some common ones, but it was also broken: For example, armel matched any-armel, but should match any-arm. With this commit, we load the correct tables from dpkg. Supported are both triplets and quadruplet tables (the latter introduced in dpkg 1.18.11). There are some odd things we have to deal with in the cache filter for historical and API reasons: * The character "*" must be accepted as an alternative to any - in fact it may appear anywhere in the wildcard as we also allow fnmatch() style wildcard matching on the commandline. * The code might get passed an arch with a minus at the end, for example the cmdline "install apt:any-arm-" will first try to check if any-arm- is a valid architecture. We deal with this by rejecting any wildcard ending in a minus. * Triplets are actually implemented by extending them to faux quadruplets - by prepending a "base" component for the architecture tuple, and "any" if there is a wildcard component. Once we have constructed a wildcard, it is transformed into an fnmatch() expression for historical reasons. In the future, we should really get a tuple class and implement matching in a better, more explicit way. This does for now though - it passes all the test cases and accepts all things it should accept. Closes: #748936 Thanks: James Clarke <jrtc27@jrtc27.com> for the initial patch
* Make root group configurable via ROOT_GROUPJulian Andres Klode2016-08-261-0/+3
| | | | | This is needed on BSD where root's default group is wheel, not root.
* Make directory paths configurableJulian Andres Klode2016-08-261-0/+9
| | | | | | | This allows other vendors to use different paths, or to build your own APT in /opt for testing. Note that this uses + 1 in some places, as the paths we receive are absolute, but we need to strip of the initial /.
* CMake: Handle endian.h locations on other platformsJulian Andres Klode2016-08-261-0/+6
| | | | Gbp-Dch: ignore
* CMake: Check for ptsname_r() againJulian Andres Klode2016-08-101-0/+3
| | | | | | | | This was dropped in autotools as I found no use of the HAVE_PTSNAME_R macro. Turns out it was typoed as HAVE_PTS_NAME_R. Fix the #ifdef and add checks to CMake for it. Closes: #833674
* CMake: Set PACKAGE_MAIL variableJulian Andres Klode2016-08-101-1/+1
| | | | | | | This is needed in a lot of places. Also adjust config.h.in to use it instead of the bare email address. Gbp-Dch: ignore
* CMake: Add basic CMake build systemJulian Andres Klode2016-08-061-0/+54
Introduce an initial CMake buildsystem. This build system can build a fully working apt system without translation or documentation. The FindBerkelyDB module is from kdelibs, with some small adjustements to also look in db5 directories. Initial work on this CMake build system started in 2009, and was resumed in August 2016.