guix/guix
Ludovic Courtès 67effc1560
grafts: Fix corner case involving multiple-output derivations.
Fixes a bug that would occur with references to two outputs of the same
derivation, with one of them referring to the other one.

For example, the references of libreoffice include both mariadb:dev and
mariadb:lib; additionally, mariadb:dev refers to mariadb:lib.  In this
case, the glibc graft would not be applied on one of the mariadb paths,
and both the grafted and ungrafted glibc would end up in the closure of
libreoffice.

Fixes <https://issues.guix.gnu.org/66662>.

* guix/grafts.scm (non-self-references): Simplify and include references
to outputs of DRV other than OUTPUTS.
(reference-origins): Simplify and possibly return outputs of DRV itself.
(cumulative-grafts)[graft-origin?]: Add OUTPUT parameter and honor it.
[dependency-grafts]: Adjust accordingly.
* tests/grafts.scm ("graft-derivation, multiple outputs need to be replaced"):
New test.

Change-Id: Iac2005024ab7049037537b3af55298696ec90e3c
2023-10-28 00:17:23 +02:00
..
build syscalls: Consistently use existing linux? definition. 2023-10-23 11:58:16 +02:00
build-system build-system/dub: Remove dependency on (guix build syscalls). 2023-10-23 11:56:54 +02:00
import guix: import: Don't import yanked rust crates. 2023-10-22 16:46:39 +03:00
platforms platform: Add powerpc64-linux. 2023-08-12 23:02:31 +02:00
scripts locate: Do not return the system database when it is too old. 2023-10-18 18:21:04 +02:00
store
tests
android-repo-download.scm
avahi.scm
base16.scm
base32.scm
base64.scm
build-system.scm
bzr-download.scm
cache.scm
channels.scm
ci.scm
colors.scm
combinators.scm
config.scm.in build: Add dependency on Git. 2023-09-26 17:36:58 +02:00
cpio.scm
cpu.scm
cve.scm
cvs-download.scm
d3.v3.js
deprecation.scm
derivations.scm
describe.scm
diagnostics.scm
discovery.scm
docker.scm
download.scm gnu-maintenance: Allow mirror URLs to fallback to the generic HTML updater. 2023-08-26 11:38:56 -04:00
elf.scm
ftp-client.scm
gexp.scm
git-authenticate.scm
git-download.scm git-download: Use “builtin:git-download” when available. 2023-09-26 17:36:58 +02:00
git.scm git: Restore 'false-if-git-not-found' in 'reference-available?'. 2023-09-25 12:00:18 +02:00
glob.scm
gnu-maintenance.scm gnu-maintenance: Support URI list of mixed mirrors, HTTP URLs. 2023-09-11 23:39:13 -04:00
gnupg.scm
grafts.scm grafts: Fix corner case involving multiple-output derivations. 2023-10-28 00:17:23 +02:00
graph.js
graph.scm graph: Add GraphML backend. 2023-08-25 14:24:43 +02:00
hash.scm
hg-download.scm
http-client.scm
i18n.scm
inferior.scm scripts: time-machine: Error when attempting to visit too old commits. 2023-08-16 21:34:13 -04:00
ipfs.scm
least-authority.scm
licenses.scm
lint.scm lint: Check that (cc-for-target) and friends are used. 2023-09-08 19:12:15 +02:00
man-db.scm
memoization.scm
modules.scm
monad-repl.scm
monads.scm
nar.scm
narinfo.scm
openpgp.scm
packages.scm guix: packages: Support package/inherit by package-field-location. 2023-09-06 16:41:06 -04:00
pki.scm
platform.scm
profiles.scm guix: profiles: Detect TeX Live packages propagated from non-TeX Live inputs. 2023-08-24 16:03:18 +02:00
profiling.scm
progress.scm
quirks.scm
read-print.scm read-print: Be more mindful of horizontal space in packages. 2023-09-24 02:00:00 +02:00
records.scm
remote.scm
repl.scm
rpm.scm
scripts.scm
search-paths.scm search-paths: Add GCC search paths. 2023-10-04 23:30:41 -04:00
self.scm build: Add dependency on Git. 2023-09-26 17:36:58 +02:00
serialization.scm
sets.scm
ssh.scm ssh: Also print the user when authentication fails. 2023-08-22 11:17:53 +02:00
status.scm
store.scm
substitutes.scm
svn-download.scm
swh.scm
tests.scm
transformations.scm transformations: tuned-package: Use target on cross-compile. 2023-09-17 15:31:03 +02:00
ui.scm ui: Handle EPIPE errors when displaying Guix version. 2023-10-17 14:51:53 +02:00
upstream.scm upstream: Compare symbols to symbols. 2023-09-13 22:17:21 +02:00
utils.scm utils: Add 'strip-for-target'. 2023-10-26 15:21:35 +02:00
workers.scm