<TargetFramework>net35</TargetFramework>C:\Program Files\dotnet\sdk\2.0.0\Microsoft.Common.CurrentVersion.targets(1122,5): error MSB3644: The reference assemblies for framework ".NETFramework,Version=v3.5" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.
@nguerrera we don't support using the .NET Core SDK to target .NET 3.5 do we?
Right. This doesn't work currently.
I'd love to hear some insight into why this scenario is important. Is it that you want to use the .NET Core SDK Tools to create new .NET 3.5 projects or build existing projects? If you want to use it to create existing projects, what is keeping you using .NET 3.5?
I was trying to build a managed plugin for Unity 3D game engine.
we need to use .NET 3.5 or lower so that the plugin can run on all platforms.
Thanks for that insight! I knew that but hadn't connect that back to wanting to use the .NET Core SDK tools. We are looking at having a better story for targeting .NET Framework more generally with these tools. I'll make sure that .NET Framework 3.5 gets included in that discussion.
error MSB3644: The reference assemblies for framework ".NETFramework,Version=v4.6" were not found.
It is installed and .NET4.7 on top. The problem seems to be that the file "C:\Program Files\dotnet\sdk\2.1.3\Microsoft.Common.CurrentVersion.targets" cannot be rewritten to update the targets included. Super annoying issue whichever way you look at it.
Another use case for this is building libraries that support net35 on non-Windows machines. This held up NUnit from using the new csproj until we figured out how to get Mono to do it for us when we detect we're not on Windows, but it's still more complex than it should be.
Same problem. I resolve this with FrameworkPathOverride in project, but that looks bad.
This repo is no longer actively monitored. Closing up old issues that have not had activity in while. If this is still an issue, please open a new issue in an appropriate repo listed in microsoft/dotnet#1275
Better late than never. Reference this in your project: https://www.nuget.org/packages/jnm2.ReferenceAssemblies.net35
Most helpful comment
Thanks for that insight! I knew that but hadn't connect that back to wanting to use the .NET Core SDK tools. We are looking at having a better story for targeting .NET Framework more generally with these tools. I'll make sure that .NET Framework 3.5 gets included in that discussion.