|
27 | 27 | }: |
28 | 28 |
|
29 | 29 | let |
| 30 | + atLeast15 = lib.versionAtLeast version "15"; |
30 | 31 | atLeast14 = lib.versionAtLeast version "14"; |
31 | 32 | atLeast13 = lib.versionAtLeast version "13"; |
32 | 33 | atLeast12 = lib.versionAtLeast version "12"; |
33 | 34 | atLeast11 = lib.versionAtLeast version "11"; |
34 | 35 | atLeast10 = lib.versionAtLeast version "10"; |
| 36 | + is15 = majorVersion == "15"; |
35 | 37 | is14 = majorVersion == "14"; |
36 | 38 | is13 = majorVersion == "13"; |
37 | 39 | is12 = majorVersion == "12"; |
|
150 | 152 |
|
151 | 153 | # Fixes detection of Darwin on x86_64-darwin. Otherwise, GCC uses a deployment target of 10.5, which crashes ld64. |
152 | 154 | ++ optional ( |
153 | | - atLeast14 && stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64 |
| 155 | + is14 && stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64 |
154 | 156 | ) ../patches/14/libgcc-darwin-detection.patch |
| 157 | +++ optional ( |
| 158 | + atLeast15 && stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64 |
| 159 | +) ../patches/15/libgcc-darwin-detection.patch |
155 | 160 |
|
156 | 161 | # Fix detection of bootstrap compiler Ada support (cctools as) on Nix Darwin |
157 | 162 | ++ optional ( |
|
166 | 171 | # Use absolute path in GNAT dylib install names on Darwin |
167 | 172 | ++ optionals (stdenv.hostPlatform.isDarwin && langAda) ( |
168 | 173 | { |
| 174 | + "15" = [ ../patches/14/gnat-darwin-dylib-install-name-14.patch ]; |
169 | 175 | "14" = [ ../patches/14/gnat-darwin-dylib-install-name-14.patch ]; |
170 | 176 | "13" = [ ./gnat-darwin-dylib-install-name-13.patch ]; |
171 | 177 | "12" = [ ./gnat-darwin-dylib-install-name.patch ]; |
|
175 | 181 |
|
176 | 182 | ++ optionals canApplyIainsDarwinPatches ( |
177 | 183 | { |
| 184 | + "15" = [ |
| 185 | + (fetchpatch { |
| 186 | + name = "gcc-15-darwin-aarch64-support.patch"; |
| 187 | + url = "https://raw.githubusercontent.com/Homebrew/formula-patches/a25079204c1cb3d78ba9dd7dd22b8aecce7ce264/gcc/gcc-15.1.0.diff"; |
| 188 | + sha256 = "sha256-MJxSGv6LEP1sIM8cDqbmfUV7byV0bYgADeIBY/Teyu8="; |
| 189 | + }) |
| 190 | + ]; |
178 | 191 | "14" = [ |
179 | 192 | (fetchpatch { |
180 | 193 | name = "gcc-14-darwin-aarch64-support.patch"; |
|
0 commit comments