Subject: bug#41982: [PATCH 0/1] gnu: grub: Cross-build fix for system i686-linux.

From: Ludovic Courtès <[email-masked]>
Date: Tue, 23 Jun 2020 11:27:58 +0200

Hi,

Jan Nieuwenhuizen <[email-masked]> skribis:

> Attempting to reconfigure a i686-linux guix system to a Hurd system, I
> found that the Grub(-minimal) cross build fails like this
>
> lib/i386/relocator64.S: Assembler messages:
> lib/i386/relocator64.S:66: Error: unknown pseudo-op: `.code64'
> lib/i386/relocator64.S:74: Error: bad register name `%rax'
> lib/i386/relocator64.S:98: Error: bad register name `%rax'
> lib/i386/relocator64.S:132: Error: bad register name `%rip)'

Interesting.  Why doesn’t it happen when doing:

  guix build grub-minimal -s i686-linux

?  That’s because ‘as’ supports ‘.code64’ there?

> I am not sure if and how to report this upstream.  Ideas for a bug
> description?  Apparently, non-cross builds "just" work (how?!).

The issue seems to be that ‘.code64’ is not supported by cross
assemblers to 32-bit Intel, right?

Is this a defect of cross-as in general, or a misconfiguration in our
Guix package?  Or is this normal behavior that should be fixed in GRUB?

Anyway, the patch LGTM!

Thanks,
Ludo’.