Skip to content

Commit b37f10a

Browse files
authored
Changing Windows_NT -> Windows for enabling TargetPlatformMoniker feature of the sdk for platform specific tfms. (#43651)
* eng change * coreclr change * libraries change * tests change * installer & mono change * py files changed * .md change * .yml change * remove redundant targetos property * Windows_NT -> windows after ninja change * fixing runtime build failure
1 parent e691753 commit b37f10a

File tree

297 files changed

+754
-767
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

297 files changed

+754
-767
lines changed

docs/coding-guidelines/interop-guidelines.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ internal static partial class Interop // contents of Common\src\Interop\Windows\
120120
```
121121

122122
### Build System
123-
When building dotnet/runtime, we use the "TargetOS" property to control what target platform we are building for. The valid values for this property are Windows_NT (which is the default value from MSBuild when running on Windows), Linux and OSX.
123+
When building dotnet/runtime, we use the "TargetOS" property to control what target platform we are building for. The valid values for this property are windows (which is the default value from MSBuild when running on Windows), Linux and OSX.
124124

125125
#### Project Files
126126
Whenever possible, a single .csproj should be used per assembly, spanning all target platforms, e.g. System.Console.csproj includes conditional entries for when targeting Windows vs when targeting Linux. A property can be passed to dotnet build to control which flavor is built, e.g. `dotnet build /p:TargetOS=OSX System.Console.csproj`.

docs/coding-guidelines/project-guidelines.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Below is a list of all the various options we pivot the project builds on:
1616

1717
- **Target Frameworks:** .NETFramework, .NETStandard, .NETCoreApp
1818
- **Platform Runtimes:** .NETFramework (aka CLR/Desktop), CoreCLR, Mono
19-
- **OS:** Windows_NT, Linux, OSX, FreeBSD, AnyOS
19+
- **OS:** windows, Linux, OSX, FreeBSD, AnyOS
2020
- **Flavor:** Debug, Release
2121

2222
## Individual build properties
@@ -52,7 +52,7 @@ Pure netstandard configuration:
5252
All supported targets with unique windows/unix build for netcoreapp:
5353
```
5454
<PropertyGroup>
55-
<TargetFrameworks>$(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;net461-Windows_NT</TargetFrameworks>
55+
<TargetFrameworks>$(NetCoreAppCurrent)-windows;$(NetCoreAppCurrent)-Unix;net461-windows</TargetFrameworks>
5656
<PropertyGroup>
5757
```
5858

@@ -73,7 +73,7 @@ When building an individual project the `BuildTargetFramework` and `TargetOS` wi
7373

7474
## Supported full build settings
7575
- .NET Core latest on current OS (default) -> `$(NetCoreAppCurrent)-[RunningOS]`
76-
- .NET Framework latest -> `net48-Windows_NT`
76+
- .NET Framework latest -> `net48-windows`
7777

7878
# Library project guidelines
7979

@@ -100,7 +100,7 @@ Example:
100100
Example:
101101
```
102102
<PropertyGroup>
103-
<TargetFrameworks>netstandard2.0-Windows_NT;netstandard2.0-Unix</TargetFrameworks>
103+
<TargetFrameworks>netstandard2.0-windows;netstandard2.0-Unix</TargetFrameworks>
104104
</PropertyGroup>
105105
<ItemGroup Condition="$(TargetFramework.StartsWith('netstandard2.0'))>...</ItemGroup>
106106
```

docs/design/coreclr/jit/viewing-jit-dumps.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,8 @@ The first thing to do is setup the .NET Core app we want to dump. Here are the s
6363

6464
```shell
6565
# Windows
66-
robocopy /e <runtime-repo path>\artifacts\bin\coreclr\Windows_NT.<arch>.Release <app root>\bin\Release\net5.0\<rid>\publish > NUL
67-
copy /y <runtime-repo path>\artifacts\bin\coreclr\Windows_NT.<arch>.Debug\clrjit.dll <app root>\bin\Release\net5.0\<rid>\publish > NUL
66+
robocopy /e <runtime-repo path>\artifacts\bin\coreclr\windows.<arch>.Release <app root>\bin\Release\net5.0\<rid>\publish > NUL
67+
copy /y <runtime-repo path>\artifacts\bin\coreclr\windows.<arch>.Debug\clrjit.dll <app root>\bin\Release\net5.0\<rid>\publish > NUL
6868

6969
# Unix
7070
cp -rT <runtime-repo path>/artifacts/bin/coreclr/<OS>.<arch>.Release <app root>/bin/Release/net5.0/<rid>/publish

docs/pr-guide.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ If you have determined the failure is definitely not caused by changes in your P
7474
* Search for an [existing issue](https://github.com/dotnet/runtime/issues). Usually the test method name or (if a crash/hang) the test assembly name are good search parameters.
7575
* If there's an existing issue, add a comment with
7676
* a) the link to the build
77-
* b) the affected configuration (ie `netcoreapp-Windows_NT-Release-x64-Windows.81.Amd64.Open`)
77+
* b) the affected configuration (ie `net6.0-windows-Release-x64-Windows.81.Amd64.Open`)
7878
* c) all console output including the error message and stack trace from the Azure DevOps tab (This is necessary as retention policies are in place that recycle old builds.)
7979
* d) if there's a dump file (see Attachments tab in Azure DevOps) include that
8080
* If the issue is already closed, reopen it and update the labels to reflect the current failure state.

