Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions src/libraries/Common/src/Interop/OSX/Interop.libobjc.cs
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,17 @@ internal static Version GetOperatingSystemVersion()
}
}

if (major == 10 && minor == 16)
#if TARGET_OSX
if (major == 16)
{
// We get "compat" version for 11.0 unless we build with updated SDK.
// Hopefully that will be before 11.x comes out
// For now, this maps 10.16 to 11.0.
major = 11;
minor = 0;
// MacOS Tahoe returns a compatibility version unless it is built with a new SDK. Map the compatibility
// version to the "correct" version. This assumes the minor versions will map unchanged.
// 16.0 => 26.0
// 16.1 => 26.1
// etc
major = 26;
}
#endif

return new Version(major, minor, patch);
}
Expand Down
Loading