ch-robinson / dotnet-avro

An Avro implementation for .NET
https://engineering.chrobinson.com/dotnet-avro/
MIT License
135 stars 51 forks source link

fix(codegen): added .net6 as target framework due to issues with directive #300

Closed xontab closed 8 months ago

xontab commented 8 months ago

Changed TargetFramework to include multi-target similar to other Chr.Avro projects (such as Chr.Avro.Binary,Chr.Avro.Confluent, Chr.Avro.Json and Chr.Avro).

The reason behind this change is because the NET6_0_OR_GREATER directive is not working on .NET Standard projects (at least on ARM64 architecture). This workaround will however work on .NET 6+ since the framework package is used instead of the netstandard one.

xontab commented 8 months ago

🤦 should have caught this with #298, thanks

Agreed... But somehow this was working fine on x64 based systems but not ARM64. Might be a bug in .NET/MSBuild since the behaviour changes according to the CPU architecture.

Thanks for merging.