guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: gnu: llvm-9: Fix building on riscv64-linux.


From: guix-commits
Subject: branch master updated: gnu: llvm-9: Fix building on riscv64-linux.
Date: Wed, 22 Jun 2022 02:47:14 -0400

This is an automated email from the git hooks/post-receive script.

efraim pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new 0ea51a8177 gnu: llvm-9: Fix building on riscv64-linux.
0ea51a8177 is described below

commit 0ea51a817784125a32bbc96a524b2fe95a26034a
Author: Efraim Flashner <efraim@flashner.co.il>
AuthorDate: Wed Jun 22 09:23:28 2022 +0300

    gnu: llvm-9: Fix building on riscv64-linux.
    
    * gnu/packages/llvm.scm (llvm-9)[arguments]: When building for
    riscv64-linux add a phase to fix building one of the binaries.
---
 gnu/packages/llvm.scm | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 32625385ff..6e12c3ebde 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -878,7 +878,22 @@ of programming tools as well as libraries with equivalent 
functionality.")
        (patches (search-patches
                  "llvm-9-fix-bitcast-miscompilation.patch"
                  "llvm-9-fix-scev-miscompilation.patch"
-                 "llvm-9-fix-lpad-miscompilation.patch"))))))
+                 "llvm-9-fix-lpad-miscompilation.patch"))))
+    (arguments
+     (if (target-riscv64?)
+       (substitute-keyword-arguments (package-arguments llvm-10)
+         ((#:phases phases)
+          `(modify-phases ,phases
+             (add-after 'unpack 'patch-dsymutil-link
+               (lambda _
+                 (substitute* "tools/dsymutil/CMakeLists.txt"
+                   (("endif\\(APPLE\\)")
+                    (string-append
+                      "endif(APPLE)\n\n"
+                      "if (CMAKE_HOST_SYSTEM_PROCESSOR MATCHES \"riscv64\")\n"
+                      "  target_link_libraries(dsymutil PRIVATE atomic)\n"
+                      "endif()"))))))))
+       (package-arguments llvm-10)))))
 
 (define-public clang-runtime-9
   (clang-runtime-from-llvm



reply via email to

[Prev in Thread] Current Thread [Next in Thread]