-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Manually update the dependencies.props and move S.P.Corelib to use LangVersion=8.0 #22452
Conversation
Still looking into why building S.P.Corelib hangs. I am waiting on a machine to finish imaging so I can try to repro locally. |
Looks like we need to either upgrade the Jenkins machines or wait until we can move fully onto |
Isn't there a .NET Core based compiler? |
Yes. It would require additional work in BuildTools to enable, however. I'm also not sure how close we are to fully switching onto the Azure DevOps based build-system, so I couldn't say if it is worth the effort. |
CC. @jashook on the above |
/cc @sbomer |
Rebased onto current head and moved |
If I follow, I think the above error would be fixed by building managed projects using "dotnet msbuild" instead of desktop msbuild on windows. If that's the case, you may be able to get it working by making https://github.com/dotnet/coreclr/blob/c4007d88a0c556182f70d7714e5b55cca92331a0/msbuild.cmd call "dotnet msbuild" using the SDK bootstrapped by buildtools. I believe you'd just need to update the native build on windows to continue using desktop msbuild explicitly. |
Still validating locally and in CI, but the latest commit adds a |
BuildTools on Windows only restores the Desktop Toolset Compiler. It needs to be updated to also restore the NetCore Toolset Compiler. |
I put up a PR that updates BuildTools to also restore the .NETCore toolset on Windows: dotnet/buildtools#2222 |
|
Yes |
I have the CoreRT side here: dotnet/corert#7015 |
@@ -4,6 +4,10 @@ | |||
|
|||
<Import Project="dir.common.props" /> | |||
|
|||
<PropertyGroup> | |||
<LangVersion>8.0</LangVersion> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Had to move the LangVersion
definition to here and tests\dir.props
, since those are the only things that actually import $(RoslynPropsFile)
.
I think it would be nice to get this cleaned up (and using Directory.Build.props
, etc). But that is a more complicated change and should be done separately. Doing so would allow this logic to be centrally managed, rather than duplicated in multiple places.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, that would be part of "Arcade migration".
@@ -4,6 +4,11 @@ | |||
|
|||
<Import Project="dir.common.props" /> | |||
|
|||
<PropertyGroup> | |||
<LangVersion>8.0</LangVersion> | |||
<UseSharedCompilation>true</UseSharedCompilation> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pushed a commit setting UseSharedCompilation=true
, as we did on CoreFX.
When using a non-toolset compiler this is the default, but for Toolset builds the reverse is true and this is disabled. This should speed up the build and avoid the timeout that was getting hit.
Looks like several jobs are hitting a hang here:
Trying to get a repro machine, but the |
@tannergooding we have our best Alex working on this, see https://github.com/dotnet/core-eng/issues/5203 for status. |
The project causing the stall looks to be an ilproj. |
@tannergooding just a theory at the moment but if an ILProj is stalling build it can often be caused by Windows Defender / other AV things mistaking the output of such projects as malware. For the old Jenkins machines though I do not know how they have this configured. |
Found a couple of callsites that were just calling |
Had to revert packages.builds to use Desktop msbuild on Windows. This should be fine since it is just packaging. Some machines would otherwise fail with:
|
Looks like this should be good now (only 2 arm jobs and one of the CoreFX jobs remain). It would be great if people who have already signed-off could give this a second glance, given it required a few more iterations to get correct. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, Tanner.
Just as a note, I believe I've resolved the CoreRT side as well, but we still won't want to use C# 8 features in the shared corelib code until after dotnet/corert#7015 is merged. |
…ngVersion=8.0 (dotnet/coreclr#22452) * Update BuildTools to preview1-03713-01 (master) * Updating CoreCLR to use LangVersion=8.0 * Moving the Windows scripts to default to `dotnet msbuild` for managed components * Setting UseSharedCompilation=true * Changing some additional callsites that were using msbuild to use dotnet msbuild * Revert packages.builds to use Desktop msbuild on Windows * Fixing runtest.cmd to always set DotNetCli Commit migrated from dotnet/coreclr@cd9831c
The dependencies.props were manually updated since the automatic sync is not currently working. A fix for that and more details on the issue are here: dotnet/versions#419
This simultaneously updates S.P.Corelib to use
LangVersion=8.0
since the build-tools update makes that possible.CC. @jkotas, @benaadams, @stephentoub