Use the portable linux-x64
runtime when building on Linux.
This commit is contained in:
parent
dff66c1acb
commit
a97b572e49
4 changed files with 13 additions and 1 deletions
|
@ -7,5 +7,6 @@
|
|||
<IncludeAdditionalSharedFrameworks Condition=" '$(IncludeAdditionalSharedFrameworks)' == '' ">false</IncludeAdditionalSharedFrameworks>
|
||||
<IncludeNuGetPackageArchive Condition=" '$(IncludeNuGetPackageArchive)' == '' ">true</IncludeNuGetPackageArchive>
|
||||
<SkipBuildingInstallers Condition=" '$(SkipBuildingInstallers)' == '' ">false</SkipBuildingInstallers>
|
||||
<UsePortableLinuxSharedFramework Condition=" '$(UsePortableLinuxSharedFramework)' == '' AND '$(OSPlatform)' == 'linux' ">true</UsePortableLinuxSharedFramework>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
|
|
@ -5,12 +5,14 @@
|
|||
<GetCurrentRuntimeInformation>
|
||||
<Output TaskParameter="Rid" PropertyName="HostRid" />
|
||||
<Output TaskParameter="OSName" PropertyName="HostOSName" />
|
||||
<Output TaskParameter="OSPlatform" PropertyName="HostOSPlatform" />
|
||||
</GetCurrentRuntimeInformation>
|
||||
|
||||
<PropertyGroup>
|
||||
<Rid Condition=" '$(Rid)' == '' ">$(HostRid)</Rid>
|
||||
<Architecture Condition=" '$(Architecture)' == '' ">x64</Architecture>
|
||||
<OSName Condition=" '$(OSName)' == '' ">$(HostOSName)</OSName>
|
||||
<OSPlatform Condition=" '$(OSPlatform)' == '' ">$(HostOSPlatform)</OSPlatform>
|
||||
|
||||
<BuildInfoPropsContent>
|
||||
<Project ToolsVersion="15.0">
|
||||
|
@ -18,6 +20,7 @@
|
|||
<Rid>$(Rid)</Rid>
|
||||
<Architecture>$(Architecture)</Architecture>
|
||||
<OSName>$(OSName)</OSName>
|
||||
<OSPlatform>$(OSPlatform)</OSPlatform>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
</BuildInfoPropsContent>
|
||||
|
|
|
@ -10,7 +10,11 @@
|
|||
<DownloadedSharedFrameworkInstallerFileName Condition=" '$(InstallerExtension)' != '' ">dotnet-sharedframework-$(ProductMonikerRid).$(SharedFrameworkVersion)$(InstallerExtension)</DownloadedSharedFrameworkInstallerFileName>
|
||||
<DownloadedSharedFrameworkInstallerFile Condition=" '$(InstallerExtension)' != '' ">$(PackagesDirectory)/$(DownloadedSharedFrameworkInstallerFileName)</DownloadedSharedFrameworkInstallerFile>
|
||||
|
||||
<CombinedFrameworkHostCompressedFileName>dotnet-$(ProductMonikerRid).$(SharedFrameworkVersion)$(ArchiveExtension)</CombinedFrameworkHostCompressedFileName>
|
||||
<!-- Use the portable linux-x64 Rid when downloading the shared framework compressed file.
|
||||
NOTE: There isn't a 'linux-x64' version of the installers or the additional shared framweork. -->
|
||||
<SharedFrameworkRid>$(ProductMonikerRid)</SharedFrameworkRid>
|
||||
<SharedFrameworkRid Condition=" '$(UsePortableLinuxSharedFramework)' == 'true' ">linux-x64</SharedFrameworkRid>
|
||||
<CombinedFrameworkHostCompressedFileName>dotnet-$(SharedFrameworkRid).$(SharedFrameworkVersion)$(ArchiveExtension)</CombinedFrameworkHostCompressedFileName>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Additional Shared Framework to be installed -->
|
||||
|
|
|
@ -16,10 +16,14 @@ namespace Microsoft.DotNet.Cli.Build
|
|||
[Output]
|
||||
public string OSName { get; set; }
|
||||
|
||||
[Output]
|
||||
public string OSPlatform { get; set; }
|
||||
|
||||
public override bool Execute()
|
||||
{
|
||||
Rid = RuntimeEnvironment.GetRuntimeIdentifier();
|
||||
OSName = GetOSShortName();
|
||||
OSPlatform = RuntimeEnvironment.OperatingSystemPlatform.ToString().ToLower();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue