-
Notifications
You must be signed in to change notification settings - Fork 4.7k
/
netstandard2.1.proj
60 lines (49 loc) · 2.85 KB
/
netstandard2.1.proj
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<Project Sdk="Microsoft.Build.NoTargets">
<PropertyGroup>
<SkipBuild Condition="'$(RuntimeFlavor)' != '$(PrimaryRuntimeFlavor)' or '$(TargetsMobile)' == 'true'">true</SkipBuild>
<GenerateInstallers>true</GenerateInstallers>
<InstallerName>netstandard-targeting-pack-2.1</InstallerName>
<PackageBrandNameSuffix>NETStandard.Library.Ref</PackageBrandNameSuffix>
<ProductBrandName>NETStandard.Library.Ref 2.1.0</ProductBrandName>
<VersionInstallerName>false</VersionInstallerName>
<PlatformPackageType>ToolPack</PlatformPackageType>
<UseBrandingNameInLinuxPackageDescription>true</UseBrandingNameInLinuxPackageDescription>
<OriginalNETStandard21PkgFilename>netstandard-targeting-pack-2.1.0-x64.rpm</OriginalNETStandard21PkgFilename>
<NETStandard21PkgDownloadUrl>https://dotnetcli.blob.core.windows.net/dotnet/Runtime/3.1.0/$(OriginalNETStandard21PkgFilename)</NETStandard21PkgDownloadUrl>
<NETStandard21TempDir>$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', 'download'))</NETStandard21TempDir>
<NETStandard21PkgDestinationPath>$(NETStandard21TempDir)$(OriginalNETStandard21PkgFilename)</NETStandard21PkgDestinationPath>
<NETStandard21PkgDownloadSemaphore>$(NETStandard21TempDir)netstandard21.semaphore</NETStandard21PkgDownloadSemaphore>
</PropertyGroup>
<UsingTask TaskName="DownloadFile" AssemblyFile="$(ArcadeSdkBuildTasksAssembly)" />
<Target Name="AcquireNETStandard21PackageContents"
Inputs="$(NETStandard21PkgDestinationPath)"
Outputs="$(NETStandard21PkgDownloadSemaphore)">
<RemoveDir Directories="$(NETStandard21TempDir)" />
<DownloadFile
Uri="$(NETStandard21PkgDownloadUrl)"
DestinationPath="$(NETStandard21PkgDestinationPath)"
Overwrite="true"
TimeoutInSeconds="9999" />
<Exec Command="rpm2cpio $(NETStandard21PkgDestinationPath) | cpio -idmv"
WorkingDirectory="$(NETStandard21TempDir)" />
<WriteLinesToFile
File="$(NETStandard21PkgDownloadSemaphore)"
Lines="$(NETStandard21PkgDownloadUrl)"
Overwrite="true"
Encoding="Unicode" />
</Target>
<Target Name="PublishToDisk"
DependsOnTargets="AcquireNETStandard21PackageContents">
<Error Condition="'$(OutputPath)' == ''" Text="Publishing to disk requires the OutputPath to be set to the root of the path to write to." />
<ItemGroup>
<Content Include="$(NETStandard21TempDir)usr/share/dotnet/**/*" />
</ItemGroup>
<Copy SourceFiles="@(Content)"
DestinationFolder="$(OutputPath)/%(RecursiveDir)" />
</Target>
<Target Name="AddLinuxPackageInformation" BeforeTargets="GetRpmInstallerJsonProperties">
<ItemGroup>
<RpmJsonProperty Include="directories" Object="[ "/usr/share/dotnet/packs/NETStandard.Library.Ref/2.1.0", "/usr/share/doc/netstandard-targeting-pack-2.1" ]" />
</ItemGroup>
</Target>
</Project>