machinelearning/Directory.Build.props

74 строки
3.5 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<Project>
<Import Project="Sdk.props" Sdk="Microsoft.DotNet.Arcade.Sdk" />
<Import Project="eng/BranchInfo.props" />
<Import Project="eng/ExternalBenchmarkDataFiles.props" />
<Import Project="eng/TensorflowMetaFiles.props" />
<PropertyGroup>
<Copyright>$(CopyrightNetFoundation)</Copyright>
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
<DebugType>portable</DebugType>
<DebugSymbols>true</DebugSymbols>
<LangVersion>latest</LangVersion>
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
</PropertyGroup>
<PropertyGroup>
<Configuration Condition="'$(Configuration)'==''">Debug</Configuration>
<Platform Condition="'$(Platform)'==''">AnyCPU</Platform>
<TargetArchitecture Condition="'$(TargetArchitecture)' == ''">$([System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture)</TargetArchitecture>
<TargetArchitecture>$(TargetArchitecture.ToLower())</TargetArchitecture>
<PlatformConfig>$(Platform).$(Configuration)</PlatformConfig>
<StrongNameKeyId>Open</StrongNameKeyId>
<!-- temporarily suppress NETSDK 1206 until we can update OnnxRuntime to fix https://github.com/dotnet/machinelearning/issues/6916 -->
<NoWarn>$(NoWarn);NETSDK1206</NoWarn>
</PropertyGroup>
<PropertyGroup>
<!-- Need to save space when running CI builds. -->
<CreateHardLinksForPublishFilesIfPossible Condition="$(CreateHardLinksForPublishFilesIfPossible) == ''">True</CreateHardLinksForPublishFilesIfPossible>
<CreateHardLinksForCopyFilesToOutputDirectoryIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)' == ''">false</CreateHardLinksForCopyFilesToOutputDirectoryIfPossible>
</PropertyGroup>
<PropertyGroup>
<ModelDownloadPath>$(ArtifactsDir)models/</ModelDownloadPath>
<PackageAssetsPath>$(ArtifactsDir)pkgassets/</PackageAssetsPath>
<PkgDir>$(RepoRoot)pkg/</PkgDir>
<Authors>Microsoft</Authors>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<PackageProjectUrl>https://dot.net/ml</PackageProjectUrl>
<PackageIcon>mlnetlogo.png</PackageIcon>
<PackageReleaseNotes>https://aka.ms/mlnetreleasenotes</PackageReleaseNotes>
<!-- space separated -->
<PackageTags>ML.NET ML Machine Learning</PackageTags>
</PropertyGroup>
<!-- Need to explicitly set these properties for the -net6_0 or -netfx configurations becuase they are typically based off 'Debug' or 'Release' configs -->
<!-- Taken from https://github.com/dotnet/sdk/blob/073c98b92c81066c6c2e17c3674adbb6e833409a/src/Tasks/Microsoft.NET.Build.Tasks/targets/Microsoft.NET.Sdk.props#L41-L47 -->
<PropertyGroup Condition="$(Configuration.StartsWith('Debug'))">
<DebugSymbols>true</DebugSymbols>
<DefineConstants>$(DefineContants);DEBUG</DefineConstants>
<Optimize>false</Optimize>
</PropertyGroup>
<PropertyGroup Condition="$(Configuration.StartsWith('Release'))">
<Optimize>true</Optimize>
</PropertyGroup>
<PropertyGroup>
<!-- Optional: Publish the repository URL in the built .nupkg (in the NuSpec <Repository> element) -->
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<!-- Optional: Embed source files that are not tracked by the source control manager in the PDB -->
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<!-- Optional: Build symbol packages (.symbols.nupkg) to distribute the PDB containing Source Link -->
<IncludeSymbols>true</IncludeSymbols>
</PropertyGroup>
</Project>