Skip to content

Commit

Permalink
Dont use PSC for RID checks.
Browse files Browse the repository at this point in the history
  • Loading branch information
nagilson committed Nov 2, 2022
1 parent 8516ab6 commit d923dae
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ Copyright (c) .NET Foundation. All rights reserved.
<RuntimeIdentifier Condition="'$(PlatformTarget)' == 'x86' or '$(PlatformTarget)' == ''">win7-x86</RuntimeIdentifier>
</PropertyGroup>

<!-- PubishSelfContained may be set but not change self contained if we are not publishing, or self contained was already set globally. This condition tracks whether it will take effect.-->
<PropertyGroup Condition=" '$(_CommandLineDefinedSelfContained)' != 'true' and '$(_IsPublishing)' == 'true' and ('$(PublishSelfContained)' == 'true' or '$(PublishSelfContained)' == 'false')">
<_PublishSelfContainedIsActive>true</_PublishSelfContainedIsActive>
</PropertyGroup>

<PropertyGroup Condition="'$(UseCurrentRuntimeIdentifier)' == ''">
<UseCurrentRuntimeIdentifier Condition="
'$(RuntimeIdentifier)' == '' and
Expand All @@ -71,7 +76,7 @@ Copyright (c) .NET Foundation. All rights reserved.
'$(PublishReadyToRun)' == 'true' or
'$(PublishSingleFile)' == 'true' or
'$(PublishAot)' == 'true' or
('$(_CommandLineDefinedSelfContained)' != 'true' and '$(_IsPublishing)' == 'true' and '$(PublishSelfContained)' == 'true')
'$(_PublishSelfContainedIsActive)' == 'true'
)">true</UseCurrentRuntimeIdentifier>
</PropertyGroup>

Expand Down Expand Up @@ -170,7 +175,7 @@ Copyright (c) .NET Foundation. All rights reserved.
ResourceName="ImplicitRuntimeIdentifierResolutionForPublishPropertyFailed"
FormatArguments="SelfContained"/>

<NETSdkError Condition="'$(_IsPublishing)' == 'true' and '$(PublishSelfContained)' == 'true' and '$(RuntimeIdentifier)' == '' and '$(RuntimeIdentifiers)' == ''"
<NETSdkError Condition="'$(_PublishSelfContainedIsActive)' == 'true' and '$(RuntimeIdentifier)' == '' and '$(RuntimeIdentifiers)' == ''"
ResourceName="ImplicitRuntimeIdentifierResolutionForPublishPropertyFailed"
FormatArguments="PublishSelfContained"/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Copyright (c) .NET Foundation. All rights reserved.

<!-- Edit SelfContained to match the value of PublishSelfContained if we are publishing.
This Won't affect t:/Publish (because of _IsPublishing), and also won't override a global SelfContained property.-->
<PropertyGroup Condition="'$(_CommandLineDefinedSelfContained)' != 'true' and '$(_IsPublishing)' == 'true'">
<PropertyGroup Condition="'$(_PublishSelfContainedIsActive)' == 'true'">
<SelfContained Condition="'$(PublishSelfContained)' == 'true' or '$(PublishSelfContained)' == 'false'">$(PublishSelfContained)</SelfContained>
</PropertyGroup>

Expand Down

0 comments on commit d923dae

Please sign in to comment.