GNU bug report logs - #49244
[PATCH] gnu: grub-efi: Only enable the stack protector on x86_64-linux.

Previous Next

Package: guix-patches;

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

Date: Sun, 27 Jun 2021 18:48:02 UTC

Severity: normal

Tags: patch

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

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 49244 in the body.
You can then email your comments to 49244 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 guix-patches <at> gnu.org:
bug#49244; Package guix-patches. (Sun, 27 Jun 2021 18:48:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Christopher Baines <mail <at> cbaines.net>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sun, 27 Jun 2021 18:48:02 GMT) Full text and rfc822 format available.

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

From: Christopher Baines <mail <at> cbaines.net>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: grub-efi: Only enable the stack protector on
 x86_64-linux.
Date: Sun, 27 Jun 2021 19:47:08 +0100
Follow up to 018f95094153660e3041ec160718f0bda286a3dc, as gcc on aarch64-linux
doesn't seem to support -mstack-protector-guard=global.

* gnu/packages/bootloaders.scm (grub-efi)[arguments]: Only add
"--enable-stack-protector" to #:configure-flags when system is x86_64-linux.
---
 gnu/packages/bootloaders.scm | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm
index e83f21ea63..1ff0348ac7 100644
--- a/gnu/packages/bootloaders.scm
+++ b/gnu/packages/bootloaders.scm
@@ -303,7 +303,10 @@ menu to select one of the installed operating systems.")
            ((#:tests? _ #f) #f)
            ((#:configure-flags flags ''())
             `(cons* "--with-platform=efi"
-                    "--enable-stack-protector" ; EFI-only for now
+                    ,@(if (string=? (%current-system)
+                                    "x86_64-linux")
+                          '("--enable-stack-protector") ; EFI-only for now
+                          '())
                     ,flags))
            ((#:phases phases)
             `(modify-phases ,phases
-- 
2.32.0





Information forwarded to guix-patches <at> gnu.org:
bug#49244; Package guix-patches. (Tue, 29 Jun 2021 15:37:01 GMT) Full text and rfc822 format available.

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

From: Mathieu Othacehe <othacehe <at> gnu.org>
To: Christopher Baines <mail <at> cbaines.net>
Cc: 49244 <at> debbugs.gnu.org
Subject: Re: bug#49244: [PATCH] gnu: grub-efi: Only enable the stack
 protector on x86_64-linux.
Date: Tue, 29 Jun 2021 17:36:18 +0200
Hey Chris,

> +                    ,@(if (string=? (%current-system)
> +                                    "x86_64-linux")
> +                          '("--enable-stack-protector") ; EFI-only for now
> +                          '())

Maybe we should also avoid this option when cross-compiling? Otherwise
it looks OK.

Thanks,

Mathieu




Information forwarded to guix-patches <at> gnu.org:
bug#49244; Package guix-patches. (Wed, 30 Jun 2021 15:16:02 GMT) Full text and rfc822 format available.

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

From: Maxime Devos <maximedevos <at> telenet.be>
To: Mathieu Othacehe <othacehe <at> gnu.org>, Christopher Baines <mail <at> cbaines.net>
Cc: 49244 <at> debbugs.gnu.org
Subject: Re: [bug#49244] [PATCH] gnu: grub-efi: Only enable the stack
 protector on x86_64-linux.
Date: Wed, 30 Jun 2021 17:14:56 +0200
[Message part 1 (text/plain, inline)]
Mathieu Othacehe schreef op di 29-06-2021 om 17:36 [+0200]:
> Hey Chris,
> 
> > +                    ,@(if (string=? (%current-system)
> > +                                    "x86_64-linux")
> > +                          '("--enable-stack-protector") ; EFI-only for now
> > +                          '())
> 
> Maybe we should also avoid this option when cross-compiling? Otherwise
> it looks OK.

Or rather,
(string-prefix? (or (%current-target-system) (%current-system)) "x86_64")
(or was it the other way around)?

Greetings,
Maxime.
[signature.asc (application/pgp-signature, inline)]

Reply sent to Christopher Baines <mail <at> cbaines.net>:
You have taken responsibility. (Thu, 01 Jul 2021 23:31:01 GMT) Full text and rfc822 format available.

Notification sent to Christopher Baines <mail <at> cbaines.net>:
bug acknowledged by developer. (Thu, 01 Jul 2021 23:31:02 GMT) Full text and rfc822 format available.

Message #16 received at 49244-done <at> debbugs.gnu.org (full text, mbox):

From: Christopher Baines <mail <at> cbaines.net>
To: 49244-done <at> debbugs.gnu.org
Cc: Mathieu Othacehe <othacehe <at> gnu.org>
Subject: Re: bug#49244: [PATCH] gnu: grub-efi: Only enable the stack
 protector on x86_64-linux.
Date: Fri, 02 Jul 2021 00:30:58 +0100
[Message part 1 (text/plain, inline)]
Mathieu Othacehe <othacehe <at> gnu.org> writes:

> Hey Chris,
>
>> +                    ,@(if (string=? (%current-system)
>> +                                    "x86_64-linux")
>> +                          '("--enable-stack-protector") ; EFI-only for now
>> +                          '())
>
> Maybe we should also avoid this option when cross-compiling? Otherwise
> it looks OK.

Yeah, I was trying to test the cross-compiling case, but I think
something else fails regardless. Anyway, I've pushed something similar
to what Maxime suggested as fd549750d9ab23a0505aeb4c03e1299e860a4f16.

Thanks,

CHris
[signature.asc (application/pgp-signature, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 30 Jul 2021 11:24:07 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 263 days ago.

Previous Next


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