From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
To: Janneke Nieuwenhuizen <janneke@gnu.org>
Cc: guix-devel@gnu.org, "Ludovic Courtès" <ludo@gnu.org>
Subject: Re: [core-updates] Native build of make-boot0 fails on missing zstd
Date: Sun, 21 Jan 2024 12:58:27 -0500 [thread overview]
Message-ID: <874jf6a7r0.fsf@gmail.com> (raw)
In-Reply-To: <87h6j6lgf5.fsf@gnu.org> (Janneke Nieuwenhuizen's message of "Sun, 21 Jan 2024 18:55:42 +0100")
Hi Janneke,
Janneke Nieuwenhuizen <janneke@gnu.org> writes:
> Maxim Cournoyer writes:
>
> Hi,
>
>> Efraim Flashner <efraim@flashner.co.il> writes:
>>
>>> On Sun, Jan 21, 2024 at 10:33:37AM +0100, Janneke Nieuwenhuizen wrote:
>>>> Hi!
>>>>
>>>> On core-updates, running
>>>>
>>>> ./pre-inst-env guix build --system=i586-gnu -e '(@@ (gnu packages commencement) gnu-make-boot0)'
>>>>
>>>> fails for me with
>>>>
>>>> sh: zstd: command not found
>>>>
>>>> See log below. FWIW, using --system=i686-linux for example, works fine.
>>
>> I don't know what it'd only affect non-x86 systems, but I've noticed one
>> bug in my recent "default to zstd" repack logic, which would name a xz
>> tarball as .tar.zst. Perhaps tar then try to use zstd to decompress it,
>> even if it's really a xz compressed archive?
>
> Ah, that could be...
My previous diff included yet another bug... here's one that seems to
work fine:
--8<---------------cut here---------------start------------->8---
modified guix/packages.scm
@@ -949,10 +949,7 @@ (define* (patch-and-repack source patches
(bzip2 (lookup-input "bzip2"))
(lzip (lookup-input "lzip"))
(xz (lookup-input "xz"))
- (zstd (or (lookup-input "zstd")
- ;; Fallback to xz in case zstd is not available, such as
- ;; for bootstrap packages.
- xz))
+ (zstd (lookup-input "zstd"))
(patch (lookup-input "patch"))
(comp (and=> (compressor source-file-name) lookup-input))
(patches (map instantiate-patch patches)))
@@ -1033,10 +1030,13 @@ (define* (patch-and-repack source patches
locale (system-error-errno args)))))
(setenv "PATH"
- (string-append #+zstd "/bin"
- (if #+comp
- (string-append ":" #+comp "/bin")
- "")))
+ (string-join
+ (map (cut string-append <> "/bin")
+ ;; Fallback to xz in case zstd is not
+ ;; available, such as for bootstrap packages.
+ (delete-duplicates
+ (filter-map identity (list #+zstd #+xz #+comp))))
+ ":"))
--8<---------------cut here---------------end--------------->8---
I'll push this to core-updates along a list of cherry-picked changes
from our tracker destined for core-updates, if it tests good on your
side.
--
Thanks,
Maxim
next prev parent reply other threads:[~2024-01-21 17:58 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-21 9:33 [core-updates] Native build of make-boot0 fails on missing zstd Janneke Nieuwenhuizen
2024-01-21 11:19 ` Efraim Flashner
2024-01-21 16:36 ` Maxim Cournoyer
2024-01-21 17:55 ` Janneke Nieuwenhuizen
2024-01-21 17:58 ` Maxim Cournoyer [this message]
2024-01-21 18:07 ` Janneke Nieuwenhuizen
2024-01-21 18:11 ` Maxim Cournoyer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874jf6a7r0.fsf@gmail.com \
--to=maxim.cournoyer@gmail.com \
--cc=guix-devel@gnu.org \
--cc=janneke@gnu.org \
--cc=ludo@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).