mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-17 01:41:17 -10:00
- Add a private static variable to HttpClient called `Func<HttpMessageHandler> GetHttpMessageHandler` that will be used to obtain the default message handler and can be set for example as follows:
```
var httpMessageHandler = typeof(HttpClient).GetField("GetHttpMessageHandler",
BindingFlags.Static |
BindingFlags.NonPublic);
httpMessageHandler.SetValue(null, (Func<HttpClientHandler>) (() => {
return new MyHttpClientHandler ();
}));
```
- If a handler is not set or returns null the default implementation HttpClientHandler will be returned.
- Add HttpClient.wasm.cs implementation to handle the default HttpClient
- Add simple test to the wasm test harness bindings-test.
- Reference https://github.com/mono/mono/issues/9941
<!--
Thank you for your Pull Request!
If you are new to contributing to Mono, please try to do your best at conforming to our coding guidelines http://www.mono-project.com/community/contributing/coding-guidelines/ but don't worry if you get something wrong. One of the project members will help you to get things landed.
Does your pull request fix any of the existing issues? Please use the following format: Fixes #issue-number
-->
249 lines
15 KiB
XML
249 lines
15 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- WARNING: this file is autogenerated, don't modify it. Edit the .sources file of the corresponding assembly instead if you want to add/remove C# source files. -->
|
|
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
<PropertyGroup>
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
<Platform Condition=" '$(Platform)' == '' ">net_4_x</Platform>
|
|
<ProjectGuid>{4DE5B183-8B61-4159-890B-F5BD501C4507}</ProjectGuid>
|
|
<OutputType>Library</OutputType>
|
|
<NoWarn>1699</NoWarn>
|
|
<LangVersion>latest</LangVersion>
|
|
<HostPlatform Condition=" '$(HostPlatform)' == '' and '$(OS)' == 'Windows_NT'">win32</HostPlatform>
|
|
<HostPlatform Condition=" '$(HostPlatform)' == '' and '$(OS)' == 'Unix' and $([System.IO.File]::Exists('/usr/lib/libc.dylib'))">darwin</HostPlatform>
|
|
<HostPlatform Condition=" '$(HostPlatform)' == '' and '$(OS)' == 'Unix'">linux</HostPlatform>
|
|
<GenerateTargetFrameworkAttribute>false</GenerateTargetFrameworkAttribute>
|
|
<NoStdLib>True</NoStdLib>
|
|
<NoConfig>True</NoConfig>
|
|
<AssemblyName>System.Net.Http</AssemblyName>
|
|
<TargetFrameworkVersion>v4.6.2</TargetFrameworkVersion>
|
|
<SignAssembly>true</SignAssembly>
|
|
<AssemblyOriginatorKeyFile>../msfinal.pub</AssemblyOriginatorKeyFile>
|
|
</PropertyGroup>
|
|
<!-- Set AddAdditionalExplicitAssemblyReferences to false, otherwise if targetting .NET4.0,
|
|
Microsoft.NETFramework.props will force a dependency on the assembly System.Core. This
|
|
is a problem to compile the Mono mscorlib.dll -->
|
|
<PropertyGroup>
|
|
<AddAdditionalExplicitAssemblyReferences>false</AddAdditionalExplicitAssemblyReferences>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'net_4_x' ">
|
|
<OutputPath>./../../class/lib/net_4_x-$(HostPlatform)</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-net_4_x-$(HostPlatform)</IntermediateOutputPath>
|
|
<DefineConstants>NET_4_0;NET_4_5;NET_4_6;MONO;WIN_PLATFORM</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'monodroid' ">
|
|
<OutputPath>./../../class/lib/monodroid</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-monodroid</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MONO;MOBILE;MOBILE_LEGACY;MOBILE_DYNAMIC;MONODROID;ANDROID;XAMARIN_MODERN</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'monotouch' ">
|
|
<OutputPath>./../../class/lib/monotouch</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-monotouch</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MOBILE;MOBILE_LEGACY;MONO;MONOTOUCH;DISABLE_REMOTING;DISABLE_COM;FEATURE_INTERCEPTABLE_THREADPOOL_CALLBACK;FULL_AOT_RUNTIME</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'monotouch_watch' ">
|
|
<OutputPath>./../../class/lib/monotouch_watch</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-monotouch_watch</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MOBILE;MOBILE_LEGACY;MONO;MONOTOUCH;DISABLE_REMOTING;DISABLE_COM;FEATURE_INTERCEPTABLE_THREADPOOL_CALLBACK;FULL_AOT_RUNTIME;FEATURE_NO_BSD_SOCKETS;MONOTOUCH_WATCH</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'monotouch_tv' ">
|
|
<OutputPath>./../../class/lib/monotouch_tv</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-monotouch_tv</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MOBILE;MOBILE_LEGACY;MONO;MONOTOUCH;DISABLE_REMOTING;DISABLE_COM;FEATURE_INTERCEPTABLE_THREADPOOL_CALLBACK;FULL_AOT_RUNTIME;MONOTOUCH_TV</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'testing_aot_hybrid' ">
|
|
<OutputPath>./../../class/lib/testing_aot_hybrid</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-testing_aot_hybrid</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;MOBILE;MOBILE_LEGACY;MOBILE_DYNAMIC;NET_3_5;NET_4_0;NET_4_5;MONO</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'testing_aot_full' ">
|
|
<OutputPath>./../../class/lib/testing_aot_full</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-testing_aot_full</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MONO;MOBILE;MOBILE_LEGACY;FULL_AOT_DESKTOP;FULL_AOT_RUNTIME;DISABLE_REMOTING;DISABLE_COM</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'winaot' ">
|
|
<OutputPath>./../../class/lib/winaot</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-winaot</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MONO;MOBILE;MOBILE_LEGACY;FULL_AOT_DESKTOP;FULL_AOT_RUNTIME;DISABLE_REMOTING;DISABLE_COM;WIN_PLATFORM</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'xammac' ">
|
|
<OutputPath>./../../class/lib/xammac</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-xammac</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MONO;MOBILE;MOBILE_DYNAMIC;XAMMAC;FEATURE_INTERCEPTABLE_THREADPOOL_CALLBACK;XAMARIN_MODERN</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'xammac_net_4_5' ">
|
|
<OutputPath>./../../class/lib/xammac_net_4_5</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-xammac_net_4_5</IntermediateOutputPath>
|
|
<DefineConstants>NET_4_0;NET_4_5;NET_4_6;MONO;FEATURE_INTERCEPTABLE_THREADPOOL_CALLBACK;NO_SYSTEM_DRAWING_DEPENDENCY;NO_WINFORMS_DEPENDENCY;NO_SYSTEM_WEB_DEPENDENCY;XAMMAC_4_5;XAMARIN_MODERN</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'orbis' ">
|
|
<OutputPath>./../../class/lib/orbis</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-orbis</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MONO;MOBILE;MOBILE_LEGACY;FULL_AOT_DESKTOP;FULL_AOT_RUNTIME;ORBIS;DISABLE_REMOTING;DISABLE_COM</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'unreal' ">
|
|
<OutputPath>./../../class/lib/unreal</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-unreal</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;MOBILE;MOBILE_DYNAMIC;NET_3_5;NET_4_0;NET_4_5;MONO</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Platform)' == 'wasm' ">
|
|
<OutputPath>./../../class/lib/wasm</OutputPath>
|
|
<IntermediateOutputPath>./../../class/obj/$(AssemblyName)-wasm</IntermediateOutputPath>
|
|
<DefineConstants>NET_1_1;NET_2_0;NET_2_1;NET_3_5;NET_4_0;NET_4_5;MONO;MOBILE;MOBILE_LEGACY;FULL_AOT_DESKTOP;FULL_AOT_RUNTIME;WASM;DISABLE_REMOTING;DISABLE_COM;FEATURE_NO_BSD_SOCKETS</DefineConstants>
|
|
</PropertyGroup>
|
|
<!-- @ALL_PROFILE_PROPERTIES@ -->
|
|
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
|
|
<DebugSymbols>true</DebugSymbols>
|
|
<DebugType>full</DebugType>
|
|
<Optimize>false</Optimize>
|
|
<!-- TRACE is set only for Debug configuration, so inherit from platform-specific value -->
|
|
<DefineConstants>TRACE;$(DefineConstants)</DefineConstants>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
|
|
<DebugType>pdbonly</DebugType>
|
|
<Optimize>true</Optimize>
|
|
</PropertyGroup>
|
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
|
<!-- @BUILT_SOURCES@ -->
|
|
<!--Common files-->
|
|
<ItemGroup>
|
|
<Compile Include="..\..\build\common\Consts.cs" />
|
|
<Compile Include="Assembly\AssemblyInfo.cs" />
|
|
<Compile Include="System.Net.Http.Headers\AuthenticationHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\CacheControlHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\CollectionExtensions.cs" />
|
|
<Compile Include="System.Net.Http.Headers\CollectionParser.cs" />
|
|
<Compile Include="System.Net.Http.Headers\ContentDispositionHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\ContentRangeHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\EntityTagHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HashCodeCalculator.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HeaderInfo.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HttpContentHeaders.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HttpHeaderKind.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HttpHeaderValueCollection.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HttpHeaders.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HttpRequestHeaders.cs" />
|
|
<Compile Include="System.Net.Http.Headers\HttpResponseHeaders.cs" />
|
|
<Compile Include="System.Net.Http.Headers\Lexer.cs" />
|
|
<Compile Include="System.Net.Http.Headers\MediaTypeHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\MediaTypeWithQualityHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\NameValueHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\NameValueWithParametersHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\Parser.cs" />
|
|
<Compile Include="System.Net.Http.Headers\ProductHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\ProductInfoHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\QualityValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\RangeConditionHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\RangeHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\RangeItemHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\RetryConditionHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\StringWithQualityHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\TransferCodingHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\TransferCodingWithQualityHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\ViaHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http.Headers\WarningHeaderValue.cs" />
|
|
<Compile Include="System.Net.Http\ByteArrayContent.cs" />
|
|
<Compile Include="System.Net.Http\ClientCertificateOption.cs" />
|
|
<Compile Include="System.Net.Http\DelegatingHandler.cs" />
|
|
<Compile Include="System.Net.Http\FormUrlEncodedContent.cs" />
|
|
<Compile Include="System.Net.Http\HttpClient.cs" />
|
|
<Compile Include="System.Net.Http\HttpCompletionOption.cs" />
|
|
<Compile Include="System.Net.Http\HttpContent.cs" />
|
|
<Compile Include="System.Net.Http\HttpMessageHandler.cs" />
|
|
<Compile Include="System.Net.Http\HttpMessageInvoker.cs" />
|
|
<Compile Include="System.Net.Http\HttpMethod.cs" />
|
|
<Compile Include="System.Net.Http\HttpRequestException.cs" />
|
|
<Compile Include="System.Net.Http\HttpRequestMessage.cs" />
|
|
<Compile Include="System.Net.Http\HttpResponseMessage.cs" />
|
|
<Compile Include="System.Net.Http\MessageProcessingHandler.cs" />
|
|
<Compile Include="System.Net.Http\MultipartContent.cs" />
|
|
<Compile Include="System.Net.Http\MultipartFormDataContent.cs" />
|
|
<Compile Include="System.Net.Http\StreamContent.cs" />
|
|
<Compile Include="System.Net.Http\StringContent.cs" />
|
|
<!--Genconsts dependency because this project includes Consts.cs-->
|
|
<ProjectReference Include="$(SolutionDir)\msvc\scripts\genconsts.csproj">
|
|
<Name>genconsts</Name>
|
|
<Project>{702AE2C0-71DD-4112-9A06-E4FABCA59986}</Project>
|
|
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
|
|
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
|
|
<Private>false</Private>
|
|
</ProjectReference>
|
|
</ItemGroup>
|
|
<!--End of common files-->
|
|
<!--Per-profile files-->
|
|
<Choose>
|
|
<When Condition="'$(Platform)' == 'xammac'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClient.mac.cs" />
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'winaot'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'wasm'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClient.wasm.cs" />
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'unreal'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'orbis'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'net_4_x'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'monotouch_watch'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.platformnotsupported.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'monotouch_tv'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'monotouch'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
<When Condition="'$(Platform)' == 'monodroid'">
|
|
<ItemGroup>
|
|
<Compile Include="System.Net.Http\HttpClient.android.cs" />
|
|
<Compile Include="System.Net.Http\HttpClientHandler.cs" />
|
|
</ItemGroup>
|
|
</When>
|
|
</Choose>
|
|
<!--End of per-profile files-->
|
|
<!-- @ALL_SOURCES@ -->
|
|
<ItemGroup>
|
|
<ProjectReference Include="../System.Core/System.Core.csproj" />
|
|
<ProjectReference Include="../System/System.csproj" />
|
|
<ProjectReference Include="../corlib/corlib.csproj" />
|
|
</ItemGroup>
|
|
<ItemGroup Condition=" '$(Platform)' == 'testing_aot_hybrid' ">
|
|
<Reference Include="nunitlite">
|
|
<HintPath>..\lib\testing_aot_hybrid\nunitlite.dll</HintPath>
|
|
<Private>False</Private>
|
|
</Reference>
|
|
</ItemGroup>
|
|
<ItemGroup Condition=" '$(Platform)' == 'testing_aot_full' ">
|
|
<Reference Include="nunitlite">
|
|
<HintPath>..\lib\testing_aot_full\nunitlite.dll</HintPath>
|
|
<Private>False</Private>
|
|
</Reference>
|
|
</ItemGroup>
|
|
<!-- @ALL_REFERENCES@ -->
|
|
<!-- @ALL_RESOURCES@ -->
|
|
</Project> |