Skip to content

Commit

Permalink
Added import of .user file for multi-targeted builds (#9444) (#9558)
Browse files Browse the repository at this point in the history
Fixes #9131

Context
As described on the issue, muti-targeted builds did not import the .user file on the outer build. This change makes the outer build import the .user file.

Changes Made
Added import reference to .user file in  Microsoft.Common.CrossTargeting.targets .

Testing
Test is in SDK repo (dotnet/sdk#37192)
  • Loading branch information
maridematte authored Dec 18, 2023
1 parent 65abd9a commit 00e3ae8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Tasks/Microsoft.Common.CrossTargeting.targets
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ Copyright (C) Microsoft Corporation. All rights reserved.
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.CrossTargeting.targets\ImportBefore\*.targets"
Condition="'$(ImportByWildcardBeforeMicrosoftCommonCrossTargetingTargets)' == 'true' and exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.CrossTargeting.targets\ImportBefore')"/>

<Import Project="$(MSBuildProjectFullPath).user" Condition="Exists('$(MSBuildProjectFullPath).user')"/>

<Import Project="$(CustomBeforeMicrosoftCommonCrossTargetingTargets)" Condition="'$(CustomBeforeMicrosoftCommonCrossTargetingTargets)' != '' and Exists('$(CustomBeforeMicrosoftCommonCrossTargetingTargets)')"/>

<Target Name="GetTargetFrameworks"
Expand Down

0 comments on commit 00e3ae8

Please sign in to comment.