forked from SubnauticaNitrox/Nitrox
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDirectory.Build.props
More file actions
98 lines (90 loc) · 4.12 KB
/
Directory.Build.props
File metadata and controls
98 lines (90 loc) · 4.12 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
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="Nitrox.Shared.props" />
<!-- Framework properties -->
<PropertyGroup>
<LangVersion>14</LangVersion>
<Version>1.9.0.0</Version>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<Prefer32Bit>false</Prefer32Bit>
<DebugType>embedded</DebugType>
<Nullable>annotations</Nullable>
<ImplicitUsings>disable</ImplicitUsings>
<PathMap>$(MSBuildProjectDirectory)=$(MSBuildProjectName)</PathMap>
<EnableNETAnalyzers>true</EnableNETAnalyzers>
<AccelerateBuildsInVisualStudio>false</AccelerateBuildsInVisualStudio>
<DisableFastUpToDateCheck>true</DisableFastUpToDateCheck>
</PropertyGroup>
<!-- Nitrox specific properties -->
<PropertyGroup>
<Authors>Nitrox</Authors>
<Company>Nitrox</Company>
<NitroxProject>false</NitroxProject>
<TestLibrary>false</TestLibrary>
<NitroxLibrary>false</NitroxLibrary>
<UnityModLibrary>false</UnityModLibrary>
<GameName>Subnautica</GameName>
<GameMinimumVersion>82304</GameMinimumVersion>
</PropertyGroup>
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch($(MSBuildProjectName), '^Nitrox.*$'))">
<NitroxProject>true</NitroxProject>
</PropertyGroup>
<PropertyGroup Condition="'$(NitroxProject)' == 'true' and '$(MSBuildProjectName)' != 'Nitrox.Test'">
<NitroxLibrary>true</NitroxLibrary>
</PropertyGroup>
<PropertyGroup Condition="'$(NitroxLibrary)' == 'true' and '$(MSBuildProjectName)' != 'Nitrox.Model' and '$(MSBuildProjectName)' != 'Nitrox.Launcher'">
<UnityModLibrary>true</UnityModLibrary>
</PropertyGroup>
<PropertyGroup Condition="'$(MSBuildProjectName)' == 'Nitrox.Test'">
<TestLibrary>true</TestLibrary>
</PropertyGroup>
<PropertyGroup>
<NotTestLibrary>false</NotTestLibrary>
<NotTestLibrary Condition="'$(TestLibrary)' == 'false'">true</NotTestLibrary>
</PropertyGroup>
<!-- Shared dependencies for all Nitrox.* projects -->
<ItemGroup Condition="'$(NitroxProject)' == 'true'">
<PackageReference Include="JetBrains.Annotations">
<Aliases>JB</Aliases>
</PackageReference>
<PackageReference Include="PolySharp">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
</ItemGroup>
<Choose>
<When Condition="'$(TestLibrary)' == 'false'">
<ItemGroup>
<PackageReference Include="Nitrox.Analyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</When>
</Choose>
<!-- Include default project references to all other "Nitrox*" projects -->
<Choose>
<When Condition="'$(UnityModLibrary)' == 'true' or '$(TestLibrary)' == 'true'">
<ItemGroup>
<PackageReference Include="BepInEx.AssemblyPublicizer.MSBuild">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="Nitrox.Discovery.MSBuild">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
</ItemGroup>
</When>
</Choose>
<!-- Set internals visible for all projects for Nitrox.Test (excluding Nitrox.Test itself) -->
<Choose>
<When Condition="'$(NitroxLibrary)' == 'true'">
<ItemGroup>
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
<_Parameter1>Nitrox.Test</_Parameter1>
</AssemblyAttribute>
</ItemGroup>
</When>
</Choose>
</Project>