Build Output: Consider app.config remapping of assembly

2

I'm getting the message below for several Assemblies , the project compiles and runs normally, but wanted to know how to resolve and could cause future problems.

  

Consider app.config remapping of assembly "System.Net.Primitives,   Culture = neutral, PublicKeyToken = b03f5f7f11d50a3a "from Version   "3.9.0.0" [] to Version "4.0.0.0" [C: \ Program Files (x86) \ Reference   Assemblies \ Microsoft \ Framework \ MonoAndroid \ v1.0 \ Facades \ System.Net.Primitives.dll]   to solve conflict and get rid of warning.

    
asked by anonymous 26.08.2015 / 18:11

1 answer

1

This section is in web.config :

<configuration>
  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      ...
      <dependentAssembly>
        <assemblyIdentity name="System.Net.Primitives" culture="neutral" publicKeyToken="b03f5f7f11d50a3a" />
        <bindingRedirect oldVersion="0.0.0.0-4.0.0.0" newVersion="4.0.0.0" />
      </dependentAssembly>
      ...
    </assemblyBinding>
    ...
  </runtime>
  ...
</configuration>

Basically, you indicate a range of versions in oldVersion and the assembly in newVersion . There is not much secret.

The compiler gives this warning when the assembly version was found, but this may not always happen. The above configuration solves this problem.

    
13.09.2015 / 08:42