Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The related code blocks got split by the introduction of code inbetween
in commit e5bf4b7412bb2a4e5ff33f128c3cb8dcd96fcfdb.
|
|
Doxygen considers <word> as HTML markup text, and issues warnings on
unknown keywords.
|
|
|
|
|
|
Print the bogus value that triggered the internal error, or simply
reword unclear messages.
|
|
This will allow us to query if the currently installed dpkg has
multi-arch support.
|
|
|
|
Packages within a set can rightfully share files and should not
be disappeared in the case where they share all the files.
Closes: #652063
Reported-by: Martin Pitt <mpitt@debian.org>
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
The upgrade is scheduled by explicit calls to pkg_infodb_upgrade() if
the current database format version is less than the latest supported
format or if the previous upgrade was interrupted.
The upgrade goes as follows:
- link all old files to their new names.
- set <admindir>/info/format-new to 1.
- remove all old files.
- rename <admindir>/info/format-new to <admindir>/info/format.
In case of abrupt interruption, the presence of <admindir>/info/format-new
means the upgrade is not yet completed and it needs to be retried. In case
of clean interruption with rollback, that file is removed after the old
layout has been restored.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Designed-by: Guillem Jover <guillem@debian.org>
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
The usage of the new layout is conditional to a prior database
upgrade that should write a version number greater than 0 in
<admindir>/info/format.
The file is parsed when needed from pkg_infodb_get_format().
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
If all the already installed packages are synchronized, and the version
to be installed is the same, then we check that the shared file has the
same contents as what's already installed. Otherwise we blindly allow
the updated package to replace the file.
For conffiles, instead of checking against the on-disk version, we
check instead against either:
- the MD5 hash stored for any of the other configured instances of
the package.
- the MD5 hash of the already present .dpkg-new file for the
unpacked instances of the packages.
During removal, we only remove the file if it's not shared with other
packages of the same set.
During upgrade, we don't remove the file from other packages containing
the same file if the package is part of the same set. We do this even
for packages which are not “Multi-Arch: same” since there's only one
.list controlg file for the package set and we should not modify it
since it has already been written.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
This will be used later by the extraction code to know whether it should
ensure consistency of shared files or not.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
|
|
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
When we upgrade from “Multi-Arch: same” to something else (or vice versa)
the layout used for the control files changes (pkg.foo vs pkg:arch.foo)
and it means we must get rid of the old control files.
Sponsored-by: Linaro Limited
[guillem@debian.org:
- Reword comment and debug message. ]
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
dpkg-divert does nothing if the same diversion is recorded multiple
times. However when a diversion is removed, it does so even if
the shared file is still in place.
We change dpkg-divert's behaviour to ignore a diversion removal request
until the diverted file is no longer owned by another package of the
same package set.
We also update the test-suite to provide a status file now that
dpkg-divert reads it.
Sponsored-by: Linaro Limited
[guillem@debian.org:
- Handle missing DPKG_MAINTSCRIPT_ARCH when upgrading from old dpkg.
- Split ignore removal logic into a new function. ]
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
|
|
This will be used for checksum generation at unpack time, and for shared
file verification.
|
|
|
|
|
|
|
|
|
|
A “Multi-Arch: same” package can only be configured if all the other
instances of the same package are synchronized (i.e. have the same
unpacked version) and if they are in state where they can be configured.
Sponsored-by: Linaro Limited
[guillem@debian.org:
- Rework error strings.
- Fix coding-style.
- Check against <= stat_configfiles instead of < stat_halfinstalled.
- Split unrelated check into different conditionals. ]
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
When a new version of a “Multi-Arch: same” package is installed,
the other instances that are not synchronized (i.e. which
have a different version) must be deconfigured.
Sponsored-by: Linaro Limited
[guillem@debian.org:
- Ignore the package earlier if the package state is not correct.
- Use enqueue_deconfigure() instead of ad-hoc code. ]
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
Packages whose architecture has been whitelisted with
--add-architecture do not need --force-architecture to be installed.
Even foreign packages which are “Multi-Arch: no” can be installed
provided that all their foreign dependencies are already satisfied.
Sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
In places where the architecture qualifier of a dependency has not been
validated before-hand (through usage of deppossi_pkg_iterator), add a
manual verification.
In both cases, the checks are not needed with the current rules where
both Replaces and Breaks can only have “any” as architecture qualifier
but for completeness, we put them nevertheless.
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
To fix the non-working --force-depends-version (bug #57104) in
commit c54fb50e3a08d467955856e81be178b712b7ebdb, a check for
fc_dependsversion was added alongside the existing fc_depends for
dependtry >= 3, as it could not be just replaced because there was
no other code to pickup the fc_depends for that specific case in
dependtry >= 4.
Now that fc_depends always gets applied after all calls to
deppossi_ok_found() have finished, it's safe to remove the misplaced
fc_depends, so that it happens at dependtry >= 4, where it belongs.
|
|
The logic that allowed --force-depends to do its job was embedded
in deppossi_ok_found() but that function is no longer called
when there are no packages matching the architecture restriction
implied by the dependency. Due to the structure of the internal
database this happens only with foreign packages.
Instead of relying on deppossi_ok_found() we move the logic directly
into dependencies_ok(), just at the end of the dependencies checks.
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
Sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
This affects --audit, --yet-to-unpack and --get-selections.
Sponsored-by: Linaro Limited
[guillem@debian.org:
- Adapt to new pkg_name API.
- Only arch-qualify when unambiguous. ]
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
Replace pkg->set->name with pkg_name() and pkgbin_name().
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
The colon is often used as a separator but it is always preceded and/or
followed by a space so that it's possible to distinguish between the
colon used as a separator and the colon embedded in a package name
(like in "libc6:amd64").
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
This affects --list and --show. Also use package specifiers in the
default output format and document this change in the manual page.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
Instead of storing/parsing package names, we have to store/parse
package specifiers that can include an architecture qualifier.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
This affects --ignore-depends, --configure, --remove, --purge,
--triggers-only, --get-selections and --set-selections.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
This affects --list, --show, --listfiles, --status, --print-avail
and --control-path.
Sponsored-by: Linaro Limited
[guillem@debian.org:
- Adapt to new pkg_spec API.
- Do not memset the pkg_spec array nor directly assign to flags member,
use pkg_spec_init() instead.
- Check for parse errors from pkg_spec_parse_pkg() and bail out.
- Use psf_arch_def_wildcard instead of _native for -l and -W. ]
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
Change the default behaviour of not loading the available file depending
on whether arguments have been passed to the commands, to instead adding
a new explicit option to let the user request the additional information
from the available file.
This is needed to avoid confusion given that with multiarch the
available file can contain multiple instances for the same package.
|
|
Use cmdinfo long name instead of hard-coding it in the literal string,
and reword some strings to make them more generally usable.
|
|
|
|
|
|
The reworked function takes into account the architecture while comparing
the packages, if that would make the package name output ambiguous.
Based-on-patch-by: Raphaël Hertzog <hertzog@debian.org>
Patch-sponsored-by: Linaro Limited
Signed-off-by: Guillem Jover <guillem@debian.org>
|
|
The function is being used for showing purposes.
|
|
|