-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathFFmpegKit.Net.csproj
More file actions
107 lines (90 loc) · 6.18 KB
/
Copy pathFFmpegKit.Net.csproj
File metadata and controls
107 lines (90 loc) · 6.18 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
<Project Sdk="Microsoft.NET.Sdk">
<!--
The cross-platform API: one FFmpegKit.Execute/ExecuteAsync surface shared by Android, iOS and macOS,
instead of every consumer writing the adapter between Ffmpegkit.Droid and Ffmpegkit.Ios by
hand. See FFmpegKit.cs, FFprobeKit.cs and FFmpegKitConfig.cs for what it covers, and the
Platforms/Android and Platforms/iOS folders for the two implementations.
The Android, iOS and macOS bindings themselves are NOT built in this repository - they are
FFmpegKit.Net.<Variant>.Android / .iOS, published to nuget.org from sbokatuk/FFmpegKit.Android
and sbokatuk/FFmpegKit.iOS respectively. This project only depends on them, pinned to an exact
version in Directory.Build.props (FFmpegKitAndroidPackageVersion / FFmpegKitIosPackageVersion).
Deliberately no MAUI dependency, so plain .NET for Android and .NET for iOS apps can use this.
The MAUI-specific glue lives in FFmpegKit.Net.Maui.
Both platforms' target frameworks are listed together, which is why this can only be packed on
macOS - restoring the iOS leg needs the iOS workload. See build/BuildNugets.sh.
Parameterized by FFmpegKitBuildType like the external bindings: Ffmpegkit.Ios.FFmpegKit and
Ffmpegkit.Droid.FFmpegKit are identical across variants, but each variant is a distinct
assembly (FFmpegKit.Net.Video.iOS vs FFmpegKit.Net.Full.iOS, ...), so a cross-platform
assembly built against one is bound to that variant's assembly identity. CI builds this once
per variant.
-->
<PropertyGroup>
<TargetFrameworks>$(FFmpegKitAndroidTargetFrameworks);$(FFmpegKitIosTargetFrameworks);$(FFmpegKitMacTargetFrameworks)</TargetFrameworks>
<AssemblyName>FFmpegKit.Net.$(FFmpegKitBuildType)</AssemblyName>
<RootNamespace>Ffmpegkit.Net</RootNamespace>
<LangVersion>latest</LangVersion>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<!-- CS1591: a handful of internal conversion helpers are exposed as internal, not private, and warn without a doc comment. -->
<NoWarn>$(NoWarn);CS1591</NoWarn>
</PropertyGroup>
<!--
Platform code is picked per target framework rather than by the default glob, which would try
to compile the Android half into the iOS assembly (and vice versa).
-->
<ItemGroup>
<Compile Remove="Platforms/**/*.cs" />
</ItemGroup>
<ItemGroup Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">
<Compile Include="Platforms/Android/**/*.cs" />
<PackageReference Include="FFmpegKit.Net.$(FFmpegKitBuildType).Android" Version="[$(FFmpegKitAndroidPackageVersion)]" />
</ItemGroup>
<ItemGroup Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">
<Compile Include="Platforms/iOS/**/*.cs" />
<PackageReference Include="FFmpegKit.Net.$(FFmpegKitBuildType).iOS" Version="[$(FFmpegKitIosPackageVersion)]" />
</ItemGroup>
<ItemGroup Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'macos'">
<Compile Include="Platforms/MacOS/**/*.cs" />
<PackageReference Include="FFmpegKit.Net.$(FFmpegKitBuildType).Mac" Version="[$(FFmpegKitMacPackageVersion)]" />
</ItemGroup>
<!--
Licensing follows whichever external binding this variant pulls in - both carry the same
native license for a given variant (GPL-3.0 for the -Gpl build types, LGPL-3.0 otherwise), and
this package embeds no native payload of its own.
-->
<PropertyGroup>
<FFmpegKitIsGpl>false</FFmpegKitIsGpl>
<FFmpegKitIsGpl Condition="$(FFmpegKitBuildType.EndsWith('Gpl'))">true</FFmpegKitIsGpl>
<FFmpegKitNativeLicense Condition=" '$(FFmpegKitIsGpl)' == 'true' ">GPL-3.0-only</FFmpegKitNativeLicense>
<FFmpegKitNativeLicense Condition=" '$(FFmpegKitIsGpl)' != 'true' ">LGPL-3.0-only</FFmpegKitNativeLicense>
<FFmpegKitNativeLicenseFile Condition=" '$(FFmpegKitIsGpl)' == 'true' ">../../licenses/GPL-3.0.txt</FFmpegKitNativeLicenseFile>
<FFmpegKitNativeLicenseFile Condition=" '$(FFmpegKitIsGpl)' != 'true' ">../../licenses/LGPL-3.0.txt</FFmpegKitNativeLicenseFile>
<FFmpegKitVariantName>$(FFmpegKitBuildType.ToLowerInvariant().Replace('gpl', '-gpl'))</FFmpegKitVariantName>
</PropertyGroup>
<PropertyGroup>
<IsPackable>true</IsPackable>
<PackageId>FFmpegKit.Net.$(FFmpegKitBuildType)</PackageId>
<Title>Cross-platform .NET client for the native FFmpegKit $(FFmpegKitBuildType) SDK.</Title>
<Description>One API over the FFmpegKit bindings for Android, iOS and macOS: run FFmpeg/FFprobe commands with awaitable calls, typed media information, progress reporting, failure output on the result and an injectable IFFmpegKit, instead of writing a per-platform adapter over Ffmpegkit.Droid, Ffmpegkit.Ios and Ffmpegkit.Mac by hand. Pulls in the platform binding that matches whichever target framework you build. For .NET MAUI apps, FFmpegKit.Net.Maui adds the app-builder wiring.</Description>
<PackageLicenseExpression>MIT AND $(FFmpegKitNativeLicense)</PackageLicenseExpression>
<PackageTags>ffmpeg;ffmpegkit;$(FFmpegKitVariantName);video;audio;transcode;SDK;MAUI;Android;iOS;Binding</PackageTags>
<PackageIcon>icon.png</PackageIcon>
<PackageReadmeFile>README.md</PackageReadmeFile>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
</PropertyGroup>
<ItemGroup>
<None Include="../../build/icon.png" Pack="true" PackagePath="/" Visible="false" />
<None Include="../../README.md" Pack="true" PackagePath="/" Visible="false" />
<!--
Ship both licence texts the package is covered by, matching the external bindings. This
package carries no native payload itself, but it declares MIT AND LGPL/GPL and hard-pins the
binding that does, so a consumer should find the terms here too. Packed into a folder so
each file keeps its own name - naming the target explicitly would make NuGet treat the
extensionless LICENSE as a directory.
-->
<None Include="../../LICENSE" Pack="true" PackagePath="licenses/" Visible="false" />
<None Include="$(FFmpegKitNativeLicenseFile)" Pack="true" PackagePath="licenses/" Visible="false" />
</ItemGroup>
</Project>