Fix Tizen build by passing through OutputRid, if it is defined.

This commit is contained in:
Eric Erhardt 2017-10-23 13:37:30 -05:00
Родитель 1732b0ab67
Коммит 96f0e7ad51
2 изменённых файлов: 7 добавлений и 0 удалений

Просмотреть файл

@ -402,6 +402,7 @@
in order to get the correct output directories in the child project.
-->
<MSBuildPassThroughPropertyList>/p:OSGroup=$(OSGroup) /p:PortableBuild=$(PortableBuild) /p:TargetArchitecture=$(TargetArchitecture) /p:ConfigurationGroup=$(ConfigurationGroup)</MSBuildPassThroughPropertyList>
<MSBuildPassThroughPropertyList Condition="'$(OutputRid)' != ''">$(MSBuildPassThroughPropertyList) /p:OutputRid=$(OutputRid)</MSBuildPassThroughPropertyList>
</PropertyGroup>
<!-- Use Roslyn Compilers to build, if we are not using the .NET SDK to build -->

Просмотреть файл

@ -3,6 +3,7 @@ using Microsoft.Build.Utilities;
using Microsoft.Extensions.DependencyModel;
using NuGet.Common;
using NuGet.ProjectModel;
using System;
using System.IO;
using System.Linq;
@ -41,7 +42,12 @@ namespace Microsoft.DotNet.Build.Tasks
{
context = new DependencyContextJsonReader().Read(depsStream);
}
LockFile lockFile = LockFileUtilities.GetLockFile(AssetsFilePath, NullLogger.Instance);
if (lockFile == null)
{
throw new ArgumentException($"Could not load a LockFile at '{AssetsFilePath}'.", nameof(AssetsFilePath));
}
var manager = new RuntimeGraphManager();
var graph = manager.Collect(lockFile);