Repository navigation
Expand file tree
/
Copy pathDirectory.Build.props
More file actions
86 lines (67 loc) · 5.9 KB
/
Copy pathDirectory.Build.props
File metadata and controls
86 lines (67 loc) · 5.9 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
<?xml version="1.0" encoding="utf-8"?>
<Project>
<!-- This import will noop when customer code is built. This import is here to help building the bits in the react-native-windows repository. -->
<Import Condition="Exists($([MSBuild]::GetPathOfFileAbove('Directory.Build.props', '$(MSBuildThisFileDirectory)../')))" Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.props', '$(MSBuildThisFileDirectory)../'))" />
<PropertyGroup>
<SolutionDir Condition="'$(SolutionDir)' == '' OR '$(SolutionDir)' == '*Undefined*'">$(MSBuildThisFileDirectory)</SolutionDir>
<!-- This property can be used to affect project builds in-repo (as opposed to by customers) -->
<BuildingInRnwRepo Condition="'$(BuildingInRnwRepo)' == '' AND Exists('$(MSBuildThisFileDirectory)\src-win')">true</BuildingInRnwRepo>
<!-- This property sets the CscTask to print the full path of the csharp file on errors and warnings rather than just the filename. -->
<GenerateFullPaths>true</GenerateFullPaths>
<!--
SourceLink is disabled by default since customer projects are still building our projects and therefore we don't want to force customers to use this.
In-repo builds (BuildingInRnwRepo=true) turn it back on below.
-->
<EnableSourceLink Condition="'$(EnableSourceLink)' == '' AND '$(BuildingInRnwRepo)' == 'true'">true</EnableSourceLink>
<EnableSourceLink Condition="'$(EnableSourceLink)' == ''">false</EnableSourceLink>
<!-- Symbol Publishing Compliance (Work Item 59264834) - Generate PDB files for Release builds -->
<DebugSymbols Condition="'$(Configuration)' == 'Release'">true</DebugSymbols>
<DebugType Condition="'$(Configuration)' == 'Release'">pdbonly</DebugType>
<IncludeSymbols Condition="'$(Configuration)' == 'Release'">true</IncludeSymbols>
<IncludeSource Condition="'$(Configuration)' == 'Release'">false</IncludeSource>
<!-- Commit hash for https://github.com/microsoft/node-api-jsi code. -->
<NodeApiJsiCommitHash>9f2fdfa2a923784a73cc97da9b369edaf4c6c243</NodeApiJsiCommitHash>
</PropertyGroup>
<!--
IMPORTANT: Traversals left in a directory will break some tools like midl, but we also cannot call
[MSBuild]::NormalizeDirectory on relative paths since cwd is not always correct. This logic should prefer to operate
on full paths and avoid extra normalization.
-->
<PropertyGroup Label="NodeNativeDeps" Condition="'$(IgnoreNodeNativeDeps)' != 'true'">
<ReactNativeWindowsDir Condition="'$(ReactNativeWindowsDir)' == ''">$(MSBuildThisFileDirectory)</ReactNativeWindowsDir>
<ReactNativeDir Condition="'$(ReactNativeDir)' == ''">$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'node_modules\react-native\package.json'))\node_modules\react-native\</ReactNativeDir>
<YogaDir Condition="'$(YogaDir)' == ''">$(ReactNativeDir)ReactCommon\yoga</YogaDir>
<ExternalDir Condition="'$(ExternalDir)' == ''">$(ReactNativeWindowsDir)external\</ExternalDir>
<NodeApiJsiDir Condition="'$(NodeApiJsiDir)' == '' AND Exists('$([MSBuild]::NormalizeDirectory($(ReactNativeDir)..\..\node_modules))')">$(ReactNativeDir)..\..\node_modules\.node-api-jsi\node-api-jsi-$(NodeApiJsiCommitHash)</NodeApiJsiDir>
<NodeApiJsiDir>$([MSBuild]::NormalizeDirectory($(NodeApiJsiDir)))</NodeApiJsiDir>
</PropertyGroup>
<PropertyGroup Label="Configuration">
<ProjectName Condition="'$(ProjectName)'==''">$(MSBuildProjectName)</ProjectName>
<RootIntDir Condition="'$(RootIntDir)' == ''">$(ReactNativeWindowsDir)build</RootIntDir>
<RootOutDir Condition="'$(RootOutDir)' == ''">$(ReactNativeWindowsDir)target</RootOutDir>
<!-- Visual Studio forces using 'Win32' for the 'x86' platform. -->
<BaseIntDir Condition="'$(BaseIntDir)' == '' AND '$(Platform)' == 'Win32'">$(RootIntDir)\x86\$(Configuration)</BaseIntDir>
<BaseIntDir Condition="'$(BaseIntDir)' == '' AND '$(Platform)' != 'Win32'">$(RootIntDir)\$(Platform)\$(Configuration)</BaseIntDir>
<BaseOutDir Condition="'$(BaseOutDir)' == '' AND '$(Platform)' == 'Win32'">$(RootOutDir)\x86\$(Configuration)</BaseOutDir>
<BaseOutDir Condition="'$(BaseOutDir)' == '' AND '$(Platform)' != 'Win32'">$(RootOutDir)\$(Platform)\$(Configuration)</BaseOutDir>
<IntDir Condition="'$(ProjectName)' != ''">$(BaseIntDir)\$(ProjectName)\</IntDir>
<IntDir Condition="'$(ProjectName)' == ''">$(BaseIntDir)\$(MSBuildProjectName)\</IntDir>
<OutDir Condition="'$(ProjectName)' != ''">$(BaseOutDir)\$(ProjectName)\</OutDir>
<OutDir Condition="'$(ProjectName)' == ''">$(BaseOutDir)\$(MSBuildProjectName)\</OutDir>
<PublishDir>$(OutDir)\Publish\</PublishDir>
<GeneratedFilesDir>$(IntDir)Generated Files\</GeneratedFilesDir>
<IntermediateOutputPath Condition="'$(MSBuildProjectExtension)' == '.csproj'">$(IntDir)</IntermediateOutputPath>
<OutputPath Condition="'$(MSBuildProjectExtension)' == '.csproj'">$(OutDir)</OutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(BuildingInRnwRepo)' != 'true'">
<!-- Consumers of RNW outside of the repo don't need lock files unless they ask for it -->
<RestoreLockedMode Condition="'$(RestoreLockedMode)' == ''">false</RestoreLockedMode>
<RestorePackagesWithLockFile Condition="'$(RestorePackagesWithLockFile)' == ''">false</RestorePackagesWithLockFile>
<RestoreForceEvaluate Condition="'$(RestoreForceEvaluate)' == ''">false</RestoreForceEvaluate>
</PropertyGroup>
<PropertyGroup Label="NuGet" Condition="'$(MSBuildProjectExtension)' == '.vcxproj'">
<!-- See https://docs.microsoft.com/en-us/nuget/reference/msbuild-targets#restore-target -->
<!-- RestoreUseStaticGraphEvaluation broke in VS 17.6, see https://github.com/microsoft/react-native-windows/issues/11670 -->
<RestoreUseStaticGraphEvaluation Condition="'$(BuildingInsideVisualStudio)' == 'true' AND $([MSBuild]::VersionLessThan('$(MSBuildVersion)', '17.6')) AND '$(DisableRestoreUseStaticGraphEvaluation)' != 'true'">true</RestoreUseStaticGraphEvaluation>
</PropertyGroup>
</Project>