From 9123ea6a7c9f4b68bdc9d41a2381e33dfa0c38b2 Mon Sep 17 00:00:00 2001 From: Tomas Date: Mon, 15 Mar 2021 20:17:39 +0100 Subject: [PATCH 01/11] Fix incorrect merge suppressing my change to publish CG2 framework As David discovered, I apparently made a merge bug in rebasing my CG2 framework switch-over change prior to checking in that actually suppressed CG2 publishing due to losing the property PublishReadyToRunUseCrossgen2. This change fixes that deficiency. Thanks Tomas --- src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 1 + 1 file changed, 1 insertion(+) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index 4af8a0f6061ed6..ff4942bacd1022 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -6,6 +6,7 @@ x64 $(CoreCLRArtifactsPath)\$(CrossDir)\crossgen2 $(Crossgen2Dir)\crossgen2$(ExeSuffix) + true --targetarch:$(TargetArchitecture) unix From 3489e1c9b861844fc55a556869f436073c825a51 Mon Sep 17 00:00:00 2001 From: Tomas Date: Mon, 15 Mar 2021 22:28:43 +0100 Subject: [PATCH 02/11] Fix DOTNET_ROOT location --- src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index ff4942bacd1022..e86c4c63594968 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -49,7 +49,7 @@ $(DOTNET_ROOT) - $(RepoRoot) + $([System.IO.Path]::Combine('$(RepoRoot)', '.dotnet')) From ed44b8e18cac607ab29ffd0687a56b44475f39a8 Mon Sep 17 00:00:00 2001 From: Tomas Date: Tue, 16 Mar 2021 00:16:12 +0100 Subject: [PATCH 03/11] Address David's PR feedback; add instrumentation to show the .NET root --- .../pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index e86c4c63594968..41d501c0d4638b 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -47,10 +47,16 @@ + + + + $(DOTNET_ROOT) - $([System.IO.Path]::Combine('$(RepoRoot)', '.dotnet')) + @(DotNetRoot) + + From 43a0d4dfce98c6649aefb1f470dc382f16ea211d Mon Sep 17 00:00:00 2001 From: Tomas Date: Tue, 16 Mar 2021 01:43:13 +0100 Subject: [PATCH 04/11] Address additional Anton's PR feedback; use RepoRoot instead of ArtifactsDir --- .../pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index 41d501c0d4638b..7dc6b228968b6a 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -47,15 +47,14 @@ - - - - $(DOTNET_ROOT) - @(DotNetRoot) + + + + From 1b1581b6efcc66a67fc0cf84aef3f502b5048978 Mon Sep 17 00:00:00 2001 From: Tomas Rylek Date: Tue, 16 Mar 2021 07:03:02 -0700 Subject: [PATCH 05/11] Actually set the DOTNET_ROOT environment variable for Crossgen2 --- .../Microsoft.NETCore.App/ReadyToRun.targets | 28 +++++++++++++++---- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index 7dc6b228968b6a..f4465bf96a3a57 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -41,6 +41,26 @@ + + + + + + + + + + + + + + + @@ -52,16 +72,14 @@ - + - + - - $(OriginalDotnetRootValue) - + From 703be45de0089e298975eb6f7a4991de8f216343 Mon Sep 17 00:00:00 2001 From: Tomas Rylek Date: Tue, 16 Mar 2021 08:23:16 -0700 Subject: [PATCH 06/11] Instrumentation --- .../pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index f4465bf96a3a57..65d37cffd82ffe 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -63,18 +63,21 @@ - $(DOTNET_ROOT) + $(RepoRoot)/artifacts/toolset/sdk.txt - + + + + From fcdf285ebcd5fd7622ce054538bd1b8410f0a35f Mon Sep 17 00:00:00 2001 From: Tomas Rylek Date: Tue, 16 Mar 2021 09:33:20 -0700 Subject: [PATCH 07/11] Normalize path to the sdk.txt file --- src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index 65d37cffd82ffe..cce8f611b87269 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -68,7 +68,7 @@ $(DOTNET_ROOT) - $(RepoRoot)/artifacts/toolset/sdk.txt + $([MSBuild]::NormalizePath('$(RepoRoot)', 'artifacts', 'toolset', 'sdk.txt')) From 19fba36253b2c275cc04fde830460a42fec7f194 Mon Sep 17 00:00:00 2001 From: Tomas Date: Tue, 16 Mar 2021 20:26:54 +0100 Subject: [PATCH 08/11] More instrumentation as I still fail to grasp why it doesn't work --- .../pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index cce8f611b87269..2e0c29ebb5d270 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -68,11 +68,16 @@ $(DOTNET_ROOT) - $([MSBuild]::NormalizePath('$(RepoRoot)', 'artifacts', 'toolset', 'sdk.txt')) + $([MSBuild]::NormalizePath('$(RepoRoot)', 'artifacts', 'toolset')) + $([MSBuild]::NormalizePath('$(ToolsetDir)', 'sdk.txt')) + + + + - + From 305071a1711714e57a960a384949e4900a378c58 Mon Sep 17 00:00:00 2001 From: Tomas Date: Tue, 16 Mar 2021 23:51:55 +0100 Subject: [PATCH 09/11] Explicitly initialize the .NET CLI per Jeremy's suggestion --- .../pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index 2e0c29ebb5d270..fe5c209eaf6c32 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -70,8 +70,13 @@ $(DOTNET_ROOT) $([MSBuild]::NormalizePath('$(RepoRoot)', 'artifacts', 'toolset')) $([MSBuild]::NormalizePath('$(ToolsetDir)', 'sdk.txt')) + .sh + .cmd + + + From 755ffc20dbeef73296e3590251e0e2472e030e9b Mon Sep 17 00:00:00 2001 From: Tomas Date: Wed, 17 Mar 2021 08:44:54 +0100 Subject: [PATCH 10/11] Simplify DOTNET_ROOT logic based on Jeremy's advice --- .../Microsoft.NETCore.App/ReadyToRun.targets | 21 ++----------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index fe5c209eaf6c32..fc00af1bb96b98 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -68,27 +68,10 @@ $(DOTNET_ROOT) - $([MSBuild]::NormalizePath('$(RepoRoot)', 'artifacts', 'toolset')) - $([MSBuild]::NormalizePath('$(ToolsetDir)', 'sdk.txt')) - .sh - .cmd - - - - - - - - - - - - - - - + + From 24255b3e94899b952d553e3bff455deef26d7af2 Mon Sep 17 00:00:00 2001 From: Tomas Date: Wed, 17 Mar 2021 11:25:27 +0100 Subject: [PATCH 11/11] Remove instrumentation as the change finally works --- .../pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets index fc00af1bb96b98..b898cdaea116ae 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/ReadyToRun.targets @@ -62,15 +62,10 @@ - + $(DOTNET_ROOT) - - $(DOTNET_ROOT) - - -