AArnott / CodeGeneration.Roslyn

Assists in performing Roslyn-based code generation during a build.
Microsoft Public License
408 stars 60 forks source link

.NET Core 3/netstandard 2.1 support? #169

Closed ugumba closed 4 years ago

ugumba commented 4 years ago

Should it work? After upgrading my projects, which work fine with .NET Core 2.1 and codegen 0.6.1, any project with codegen fails to compile, complaining about locating "netstandard, Version 2.1.0.0, ...", with CodeGeneration.Roslyn at the top of the call stack.

ticofab commented 4 years ago

I would love an update to .NET Core 3.x too :)

amis92 commented 4 years ago

.NET Core 3.0 workaround

There's one quite simple workaround for now, for the cases where you don't have v2.1 of runtime installed, and only 3.0 SDK+RT.

Set an environment variable: DOTNET_ROLL_FORWARD_ON_NO_CANDIDATE_FX=2

Documentation: https://github.com/dotnet/core-setup/blob/master/Documentation/design-docs/roll-forward-on-no-candidate-fx.md

amis92 commented 4 years ago

This should be fixed by #178 - await 0.7 release.