docs/project/garbage-collector-guidelines.md

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,6 @@ This will run the stress framework for the default amount of time (15 hours) on
3737
## Functional Testing ##
3838
A functional test run executes the same code as a stress run, but only runs for 30 minutes.
3939

40-
It is recommended that you run at least some of the below PR-triggered CI jobs:
41-
42-
```
43-
@dotnet_bot test Windows_NT Checked longgc
44-
@dotnet_bot test OSX10.12 Checked longgc
45-
@dotnet_bot test Ubuntu Checked longgc
46-
@dotnet_bot test Windows_NT Checked standalone_gc
47-
@dotnet_bot test OSX10.12 Checked standalone_gc
48-
@dotnet_bot test Ubuntu Checked standalone_gc
49-
```
50-
5140
The "Long GC" tests are a series of GC tests whose running time is too long or memory usage is too high to run with
5241
the rest of the Priority 0 unit tests. The "Standalone GC" build mode builds and runs the GC in a semi-standalone manner
5342
(see https://github.com/dotnet/coreclr/projects/3).
@@ -56,7 +45,7 @@ You may also wish to run the GC Simulator tests. They may take up to 24 hours to
5645
due to poor interactions with the Linux OOM killer. However, they have proven to be quite useful in finding bugs in the past:
5746

5847
```
59-
@dotnet_bot test Windows_NT Release gcsimulator
48+
@dotnet_bot test windows Release gcsimulator
6049
@dotnet_bot test Ubuntu Release gcsimulator
6150
@dotnet_bot test OSX10.12 Release gcsimulator
6251
```

docs/workflow/building/libraries/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ The libraries build has two logical components, the native build which produces
7575
The build settings (BuildTargetFramework, TargetOS, Configuration, Architecture) are generally defaulted based on where you are building (i.e. which OS or which architecture) but we have a few shortcuts for the individual properties that can be passed to the build scripts:
7676

7777
- `-framework|-f` identifies the target framework for the build. Possible values include `net5.0` (currently the latest .NET version) or `net48` (the latest .NETFramework version). (msbuild property `BuildTargetFramework`)
78-
- `-os` identifies the OS for the build. It defaults to the OS you are running on but possible values include `Windows_NT`, `Unix`, `Linux`, or `OSX`. (msbuild property `TargetOS`)
78+
- `-os` identifies the OS for the build. It defaults to the OS you are running on but possible values include `windows`, `Unix`, `Linux`, or `OSX`. (msbuild property `TargetOS`)
7979
- `-configuration|-c Debug|Release` controls the optimization level the compilers use for the build. It defaults to `Debug`. (msbuild property `Configuration`)
8080
- `-arch` identifies the architecture for the build. It defaults to `x64` but possible values include `x64`, `x86`, `arm`, or `arm64`. (msbuild property `TargetArchitecture`)
8181

docs/workflow/building/libraries/freebsd-instructions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ index 81b8c7b..bb26868 100644
7979
@@ -5,6 +5,7 @@
8080
<BuildArguments>$(Platform) $(Configuration) skiptests</BuildArguments>
8181
<BuildArguments Condition="'$(SkipDisablePgo)' != 'true'">$(BuildArguments) -nopgooptimize</BuildArguments>
82-
<BuildArguments Condition="'$(TargetOS)' != 'Windows_NT'">$(BuildArguments) msbuildonunsupportedplatform</BuildArguments>
82+
<BuildArguments Condition="'$(TargetOS)' != 'windows'">$(BuildArguments) msbuildonunsupportedplatform</BuildArguments>
8383
+ <BuildArguments Condition="'$(TargetOS)' == 'FreeBSD'">$(BuildArguments) -clang6.0</BuildArguments>
8484
<BuildArguments Condition="'$(UseSystemLibraries)' == 'true'">$(BuildArguments) cmakeargs -DCLR_CMAKE_USE_SYSTEM_LIBUNWIND=TRUE</BuildArguments>
8585
<BuildArguments Condition="$(Platform.Contains('arm'))">$(BuildArguments) skipnuget cross -skiprestore cmakeargs -DFEATURE_GDBJIT=TRUE</BuildArguments>

docs/workflow/debugging/coreclr/debugging.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,17 @@ Debugging CoreCLR on Windows
99
============================
1010

1111
1. Perform a build of the repo.
12-
2. Open solution \<reporoot\>\artifacts\obj\coreclr\Windows_NT.\<platform\>.\<configuration\>\CoreCLR.sln in Visual Studio. \<platform\> and \<configuration\> are based
12+
2. Open solution \<reporoot\>\artifacts\obj\coreclr\windows.\<platform\>.\<configuration\>\CoreCLR.sln in Visual Studio. \<platform\> and \<configuration\> are based
1313
on type of build you did. By default they are 'x64' and 'Debug'.
1414
3. Right-click the INSTALL project and choose ‘Set as StartUp Project’
1515
4. Bring up the properties page for the INSTALL project
1616
5. Select Configuration Properties->Debugging from the left side tree control
17-
6. Set Command=`$(SolutionDir)\..\..\..\bin\coreclr\Windows_NT.$(Platform).$(Configuration)\corerun.exe`
17+
6. Set Command=`$(SolutionDir)\..\..\..\bin\coreclr\windows.$(Platform).$(Configuration)\corerun.exe`
1818
1. This points to the folder where the built runtime binaries are present.
1919
7. Set Command Arguments=`<managed app you wish to run>` (e.g. HelloWorld.dll)
20-
8. Set Working Directory=`$(SolutionDir)\..\..\..\bin\coreclr\Windows_NT.$(Platform).$(Configuration)`
20+
8. Set Working Directory=`$(SolutionDir)\..\..\..\bin\coreclr\windows.$(Platform).$(Configuration)`
2121
1. This points to the folder containing CoreCLR binaries.
22-
9. Set Environment=`CORE_LIBRARIES=$(SolutionDir)\..\..\..\bin\runtime\<current tfm>-Windows_NT-$(Configuration)-$(Platform)`,
22+
9. Set Environment=`CORE_LIBRARIES=$(SolutionDir)\..\..\..\bin\runtime\<current tfm>-windows-$(Configuration)-$(Platform)`,
2323
where '\<current tfm\>' is the target framework of current branch, for example `netcoreapp3.1` `net5.0`.
2424
1. This points to the folder containing core libraries except `System.Private.CoreLib`.
2525
2. This step can be skipped if you are debugging CLR tests that references only `System.Private.CoreLib`.

docs/workflow/debugging/libraries/debugging-packages.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,5 +101,5 @@ dotnet build System.Net.ServicePoint.Tests.csproj -f netcoreapp2.0 /t:test /p:Ou
101101
Will run the test using the following pivot values:
102102
* Architecture: AnyCPU
103103
* Flavor: Debug
104-
* OS: Windows_NT
104+
* OS: windows
105105
* Target: netstandard2.0

docs/workflow/debugging/libraries/windows-instructions.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ To run a single test from command line:
3333

3434
* Locate the test binary folder based on the CSPROJ name.
3535

36-
For example: `src\System.Net.Sockets\tests\Functional\System.Net.Sockets.Tests.csproj` will build and output binaries at `bin\tests\Windows_NT.AnyCPU.Debug\System.Net.Sockets.Tests\netcoreapp1.0`.
36+
For example: `src\System.Net.Sockets\tests\Functional\System.Net.Sockets.Tests.csproj` will build and output binaries at `bin\tests\windows.AnyCPU.Debug\System.Net.Sockets.Tests\netcoreapp1.0`.
3737

3838
* Execute the test
3939

4040
Assuming that your repo is at `C:\corefx`:
4141

4242
```
43-
cd C:\corefx\bin\tests\Windows_NT.AnyCPU.Debug\System.Net.Sockets.Tests\netcoreapp1.0
44-
C:\corefx\bin\tests\Windows_NT.AnyCPU.Debug\System.Net.Sockets.Tests\netcoreapp1.0\CoreRun.exe xunit.console.dll System.Net.Sockets.Tests.dll -xml testResults.xml -notrait category=nonwindowstests -notrait category=OuterLoop -notrait category=failing
43+
cd C:\corefx\bin\tests\windows.AnyCPU.Debug\System.Net.Sockets.Tests\netcoreapp1.0
44+
C:\corefx\bin\tests\windows.AnyCPU.Debug\System.Net.Sockets.Tests\netcoreapp1.0\CoreRun.exe xunit.console.dll System.Net.Sockets.Tests.dll -xml testResults.xml -notrait category=nonwindowstests -notrait category=OuterLoop -notrait category=failing
4545
```
4646

4747
* If the test crashes or encounters a `Debugger.Launch()` method call, WinDBG will automatically start and attach to the `CoreRun.exe` process

0 commit comments

Comments
 (0)