GNU bug report logs - #70985
[PATCH 0/4] Use specific errors for unsupported targets

Previous Next

Package: guix-patches;

Reported by: Christopher Baines <mail <at> cbaines.net>

Date: Thu, 16 May 2024 15:01:02 UTC

Severity: normal

Tags: patch

Done: Christopher Baines <mail <at> cbaines.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Christopher Baines <mail <at> cbaines.net>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 70985 <at> debbugs.gnu.org
Subject: [bug#70985] [PATCH 4/4] guix: build-system: meson: Don't error on unsupported targets.
Date: Thu, 16 May 2024 17:10:16 +0100
[Message part 1 (text/plain, inline)]
Ludovic Courtès <ludo <at> gnu.org> writes:

> Christopher Baines <mail <at> cbaines.net> writes:
>
>> Rather than raising generic errors.
>>
>> * guix/build-system/meson.scm (make-machine-alist): Return #f if the triplet
>> is unsupported.
>> (lower): Return #f if the machine alist is #f.
>>
>> Change-Id: If6a1f8d1c2073e43107406ac186aa9c845005a95
>
> [...]
>
>> +  (and
>> +   (make-machine-alist target)
>
> I think this call is unnecessary (and kinda confusing because
> ‘make-machine-alist’ is a pure function) because ‘meson-cross-build’
> calls ‘make-cross-file’, which calls ‘make-machine-alist’.

The situation here is that the meson build system does support cross
builds, but make-machine-alist calls error for some targets which I'm
treating as a bug here, because error isn't really machine readable.

I think this line should actually be (or (not target)
(make-machine-alist target)) to handle the case where the target is #f,
but this is sort of helpful in that it changes the error to the usual
error when the build system doesn't support cross builds.

This is still far from perfect though as the UI would say that "build
system `meson' does not support cross builds", which is obviously wrong,
it just doesn't support cross builds for the given target. I'm not sure
how to signal this though?
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 338 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.