diff options
author | Wes Haggard <Wes.Haggard@microsoft.com> | 2017-03-01 23:53:25 +0300 |
---|---|---|
committer | Wes Haggard <Wes.Haggard@microsoft.com> | 2017-03-01 23:53:25 +0300 |
commit | 5eaf66d4ec42df22426dd6a41a4ee6fe908d8cb8 (patch) | |
tree | 644acbe59eb466c8a3fa534a666723f60cf4855a /referenceFromRuntime.targets | |
parent | e7c0d730088ff84d39862596264bf20f50fe88b3 (diff) |
Allow native images to resolve for ReferenceFromRuntime references
We will likely be removing the System.Private.CoreLib.dll and only
having System.Private.CoreLib.ni.dll so we need our ReferenceFromRuntime
infrastructure to support falling back to the ni if that is the only
thing present.
Diffstat (limited to 'referenceFromRuntime.targets')
-rw-r--r-- | referenceFromRuntime.targets | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/referenceFromRuntime.targets b/referenceFromRuntime.targets index df0b90a15e..d707f8313f 100644 --- a/referenceFromRuntime.targets +++ b/referenceFromRuntime.targets @@ -36,13 +36,23 @@ <_filteredReferencePathFromRuntimeByFileName Include="@(_referencePathFromRuntimeByFileName)" Condition="'@(_referencePathFromRuntimeByFileName)' == '@(ReferenceFromRuntime)' AND '%(Identity)' != ''" /> - <_missingReferenceFromRuntime Include="@(ReferenceFromRuntime)" Exclude="@(_referencePathFromRuntimeByFileName)" /> + <_remainingReferenceFromRuntime Include="@(ReferenceFromRuntime)" Exclude="@(_filteredReferencePathFromRuntimeByFileName)" /> + + <!-- Fallback and check for native images for the references as well --> + <_remainingReferenceFromRuntimeWithNI Include="@(_remainingReferenceFromRuntime->'%(Identity).ni')"> + <OriginalReferenceFromRuntime>%(Identity)</OriginalReferenceFromRuntime> + </_remainingReferenceFromRuntimeWithNI> + + <_filteredReferencePathFromRuntimeByFileName Include="@(_referencePathFromRuntimeByFileName)" + Condition="'@(_referencePathFromRuntimeByFileName)' == '@(_remainingReferenceFromRuntimeWithNI)' AND '%(Identity)' != ''" /> + + <_missingReferenceFromRuntime Include="@(_remainingReferenceFromRuntimeWithNI)" Exclude="@(_filteredReferencePathFromRuntimeByFileName)" /> <!-- transform back to path --> <ReferencePath Include="@(_filteredReferencePathFromRuntimeByFileName->'%(ReferencePath)')" /> </ItemGroup> <Error Condition="'@(_missingReferenceFromRuntime)' != ''" - Text="Could not resolve ReferenceFromRuntime item(s) '@(_missingReferenceFromRuntime)' from '$(RuntimeProjectFile)'." /> + Text="Could not resolve ReferenceFromRuntime item(s) '%(_missingReferenceFromRuntime.OriginalReferenceFromRuntime)' from '$(RuntimeProjectFile)'." /> </Target> </Project> |