summaryrefslogtreecommitdiffstats
path: root/PCbuild/pyproject.props
diff options
context:
space:
mode:
Diffstat (limited to 'PCbuild/pyproject.props')
-rw-r--r--PCbuild/pyproject.props18
1 files changed, 17 insertions, 1 deletions
diff --git a/PCbuild/pyproject.props b/PCbuild/pyproject.props
index 6ab9b65..aed8f34 100644
--- a/PCbuild/pyproject.props
+++ b/PCbuild/pyproject.props
@@ -147,8 +147,24 @@ foreach (System.Diagnostics.Process p in System.Diagnostics.Process.GetProcesses
Targets="CleanAll" />
</Target>
+ <Target Name="CopyPGCFiles" BeforeTargets="PrepareForBuild" Condition="$(Configuration) == 'PGUpdate'">
+ <ItemGroup>
+ <_PGCFiles Include="$(OutDir)instrumented\$(TargetName)!*.pgc" />
+ <_PGDFile Include="$(OutDir)instrumented\$(TargetName).pgd" />
+ <_CopyFiles Include="@(_PGCFiles);@(_PGDFile)" Condition="Exists(%(FullPath))" />
+ </ItemGroup>
+ <Delete Files="@(_CopyFiles->'$(OutDir)%(Filename)%(Extension)')" />
+ <Error Text="PGO run did not succeed (no $(TargetName)!*.pgc files) and there is no data to merge"
+ Condition="$(RequirePGCFiles) == 'true' and @(_PGCFiles) == ''" />
+ <Copy SourceFiles="@(_CopyFiles)"
+ DestinationFolder="$(OutDir)"
+ UseHardLinksIfPossible="true"
+ OverwriteReadOnlyFiles="true" />
+ </Target>
+
<PropertyGroup>
- <SdkBinPath Condition="'$(SdkBinPath)' == '' or !Exists($(SdkBinPath))">$(registry:HKEY_LOCAL_MACHINE\Software\Microsoft\Windows Kits\Installed Roots@KitsRoot10)\bin\x86</SdkBinPath>
+ <SdkBinPath Condition="'$(SdkBinPath)' == '' or !Exists($(SdkBinPath))">$(registry:HKEY_LOCAL_MACHINE\Software\Microsoft\Windows Kits\Installed Roots@KitsRoot10)\bin\$(DefaultWindowsSDKVersion)\x86</SdkBinPath>
+ <SdkBinPath Condition="!Exists($(SdkBinPath))">$(registry:HKEY_LOCAL_MACHINE\Software\Microsoft\Windows Kits\Installed Roots@KitsRoot10)\bin\x86</SdkBinPath>
<SdkBinPath Condition="!Exists($(SdkBinPath))">$(registry:HKEY_LOCAL_MACHINE\Software\Microsoft\Windows Kits\Installed Roots@KitsRoot81)\bin\x86</SdkBinPath>
<SdkBinPath Condition="!Exists($(SdkBinPath))">$(registry:HKEY_LOCAL_MACHINE\Software\Microsoft\Windows Kits\Installed Roots@KitsRoot)\bin\x86</SdkBinPath>
<SdkBinPath Condition="!Exists($(SdkBinPath))">$(registry:HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.1A@InstallationFolder)\Bin\</SdkBinPath>