Message ID | 20210903153116.22517-1-maxim.cournoyer@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | Shortened Rust bootstrap & other fixes. | expand |
Context | Check | Description |
---|---|---|
cbaines/applying patch | fail | View Laminar job |
cbaines/issue | success | View issue |
Hello Maxim, > * guix/packages.scm (patch-and-repack): Test for a tarball using tarball? and > move the plain file copy to the else clause. I could not test it locally, but it looks fine to me. Thanks for fixing it, Mathieu
Hi, Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis: > Fixes <https://issues.guix.gnu.org/50066>. > > * guix/packages.scm (patch-and-repack): Test for a tarball using tarball? and > move the plain file copy to the else clause. > > Reported-by: Mathieu Othacehe <othacehe@gnu.org> [...] > + ((or #+comp (tarball? #+source)) > + (repack directory #$output)) Would (tarball? #+source) be enough? Otherwise LGTM! (Too bad I had overlooked this patch, it would have been nice to be done with world rebuilds.) Thanks, Ludo’.
Hello! Ludovic Courtès <ludo@gnu.org> writes: > Hi, > > Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis: > >> Fixes <https://issues.guix.gnu.org/50066>. >> >> * guix/packages.scm (patch-and-repack): Test for a tarball using tarball? and >> move the plain file copy to the else clause. >> >> Reported-by: Mathieu Othacehe <othacehe@gnu.org> > > [...] > >> + ((or #+comp (tarball? #+source)) >> + (repack directory #$output)) > > Would (tarball? #+source) be enough? No! Because any (non-tarball) compressed archives (of the types handled by compressor in (guix build utils) must also be repacked) :-). > Otherwise LGTM! (Too bad I had overlooked this patch, it would have > been nice to be done with world rebuilds.) Yeah. I'm attempting to synchronize for the next rebuild. Thanks! Maxim
diff --git a/guix/packages.scm b/guix/packages.scm index 2349bb4340..f0dd1d43d2 100644 --- a/guix/packages.scm +++ b/guix/packages.scm @@ -836,10 +836,10 @@ specifies modules in scope when evaluating SNIPPET." ((file-is-directory? #+source) (copy-recursively directory #$output #:log (%make-void-port "w"))) - ((not #+comp) - (copy-file file #$output)) - (else - (repack directory #$output))))))) + ((or #+comp (tarball? #+source)) + (repack directory #$output)) + (else ;single uncompressed file + (copy-file file #$output))))))) (let ((name (if (or (checkout? original-file-name) (not (compressor original-file-name)))