-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathFFmpegKit.Android.Example.csproj
More file actions
117 lines (104 loc) · 6.39 KB
/
Copy pathFFmpegKit.Android.Example.csproj
File metadata and controls
117 lines (104 loc) · 6.39 KB
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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<!--
One target framework per SDK band, selected by SampleSdkBand. The CI sample matrix builds
the net8 and net10 extremes, each on its own SDK band (the API level owns the runtime packs:
34/35/36 for net8/net9/net10), so a single band's workload is enough per leg and restore
never walks a target framework that band cannot build. Unset locally it is the net9 dev band,
so `dotnet build` just works without installing the other two.
-->
<SampleSdkBand Condition=" '$(SampleSdkBand)' == '' ">net9</SampleSdkBand>
<TargetFrameworks Condition=" '$(SampleSdkBand)' == 'net8' ">net8.0-android34.0</TargetFrameworks>
<TargetFrameworks Condition=" '$(SampleSdkBand)' == 'net9' ">net9.0-android35.0</TargetFrameworks>
<TargetFrameworks Condition=" '$(SampleSdkBand)' == 'net10' ">net10.0-android36.0</TargetFrameworks>
<OutputType>Exe</OutputType>
<RootNamespace>FFmpegKit.Android.Example</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
<CheckEolTargetFramework>false</CheckEolTargetFramework>
<CheckEolWorkloads>false</CheckEolWorkloads>
<ApplicationTitle>FFmpegKit.Android.Example</ApplicationTitle>
<ApplicationId>com.sbokatuk.ffmpegkit.example</ApplicationId>
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>
<!--
FFmpegKit's native .aar requires minSdkVersion 24, but this sample previews the result with
CommunityToolkit's MediaElement, which requires 26. The sample therefore takes the higher
floor; an app that does not use MediaElement can still target 24.
-->
<SupportedOSPlatformVersion>26.0</SupportedOSPlatformVersion>
<!--
The other half of the same story. The native .aar carries arm64-v8a and x86_64 only, but the
.NET Android SDK's default runtime identifier list still includes the 32-bit android-arm and
android-x86 - so the default build packages ABIs with no libffmpegkit.so in them, and a
32-bit device installs the app and crashes on first use. FFMPEGKIT002, raised by
src/FFmpegKit.Android/FFmpegKit.Net.Android.targets, says exactly this at build time.
Set rather than added to NoWarn: this sample is what a consumer copies, and 64-bit-only is
what a consuming app should ship anyway (Play Store has required a 64-bit slice since 2019).
-->
<RuntimeIdentifiers>android-arm64;android-x64</RuntimeIdentifiers>
<!--
Which build of the FFmpegKit package to demo. Defaults to FFmpegVersion from
Directory.Build.props, so it tracks the repository automatically; pass
-p:FFmpegKitVersion=8.1.2.4-beta.4 to try a specific build.
FFmpegVersion, not FFmpegKitNativeVersion: package versions are based on the FFmpeg the
build contains (8.1.2), while FFmpegKitNativeVersion is the fork's own release number
(8.1.7). Asking for the latter resolves a published 8.1.7.x from nuget.org instead of the
package you just built, which fails in whichever confusing way the two happen to differ.
-->
<FFmpegKitVersion Condition=" '$(FFmpegKitVersion)' == '' ">$(FFmpegVersion)</FFmpegKitVersion>
</PropertyGroup>
<ItemGroup>
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />
<MauiImage Include="Resources\Images\*" />
<MauiImage Update="Resources\Images\dotnet_bot.png" Resize="True" BaseSize="300,185" />
<MauiFont Include="Resources\Fonts\*" />
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>
<!--
$(MauiVersion) is whatever Controls the installed workload bundles, which on the net10 band is
older than the 10.0.60 CommunityToolkit.Maui.MediaElement 10.0.0 declares - restore then fails
NU1605. Controls is an ordinary NuGet package independent of the workload pack, so the net10
band pins the toolkit's floor explicitly; net8 and net9 keep the workload's own.
-->
<ItemGroup Condition="!$(TargetFramework.StartsWith('net10.0'))">
<PackageReference Include="Microsoft.Maui.Controls" Version="$(MauiVersion)" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net10.0'))">
<PackageReference Include="Microsoft.Maui.Controls" Version="10.0.60" />
</ItemGroup>
<!--
CommunityToolkit.Maui and its MediaElement (used for the before/after video preview) have no
single version that spans net8 and net10 - each band dropped support as the next arrived - so
the versions are selected per target framework. Microsoft.Extensions.Logging.Debug matches the
band too, to avoid a downgrade against the MAUI metapackage's transitive Logging on net10.
-->
<ItemGroup Condition="$(TargetFramework.StartsWith('net8.0'))">
<PackageReference Include="CommunityToolkit.Maui" Version="9.1.1" />
<PackageReference Include="CommunityToolkit.Maui.MediaElement" Version="4.1.2" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="8.0.1" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net9.0'))">
<PackageReference Include="CommunityToolkit.Maui" Version="11.0.0" />
<PackageReference Include="CommunityToolkit.Maui.MediaElement" Version="6.0.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.0" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net10.0'))">
<PackageReference Include="CommunityToolkit.Maui" Version="15.0.0" />
<PackageReference Include="CommunityToolkit.Maui.MediaElement" Version="10.0.0" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="10.0.0" />
</ItemGroup>
<ItemGroup>
<!--
The locally built package, resolved from ./artifacts via the local-artifacts source in the
repository's NuGet.config. Run src/FFmpegKit.Android/BuildNugets.sh first - this deliberately
does not come from nuget.org, so the example exercises what you just built.
Full is the LGPL variant; the -gpl ones would make this sample GPL-3.0.
-->
<PackageReference Include="FFmpegKit.Net.Full.Android" Version="$(FFmpegKitVersion)" />
</ItemGroup>
</Project>