Skip to content

Commit 160e9e4

Browse files
authored
Add Parquet symbols nuget package. (#145)
Add symbols package for ML.Parquet package. Put common NuGet package logic in props file. Fix #144
1 parent 3102180 commit 160e9e4

5 files changed

+21
-25
lines changed

pkg/Directory.Build.props

+14
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
<IncludeBuildOutput>false</IncludeBuildOutput>
77
<IncludeSymbols>false</IncludeSymbols>
88

9+
<IsSymbolsPackage Condition="$(MSBuildProjectName.Contains('.symbols'))">true</IsSymbolsPackage>
10+
<PackageIdFolderName>$(MSBuildProjectName.Replace('.symbols', ''))</PackageIdFolderName>
11+
912
<!--
1013
Our .nupkgproj files have conflicting names with src projects, which puts their intermediate
1114
output in the same folder (like project.assets.json). Override the intermediate output to
@@ -24,6 +27,17 @@
2427
<PackageReleaseNotes>https://github.com/dotnet/machinelearning/tree/master/Documentation/release-notes</PackageReleaseNotes>
2528
</PropertyGroup>
2629

30+
<ItemGroup>
31+
<Content Include="$(PackageAssetsPath)$(PackageIdFolderName)\lib\**\*" Pack="true" PackagePath="lib" />
32+
<Content Include="$(PackageAssetsPath)$(PackageIdFolderName)\runtimes\**\*" Pack="true" PackagePath="runtimes" />
33+
</ItemGroup>
34+
35+
<ItemGroup Condition="'$(IsSymbolsPackage)' != 'true'">
36+
<Content Remove="$(PackageAssetsPath)$(PackageIdFolderName)\**\*.pdb" />
37+
<Content Remove="$(PackageAssetsPath)$(PackageIdFolderName)\**\*.dwarf" />
38+
<Content Remove="$(PackageAssetsPath)$(PackageIdFolderName)\**\*.dbg" />
39+
</ItemGroup>
40+
2741
<!-- Work around https://github.com/NuGet/Home/issues/6091 -->
2842
<ItemDefinitionGroup>
2943
<PackageReference>

pkg/Microsoft.ML.Parquet/Microsoft.ML.Parquet.nupkgproj

-6
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,4 @@
1010
<PackageReference Include="Parquet.Net" Version="$(ParquetDotNetPackageVersion)" />
1111
</ItemGroup>
1212

13-
<ItemGroup>
14-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\lib\**\*" Pack="true" PackagePath="lib" />
15-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\lib\**\*.xml" Pack="true" PackagePath="lib" />
16-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\runtimes\**\*" Pack="true" PackagePath="runtimes" />
17-
</ItemGroup>
18-
1913
</Project>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<Project DefaultTargets="Pack">
2+
3+
<Import Project="Microsoft.ML.Parquet.nupkgproj" />
4+
5+
</Project>

pkg/Microsoft.ML/Microsoft.ML.nupkgproj

+1-9
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,7 @@
1111
<PackageReference Include="System.Reflection.Emit.Lightweight" Version="$(SystemReflectionEmitLightweightPackageVersion)" />
1212
<PackageReference Include="System.Threading.Tasks.Dataflow" Version="$(SystemThreadingTasksDataflowPackageVersion)" />
1313
<PackageReference Include="System.CodeDom" Version="$(SystemCodeDomPackageVersion)" />
14-
<PackageReference Include="System.ValueTuple" Version="$(SystemValueTupleVersion)" />
15-
</ItemGroup>
16-
17-
<ItemGroup>
18-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\lib\**\*.dll" Pack="true" PackagePath="lib" />
19-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\lib\**\*.xml" Pack="true" PackagePath="lib" />
20-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\runtimes\**\*.dll" Pack="true" PackagePath="runtimes" />
21-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\runtimes\**\*.dylib" Pack="true" PackagePath="runtimes" />
22-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectName)\runtimes\**\*.so" Pack="true" PackagePath="runtimes" />
14+
<PackageReference Include="System.ValueTuple" Version="$(SystemValueTupleVersion)" />
2315
</ItemGroup>
2416

2517
</Project>
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
1-
<Project Sdk="Microsoft.NET.Sdk" DefaultTargets="Pack">
1+
<Project DefaultTargets="Pack">
22

33
<Import Project="Microsoft.ML.nupkgproj" />
44

5-
<PropertyGroup>
6-
<MSBuildProjectNameWithoutSymbols>$(MSBuildProjectName.Replace('.symbols', ''))</MSBuildProjectNameWithoutSymbols>
7-
</PropertyGroup>
8-
9-
<ItemGroup>
10-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectNameWithoutSymbols)\lib\**\*" Pack="true" PackagePath="lib" />
11-
<Content Include="$(PackageAssetsPath)$(MSBuildProjectNameWithoutSymbols)\runtimes\**\*" Pack="true" PackagePath="runtimes" />
12-
</ItemGroup>
13-
145
</Project>

0 commit comments

Comments
 (0)