mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-14 20:48:00 +00:00
* Enable ARM64 release builds * Add ARM release * Skip C# dll signing in ARM * Copy ARM binaries to Nuget * Restore nuget packages before ARM packaging * wip * Use host protoc at C# build * Set ProtocDirectory on cross-compiled builds * wip * Fix typo
73 lines
3.1 KiB
XML
73 lines
3.1 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
This is the master msbuild project file for all csharp components.
|
|
This is created so that the NuGet dependencies are restored before the projects are built during a CI build.
|
|
CMake creates a target to this project
|
|
-->
|
|
|
|
<Project DefaultTargets="Build">
|
|
|
|
<PropertyGroup>
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
<OutputPath>bin\$(Platform)\$(Configuration)\</OutputPath>
|
|
<DotNetExe Condition= " '$(DotNetExe)' == '' ">dotnet</DotNetExe>
|
|
</PropertyGroup>
|
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
|
|
|
<Target Name="RestoreProjects" BeforeTargets="Build">
|
|
<Message Importance="High" Text="Restoring NuGet packages for CSharp projects..." />
|
|
<MSBuild Projects="src\Microsoft.ML.OnnxRuntime\Microsoft.ML.OnnxRuntime.csproj"
|
|
Targets="Restore"
|
|
Properties="Platform=AnyCPU"
|
|
/>
|
|
<MSBuild Projects="sample\Microsoft.ML.OnnxRuntime.InferenceSample\Microsoft.ML.OnnxRuntime.InferenceSample.csproj"
|
|
Targets="Restore"
|
|
Properties="Platform=AnyCPU"
|
|
/>
|
|
<MSBuild Projects="test\Microsoft.ML.OnnxRuntime.Tests\Microsoft.ML.OnnxRuntime.Tests.csproj"
|
|
Targets="Restore"
|
|
Properties="ProtocDirectory=$(ProtocDirectory)"
|
|
/>
|
|
<MSBuild Projects="tools\Microsoft.ML.OnnxRuntime.PerfTool\Microsoft.ML.OnnxRuntime.PerfTool.csproj"
|
|
Targets="Restore"
|
|
Properties="Platform=AnyCPU"
|
|
/>
|
|
</Target>
|
|
|
|
<Target Name="Build">
|
|
<Message Importance="High" Text="Building CSharp projects..." />
|
|
|
|
<MSBuild Projects="src\Microsoft.ML.OnnxRuntime\Microsoft.ML.OnnxRuntime.csproj"
|
|
Targets="ObtainPackageVersion;Build"
|
|
Properties="Platform=AnyCPU"/>
|
|
<MSBuild Projects="sample\Microsoft.ML.OnnxRuntime.InferenceSample\Microsoft.ML.OnnxRuntime.InferenceSample.csproj"
|
|
Targets="Build"
|
|
Properties="Platform=AnyCPU"
|
|
/>
|
|
<MSBuild Projects="test\Microsoft.ML.OnnxRuntime.Tests\Microsoft.ML.OnnxRuntime.Tests.csproj"
|
|
Targets="Build"
|
|
/>
|
|
<MSBuild Projects="tools\Microsoft.ML.OnnxRuntime.PerfTool\Microsoft.ML.OnnxRuntime.PerfTool.csproj"
|
|
Targets="Build"
|
|
Properties="Platform=AnyCPU"
|
|
/>
|
|
</Target>
|
|
|
|
<Target Name="RunTest">
|
|
<Message Importance="High" Text="Running CSharp tests..." />
|
|
<Exec Command="$(DotNetExe) test test\Microsoft.ML.OnnxRuntime.Tests\Microsoft.ML.OnnxRuntime.Tests.csproj -c $(Configuration) --no-build --blame -v n" ConsoleToMSBuild="true">
|
|
<Output TaskParameter="ConsoleOutput" PropertyName="OutputOfExec" />
|
|
</Exec>
|
|
</Target>
|
|
|
|
<Target Name="CreatePackage">
|
|
<Message Importance="High" Text="Bundling NuGet package ..." />
|
|
<MSBuild Projects="src\Microsoft.ML.OnnxRuntime\Microsoft.ML.OnnxRuntime.csproj"
|
|
Targets="ObtainPackageVersion;Pack"
|
|
Properties="NoBuild=true;Platform=AnyCPU"
|
|
/>
|
|
</Target>
|
|
|
|
|
|
</Project>
|