(address . bug-guix@gnu.org)
$ cat test.scm
(use-modules
(guix packages)
(guix build-system trivial))
(define-public core-pkg
(package
(name "core-pkg")
(version "1.0")
(replacement core-pkg/fixed)
(source #f)
(outputs '("out" "lib"))
(build-system trivial-build-system)
(arguments
`(#:modules ((guix build utils))
#:builder
(begin
(use-modules (guix build utils))
(let ((outdir (assoc-ref %outputs "out"))
(libdir (assoc-ref %outputs "lib")))
(mkdir-p outdir)
(mkdir-p libdir)
#t))))
(synopsis #f)
(description #f)
(home-page #f)
(license #f)))
(define-public core-pkg/fixed
(package
(inherit core-pkg)
(version "1.1")))
(package
(name "other-pkg")
(version "4.2")
(source #f)
(build-system trivial-build-system)
(inputs
`(("core-pkg" ,core-pkg)
("core-pkg:lib" ,core-pkg "lib")))
(arguments
`(#:modules ((guix build utils))
#:builder
(begin
(use-modules (guix build utils))
(let ((outdir (assoc-ref %outputs "out")))
(mkdir-p outdir)
(with-output-to-file (string-append outdir "/hello")
(lambda ()
(display (assoc-ref %build-inputs "core-pkg"))
(newline)
(display (assoc-ref %build-inputs "core-pkg:lib"))
(newline)))
#t))))
(synopsis #f)
(description #f)
(home-page #f)
(license #f))
~$ cat `guix build --no-offload -f test.scm`/hello
/gnu/store/pmz07rzm63z02lkyyldsw3srf98h01y2-core-pkg-1.1
/gnu/store/pivsji8qfpln4i4v0f5v5cjmzakmcmvg-core-pkg-1.0-lib
Expected output: the second line contains -core-pkg-1.1-lib.
Regards,
Jakub K?dzio?ka
-----BEGIN PGP SIGNATURE-----
iQIyBAABCAAdFiEE5Xa/ss9usT31cTO54xWnWEYTFWQFAl7hX28ACgkQ4xWnWEYT
FWSEyw/3XMAjfC55ltrKpOkpQnX8abjwBJjJlwHy/b+qQHf+WwTMGxecYCUVExXt
qsFRho0qCQVqkhj5iwB0ownem/GZCnwjkbUXJ2vMwb3wHrra3pBFwoQjdg6Yv+Q5
KKlyP+nNK9+MTz8+AKzMd9Yng52dl2LE4qS/v9Gi6oxirreStG3+MdBrenpYBPWU
gitD/erPRx6abYeHHP4l1HI5YdmU/MtP4orNBv8N+bKBMaqEcYhpg6dhPLJg6vHB
mozrW9AMR0XghKr6xlNwg7ddh8xcyQnW6Mj4Ongl/LXqQXr/znq1kgrR3jeemRGu
SDGMYdmW1gsRtqwBnrGL0bvY++Kcbb3+lYuxqOkLvE/Br2u4c9e/TYcw5p8AqeGA
vY6McSyv1VLFOmFhQ19fejaO3bQiglACBRdZGVybWQ8yNh6olfip8DfVUVrgxPAz
tpf1aqroaWAR68RrgsQEc6LmPfYysKzZVJp8drJtiGvqU7MsgWNFBrHVxZpGv4l9
DUSQMyz0M9NPLSMzz9Nz9q4lU4Nt1MkyvV52iT08Rgls9WU5w+M+QK2b3FS2sZlq
uqV/8TzB3HhCbCjAeNY5HNYzFwiqBd/TCwSnArYlUwAKnb0/88tHoy0nS2+/C2pd
x+VhpFNcqj+F/nbhhPuk0atztnhi274c6GYTKO0+uve6Wh9ZKA==
=o5vg
-----END PGP SIGNATURE-----