Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

eng/SourceBuild.props: when unset, let the repo determine RuntimeOS. #82546

Merged
merged 2 commits into from
Mar 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 4 additions & 8 deletions eng/SourceBuild.props
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,6 @@
<_targetRidPlatformIndex>$(TargetRid.LastIndexOf('-'))</_targetRidPlatformIndex>
<TargetArch>$(TargetRid.Substring($(_targetRidPlatformIndex)).TrimStart('-'))</TargetArch>

<!-- RuntimeOS is the build host rid OS. -->
<RuntimeOS>$(TargetRid.Substring(0, $(_targetRidPlatformIndex)))</RuntimeOS>

<!-- BaseOS is an expected known rid in the graph that TargetRid is compatible with.
It's used to add TargetRid in the graph if the parent can't be detected. -->
<BaseOS>$(RuntimeOS)</BaseOS>

<LogVerbosity Condition="'$(LogVerbosity)' == ''">minimal</LogVerbosity>
</PropertyGroup>

Expand All @@ -38,10 +31,13 @@
<InnerBuildArgs>$(InnerBuildArgs) --nodereuse false</InnerBuildArgs>
<InnerBuildArgs>$(InnerBuildArgs) --warnAsError false</InnerBuildArgs>
<InnerBuildArgs>$(InnerBuildArgs) --outputrid $(TargetRid)</InnerBuildArgs>
<!-- RuntimeOS is the build host rid OS. -->
<InnerBuildArgs>$(InnerBuildArgs) /p:RuntimeOS=$(RuntimeOS)</InnerBuildArgs>
<!-- BaseOS is an expected known rid in the graph that TargetRid is compatible with.
It's used to add TargetRid in the graph if the parent can't be detected. -->
<InnerBuildArgs>$(InnerBuildArgs) /p:AdditionalRuntimeIdentifierParent=$(BaseOS)</InnerBuildArgs>
<InnerBuildArgs Condition="'$(OfficialBuildId)' != ''">$(InnerBuildArgs) /p:OfficialBuildId=$(OfficialBuildId)</InnerBuildArgs>
<InnerBuildArgs Condition="'$(ContinuousIntegrationBuild)' != ''">$(InnerBuildArgs) /p:ContinuousIntegrationBuild=$(ContinuousIntegrationBuild)</InnerBuildArgs>
<InnerBuildArgs>$(InnerBuildArgs) /p:AdditionalRuntimeIdentifierParent=$(BaseOS)</InnerBuildArgs>
<InnerBuildArgs Condition="'$(SourceBuildUseMonoRuntime)' == 'true'">$(InnerBuildArgs) /p:PrimaryRuntimeFlavor=Mono /p:RuntimeFlavor=Mono</InnerBuildArgs>
</PropertyGroup>
</Target>
Expand Down
1 change: 0 additions & 1 deletion eng/pipelines/common/global-build-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,6 @@ jobs:
buildScript: $(_sclEnableCommand) $(Build.SourcesDirectory)$(dir)build$(scriptExt)
nonPortable: ${{ parameters.isNonPortableSourceBuild }}
targetRID: ${{ parameters.targetRid }}
runtimeOS: linux
name: ${{ parameters.platform }}

- ${{ if in(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator') }}:
Expand Down