This repository has been archived on 2025-09-07. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.
dotnet-installer/TestAssets/TestProjects/AppWithNet46AndRoslyn
Eric Erhardt d98c1f8724 dotnet build raises errors MVC apps target net46.
The issue is when the ProjectContextBuilder sees a CompileTimePlaceholder "_._" file on a full framework, it assumes that dependency has to come from the "Reference Assemblies" directory.  If it can't be found there, an error is raised.  However, there are other reasons "_._" placeholders are created (when a NuGet package doesn't want its dependencies to be exposed in the Compile dependencies of its consumers). And these placeholders can exist for assemblies that aren't in the full framework - in this case System.Diagnostics.FileVersionInfo and others.

To fix this, if the reference can't be resolved from the "Reference Assemblies" folder, it is just skipped. If the compiler really needs that assembly, it will raise an error to the user.  Dotnet build shouldn't raise the error.

Fix #2906
2016-05-06 14:32:50 -05:00
..
.noautobuild dotnet build raises errors MVC apps target net46. 2016-05-06 14:32:50 -05:00
Program.cs dotnet build raises errors MVC apps target net46. 2016-05-06 14:32:50 -05:00
project.json dotnet build raises errors MVC apps target net46. 2016-05-06 14:32:50 -05:00