Bump MSBuild Version to 15.1.0-preview-000503-01 #5199

Merged
merged 8 commits into from Jan 5, 2017

Projects

None yet

7 participants

Collaborator
piotrpMSFT commented Jan 4, 2017 edited

This PR bumps:

  • MSBuild 15.1.0-preview-000458-02 -> 15.1.0-preview-000503-01
  • Roslyn 2.0.0-beta6-60922-08 -> 2.0.0-rc3-61212-03

The change required CLI to absorb the new layout of Roslyn on-disk. Specifically, Roslyn now must be deployed to $(MSBuildToolsPath)/Roslyn instead of being deployed to $(MSBuildToolsPath) directly. The CLI must still compose a runnable CSC.exe [generate runtimeconfig.json + deps.json] but this now happens inside of the Roslyn directory.

This change required performing a second publish during the CLI build. A side-effect of that is the duplication of a number of Framework binaries that do not ship in the Shared Framework, specifically:

  • System.Collections.NonGeneric.dll
  • System.Collections.Specialized.dll
  • System.Diagnostics.StackTrace.dll
  • System.Reflection.Metadata.dll
  • System.ValueTuple.dll
  • System.Xml.XmlDocument.dll
  • System.Xml.XPath.dll
  • System.Xml.XPath.XDocument.dll

as well as some framework-specific implementation binaries. We will likely need to do some de-duping work in CLI [likely with --additional-probing-path] during our final 1.0 size push. The duplication led to an 18MB [20%] size increase on my dev build. I chose to move forward so we have functionality in-place and can improve perf [size] in the RTM milestone.

While making this change we identified that a change in Roslyn 2.0.0-rc3-61212-04 prevents CLI from picking up that, or a higher, Roslyn version so I locked this PR back to this December build. The specific issue is that Roslyn took on a Microsoft.NetCore.App dependency [at least for System.Security.Cryptography.] which is not available in the 1.0. Shared Framework. Since CLI is built on 1.0 at the moment and @eerhardt just ran into blockers that prevent us from moving forward, we are not currently able to move forward to newer compilers. I ping'd @jaredpar about this below as FYI.

Since this change touches a lot of CLI build system internals, I've commented the code in this PR to help folks see what's going on.

@jonsequitur @jgoshi @krwq @livarcocc @piotroko for code review

@srivatsn for signoff

@jeffkl @rainersigwald FYI

Collaborator

@jeffkl looks like the change you were telling us about [Roslyn directory] needed a matching CLI change? Should we expect that latest Roslyn packages will auto-create the needed layout? Or is this something we need to fix manually? Is there a back-compat mode?

@livarcocc @jonsequitur @rainersigwald

Collaborator

For reference:

error MSB4019: The imported project "/mnt/resource/j/workspace/dotnet_cli/rel_1.0.0/debug_opensuse13.2_x64_prtest/artifacts/opensuse.13.2-x64/stage2/sdk/1.0.0-preview5-004384/Roslyn/Microsoft.CSharp.Core.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk. 
Collaborator
jeffkl commented Jan 4, 2017

Yes you'll need to either place the Roslyn stuff under a Roslyn subfolder or set RoslynTargetsPath to the folder where you placed them (the MSBuild folder). Sorry I forgot to mention that!

Collaborator

@dotnet-bot test Ubuntu x64 Release Build please.

Collaborator

@jaredpar FYI, 2.0.0-rc3-61212-03 is the maximum version of Roslyn we were able to move to. The next version took on System.Security.Cryptography* 4.3.0 which is > what is in the 1.0.0-1.0.3 shared frameworks. 4.3.0 IS available in NetCore.App 1.1, but we have a number of blockers to get through before CLI can be made to function there, so we're capped at the moment.

@@ -124,7 +124,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.DotNet.TestFramew
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "redist", "src\redist\redist.csproj", "{098D9321-1201-4974-A75E-F58EBCD98ACF}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "tool_csc", "src\tool_csc\tool_csc.csproj", "{A0670C63-BA7A-4C1B-B9A7-1CA26A7F235C}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "tool_roslyn", "src\tool_roslyn\tool_roslyn.csproj", "{A0670C63-BA7A-4C1B-B9A7-1CA26A7F235C}"
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

Roslyn better represent common nomenclature for this component.

@@ -5,6 +5,7 @@
<clear />
<add key="dotnet-core" value="https://dotnet.myget.org/F/dotnet-core/api/v3/index.json" />
<add key="cli-deps" value="https://dotnet.myget.org/F/cli-deps/api/v3/index.json" />
+ <add key="roslyn" value="https://dotnet.myget.org/f/roslyn/api/v3/index.json" />
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

CLI-Deps wasn't caught up yet. Will remove once it's back up to speed, in a future PR.

@@ -15,9 +16,6 @@
<CLITargets Condition=" '$(CLITargets)' == '' ">Prepare;Compile;Test;Package;Publish</CLITargets>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
- <RepoRoot>$(MSBuildThisFileDirectory)</RepoRoot>
- <CLIBuildFileName>$(RepoRoot)/build_projects/dotnet-cli-build/bin/dotnet-cli-build</CLIBuildFileName>
- <CLIBuildDll>$(CLIBuildFileName).dll</CLIBuildDll>
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

