onnxruntime/csharp/src/Microsoft.ML.OnnxRuntime/Microsoft.ML.OnnxRuntime.csproj
Sreekanth Yalachigere 31ea11a696 Renaming MKL-DNN as DNNL (#2515)
* DNNL: Moving Files to rename file names

* DNNL name change

* azure pipeline updated

* disable ceil/dialation and enable Opset10

* disable ceil/dialation tests in Python

* mlperf_ssd_resnet34_1200 disabled
2019-12-03 07:34:23 -08:00

181 lines
8.3 KiB
XML

<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard1.1</TargetFramework>
<Platforms>AnyCPU;x86</Platforms>
<LangVersion>7.2</LangVersion>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<SignAssembly>true</SignAssembly>
<DelaySign>false</DelaySign>
<AssemblyOriginatorKeyFile>..\..\OnnxRuntime.snk</AssemblyOriginatorKeyFile>
<!--internal build related properties-->
<OnnxRuntimeCsharpRoot>..\..</OnnxRuntimeCsharpRoot>
<OnnxRuntimeBuildDirectory Condition="'$(OnnxRuntimeBuildDirectory)'==''">$(OnnxRuntimeCsharpRoot)\..\build\Windows</OnnxRuntimeBuildDirectory>
<NativeBuildOutputDir>$(OnnxRuntimeBuildDirectory)\$(Configuration)\$(Configuration)</NativeBuildOutputDir>
<TargetArchitecture Condition=" '$(TargetArchitecture)' == '' ">x64</TargetArchitecture>
<!--- packaging properties -->
<OrtPackageId Condition=" '$(OrtPackageId)' == '' ">Microsoft.ML.OnnxRuntime</OrtPackageId>
<PackageId>$(OrtPackageId)</PackageId>
<Authors>Microsoft</Authors>
<Description>This package contains ONNX Runtime for .Net platforms</Description>
<PackageTags>ONNX;ONNX Runtime;Machine Learning</PackageTags>
<PackageProjectUrl>https://github.com/Microsoft/onnxruntime</PackageProjectUrl>
<Copyright>© Microsoft Corporation. All rights reserved.</Copyright>
<PackageLicenseFile>LICENSE.txt</PackageLicenseFile>
<PackageIconUrl>https://go.microsoft.com/fwlink/?linkid=2049168</PackageIconUrl>
<PackageReleaseNotes>
Release Def:
Branch: $(BUILD_SOURCEBRANCH)
Commit: $(BUILD_SOURCEVERSION)
Build: https://aiinfra.visualstudio.com/Lotus/_build/results?buildId=$(BUILD_BUILDID)
</PackageReleaseNotes>
<!-- sourcelink flags -->
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<!-- Optional: Embed source files that are not tracked by the source control manager in the PDB -->
<!--EmbedUntrackedSources>true</EmbedUntrackedSources-->
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
</PropertyGroup>
<!--TODO: this works for single platform only. Need separate packaging scripts for multi-target packaging -->
<!--TODO: Find a way to bundle the native symbol files properly -->
<ItemGroup>
<None Include="$(OnnxRuntimeCsharpRoot)\..\include\onnxruntime\core\session\onnxruntime_*.h"
PackagePath="\build\native\include"
Pack="true"
CopyToOutputDirectory="Never"
Visible="false"
/>
<None Include="$(OnnxRuntimeCsharpRoot)\..\include\onnxruntime\core\providers\cpu\cpu_provider_factory.h"
PackagePath="\build\native\include"
Pack="true"
CopyToOutputDirectory="Never"
Visible="false"
/>
<None Include="$(OnnxRuntimeCsharpRoot)\..\include\onnxruntime\core\providers\cuda\cuda_provider_factory.h"
PackagePath="\build\native\include"
Pack="true"
CopyToOutputDirectory="Never"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\onnxruntime.lib"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Never"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\onnxruntime.dll"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Always"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\onnxruntime.pdb"
Condition="Exists('$(NativeBuildOutputDir)\onnxruntime.pdb')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Always"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\dnnl.dll"
Condition="Exists('$(NativeBuildOutputDir)\dnnl.dll')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Always"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\mklml.dll"
Condition="Exists('$(NativeBuildOutputDir)\mklml.dll')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Always"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\libiomp5md.dll"
Condition="Exists('$(NativeBuildOutputDir)\libiomp5md.dll')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Always"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\tvm.dll"
Condition="Exists('$(NativeBuildOutputDir)\tvm.dll')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
CopyToOutputDirectory="Always"
Visible="false"
/>
<None Include="$(OnnxRuntimeCsharpRoot)\..\LICENSE.txt;$(OnnxRuntimeCsharpRoot)\..\ThirdPartyNotices.txt;$(OnnxRuntimeCsharpRoot)\..\docs\Privacy.md"
PackagePath="\"
Pack="true"
Visible="false"
/>
<None Include="$(OnnxRuntimeCsharpRoot)\..\docs\CSharp_API.md"
PackagePath="\README.md"
Pack="true"
Visible="false"
/>
<None Include="$(PackageId).targets"
PackagePath="\build\$(TargetFramework);\build\native"
Pack="true"
Visible="false"
/>
<None Include="$(PackageId).props"
PackagePath="\build\$(TargetFramework);\build\native"
Pack="true"
Visible="false"
/>
<!-- Some tools to be packaged in nightly build only, should not be released -->
<!-- These are copied to the runtimes folder for coveniennce of loading with the dlls -->
<None Include="$(NativeBuildOutputDir)\onnxruntime_perf_test.exe"
Condition="('$(IsReleaseBuild)' != 'true') And ($(TargetArchitecture)=='x64') And Exists('$(NativeBuildOutputDir)\onnxruntime_perf_test.exe')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
Visible="false"
/>
<None Include="$(NativeBuildOutputDir)\onnx_test_runner.exe"
Condition="('$(IsReleaseBuild)' != 'true') And ($(TargetArchitecture)=='x64') And Exists('$(NativeBuildOutputDir)\onnx_test_runner.exe')"
PackagePath="\runtimes\win-$(TargetArchitecture)\native"
Pack="true"
Visible="false"
/>
</ItemGroup>
<ItemGroup>
<LicenseFile Include="$(OnnxRuntimeCsharpRoot)\..\LICENSE"/>
<PropertiesFile Include="$(OnnxRuntimeCsharpRoot)\src\Microsoft.ML.OnnxRuntime\props.xml"/>
<TargetsFile Include="$(OnnxRuntimeCsharpRoot)\src\Microsoft.ML.OnnxRuntime\targets.xml"/>
</ItemGroup>
<Target Name="ObtainPackageVersion" BeforeTargets="Build;Pack">
<ReadLinesFromFile File="$(OnnxRuntimeCsharpRoot)\..\VERSION_NUMBER">
<Output TaskParameter="Lines" ItemName="MajorVersionNumber"/>
</ReadLinesFromFile>
<Exec Command="git rev-parse --short HEAD" ConsoleToMSBuild="true">
<Output TaskParameter="ConsoleOutput" PropertyName="GitCommitHashShort" />
</Exec>
<PropertyGroup>
<CurrentDate>$([System.DateTime]::UtcNow.ToString(yyyyMMdd))</CurrentDate>
<CurrentTime>$([System.DateTime]::UtcNow.ToString(hhmm))</CurrentTime>
<PackageVersion>@(MajorVersionNumber)</PackageVersion>
<Version>$(PackageVersion)</Version>
<PackageVersion Condition="'$(IsReleaseBuild)'!='true'">$(PackageVersion)-dev-$(CurrentDate)-$(CurrentTime)-$(GitCommitHashShort)</PackageVersion>
</PropertyGroup>
<Message Importance="High" Text="PackageVersion=$(PackageVersion)" />
<Copy SourceFiles="@(LicenseFile)" DestinationFiles="@(LicenseFile->'$(OnnxRuntimeCsharpRoot)\..\%(Filename).txt')"/>
<Copy SourceFiles="@(PropertiesFile)" DestinationFiles="@(PropertiesFile->'$(OnnxRuntimeCsharpRoot)\src\\Microsoft.ML.OnnxRuntime\$(PackageId).props')"/>
<Copy SourceFiles="@(TargetsFile)" DestinationFiles="@(TargetsFile->'$(OnnxRuntimeCsharpRoot)\src\\Microsoft.ML.OnnxRuntime\$(PackageId).targets')"/>
</Target>
<ItemGroup>
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0-beta-63127-02" PrivateAssets="All"/>
<PackageReference Include="System.Memory" Version="4.5.3" />
</ItemGroup>
</Project>