-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathDirectory.Build.targets
36 lines (31 loc) · 2.23 KB
/
Directory.Build.targets
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
<Project>
<!--
We need to use conditional compilation for some platform-specific code in certain cases.
The macros declared here represent the platform of the build machine that is compiling the code.
You are wrong if you use these macros in code that compiles into a multi-platform binary.
(If we ship one binary for all 3 platforms, there will only be one build machine platform and it won't match the 2 others.)
-->
<PropertyGroup Condition=" $(MSBuildProjectExtension) == '.csproj' ">
<IsWindowsBuild Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Windows)))' == 'true'">true</IsWindowsBuild>
<IsOSXBuild Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::OSX)))' == 'true'">true</IsOSXBuild>
<IsLinuxBuild Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Linux)))' == 'true'">true</IsLinuxBuild>
<DefineConstants Condition=" $(IsLinuxBuild) == 'true' ">$(DefineConstants);LINUX_BUILD</DefineConstants>
<DefineConstants Condition=" $(IsOSXBuild) == 'true' ">$(DefineConstants);OSX_BUILD</DefineConstants>
<DefineConstants Condition=" $(IsWindowsBuild) == 'true' ">$(DefineConstants);WINDOWS_BUILD</DefineConstants>
</PropertyGroup>
<!-- Nuget Publishing related properties that are common to all packages -->
<PropertyGroup Condition="'$(EnableNuget)' == 'true'" >
<PackageOutputPath>$(MSBuildThisFileDirectory)\..\out</PackageOutputPath>
<Authors>Microsoft</Authors>
<Owners><!-- Don't set this field --></Owners>
<PackageLicenseUrl><!-- Don't set this field (deprecated) --></PackageLicenseUrl>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
<Copyright>© Microsoft Corporation. All rights reserved.</Copyright>
<PackageTags>MicrosoftGraph;Bicep;Types</PackageTags>
<!-- generate symbols for upload to the nuget feed -->
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<!-- sourcelink configuration -->
<RepositoryType>git</RepositoryType>
</PropertyGroup>
</Project>