These were moved to root dir.props.

@@ -10,9 +10,8 @@
<ItemGroup>
<PublishOutputExtensions Include="$(ExeExtension);.dll;.pdb;.deps.json;.runtimeconfig.json" />
- <FilesToMove Include="$(BinaryToCorehostifyRelDir)/csc.exe;" />
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

csc elements were moved to tool_roslyn for clarity.

+ Output="$(SdkOutputDirectory)/Roslyn"
+ Configuration="$(Configuration)"
+ VersionSuffix="$(CommitCount)"
+ ProjectPath="$(SrcDirectory)/tool_roslyn/tool_roslyn.csproj" />
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

Note, did not duplicate /p:GenerateRuntimeConfigurationFiles=true, setting the property in tool_csproj instead. This and other changes allow that csproj file to be independently build/publish-able. That greatly improved my dev cycle.

<CLI_NETSDK_Version>1.0.0-alpha-20161230-1</CLI_NETSDK_Version>
+ <CLI_Roslyn_Version>2.0.0-rc3-61212-03</CLI_Roslyn_Version>
<CLI_WEBSDK_Version>1.0.0-alpha-20161205-1-154</CLI_WEBSDK_Version>
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

Had to bump Roslyn so dependencies of it + MSBuild didn't clash. This is the maximum Roslyn version CLI can take until we move to NetCore.App 1.1+

- <PropertyGroup>
- <NuGetPackagesDir>$(NUGET_PACKAGES)</NuGetPackagesDir>
- <NuGetPackagesDir Condition=" '$(NuGetPackagesDir)' == '' ">$(RepoRoot)/.nuget/packages</NuGetPackagesDir>
- </PropertyGroup>
piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

Now in dir.props

Member
jaredpar commented Jan 5, 2017

Is the plan to eventually move to Net Core App 1.1 though?

Collaborator

@jaredpar eventually... We hoped to do this in 1.0 but hit blockers. Right now moving cli onto 1.1 is not a priority.

Member
jaredpar commented Jan 5, 2017

Think we need to start a conversation with @tmat then. He is the one that pushed us to Net Core 1.1. Based on my understanding of the dependencies here, admittedly limited, this means that CLI would need to be a Net App 1.1 in order to properly consume us.

+ ProjectPath="$(SrcDirectory)/redist/redist.csproj"
+ MSBuildArgs="/p:GenerateRuntimeConfigurationFiles=true" />
+
+ <!-- Publish DotNet -->
livarcocc
livarcocc Jan 5, 2017 Member

Publish Roslyn? Personally, I find this comment kind of useless. Just look at the ProjectPath.

piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

Ok. Ill remove when resolving merge conflict.

@@ -0,0 +1,63 @@
+<Project Sdk="Microsoft.NET.Sdk" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.props" />
+ <Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.tasks" />
livarcocc
livarcocc Jan 5, 2017 Member

Should we go ahead and create a PreReq target in our build just to prep these things?

piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

You mean to build the tasks all?

piotrpMSFT
piotrpMSFT Jan 5, 2017 Collaborator

You mean to build the tasks all?

piotrpMSFT and others added some commits Jan 4, 2017
@piotrpMSFT piotrpMSFT Bump MSBuild Version to 15.1.0-preview-000503-01 f121fc2
@piotrpMSFT piotrpMSFT tool_csc->tool_roslyn ea3bace
@jonsequitur @piotrpMSFT jonsequitur pull some properties up to dir.props 7f0f2ea
@piotrpMSFT piotrpMSFT Move Roslyn to "Roslyn" subdirectory 080aafa
@piotrpMSFT piotrpMSFT Fix relative paths in RunCsc.* 1346aa7
@piotrpMSFT piotrpMSFT Add removal of csc & vbc from deps.json f411db5
@piotrpMSFT piotrpMSFT Revert roslyn to 2.0.0-rc3-61212-03 d68e0c3
@piotrpMSFT piotrpMSFT netcoreapp -> 1.0.3
19bbe20
@piotrpMSFT piotrpMSFT merged commit d14698f into dotnet:rel/1.0.0 Jan 5, 2017

10 checks passed

CentOS7.1 x64 Debug Build Build finished.
Details
Debian8.2 x64 Debug Build Build finished.
Details
Fedora23 x64 Debug Build Build finished.
Details
OSX x64 Release Build Build finished.
Details
OpenSUSE13.2 x64 Debug Build Build finished.
Details
RHEL7.2 x64 Release Build Build finished.
Details
Ubuntu x64 Release Build Build finished.
Details
Ubuntu16.04 x64 Debug Build Build finished.
Details
Windows_NT x64 Release Build Build finished.
Details
Windows_NT x86 Debug Build Build finished.
Details
@piotrpMSFT piotrpMSFT deleted the piotrpMSFT:piotrpMSFT/bump/MSBuild15.1.0-preview-000503-01 branch Jan 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment