diff --git a/Directory.Build.props b/Directory.Build.props index 03f77f38f6dc4b..dc8d1caf426de5 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -366,6 +366,7 @@ $(RepositoryEngineeringDir)NoTargetsSdk.BeforeTargets.targets $(RepositoryEngineeringDir)TraversalSdk.AfterTargets.targets + $(BeforeMicrosoftNETSdkTargets);$(RepositoryEngineeringDir)ILSdk.BeforeTargets.targets diff --git a/Directory.Build.targets b/Directory.Build.targets index fb19adafecf9a9..cd68fb94f4fe99 100644 --- a/Directory.Build.targets +++ b/Directory.Build.targets @@ -25,11 +25,11 @@ %(RuntimePackRuntimeIdentifiers);$(PackageRID) + Condition="'%(TargetFramework)' == '$(NetCoreAppCurrent)'">%(RuntimePackRuntimeIdentifiers);$(NETCoreSdkRuntimeIdentifier) %(Crossgen2RuntimeIdentifiers);$(PackageRID) + Condition="'%(TargetFramework)' == '$(NetCoreAppCurrent)'" >%(Crossgen2RuntimeIdentifiers);$(NETCoreSdkRuntimeIdentifier) diff --git a/eng/DotNetBuild.props b/eng/DotNetBuild.props index 1631f76ce95771..93b34cacdc0ca9 100644 --- a/eng/DotNetBuild.props +++ b/eng/DotNetBuild.props @@ -1,6 +1,13 @@ + + + $(TargetRid) + + + + runtime @@ -8,49 +15,9 @@ .\build.cmd ./build.sh - <_hostRid>$([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier) - - $(_hostRid) - - - <_targetRidPlatformIndex>$(TargetRid.LastIndexOf('-')) - $(TargetRid.Substring($(_targetRidPlatformIndex)).TrimStart('-')) - $(TargetRid.Substring(0, $(_targetRidPlatformIndex))) - - <_hostRidPlatformIndex>$(_hostRid.LastIndexOf('-')) - <_hostArch>$(_hostRid.Substring($(_hostRidPlatformIndex)).TrimStart('-')) - minimal - - - true - true - true - true - true - true - true - true - true - - true - - - - - - false - - true - - false - - @@ -63,21 +30,20 @@ $(InnerBuildArgs) $(FlagParameterPrefix)sign $(InnerBuildArgs) $(FlagParameterPrefix)pack - $(InnerBuildArgs) $(FlagParameterPrefix)arch $(TargetArch) - $(InnerBuildArgs) $(FlagParameterPrefix)os $(TargetOS) - $(InnerBuildArgs) $(FlagParameterPrefix)cross + $(InnerBuildArgs) $(FlagParameterPrefix)arch $(TargetArchitecture) + $(InnerBuildArgs) $(FlagParameterPrefix)os windows + $(InnerBuildArgs) $(FlagParameterPrefix)os $(_portableOS) + + $(InnerBuildArgs) $(FlagParameterPrefix)cross $(InnerBuildArgs) $(FlagParameterPrefix)configuration $(Configuration) $(InnerBuildArgs) $(FlagParameterPrefix)verbosity $(LogVerbosity) $(InnerBuildArgs) $(FlagParameterPrefix)nodereuse $(ArcadeFalseBoolBuildArg) $(InnerBuildArgs) $(FlagParameterPrefix)warnAsError $(ArcadeFalseBoolBuildArg) $(InnerBuildArgs) $(FlagParameterPrefix)usemonoruntime - $(InnerBuildArgs) --outputrid $(TargetRid) - - $(InnerBuildArgs) /p:PackageOS=$(RuntimeOS) /p:ToolsOS=$(RuntimeOS) - + $(InnerBuildArgs) --outputrid $(OutputRID) + $(InnerBuildArgs) /p:AdditionalRuntimeIdentifierParent=$(BaseOS) /p:BaseOS=$(BaseOS) $(InnerBuildArgs) /p:WasmEnableThreads=true diff --git a/eng/ILSdk.BeforeTargets.targets b/eng/ILSdk.BeforeTargets.targets new file mode 100644 index 00000000000000..d6915f01f68d53 --- /dev/null +++ b/eng/ILSdk.BeforeTargets.targets @@ -0,0 +1,6 @@ + + + + $(NETCoreSdkRuntimeIdentifier) + + diff --git a/eng/OSArch.props b/eng/OSArch.props index d1be0745175825..22fb8b577fca90 100644 --- a/eng/OSArch.props +++ b/eng/OSArch.props @@ -32,4 +32,8 @@ x64 $(TargetArchitecture) - \ No newline at end of file + + + <_ImportedOSArchProps>true + + diff --git a/eng/Publishing.props b/eng/Publishing.props index dbd80cac884d17..3c4313b26f60cc 100644 --- a/eng/Publishing.props +++ b/eng/Publishing.props @@ -78,7 +78,7 @@ but we do produce them in both the VMR and the runtime official build. --> - true + true true diff --git a/eng/RuntimeIdentifier.props b/eng/RuntimeIdentifier.props index 9ebd5e65194874..c16bb0e188385a 100644 --- a/eng/RuntimeIdentifier.props +++ b/eng/RuntimeIdentifier.props @@ -25,38 +25,6 @@ <_portableOS Condition="'$(HostOS)' == 'win' and '$(TargetsMobile)' != 'true'">win - - - <_packageOS>$(_portableOS) - - <_packageOS Condition="'$(CrossBuild)' == 'true' and '$(_portableOS)' != 'linux-musl' and '$(_portableOS)' != 'linux-bionic' and '$(_portableOS)' != 'android'">$(_hostOS) - - - $(PackageOS)-$(TargetArchitecture) - $(_packageOS)-$(TargetArchitecture) - - - - - - <_portableHostOS>$(_hostOS) - <_portableHostOS Condition="'$(_portableHostOS)' == 'windows'">win - <_portableHostOS Condition="'$(CrossBuild)' != 'true' and '$(_portableOS)' == 'linux-musl'">linux-musl - - - $(ToolsOS)-$(_hostArch) - $(_portableHostOS)-$(_hostArch) - - - $(ToolsRID) - - @@ -22,12 +22,12 @@ true false - - $(PackageRID) + + $(OutputRID) false - true + true true @@ -119,29 +119,29 @@ - + - + - + - + - + true <_NativeAotSupportedArch Condition="'$(TargetArchitecture)' == 'x64' or '$(TargetArchitecture)' == 'arm64' or '$(TargetArchitecture)' == 'arm' or '$(TargetArchitecture)' == 'loongarch64' or '$(TargetArchitecture)' == 'riscv64' or ('$(TargetOS)' == 'windows' and '$(TargetArchitecture)' == 'x86')">true true + + + <_AotToolsSupportedOS Condition="'$(TargetsMobile)' != 'true' and '$(TargetsLinuxBionic)' != 'true' and '$(StageOneBuild)' != 'true'">true + <_AotToolsSupportedArch Condition="'$(TargetArchitecture)' != 'armel'">true + true @@ -99,7 +104,7 @@ clr.native+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs+clr.crossarchtools+host.native - clr.native+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs+clr.crossarchtools + clr.native+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs+clr.crossarchtools clr.native+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs+clr.crossarchtools clr.iltools+clr.packages @@ -164,7 +169,6 @@ <_IsCommunityCrossArchitecture Condition="'$(CrossBuild)' == 'true' and ('$(TargetArchitecture)' == 'loongarch64' or '$(TargetArchitecture)' == 'riscv64')">true true - true @@ -432,13 +436,14 @@ $(CoreClrProjectRoot)tools\AssemblyChecker\AssemblyChecker.csproj; $(ToolsProjectRoot)StressLogAnalyzer\src\StressLogAnalyzer.csproj" Category="clr" Condition="'$(DotNetBuildSourceOnly)' != 'true'"/> - - - - - - - + + + + + + + + true diff --git a/src/coreclr/tools/aot/ILCompiler/ILCompiler_publish.csproj b/src/coreclr/tools/aot/ILCompiler/ILCompiler_publish.csproj index c48b1aa3fb7af1..3b996b78fb0416 100644 --- a/src/coreclr/tools/aot/ILCompiler/ILCompiler_publish.csproj +++ b/src/coreclr/tools/aot/ILCompiler/ILCompiler_publish.csproj @@ -2,7 +2,8 @@ <_IsPublishing>true - $(PackageRID) + $(OutputRID) + $(BaseOS) $(RuntimeBinDir)ilc-published/ true true diff --git a/src/coreclr/tools/aot/crossgen2/crossgen2_publish.csproj b/src/coreclr/tools/aot/crossgen2/crossgen2_publish.csproj index c7041857e08577..54953da6834124 100644 --- a/src/coreclr/tools/aot/crossgen2/crossgen2_publish.csproj +++ b/src/coreclr/tools/aot/crossgen2/crossgen2_publish.csproj @@ -2,7 +2,8 @@ <_IsPublishing>true - $(PackageRID) + $(OutputRID) + $(BaseOS) $(RuntimeBinDir)crossgen2-published/ true true diff --git a/src/installer/pkg/projects/Directory.Build.props b/src/installer/pkg/projects/Directory.Build.props index 947ea568dac2ff..8fa447a2e4d261 100644 --- a/src/installer/pkg/projects/Directory.Build.props +++ b/src/installer/pkg/projects/Directory.Build.props @@ -72,7 +72,7 @@ - <_buildingOnRID Include="$(PackageRID)" Condition="'$(BuildOnUnknownPlatforms)' != 'false'"> + <_buildingOnRID Include="$(NETCoreSdkRuntimeIdentifier)" Condition="'$(BuildOnUnknownPlatforms)' != 'false'"> $(Platform) diff --git a/src/libraries/System.Runtime.InteropServices/tests/TestAssets/NativeExports/NativeExports.csproj b/src/libraries/System.Runtime.InteropServices/tests/TestAssets/NativeExports/NativeExports.csproj index ad5bd11ee41cc2..058b11597e198f 100644 --- a/src/libraries/System.Runtime.InteropServices/tests/TestAssets/NativeExports/NativeExports.csproj +++ b/src/libraries/System.Runtime.InteropServices/tests/TestAssets/NativeExports/NativeExports.csproj @@ -7,12 +7,13 @@ true true Major - - false $(OutputRID) - $(PackageRID) + + $(OutputRID) + true + + false <_TargetsAppleOS Condition="'$(TargetOS)' == 'osx' or '$(TargetOS)' == 'maccatalyst' or '$(TargetOS)' == 'ios' or '$(TargetOS)' == 'tvos' or '$(TargetOS)' == 'iossimulator' or '$(TargetOS)' == 'tvossimulator'">true @@ -23,8 +24,6 @@ - diff --git a/src/mono/browser/browser.proj b/src/mono/browser/browser.proj index e01f3e613c2798..3f4cd031156b53 100644 --- a/src/mono/browser/browser.proj +++ b/src/mono/browser/browser.proj @@ -4,7 +4,6 @@ - browser-wasm $([MSBuild]::NormalizeDirectory('$(ArtifactsBinDir)', 'native', '$(NetCoreAppCurrent)-$(TargetOS)-$(Configuration)-$(TargetArchitecture)')) $([MSBuild]::NormalizeDirectory('$(ArtifactsBinDir)', 'native', 'generated')) diff --git a/src/mono/mono.proj b/src/mono/mono.proj index 9dfdfe6f78e9ad..28b7d22ef4b29a 100644 --- a/src/mono/mono.proj +++ b/src/mono/mono.proj @@ -97,21 +97,21 @@ - - - - - - + @@ -915,7 +915,7 @@ JS_ENGINES = [NODE_JS] - <_LibclangPackageReferencePathPropertyName Include="Pkgruntime_$(_portableHostOS)-$(BuildArchitecture)_Microsoft_NETCore_Runtime_Mono_LLVM_Libclang" /> + <_LibclangPackageReferencePathPropertyName Include="Pkgruntime_$(NETCoreSdkPortableRuntimeIdentifier)_Microsoft_NETCore_Runtime_Mono_LLVM_Libclang" /> <_LibclangPackageReferencePath>$(%(_LibclangPackageReferencePathPropertyName.Identity)) diff --git a/src/mono/wasi/wasi.proj b/src/mono/wasi/wasi.proj index 1f7cf1ecc20b1a..f310a982a61b16 100644 --- a/src/mono/wasi/wasi.proj +++ b/src/mono/wasi/wasi.proj @@ -1,7 +1,6 @@ - wasi-wasm $([MSBuild]::NormalizeDirectory('$(ArtifactsBinDir)', 'native', '$(NetCoreAppCurrent)-$(TargetOS)-$(Configuration)-$(TargetArchitecture)')) @@ -216,7 +215,7 @@ $(CMakeConfigurationWasiFlags) -O2 -