about summary refs log tree commit diff
path: root/pkgs/development/compilers/gcc/10/default.nix
diff options
context:
space:
mode:
authorJohn Ericson <git@JohnEricson.me>2023-01-17 11:45:29 -0500
committerGitHub <noreply@github.com>2023-01-17 11:45:29 -0500
commit2c48770293cf1a2690090ea6aa6a992bddf48fab (patch)
tree2bd9e8fc4eefd443883e045cfebf0d59bb85c461 /pkgs/development/compilers/gcc/10/default.nix
parent37c965dc7be847f5828733492c0d2d08263d7681 (diff)
parentd6d18979043b65685de9163743558ece2365d18f (diff)
Merge pull request #210816 from obsidiansystems/gcc-fix-bug-80431
gcc: Backport fix of GCC Issue 80431 from version 12
Diffstat (limited to 'pkgs/development/compilers/gcc/10/default.nix')
-rw-r--r--pkgs/development/compilers/gcc/10/default.nix10
1 files changed, 8 insertions, 2 deletions
diff --git a/pkgs/development/compilers/gcc/10/default.nix b/pkgs/development/compilers/gcc/10/default.nix
index 7de8b14ac24ff..25eae9e77e0f0 100644
--- a/pkgs/development/compilers/gcc/10/default.nix
+++ b/pkgs/development/compilers/gcc/10/default.nix
@@ -51,8 +51,14 @@ let majorVersion = "10";
 
     inherit (stdenv) buildPlatform hostPlatform targetPlatform;
 
-    patches = [ ]
-      ++ optional (targetPlatform != hostPlatform) ../libstdc++-target.patch
+    patches = [
+      # Fix https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80431
+      (fetchurl {
+        name = "fix-bug-80431.patch";
+        url = "https://gcc.gnu.org/git/?p=gcc.git;a=patch;h=de31f5445b12fd9ab9969dc536d821fe6f0edad0";
+        sha256 = "0sd52c898msqg7m316zp0ryyj7l326cjcn2y19dcxqp15r74qj0g";
+      })
+    ] ++ optional (targetPlatform != hostPlatform) ../libstdc++-target.patch
       ++ optional noSysDirs ../no-sys-dirs.patch
       ++ optional (noSysDirs && hostPlatform.isRiscV) ../no-sys-dirs-riscv.patch
       /* ++ optional (hostPlatform != buildPlatform) (fetchpatch { # XXX: Refine when this should be applied