VisualStudio warnings
Compiling ILCompiler from scratch you get the following warnings in Visual Studio:
Restoring NuGet packages...
To prevent NuGet from restoring packages during build, open the Visual Studio Options dialog, click on the Package Manager node and uncheck 'Allow NuGet to download missing packages during build.'
Dependency specified was System.CommandLine (≥ 0.1.0-d111815-3) but ended up with System.CommandLine 0.1.0-e160208-1.
Dependency specified was System.CommandLine (≥ 0.1.0-d111815-3) but ended up with System.CommandLine 0.1.0-e160208-1.
System.CommandLine 0.1.0-e160208-1 is not compatible with .NETFramework,Version=v4.6.
Some packages are not compatible with .NETFramework,Version=v4.6.
System.CommandLine 0.1.0-e160208-1 is not compatible with .NETFramework,Version=v4.6 (win-x64).
Some packages are not compatible with .NETFramework,Version=v4.6 (win-x64).
System.CommandLine 0.1.0-e160208-1 is not compatible with DNXCore,Version=v5.0.
Some packages are not compatible with DNXCore,Version=v5.0.
NuGet package restore failed.
And then some versioning issue:
Consider app.config remapping of assembly "System.Runtime, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.20.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Runtime.dll] to Version "4.0.21.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Runtime.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.IO, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.IO.dll] to Version "4.0.11.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.IO.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Diagnostics.Debug, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Diagnostics.Debug.dll] to Version "4.0.11.0" [] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Linq, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.0.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Linq.dll] to Version "4.0.1.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Linq.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Runtime.InteropServices, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.20.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Runtime.InteropServices.dll] to Version "4.0.21.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Runtime.InteropServices.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Runtime.Extensions, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Runtime.Extensions.dll] to Version "4.0.11.0" [] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Collections, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Collections.dll] to Version "4.0.11.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Collections.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Threading, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Threading.dll] to Version "4.0.11.0" [] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Text.Encoding, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Text.Encoding.dll] to Version "4.0.11.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Text.Encoding.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Collections.Immutable, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "1.1.37.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Collections.Immutable.dll] to Version "1.2.0.0" [C:\work\Microsoft\corert\packages/System.Collections.Immutable\1.2.0-rc2-23704\lib\dotnet5.1\System.Collections.Immutable.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Globalization, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.10.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Globalization.dll] to Version "4.0.11.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Globalization.dll] to solve conflict and get rid of warning.
4> Consider app.config remapping of assembly "System.Reflection.Primitives, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.0.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6\Facades\System.Reflection.Primitives.dll] to Version "4.0.1.0" [C:\work\Microsoft\corert\bin\Product\Windows_NT.x64.Debug\System.Reflection.Primitives.dll] to solve conflict and get rid of warning.
4>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1819,5): warning MSB3276: Found conflicts between different versions of the same dependent assembly. Please set the "AutoGenerateBindingRedirects" property to true in the project file. For more information, see http://go.microsoft.com/fwlink/?LinkId=294190.
4> desktop -> C:\work\Microsoft\corert\src\ILCompiler\desktop\bin\Debug\ilc.exe
Is there a way to solve this? It is annoying to see errors in the VS Error List window.
@schellap Any thoughts on this?
With the latest CoreRT code, the output is slightly different:
Restoring NuGet packages...
To prevent NuGet from restoring packages during build, open the Visual Studio Options dialog, click on the Package Manager node and uncheck 'Allow NuGet to download missing packages during build.'
Dependency specified was System.CommandLine (>= 0.1.0-e160323-1) but ended up with System.CommandLine 1.0.0.1.
Dependency specified was System.CommandLine (>= 0.1.0-e160323-1) but ended up with System.CommandLine 1.0.0.1.
Dependency specified was System.CommandLine (>= 0.1.0-e160323-1) but ended up with System.CommandLine 1.0.0.1.
System.CommandLine 1.0.0.1 is not compatible with DNXCore,Version=v5.0.
TypeUtils 1.0.0.2 is not compatible with DNXCore,Version=v5.0.
Some packages are not compatible with DNXCore,Version=v5.0.
NuGet package restore failed.
And to be precise, the Dependency entries are treated as warning by Visual Studio, whereas the "not compatible" entries are treated as errors.
I did a build.cmd and compile in Visual Studio and did not see the nuget errors. I have the Allow Nuget to restore missing packages disabled in Tools Options.
I have both "Allow Nuget to restore missing packages" and "Automatically check for missing packages during build in Visual Studio" checked. I believe this is the default.
I am not able to repro the Dependency specified was System.CommandLine (>= 0.1.0-e160323-1) but ended up with System.CommandLine 1.0.0.1 errors with the default package manager settings (allow restore + automatically check). Not sure what it may be causing this error.
If I disable the check, then the errors and warnings disappear. The only think left is
4>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1819,5): warning MSB3276: Found conflicts between different versions of the same dependent assembly. Please set the "AutoGenerateBindingRedirects" property to true in the project file. For more information, see http://go.microsoft.com/fwlink/?LinkId=294190.
For the
Dependency specified was System.CommandLine (>= 0.1.0-e160323-1) but ended up with System.CommandLine 1.0.0.1
warning, I'll try to delete my .nuget folder and see if it addresses it.