guix-commits
[Top][All Lists]
Advanced

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

branch core-updates-frozen updated: gnu: llvm-3.6: Fix build.


From: guix-commits
Subject: branch core-updates-frozen updated: gnu: llvm-3.6: Fix build.
Date: Thu, 07 Oct 2021 08:26:42 -0400

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

glv pushed a commit to branch core-updates-frozen
in repository guix.

The following commit(s) were added to refs/heads/core-updates-frozen by this 
push:
     new 99d288a  gnu: llvm-3.6: Fix build.
99d288a is described below

commit 99d288a6b1efba1ce53f07b01644bd8932979d4f
Author: Guillaume Le Vaillant <glv@posteo.net>
AuthorDate: Thu Oct 7 14:21:25 2021 +0200

    gnu: llvm-3.6: Fix build.
    
    * gnu/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch: New file.
    * gnu/local.mk (dist_patch_DATA): Add it.
    * gnu/packages/llvm.scm (llvm-3.6)[source]: Use it.
---
 gnu/local.mk                                              |  1 +
 gnu/packages/llvm.scm                                     |  3 +++
 gnu/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch | 13 +++++++++++++
 3 files changed, 17 insertions(+)

diff --git a/gnu/local.mk b/gnu/local.mk
index bfecbfa..dfb9e50 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1409,6 +1409,7 @@ dist_patch_DATA =                                         
\
   %D%/packages/patches/lirc-reproducible-build.patch           \
   %D%/packages/patches/llhttp-bootstrap-CVE-2020-8287.patch    \
   %D%/packages/patches/llvm-3.5-fix-clang-build-with-gcc5.patch        \
+  %D%/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch    \
   %D%/packages/patches/llvm-9-fix-bitcast-miscompilation.patch \
   %D%/packages/patches/llvm-9-fix-lpad-miscompilation.patch    \
   %D%/packages/patches/llvm-9-fix-scev-miscompilation.patch    \
diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 3d62965..debcbf8 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -20,6 +20,7 @@
 ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be>
 ;;; Copyright © 2021 Julien Lepiller <julien@lepiller.eu>
 ;;; Copyright © 2021 Lars-Dominik Braun <lars@6xq.net>
+;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -841,6 +842,8 @@ of programming tools as well as libraries with equivalent 
functionality.")
      (origin
        (method url-fetch)
        (uri (llvm-uri "llvm" version))
+       (patches
+        (search-patches "llvm-3.6-fix-build-with-gcc-10.patch"))
        (sha256
         (base32
          "153vcvj8gvgwakzr4j0kndc0b7wn91c2g1vy2vg24s6spxcc23gn"))))))
diff --git a/gnu/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch 
b/gnu/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch
new file mode 100644
index 0000000..4982587
--- /dev/null
+++ b/gnu/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch
@@ -0,0 +1,13 @@
+Adapted from https://github.com/digego/extempore/pull/322/files
+
+--- a/include/llvm/IR/ValueMap.h       2015-08-04 00:30:24.000000000 +0200
++++ b/include/llvm/IR/ValueMap.h       2018-07-14 21:09:09.769502736 +0200
+@@ -99,7 +99,7 @@
+   explicit ValueMap(const ExtraData &Data, unsigned NumInitBuckets = 64)
+       : Map(NumInitBuckets), Data(Data) {}
+
+-  bool hasMD() const { return MDMap; }
++  bool hasMD() const { return static_cast<bool>(MDMap); }
+   MDMapT &MD() {
+     if (!MDMap)
+       MDMap.reset(new MDMapT);



reply via email to

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