home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   linux.debian.bugs.dist      Ohh some weird Debian bug report thing      28,835 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 27,353 of 28,835   
   Emanuele Rocca to All   
   Bug#1127747: binutils: Please build with   
   12 Feb 26 15:30:01   
   
   From: ema@debian.org   
      
   Source: binutils   
   Version: 2.46-1   
   User: debian-arm@lists.debian.org   
   Usertags: pac-bti, gcs   
      
   Hi Matthias,   
      
   please consider the attached patch to build binutils with PAC/BTI/GCS   
   support. I have explicitly distinguished between CFLAGS and CXXFLAGS   
   because a user could choose to override them individually, for whatever   
   reasons.   
      
   After building the package with the patch, all ELF files get the   
   features enabled, see:   
   https://people.debian.org/~ema/binutils-gcs.txt   
      
   Building with DEB_BUILD_MAINT_OPTIONS=hardening=-branch, the flags are   
   not set as expected.   
      
   Other than a native build, I have also tested cross-building binutils on   
   a x86 system with `sbuild --host arm64` and that works fine too.   
      
   Thanks,   
     ema   
      
   From c7efba8b4520196c0f2a26d4fd7ca13f071b3d20 Mon Sep 17 00:00:00 2001   
   From: Emanuele Rocca    
   Date: Thu, 12 Feb 2026 10:55:46 +0100   
   Subject: [PATCH] Enable PAC/BTI/GCS on arm64   
      
   ---   
    debian/changelog | 6 ++++++   
    debian/rules     | 8 ++++++++   
    2 files changed, 14 insertions(+)   
      
   diff --git a/debian/changelog b/debian/changelog   
   index f8ca1487..6e94fe51 100644   
   --- a/debian/changelog   
   +++ b/debian/changelog   
   @@ -1,3 +1,9 @@   
   +binutils (2.46-2) UNRELEASED; urgency=medium   
   +   
   +  * Enable PAC/BTI/GCS on arm64.   
   +   
   + -- Emanuele Rocca   Thu, 12 Feb 2026 10:55:09 +0100   
   +   
    binutils (2.46-1) unstable; urgency=medium   
      
      * binutils 2.46 release.   
   diff --git a/debian/rules b/debian/rules   
   index 47569018..909619a5 100755   
   --- a/debian/rules   
   +++ b/debian/rules   
   @@ -272,6 +272,14 @@ ifneq (,$(shell dpkg-buildflags | grep '^CF   
   AGS=.*-mbackchain'))   
      CFLAGS += -mbackchain   
      CXXFLAGS += -mbackchain   
    endif   
   +ifeq ($(DEB_HOST_ARCH),arm64)   
   +  ifneq (,$(findstring -mbranch-protection=standard,$(shell dpkg-buildflags   
   --get CFLAGS)))   
   +    CFLAGS += -mbranch-protection=standard   
   +  endif   
   +  ifneq (,$(findstring -mbranch-protection=standard,$(shell dpkg-buildflags   
   --get CXXFLAGS)))   
   +    CXXFLAGS += -mbranch-protection=standard   
   +  endif   
   +endif   
    STRIP  = $(CROSS)strip -R .comment -R .note   
    STRIP_LTO = $(CROSS)strip -R .gnu.lto_* -R .gnu.debuglto_* -N __gnu_lto_slim   
   -N __gnu_lto_v1   
      
   --   
   2.43.0   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca