about summary refs log tree commit diff
path: root/pkgs/development/compilers/gcc
diff options
context:
space:
mode:
authorThomas Watson <twatson52@icloud.com>2022-05-04 23:11:45 -0500
committerThomas Watson <twatson52@icloud.com>2022-05-05 08:11:09 -0500
commitec87e38d65d4ea1fa7ab76c7efe70098e36769d0 (patch)
treeaed32d0b477cb14ea6453a3f7732114158e64503 /pkgs/development/compilers/gcc
parentae265ec922e39a2d6762aaf42072d44734596a4c (diff)
Revert "gcc: 11.2.0 -> 11.3.0" for aarch64-darwin
Patches to support GCC 11.3.0 on aarch64-darwin are not available. Homebrew
also is skipping the 11.3.0 upgrade.
Diffstat (limited to 'pkgs/development/compilers/gcc')
-rw-r--r--pkgs/development/compilers/gcc/11/default.nix11
1 files changed, 9 insertions, 2 deletions
diff --git a/pkgs/development/compilers/gcc/11/default.nix b/pkgs/development/compilers/gcc/11/default.nix
index 7405050620276..ba4b10cf73ea8 100644
--- a/pkgs/development/compilers/gcc/11/default.nix
+++ b/pkgs/development/compilers/gcc/11/default.nix
@@ -52,7 +52,12 @@ with lib;
 with builtins;
 
 let majorVersion = "11";
-    version = "${majorVersion}.3.0";
+    # The patch below for aarch64-darwin does not apply to 11.3.0 and an
+    # updated version is not available. Keep aarch64-darwin on 11.2.0 so the
+    # large body of packages which depend on gfortran are still functional
+    # until GCC 12 is the default.
+    version = if (stdenv.isDarwin && stdenv.isAarch64) then
+      "${majorVersion}.2.0" else "${majorVersion}.3.0";
 
     inherit (stdenv) buildPlatform hostPlatform targetPlatform;
 
@@ -91,7 +96,9 @@ stdenv.mkDerivation ({
 
   src = fetchurl {
     url = "mirror://gcc/releases/gcc-${version}/gcc-${version}.tar.xz";
-    sha256 = "sha256-tHzygYaR9bHiHfK7OMeV+sLPvWQO3i0KXhyJ4zijrDk=";
+    sha256 = if (stdenv.isDarwin && stdenv.isAarch64)
+      then "sha256-0I7cU2tUw3KhAQ/2YZ3SdMDxYDqkkhK6IPeqLNo2+os="
+      else "sha256-tHzygYaR9bHiHfK7OMeV+sLPvWQO3i0KXhyJ4zijrDk=";
   };
 
   inherit patches;