guix_mirror_bot pushed a commit to branch core-packages-team
in repository guix.

commit 3d368021cd506173bcb16f4155a28ae7b431d83f
Author: Andreas Enge <[email protected]>
AuthorDate: Tue Jul 15 20:34:55 2025 +0200

    gnu: gdb@12: Fix build on aarch64.
    
    * gnu/packages/gdb.scm (gdb/pinned)[arguments]<#:phases>: Add
    'patch-aarch64 only on aarch64.
    
    Change-Id: I9715dfe53140bfc2adf56e7a165ea0a2c74e96a3
---
 gnu/packages/gdb.scm | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/gnu/packages/gdb.scm b/gnu/packages/gdb.scm
index 2966b8f87e..14468e6b73 100644
--- a/gnu/packages/gdb.scm
+++ b/gnu/packages/gdb.scm
@@ -7,6 +7,7 @@
 ;;; Copyright © 2020, 2021, 2024 Janneke Nieuwenhuizen <[email protected]>
 ;;; Copyright © 2020, 2021 Maxim Cournoyer <[email protected]>
 ;;; Copyright © 2025 Zheng Junjie <[email protected]>
+;;; Copyright © 2025 Andreas Enge <[email protected]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -70,6 +71,16 @@
                             #~'("--enable-targets=i586-pc-gnu,x86_64-pc-gnu")
                             #~'())
       #:phases #~(modify-phases %standard-phases
+                   ;; The following phase only applies to gdb@12, which
+                   ;; inherits from this package. Remove it when removing
+                   ;; gdb@12.
+                   #$@(if (target-aarch64?)
+                     #~((add-after 'unpack 'patch-aarch64
+                       (lambda _
+                         (substitute* "sim/aarch64/cpustate.h"
+                           (("aarch64_get_CPSR_bits  \\(sim_cpu \\*, 
uint32_t\\)")
+                             "aarch64_get_CPSR_bits  (sim_cpu *, 
FlagMask)")))))
+                     #~())
                    (add-after 'unpack 'patch-paths
                      (lambda* (#:key inputs #:allow-other-keys)
                        (let ((sh (string-append (assoc-ref inputs "bash")

Reply via email to