2

I am trying to create a NuGet package that will work on ASP.NET vNext (Desktop and CoreCLR) as well as .NET Framework 4.5.

I've looked at http://json.schemastore.org/project for the schema but it appears that there is no guidance on what "frameworks" are acceptable. This is my current project.json but I am not sure if it is correct.

What values for "frameworks" is possible?

"frameworks": {
        "aspnet50": {
            "frameworkAssemblies": {
                "System.Net.Http": "4.0.0.0",
                "System.Runtime.Serialization": "4.0.0.0",
                "System.Xml": "4.0.0.0",
                "System.Xml.Linq": "4.0.0.0"
            }
        },
        "aspnetcore50": {
            "dependencies": {
                "System.Runtime": "4.0.20-beta-22231",
                "System.Runtime.Serialization.Primitives": "4.0.0-beta-22231",
                "System.Xml.ReaderWriter": "4.0.10-beta-22231",
                "System.Xml.XDocument": "4.0.0-beta-22231",
                "System.Net.Http": "4.0.0-beta-22231",
                "System.Globalization": "4.0.10-beta-22231",
                "System.Diagnostics.Debug": "4.0.10-beta-22231",
                "System.Diagnostics.TraceSource": "4.0.0-beta-22231",
                "System.Collections": "4.0.10-beta-22231",
                "System.Linq": "4.0.0-beta-22231",
                "System.Linq.Parallel": "4.0.0-beta-22231",
                "System.Runtime.Extensions": "4.0.10-beta-22231",
                "System.IO.Compression": "4.0.0-beta-22231",
                "System.Reflection": "4.0.10-beta-22231",
                "System.IO.FileSystem": "4.0.0-beta-22231",
                "System.Threading.Thread": "4.0.0-beta-22231",
                "System.Threading": "4.0.0-beta-22231",
                "System.Reflection.Extensions": "4.0.0-beta-22231"
            }
        },
        "framework45": {
            "dependencies": {
                "Newtonsoft.Json": "6.0.4"
            }
        },
    }
2
  • What framework do you want to target? Commented Jan 14, 2015 at 21:00
  • I want to target .NET Framework 4.5. Commented Jan 14, 2015 at 22:19

1 Answer 1

2

Here is how you can target other frameworks: https://github.com/aspnet/EntityFramework/blob/dev/src/EntityFramework.Core/project.json

Use net45 for .NET 4.5

Sign up to request clarification or add additional context in comments.

3 Comments

Can you target .net40?
Yes, you can target net40.
Do you know how to do this in VS2017RC with MSBuild?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.