Skip to content

Commit

Permalink
package native quic library (#54992)
Browse files Browse the repository at this point in the history
* package native quic library

* Update System.Net.Quic.csproj

* Fix binplacing

* exclude msquic.dll from trimming

* Update src/libraries/System.Net.Quic/src/System.Net.Quic.csproj

Co-authored-by: Viktor Hofer <viktor.hofer@microsoft.com>

* remove local windows override

Co-authored-by: Viktor Hofer <viktor.hofer@microsoft.com>
  • Loading branch information
wfurt and ViktorHofer authored Jul 1, 2021
1 parent 9c060fe commit d0a0919
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 11 deletions.
26 changes: 16 additions & 10 deletions src/libraries/System.Net.Quic/src/System.Net.Quic.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,14 @@
<Compile Include="System\Net\Quic\Implementations\MsQuic\Interop\MsQuicStatusCodes.OSX.cs" />
</ItemGroup>
<!-- Project references -->
<ItemGroup Condition="'$(TargetsWindows)' == 'true'">
<PackageReference Include="System.Net.MsQuic.Transport" PrivateAssets="all" Version="$(SystemNetMsQuicTransportVersion)" />

<ItemGroup>
<PackageReference Include="System.Net.MsQuic.Transport"
Version="$(SystemNetMsQuicTransportVersion)"
PrivateAssets="all"
GeneratePathProperty="true" />
</ItemGroup>

<ItemGroup>
<Reference Include="System.Collections" />
<Reference Include="System.Collections.Concurrent" />
Expand All @@ -76,16 +81,17 @@
<Reference Include="System.Threading" />
<Reference Include="System.Threading.Channels" />
</ItemGroup>

<!-- Support for deploying msquic -->
<ItemGroup Condition="'$(TargetsWindows)' == 'true' and
('$(TargetArchitecture)' == 'x64' or '$(TargetArchitecture)' == 'x86')">
<BinPlaceDir Include="$(MicrosoftNetCoreAppRuntimePackNativeDir)" ItemName="NativeBinPlaceItem" />
<BinPlaceDir Include="$(NetCoreAppCurrentTestHostSharedFrameworkPath)" ItemName="NativeBinPlaceItem" />
<BinPlaceDir Include="$(NetCoreAppCurrentRuntimePath)" ItemName="NativeBinPlaceItem" />
<NativeBinPlaceItem Include="$(PkgSystem_Net_MsQuic_Transport)\runtimes\win10-$(TargetArchitecture)\native\*" />
</ItemGroup>

<ItemGroup>
<Content Include="msquic.dll" Condition="Exists('msquic.dll')">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
<Content Include="msquic.pdb" Condition="Exists('msquic.pdb')">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
<Content Include="libmsquic.dylib" Condition="Exists('libmsquic.dylib')">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
Expand Down
2 changes: 1 addition & 1 deletion src/libraries/illink-oob.targets
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<_OOBsToIgnore Include="System.Configuration.ConfigurationManager" />
<_OOBsToIgnore Include="System.Speech" />

<_NetCoreAppRuntimeAssemblies Include="$(NetCoreAppCurrentRuntimePath)*.dll" Exclude="$(NetCoreAppCurrentRuntimePath)*.Generator.dll;$(NetCoreAppCurrentRuntimePath)*.Native.dll" />
<_NetCoreAppRuntimeAssemblies Include="$(NetCoreAppCurrentRuntimePath)*.dll" Exclude="$(NetCoreAppCurrentRuntimePath)*.Generator.dll;$(NetCoreAppCurrentRuntimePath)*.Native.dll;$(NetCoreAppCurrentRuntimePath)*msquic.dll" />
<_RuntimePackTrimmedAssemblies Include="$(MicrosoftNetCoreAppRuntimePackRidLibTfmDir)*.dll" />

<!-- Move previous items to FileName so that we can subtract them -->
Expand Down

0 comments on commit d0a0919

Please sign in to comment.