From fd04c9c736e1f930011a9822b960e31b3b561839 Mon Sep 17 00:00:00 2001 From: Antoine Martin Date: Tue, 15 Nov 2022 01:04:07 -0500 Subject: [PATCH] Eliminate runtime portable build (backport dotnet#14549) --- .../tarball/content/Directory.Build.props | 8 -- .../tarball/content/repos/aspnetcore.proj | 1 + .../tarball/content/repos/installer.proj | 2 +- .../tarball/content/repos/known-good.proj | 1 - .../content/repos/runtime-portable.proj | 47 ---------- .../content/repos/runtime.common.props | 43 ---------- .../content/repos/runtime.common.targets | 46 ---------- .../tarball/content/repos/runtime.proj | 86 ++++++++++++++++++- .../source-build-reference-packages.proj | 4 +- src/redist/targets/Crossgen.targets | 2 +- src/redist/targets/GenerateLayout.targets | 3 + 11 files changed, 92 insertions(+), 151 deletions(-) delete mode 100644 src/SourceBuild/tarball/content/repos/runtime-portable.proj delete mode 100644 src/SourceBuild/tarball/content/repos/runtime.common.props delete mode 100644 src/SourceBuild/tarball/content/repos/runtime.common.targets diff --git a/src/SourceBuild/tarball/content/Directory.Build.props b/src/SourceBuild/tarball/content/Directory.Build.props index 61cc6ff6746a..2e2d7e8bcec7 100644 --- a/src/SourceBuild/tarball/content/Directory.Build.props +++ b/src/SourceBuild/tarball/content/Directory.Build.props @@ -22,14 +22,6 @@ x64 false - - - false - false - true - false diff --git a/src/SourceBuild/tarball/content/repos/aspnetcore.proj b/src/SourceBuild/tarball/content/repos/aspnetcore.proj index 480f3c7132ee..52243024aaa7 100644 --- a/src/SourceBuild/tarball/content/repos/aspnetcore.proj +++ b/src/SourceBuild/tarball/content/repos/aspnetcore.proj @@ -9,6 +9,7 @@ $(BuildCommandArgs) --no-build-repo-tasks $(BuildCommandArgs) /p:BuildNodeJs=false $(BuildCommandArgs) /p:PublishCompressedFilesPathPrefix=$(SourceBuiltAspNetCoreRuntime) + $(BuildCommandArgs) /p:PortableBuild=false /p:TargetRuntimeIdentifier=$(TargetRid) $(BuildCommandArgs) /p:MicrosoftNetFrameworkReferenceAssembliesVersion=1.0.0 diff --git a/src/SourceBuild/tarball/content/repos/installer.proj b/src/SourceBuild/tarball/content/repos/installer.proj index e34337b8599c..6c08a1f67d8e 100644 --- a/src/SourceBuild/tarball/content/repos/installer.proj +++ b/src/SourceBuild/tarball/content/repos/installer.proj @@ -25,7 +25,7 @@ $(BuildCommandArgs) /p:Rid=$(TargetRid) $(BuildCommandArgs) /p:DOTNET_INSTALL_DIR=$(DotNetCliToolDir) - $(BuildCommandArgs) /p:AspNetCoreInstallerRid=linux-$(Platform) + $(BuildCommandArgs) /p:AspNetCoreInstallerRid=$(TargetRid) $(BuildCommandArgs) /p:CoreSetupRid=freebsd-x64 /p:PortableBuild=true $(BuildCommandArgs) /p:CoreSetupRid=osx-x64 diff --git a/src/SourceBuild/tarball/content/repos/known-good.proj b/src/SourceBuild/tarball/content/repos/known-good.proj index eab5162908d2..12d9943da8ec 100644 --- a/src/SourceBuild/tarball/content/repos/known-good.proj +++ b/src/SourceBuild/tarball/content/repos/known-good.proj @@ -44,7 +44,6 @@ - diff --git a/src/SourceBuild/tarball/content/repos/runtime-portable.proj b/src/SourceBuild/tarball/content/repos/runtime-portable.proj deleted file mode 100644 index f90a7b7d63a7..000000000000 --- a/src/SourceBuild/tarball/content/repos/runtime-portable.proj +++ /dev/null @@ -1,47 +0,0 @@ - - - - - runtime - - - - - - - - - - - - - - - $(ProjectDirectory)artifacts/portableLog - $(ProjectDirectory)artifacts/portableObj - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/SourceBuild/tarball/content/repos/runtime.common.props b/src/SourceBuild/tarball/content/repos/runtime.common.props deleted file mode 100644 index b1e9e6adb336..000000000000 --- a/src/SourceBuild/tarball/content/repos/runtime.common.props +++ /dev/null @@ -1,43 +0,0 @@ - - - runtime - - - - - - - true - - - $(StandardSourceBuildArgs.Replace('-bl', '-nobl')) - - $(StandardSourceBuildCommand) $(BuildCommandArgs) - $(ArmEnvironmentVariables) $(StandardSourceBuildCommand) $(BuildCommandArgs) - - $(ProjectDirectory)/clean$(ShellExtension) - - - - - $(ProjectDirectory)global.json - $(ProjectDirectory)NuGet.config - false - true - - - - - - - - - - - - - - - - - diff --git a/src/SourceBuild/tarball/content/repos/runtime.common.targets b/src/SourceBuild/tarball/content/repos/runtime.common.targets deleted file mode 100644 index 862b70dc832d..000000000000 --- a/src/SourceBuild/tarball/content/repos/runtime.common.targets +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - - - - - - - $(ProjectDirectory)pkg/Microsoft.NETCore.Platforms/runtime.json - - - - - - - - - <_builtRuntimePackages Include="$(SourceBuiltAssetsDir)*.symbols.nupkg" /> - <_builtRuntimePackages> - $([System.String]::Copy('%(FileName)').Replace('symbols', 'nupkg')) - - - - - - - - - - - - diff --git a/src/SourceBuild/tarball/content/repos/runtime.proj b/src/SourceBuild/tarball/content/repos/runtime.proj index f3ed143f889a..073cd8bc13f8 100644 --- a/src/SourceBuild/tarball/content/repos/runtime.proj +++ b/src/SourceBuild/tarball/content/repos/runtime.proj @@ -1,18 +1,57 @@ - + + + true + + $(ProjectDirectory)/clean$(ShellExtension) + $(TargetRid) osx-x64 freebsd-x64 win-x64 + <_platformIndex>$(NETCoreSdkRuntimeIdentifier.LastIndexOf('-')) + $(NETCoreSdkRuntimeIdentifier.Substring(0, $(_platformIndex))) + + <_platformIndex>$(NETCoreSdkPortableRuntimeIdentifier.LastIndexOf('-')) + $(NETCoreSdkPortableRuntimeIdentifier.Substring(0, $(_platformIndex))) + $(StandardSourceBuildArgs) $(BuildCommandArgs) /p:TargetRid=$(OverrideTargetRid) + $(BuildCommandArgs) /p:RuntimeOS=$(RuntimeOS) + $(BuildCommandArgs) /p:BaseOS=$(BaseOS) $(BuildCommandArgs) /p:SourceBuildNonPortable=true $(StandardSourceBuildCommand) $(BuildCommandArgs) + + + $(ProjectDirectory)global.json + $(ProjectDirectory)NuGet.config + false + true + + + + + + + + + + + + + + + + + + + + @@ -20,8 +59,49 @@ - - + + + + + + + + + + + + + $(ProjectDirectory)pkg/Microsoft.NETCore.Platforms/runtime.json + + + + + + + + + <_builtRuntimePackages Include="$(SourceBuiltAssetsDir)*.symbols.nupkg" /> + <_builtRuntimePackages> + $([System.String]::Copy('%(FileName)').Replace('symbols', 'nupkg')) + + + + + + + + + + + diff --git a/src/SourceBuild/tarball/content/repos/source-build-reference-packages.proj b/src/SourceBuild/tarball/content/repos/source-build-reference-packages.proj index 69ab564a2adc..9545b50e4bf7 100644 --- a/src/SourceBuild/tarball/content/repos/source-build-reference-packages.proj +++ b/src/SourceBuild/tarball/content/repos/source-build-reference-packages.proj @@ -2,7 +2,9 @@ - $(StandardSourceBuildCommand) $(StandardSourceBuildArgs) + $(StandardSourceBuildArgs) + $(BuildCommandArgs) /p:MicrosoftNetCoreIlasmPackageRuntimeId=$(NETCoreSdkRuntimeIdentifier) + $(StandardSourceBuildCommand) $(BuildCommandArgs) $(ProjectDirectory)NuGet.config $(ProjectDirectory)global.json diff --git a/src/redist/targets/Crossgen.targets b/src/redist/targets/Crossgen.targets index 8949af13254c..a59ed388fa08 100644 --- a/src/redist/targets/Crossgen.targets +++ b/src/redist/targets/Crossgen.targets @@ -6,7 +6,7 @@ microsoft.netcore.app.runtime.$(SharedFrameworkRid) - microsoft.netcore.app.crossgen2.$(HostOSName)-$(BuildArchitecture) + microsoft.netcore.app.crossgen2.$(Crossgen2Rid) $(NuGetPackageRoot)/$(RuntimeNETCrossgenPackageName)/$(MicrosoftNETCoreAppRuntimePackageVersion)/tools/crossgen2$(ExeExtension) diff --git a/src/redist/targets/GenerateLayout.targets b/src/redist/targets/GenerateLayout.targets index 88a053b61d4d..ce5e09b69ece 100644 --- a/src/redist/targets/GenerateLayout.targets +++ b/src/redist/targets/GenerateLayout.targets @@ -84,6 +84,9 @@ dotnet-runtime$(PgoTerm)-$(VSRedistCommonNetCoreSharedFrameworkx6460PackageVersion)-$(SharedFrameworkRid)$(ArchiveExtension) windowsdesktop-runtime-$(MicrosoftWindowsDesktopAppRuntimePackageVersion)-$(SharedFrameworkRid)$(ArchiveExtension) + $(HostOSName)-$(BuildArchitecture) + $(SharedFrameworkRid) + $(SharedFrameworkRid) linux-x64 $(AspNetCoreInstallerRid)