Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 510d09a

Browse files
authored
Merge pull request #21129 from mmitche/sign-xstat
Sign api-ms-win-core-xstate-l2-1-0.dll
2 parents 432cd0b + 557c8f0 commit 510d09a

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

src/.nuget/Microsoft.NETCore.Runtime.CoreCLR/runtime.Windows_NT.Microsoft.NETCore.Runtime.CoreCLR.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<NativeBinary Include="$(BinDir)mscorrc.debug.dll" />
2020
<NativeBinary Include="$(BinDir)mscorrc.dll" />
2121
<NativeBinary Include="$(BinDir)sos.dll" />
22-
<NativeBinary Include="$(UniversalCRTSDKDir)Redist\ucrt\DLLs\$(BuildArch)\*.dll" Condition="'$(BuildType)'=='Release' AND '$(BuildArch)' != 'arm64'" />
22+
<NativeBinary Include="$(BinDir)Redist\ucrt\DLLs\$(BuildArch)\*.dll" Condition="'$(BuildType)'=='Release' AND '$(BuildArch)' != 'arm64'" />
2323
<CrossGenBinary Include="$(BinDir)System.Private.CoreLib.dll" />
2424
<ArchitectureSpecificLibFile Include="$(BinDir)SOS.NETCore.dll" />
2525
<ArchitectureSpecificToolFile Include="$(BinDir)crossgen.exe" />

src/build.proj

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,17 @@
4343
DestinationFolder="$(BinDir)PDB" />
4444
</Target>
4545

46+
<ItemGroup>
47+
<UcrtFilesToCopy Include="$(UniversalCRTSDKDir)Redist\ucrt\DLLs\$(BuildArch)\*.dll" />
48+
</ItemGroup>
49+
<!-- Copy the UCRT files from the windows kit directory to the local directory.
50+
The api-*xstate.dll binary needs to be signed. -->
51+
<Target Name="CopyUcrtFiles" AfterTargets="Build">
52+
<Copy Condition="'$(BuildType)'=='Release' AND '$(BuildArch)' != 'arm64'"
53+
SourceFiles="@(UcrtFilesToCopy)"
54+
DestinationFolder="$(BinDir)Redist\ucrt\DLLs\$(BuildArch)" />
55+
</Target>
56+
4657
<PropertyGroup>
4758
<RunEnforcePGO Condition="$(__EnforcePgo) == '1'">true</RunEnforcePGO>
4859
<RunEnforcePGO Condition="$(__BuildArch) == 'arm' OR $(__BuildArch) == 'arm64'">false</RunEnforcePGO>

src/sign.builds

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,12 @@
1515
<WindowsNativeLocation Include="$(BinDir)*.dll" />
1616
<WindowsNativeLocation Include="$(BinDir)*.exe" />
1717
</ItemGroup>
18+
19+
<ItemGroup Condition="'$(BuildArch)' == 'x86'">
20+
<!-- Sign api-ms-win-core-xstate-l2-1-0 binary as it is only catalog signed in the current SDK. -->
21+
<WindowsNativeLocation Include="$(BinDir)Redist\ucrt\DLLs\$(BuildArch)\api-ms-win-core-xstate-l2-1-0.dll" />
22+
</ItemGroup>
23+
1824
<!-- sign the cross targeted files as well -->
1925
<ItemGroup Condition="'$(CrossTargetComponentFolder)' != ''">
2026
<WindowsNativeLocation Include="$(BinDir)$(CrossTargetComponentFolder)/*.dll" />

0 commit comments

Comments
 (0)