ostree/src
Jonathan Lebon 9503189362 lib/checkout: fallback to checksum for UNION_IDENTICAL
There's a subtle issue going on with the way we use `UNION_IDENTICAL`
now in rpm-ostree. Basically, the crux of the issue is that we checkout
the whole tree from the system repo, but then overlay packages by
checking out from the pkgcache repo. This is an easy way to break the
assumption that we will be merging hardlinks from the same repo.

This ends up causing issues like:
https://github.com/projectatomic/rpm-ostree/issues/1047

There, `vim-minimal` is already part of the host and has an object for
`/usr/share/man/man1/ex.1.gz`. `vim-common` has that same file, but
because it's unpacked in the pkgcache repo first, the hardlinks are not
the same.

There are a few ways we *could* work around this in rpm-ostree itself,
e.g. by re-establishing hardlinks when we do the content pull into the
system repo, but it still felt somewhat hacky. Let's just do this the
proper way and fall back to checksumming the target file if needed,
which is what librpm does as well in this case. Note that we only
checksum if they're not hard links, but they're the same size.

Closes: #1258
Approved by: cgwalters
2017-10-14 13:19:18 +00:00
..
boot boot: Add a tmpfiles.d snippet to clean up /var/tmp/ostree-ovl.XXX 2017-08-17 18:38:45 +00:00
libostree lib/checkout: fallback to checksum for UNION_IDENTICAL 2017-10-14 13:19:18 +00:00
libotutil lib/utils: Check for invalid UTF-8 in filenames 2017-10-14 00:47:40 +00:00
ostree lib/core: add ostree_checksum_file_at API 2017-10-12 12:53:01 +00:00
rofiles-fuse tree-wide: Update to new libglnx fd APIs 2017-10-11 19:26:10 +00:00
switchroot tree-wide: Remove Emacs modelines 2017-09-21 21:38:34 +00:00