diff mbox series

[bug#74290,12/31] gnu: libstdc++: Support the 64bit Hurd.

Message ID 1351fabb950e28169511b86e1e85fc197eac1674.1731232753.git.janneke@gnu.org
State New
Headers show
Series Add support for x86_64-gnu, aka the 64bit Hurd. | expand

Commit Message

Janneke Nieuwenhuizen Nov. 10, 2024, 10:38 a.m. UTC
* gnu/packages/gcc.scm (make-libstdc++)[arguments]: When building for the
64bit Hurd, add stage patch-hurd64.

Change-Id: I795a591ef8282ee5b760fec43bd4ad849007f602
---
 gnu/packages/gcc.scm | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm
index fc3746fb05..850a14cb1c 100644
--- a/gnu/packages/gcc.scm
+++ b/gnu/packages/gcc.scm
@@ -1033,7 +1033,15 @@  (define-public (make-libstdc++ gcc)
                   (("/lib64") "/lib")))))
           (add-before 'configure 'chdir
             (lambda _
-              (chdir "libstdc++-v3"))))
+              (chdir "libstdc++-v3")))
+          #$@(let ((version (package-version gcc)))
+               (if (target-hurd64?)
+                   #~((add-after 'unpack 'patch-hurd64
+                        (lambda _
+                          (substitute* "libstdc++-v3/src/c++20/tzdb.cc"
+                            (("#if ! defined _GLIBCXX_ZONEINFO_DIR")
+                             "#if __GNU__ || ! defined _GLIBCXX_ZONEINFO_DIR")))))
+                   '())))
 
       #:configure-flags '`("--disable-libstdcxx-pch"
                            ,(string-append "--with-gxx-include-dir="