-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Description
This issue is to discuss what the final identifier will be within the entire public API surface and what will be the build target identifier that msbuild will use.
https://github.com/dotnet/corefx/issues/1576 started the discussion of wether to use OSName("FreeBSD") vs OSName("BSD") in the unit tests and is recommended reading before progressing with reading this issue. FreeBSD won but it can be easily refactored due to being a non-public contract.
The BSD's (FreeBSD/NetBSD/OpenBSD/DragonFlyBSD) unlike Linux all have different kernels so potentially it might be required to split them out as separate platforms. This might be completely unnecessary whereby the additional BSD's may just work as a direct result of the port team's efforts. There are enough differences between the different BSDs that it could be needed to differentiate between them however.
We have some time before a decision needs to be cemented in as there is a more pressing issue as mentioned by @stephentoub and registered as issue dotnet/corefx#1626
There's what's likely a more pressing issue, which is actually building for FreeBSD. Today, when we need to specialize an assembly for a particular platform, we effectively have three builds, producing three different managed assemblies: Windows, Linux, OSX. Sounds like at least for now we'll need a fourth, FreeBSD. I suggest you start by modifying the build to support an IsFreeBSD property (or just IsBSD of you think there's a high chance that the implementations across BSDs will be the same even with varied kernels) along with the appropriate OSGroup targets. That can then be used in the csproj files as needed to specialize an assembly with FreeBSD-specific code.
I feel uneasy about using either OSName("FreeBSD") (platform fragmentation) or OSName("BSD") (too generic) with the amount of information available at this point in time but obviously a direction needs to be chosen.
@janhenke @josteink (core members of the portteam) have put forward on multiple times that they would prefer FreeBSD and I have no strong preferences in any which direction as long as the future implications are considered carefully because this decision affects the public API surface.
Ultimately advice, direction and a decision will be needed by MSFT on this matter.
note: issue was edited/refactored based on feedback from josenink since original post.