diff --git a/.codeql.yml b/.codeql.yml
index 402e1fe9b..aac075630 100644
--- a/.codeql.yml
+++ b/.codeql.yml
@@ -43,7 +43,7 @@ jobs:
displayName: CodeQL
pool:
name: NetCore1ESPool-Internal
- demands: ImageOverride -equals windows.vs2017.amd64
+ demands: ImageOverride -equals windows.vs2019.amd64
timeoutInMinutes: 90
steps:
diff --git a/Directory.Build.props b/Directory.Build.props
index 407f4248f..41d0defa2 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -3,6 +3,11 @@
- 15.0
+ 16.0
+
+ true
diff --git a/Runtime.msbuild b/Runtime.msbuild
index dbe4db084..5862d38b4 100644
--- a/Runtime.msbuild
+++ b/Runtime.msbuild
@@ -11,6 +11,7 @@
true
true
false
+ false
false
$(MSBuildThisFileDirectory)bin\$(Configuration)\test\TestResults\
$(MSBuildThisFileDirectory)packages\Microsoft.Web.SkipStrongNames.1.0.0\tools\SkipStrongNames.exe
@@ -64,24 +65,12 @@
-
- <_NuGetPackagesAndSolutions Include="Runtime.sln" />
-
-
- <_NuGetPackagesAndSolutions Include="src\System.Net.Http.Formatting.NetCore\packages.config;
- test\System.Net.Http.Formatting.NetCore.Test\packages.config"
- Condition=" '$(BuildPortable)' == 'true' " />
- <_ProjectsToRestore Include="test\System.Net.Http.Formatting.NetStandard.Test\System.Net.Http.Formatting.NetStandard.Test.csproj"
- Condition=" '$(BuildPortable)' == 'true' " />
-
-
-
-
-
+
+
+
@@ -96,7 +85,7 @@
Properties="Configuration=Release;OutputPath=$(CustomFxCopRulesPath)" />
-
+
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index a4050925e..f63cbb9fb 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -27,10 +27,10 @@ jobs:
pool:
${{ if eq(variables['System.TeamProject'], 'public') }}:
name: NetCore-Public
- demands: ImageOverride -equals windows.vs2017.amd64.open
+ demands: ImageOverride -equals windows.vs2019.amd64.open
${{ else }}:
name: NetCore1ESPool-Internal
- demands: ImageOverride -equals windows.vs2017.amd64
+ demands: ImageOverride -equals windows.vs2019.amd64
timeoutInMinutes: 30
strategy:
diff --git a/build.cmd b/build.cmd
index a37e007d6..1cc1cd4ea 100644
--- a/build.cmd
+++ b/build.cmd
@@ -7,12 +7,11 @@ mkdir bin
:Build
-REM Find the most recent 32bit MSBuild.exe on the system. Require v15.0 (installed with VS2017) or later since .NET
-REM Core projects are coming soon.
-REM Use `vswhere` for the search since %ProgramFiles(x86)%\msbuild\15.0\Bin\MSBuild.exe almost never exists.
+REM Find the most recent 32bit MSBuild.exe on the system. Require v16.0 (installed with VS2019) or later.
+REM Use `vswhere` for the search because it can find all VS installations.
set vswhere="%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe"
if not exist %vswhere% (
- set VsWhere="%ProgramFiles%\Microsoft Visual Studio\Installer\vswhere.exe"
+ set vswhere="%ProgramFiles%\Microsoft Visual Studio\Installer\vswhere.exe"
)
if not exist %vswhere% (
REM vswhere.exe not in normal locations; check the Path.
@@ -25,19 +24,29 @@ if not exist %vswhere% (
goto BuildFail
)
+REM We're fine w/ any .NET SDK newer than 2.1.500 but also need a 2.1.x runtime. Microsoft.Net.Core.Component.SDK.2.1
+REM actually checks for only the runtime these days.
set InstallDir=
-for /f "usebackq tokens=*" %%i in (`%vswhere% -version ^[15^,16^) -latest -prerelease -products * ^
- -requires Microsoft.Component.MSBuild -requires Microsoft.Net.Core.Component.SDK.2.1 ^
+for /f "usebackq tokens=*" %%i in (`%vswhere% -version 16 -latest -prerelease -products * ^
+ -requires Microsoft.Component.MSBuild ^
+ -requires Microsoft.NetCore.Component.SDK ^
+ -requires Microsoft.Net.Core.Component.SDK.2.1 ^
-property installationPath`) do (
- set InstallDir=%%i
+ set InstallDir="%%i"
)
-if exist "%InstallDir%\MSBuild\15.0\Bin\MSBuild.exe" (
- set MSBuild="%InstallDir%\MSBuild\15.0\Bin\MSBuild.exe"
+
+if exist %InstallDir%\MSBuild\Current\Bin\MSBuild.exe (
+ set MSBuild=%InstallDir%\MSBuild\Current\Bin\MSBuild.exe
) else (
- echo Could not find MSBuild.exe. Please install the VS2017 BuildTools component or a workload that includes it.
+ echo Could not find MSBuild.exe. Please install the VS2019 BuildTools component or a workload that includes it.
goto BuildFail
)
+REM Configure NuGet operations to work w/in this repo i.e. do not pollute system packages folder.
+REM Note this causes two copies of packages restored using packages.config to land in this folder e.g.
+REM StyleCpy.5.0.0/ and stylecop/5.0.0/.
+set "NUGET_PACKAGES=%CD%\packages"
+
REM Are we running in a local dev environment (not on CI)?
if DEFINED CI (set Desktop=false) else if DEFINED TEAMCITY_VERSION (set Desktop=false) else (set Desktop=true)
diff --git a/global.json b/global.json
index 9ddc9bf9c..7b2cb540d 100644
--- a/global.json
+++ b/global.json
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "2.1.500",
- "rollForward": "latestPatch"
+ "rollForward": "major"
}
}
diff --git a/src/Strict.ruleset b/src/Strict.ruleset
index 5a2a69ba9..a0c61fcb5 100644
--- a/src/Strict.ruleset
+++ b/src/Strict.ruleset
@@ -6,5 +6,7 @@
+
+
\ No newline at end of file
diff --git a/src/System.Net.Http.Formatting.NetCore/System.Net.Http.Formatting.NetCore.csproj b/src/System.Net.Http.Formatting.NetCore/System.Net.Http.Formatting.NetCore.csproj
index e579c5926..6964b5560 100644
--- a/src/System.Net.Http.Formatting.NetCore/System.Net.Http.Formatting.NetCore.csproj
+++ b/src/System.Net.Http.Formatting.NetCore/System.Net.Http.Formatting.NetCore.csproj
@@ -266,13 +266,14 @@
..\..\packages\Microsoft.Net.Http.2.2.13\lib\portable-net40+sl4+win8+wp71\System.Net.Http.Primitives.dll
-
-
+
+
+
+ This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.
+
+
+
\ No newline at end of file
diff --git a/test/Directory.Build.targets b/test/Directory.Build.targets
index 72087f737..54ff85834 100644
--- a/test/Directory.Build.targets
+++ b/test/Directory.Build.targets
@@ -1,6 +1,6 @@
-
+
diff --git a/test/System.Net.Http.Formatting.NetCore.Test/System.Net.Http.Formatting.NetCore.Test.csproj b/test/System.Net.Http.Formatting.NetCore.Test/System.Net.Http.Formatting.NetCore.Test.csproj
index 8d7515803..7aecee20d 100644
--- a/test/System.Net.Http.Formatting.NetCore.Test/System.Net.Http.Formatting.NetCore.Test.csproj
+++ b/test/System.Net.Http.Formatting.NetCore.Test/System.Net.Http.Formatting.NetCore.Test.csproj
@@ -317,14 +317,21 @@
-
+
+
This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.
-
-
-
+
+
+
+
-
\ No newline at end of file
diff --git a/tools/WebStack.StyleCop.targets b/tools/WebStack.StyleCop.targets
index 0b73b551f..5ff6c528a 100644
--- a/tools/WebStack.StyleCop.targets
+++ b/tools/WebStack.StyleCop.targets
@@ -1,7 +1,7 @@
-
-
+
+
diff --git a/tools/src/Microsoft.Web.FxCop/Microsoft.Web.FxCop.csproj b/tools/src/Microsoft.Web.FxCop/Microsoft.Web.FxCop.csproj
index d4a4451c7..2fc7c9bb4 100644
--- a/tools/src/Microsoft.Web.FxCop/Microsoft.Web.FxCop.csproj
+++ b/tools/src/Microsoft.Web.FxCop/Microsoft.Web.FxCop.csproj
@@ -10,7 +10,8 @@
Properties
Microsoft.Web.FxCop
Microsoft.Web.FxCop
- v4.0
+
+ v4.7.2
bin\$(Configuration)