forked from dotnet/maui
/
Benchmarks.Droid.csproj
55 lines (55 loc) · 2.58 KB
/
Benchmarks.Droid.csproj
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
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>$(_MauiDotNetTfm)-android</TargetFramework>
<SupportedOSPlatformVersion>21</SupportedOSPlatformVersion>
<OutputType>Exe</OutputType>
<AssemblyName>Microsoft.Maui.Benchmarks.Droid</AssemblyName>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
<ApplicationId>com.microsoft.maui.benchmarks</ApplicationId>
<ApplicationVersion>1</ApplicationVersion>
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<PublishTrimmed>false</PublishTrimmed>
<RunAOTCompilation>false</RunAOTCompilation>
<!-- Physical device is recommended -->
<RuntimeIdentifier>android-arm64</RuntimeIdentifier>
<DisableTransitiveFrameworkReferenceDownloads>False</DisableTransitiveFrameworkReferenceDownloads>
<AndroidPackageFormat>apk</AndroidPackageFormat>
</PropertyGroup>
<ItemGroup>
<Using Include="Android.Runtime" />
<Using Include="Android.Util" />
<Using Include="BenchmarkDotNet.Analysers" />
<Using Include="BenchmarkDotNet.Attributes" />
<Using Include="BenchmarkDotNet.Configs" />
<Using Include="BenchmarkDotNet.Exporters" />
<Using Include="BenchmarkDotNet.Jobs" />
<Using Include="BenchmarkDotNet.Loggers" />
<Using Include="BenchmarkDotNet.Order" />
<Using Include="BenchmarkDotNet.Running" />
<PackageReference Include="BenchmarkDotNet" Version="0.13.10" />
<PackageReference Include="Xamarin.Android.Glide" Version="4.14.2.1" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\Controls\src\Core\Controls.Core.csproj" />
<ProjectReference Include="..\..\src\Core.csproj" />
</ItemGroup>
<Target Name="Benchmark" DependsOnTargets="Install">
<Message Text="Running benchmarks. This might take a while... See 'adb logcat' for realtime progress." Importance="High" />
<!-- Clear the log -->
<Exec Command="adb shell logcat -c" WorkingDirectory="$(AndroidSdkDirectory)/platform-tools" />
<!-- Run benchmarks -->
<Exec Command="adb shell am instrument -w $(ApplicationId)/com.microsoft.maui.MainInstrumentation" WorkingDirectory="$(AndroidSdkDirectory)/platform-tools" />
<!--
Print the log filtered by MAUI and DOTNET tags
See: https://developer.android.com/studio/command-line/logcat#outputFormat
-->
<Exec
Command="adb shell logcat -d -v tag -s "DOTNET,MAUI""
IgnoreStandardErrorWarningFormat="true"
StdErrEncoding="utf-8"
StdOutEncoding="utf-8"
WorkingDirectory="$(AndroidSdkDirectory)/platform-tools"
/>
</Target>
</Project>