Skip to content

Add roslyn repo to known-good#404

Merged
dseefeld merged 11 commits intodotnet:dev/release/2.1from
dseefeld:updateRoslynFor2.1
Apr 10, 2018
Merged

Add roslyn repo to known-good#404
dseefeld merged 11 commits intodotnet:dev/release/2.1from
dseefeld:updateRoslynFor2.1

Conversation

@dseefeld
Copy link
Contributor

@dseefeld dseefeld commented Apr 9, 2018

  • Roslyn repo has been updated to incorporate previous patches into source. Changes are on a private branch for now.
  • Added updaters for global.json and Tools.props to update CLI version.
  • Added a patch to include solution to build, since solution included in roslyn branch is currently incorrect.
  • Added patch for SDK PR1997 which is required until source-build moves to a newer CLI version than 2.1.101

cc @333fred, @jaredpar

@dseefeld dseefeld requested review from crummel and dagood April 9, 2018 16:12
@@ -0,0 +1,25 @@
From 735b7c82a16ddf16f39643830acb2ee62d2f3150 Mon Sep 17 00:00:00 2001
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this patch should live in tools-local/patches or something like that--to clarify what kind of patch this is and keep repo patches separate.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. I moved it.

init-tools.sh Outdated
"$__scriptpath/Tools/crossgen.sh" "$__scriptpath/Tools"

echo "Patching Sdk to workaround issue https://github.com/dotnet/sdk/pull/1997"
git apply --ignore-whitespace --whitespace=nowarn --directory="$__scriptpath" "$__scriptpath/patches/0001-Patch-Tools-for-sdk-pr-1997.patch"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it reasonable to do this during tools-local/init-build.proj to avoid customizing this script? (With some semaphore in the Tools dir to avoid attempting it more than once?)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dagood and I discussed offline. I will leave it in the init-tools.sh script since 1) it is very temporary and will go away on the next update of CLI version and 2) it can more easily participate in the Tools setup semaphore.

<NuSpecFiles Include="$(ProjectDirectory)/src/NuGet/Microsoft.CodeAnalysis.Build.Tasks.nuspec" />
</ItemGroup>

<Target Name="UpdateCLIVersion"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could this be in dir.targets with the json and props paths parameterized? (But we can put the move off until we use it to remove patches in other repos too.)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather leave this here for now and move it when we need it for others.


<UpdateXml XmlFilePath="$(ProjectDirectory)/build/Targets/Tools.props"
PathToElement="Project/PropertyGroup/dotnetSdkVersion"
NewElementValue="$(SDK_VERSION)" />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be removed once we merge the private branch as we jus condition away this check altogether.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can just be removed in this PR as it's based on the dev/sourcebuild branch.


In reply to: 180162495 [](ancestors = 180162495)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed. Thanks.

init-tools.sh Outdated
"$__scriptpath/Tools/crossgen.sh" "$__scriptpath/Tools"

echo "Patching Sdk to workaround issue https://github.com/dotnet/sdk/pull/1997"
git apply --ignore-whitespace --whitespace=nowarn --directory="$__scriptpath" "$__scriptpath/patches/0001-Patch-Tools-for-sdk-pr-1997.patch"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

--directory shouldn't be needed here, we need it for applying patches to repos because they were generated with the repo directory as root. It doesn't hurt anything but I think it makes it less clear here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In theory the working dir might not be $__scriptpath at this point though, and --directory="$__scriptpath" adds support for that, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With help from @dagood , found that this was the issue with the git apply in CI. Removed the --directory option.

@@ -0,0 +1,147 @@
From c7dbba01272248423989a1816625dccb3e129b74 Mon Sep 17 00:00:00 2001
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This patch is unnecessary, this commit of roslyn has Sourcebuild.sln.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the sha to the commit that fixes SourceBuild.sln.

@333fred
Copy link
Member

333fred commented Apr 9, 2018

We will need to update the PR to pull in roslyn from dev15.7.x instead of dev/sourcebuild as we get that branch merged in.

dseefeld and others added 2 commits April 9, 2018 20:24
remove temporary sln.  Remove xml updater since it isn't needed.  Move
patch to tools-local dir and update git apply to not use --directory.
@dseefeld dseefeld merged commit d777c06 into dotnet:dev/release/2.1 Apr 10, 2018
@dseefeld dseefeld deleted the updateRoslynFor2.1 branch April 10, 2018 15:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants