GNU bug report logs - #60786
unsupported mips64el architecture can cause cryptic backtraces

Previous Next

Package: guix;

Reported by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Date: Fri, 13 Jan 2023 17:27:02 UTC

Severity: normal

Done: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 60786 in the body.
You can then email your comments to 60786 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#60786; Package guix. (Fri, 13 Jan 2023 17:27:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Maxim Cournoyer <maxim.cournoyer <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Fri, 13 Jan 2023 17:27:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: bug-guix <bug-guix <at> gnu.org>
Subject: cross-kernel-headers can produce broken packages
Date: Fri, 13 Jan 2023 12:26:20 -0500
Hello,

This issue was triggered by having make-uboot-package uses #:target [0],
but it already exists on current master.  I've spent some time narrowing
down the issue, and it is caused by the package returned by
cross-kernel-headers in (gnu packages cross-base) being produced with a
bogus arguments field, or at least one that can't be access via the
package-arguments accessor:

--8<---------------cut here---------------start------------->8---
(use-modules (guix packages)
             (gnu packages cross-base))

(define linux-libre-headers-cross-mips64el-linux-gnuabi64
  (cross-kernel-headers "mips64el-linux-gnuabi64"))

(package-arguments linux-libre-headers-cross-mips64el-linux-gnuabi64)

ice-9/boot-9.scm:1685:16: In procedure raise-exception:
In procedure struct-vtable: Wrong type argument in position 1 (expecting struct): #f

Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.
scheme@(guix-user) [1]> ,bt
In gnu/packages/cross-base.scm:
   388:33  1 (loop (#:phases (modify-phases %standard-phases (delete (quote configure)) (# (…) …) …) …) …)
In ice-9/boot-9.scm:
  1685:16  0 (raise-exception _ #:continuable? _)
--8<---------------cut here---------------end--------------->8---

[0]  https://issues.guix.gnu.org/60224#30

-- 
Thanks,
Maxim




Information forwarded to bug-guix <at> gnu.org:
bug#60786; Package guix. (Fri, 13 Jan 2023 22:13:02 GMT) Full text and rfc822 format available.

Message #8 received at 60786 <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: 60786 <at> debbugs.gnu.org
Subject: Re: bug#60786: cross-kernel-headers can produce broken packages
Date: Fri, 13 Jan 2023 17:12:11 -0500
Hello,

Maxim Cournoyer <maxim.cournoyer <at> gmail.com> writes:

> Hello,
>
> This issue was triggered by having make-uboot-package uses #:target [0],
> but it already exists on current master.  I've spent some time narrowing
> down the issue, and it is caused by the package returned by
> cross-kernel-headers in (gnu packages cross-base) being produced with a
> bogus arguments field, or at least one that can't be access via the
> package-arguments accessor:
>
> (use-modules (guix packages)
>              (gnu packages cross-base))
>
> (define linux-libre-headers-cross-mips64el-linux-gnuabi64
>   (cross-kernel-headers "mips64el-linux-gnuabi64"))
>
> (package-arguments linux-libre-headers-cross-mips64el-linux-gnuabi64)
>
> ice-9/boot-9.scm:1685:16: In procedure raise-exception:
> In procedure struct-vtable: Wrong type argument in position 1 (expecting struct): #f
>
> Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.
> scheme@(guix-user) [1]> ,bt
> In gnu/packages/cross-base.scm:
>    388:33  1 (loop (#:phases (modify-phases %standard-phases (delete (quote configure)) (# (…) …) …) …) …)
> In ice-9/boot-9.scm:
>   1685:16  0 (raise-exception _ #:continuable? _)
>
> [0]  https://issues.guix.gnu.org/60224#30

OK, I think I've found the culprit:

--8<---------------cut here---------------start------------->8---
                 (setenv "ARCH" ,(platform-linux-architecture
                                  (lookup-platform-by-target target)))
--8<---------------cut here---------------end--------------->8---

in the definition of cross-kernel-headers*, in (gnu packages
cross-base).

When the target is "mips64el-linux-gnuabi64", lookup-platform-by-target
returns #f, which platform-linux-architecture does not expect.

-- 
Thanks,
Maxim




Changed bug title to 'unsupported mips64el architecture can cause cryptic backtraces' from 'cross-kernel-headers can produce broken packages' Request was from Maxim Cournoyer <maxim.cournoyer <at> gmail.com> to control <at> debbugs.gnu.org. (Sat, 14 Jan 2023 03:11:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#60786; Package guix. (Sat, 14 Jan 2023 14:30:02 GMT) Full text and rfc822 format available.

Message #13 received at 60786 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Cc: 60786 <at> debbugs.gnu.org
Subject: Re: bug#60786: unsupported mips64el architecture can cause cryptic
 backtraces
Date: Sat, 14 Jan 2023 15:29:29 +0100
Hi,

Maxim Cournoyer <maxim.cournoyer <at> gmail.com> skribis:

> Maxim Cournoyer <maxim.cournoyer <at> gmail.com> writes:

[...]

>> This issue was triggered by having make-uboot-package uses #:target [0],
>> but it already exists on current master.  I've spent some time narrowing
>> down the issue, and it is caused by the package returned by
>> cross-kernel-headers in (gnu packages cross-base) being produced with a
>> bogus arguments field, or at least one that can't be access via the
>> package-arguments accessor:

It’s not that the field cannot be accessed; the field is thunked, and
thus exceptions can be thrown when you access it, as you found out:

> OK, I think I've found the culprit:
>
>                  (setenv "ARCH" ,(platform-linux-architecture
>                                   (lookup-platform-by-target target)))

Ludo’.




bug closed, send any further explanations to 60786 <at> debbugs.gnu.org and Maxim Cournoyer <maxim.cournoyer <at> gmail.com> Request was from Maxim Cournoyer <maxim.cournoyer <at> gmail.com> to control <at> debbugs.gnu.org. (Thu, 02 Feb 2023 16:15:01 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 03 Mar 2023 12:24:10 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 48 days ago.

Previous Next


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