简体   繁体   中英

Should I include in NuGet package dlls for multiple target frameworks

Let's consider a library project which should run on three .NET runtimes: net20, net35 and net46. The source code remains the same for all versions.

When releasing should i build the project 3 times with different TargetFrameworkVersion property values in order to generate 3 dlls, one for each .NET version, and than include all three in the nupkg file in lib/<target framework>/ directories? Or is it just fine to include only .net 2.0 dll and it will work just fine on newer runtimes.

如果仅使用在2.0版上编译的代码,则无需包括其他框架版本。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM