[msbuild] Add CoreML models to our items included by default. (#10038)
This commit is contained in:
Родитель
354beec69c
Коммит
e7dd367125
|
@ -38,6 +38,11 @@ default (as `ImageAsset` items).
|
|||
All \*.png files inside \*.atlas directories in the project directory or any
|
||||
subdirectory are included by default (as `AtlasTexture` items).
|
||||
|
||||
## Core ML Models
|
||||
|
||||
All \*.mlmodel files anywhere in the project directory or any subdirectory are
|
||||
included by default (as `CoreMLModel` items).
|
||||
|
||||
## Binding projects
|
||||
|
||||
Default compilation includes is turned off for binding projects, because
|
||||
|
|
|
@ -55,4 +55,12 @@
|
|||
<IsDefaultItem>true</IsDefaultItem>
|
||||
</AtlasTexture>
|
||||
</ItemGroup>
|
||||
|
||||
<!-- Default CoreMLModel inclusion -->
|
||||
<ItemGroup Condition="'$(TargetPlatformIdentifier)' == '@PLATFORM@' And '$(_EnableDefaultXamarinItems)' == 'true' ">
|
||||
<CoreMLModel Include="**\*.mlmodel">
|
||||
<Link>$([MSBuild]::MakeRelative ('$(MSBuildProjectDirectory)', '%(Identity)'))</Link>
|
||||
<IsDefaultItem>true</IsDefaultItem>
|
||||
</CoreMLModel>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
@ -145,6 +145,7 @@
|
|||
<CreateAppBundleDependsOn>
|
||||
_DetectAppManifest;
|
||||
_CopyResourcesToBundle;
|
||||
_CompileCoreMLModels;
|
||||
_CompileEntitlements;
|
||||
_CompileAppManifest;
|
||||
_ComputeLinkerArguments;
|
||||
|
|
|
@ -118,8 +118,6 @@ namespace Xamarin.Tests {
|
|||
return false; // TODO
|
||||
} else if (components.Any (v => v.EndsWith (".appex", StringComparison.Ordinal))) {
|
||||
return false; // TODO
|
||||
} else if (components.Any (v => v.EndsWith (".mlmodelc", StringComparison.Ordinal))) {
|
||||
return false; // TODO
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
Загрузка…
Ссылка в новой задаче