@@ -296,6 +296,7 @@ function generate_compiler_wrappers!(platform::AbstractPlatform; bin_path::Abstr
296296 end
297297
298298 function macos_version (kernel_version:: Integer )
299+ # See https://en.wikipedia.org/wiki/Darwin_(operating_system)#Release_history
299300 kernel_to_macos = Dict (
300301 12 => " 10.8" ,
301302 13 => " 10.9" ,
@@ -306,6 +307,7 @@ function generate_compiler_wrappers!(platform::AbstractPlatform; bin_path::Abstr
306307 18 => " 10.14" ,
307308 19 => " 10.15" ,
308309 20 => " 11.0" ,
310+ 21 => " 12.0" ,
309311 )
310312 return get (kernel_to_macos, kernel_version, nothing )
311313 end
@@ -320,7 +322,7 @@ function generate_compiler_wrappers!(platform::AbstractPlatform; bin_path::Abstr
320322
321323 # Eventually, we'll take this in `os_version(p)`, but not just yet. We need to fix the paths
322324 # to the compiler shards first, since right now they have `14` at the end
323- version = v " 14.0.0"
325+ version = something ( os_version (p), v " 14.0.0" )
324326 return macos_version (version. major)
325327 end
326328
@@ -391,8 +393,7 @@ function generate_compiler_wrappers!(platform::AbstractPlatform; bin_path::Abstr
391393 end
392394
393395 # Simulate some of the `__OSX_AVAILABLE()` macro usage that is broken in GCC
394- # Currently, we only target 10.10, but eventually, we'll want to tailor this to `os_version(p)`
395- if Sys. isapple (p) && 14 < 16
396+ if Sys. isapple (p) && something (os_version (p), v " 14" ) < v " 16"
396397 # Disable usage of `clock_gettime()`
397398 push! (flags, " -D_DARWIN_FEATURE_CLOCK_GETTIME=0" )
398399 end
0 commit comments