Karolis2011
Karolis2011
Explore posts from servers
CC#
Created by Karolis2011 on 12/28/2022 in #help
❔ AdditionalText to Bytes or stream
I am writing a generator, I have binary file format, how can I read it's bytes from AdditionalText class? Or I am forced to abandon binary format and use JSON?
4 replies
CC#
Created by Karolis2011 on 11/14/2022 in #help
❔ Native DLL in source generator
I am trying to make source generator that relies on custom native DLL, compiled from Rust. But Issue I am facing issues with managing it to be able to load them.
CSC : warning CS8785: Generator 'HybridByondCodeGenerator' failed to generate source. It will not contribute to the output and compilation errors may occur as a result. Exception was of type 'DllNotFoundException' with message 'Unable to load DLL 'dreammaker' or one of its dependencies: The specified module could not be found. (0x8007007E)' [C:\Projektai\ExternalByondSharp\ExtBySharp.Game\ExtBySharp.Game.csproj]
CSC : warning CS8785: Generator 'HybridByondCodeGenerator' failed to generate source. It will not contribute to the output and compilation errors may occur as a result. Exception was of type 'DllNotFoundException' with message 'Unable to load DLL 'dreammaker' or one of its dependencies: The specified module could not be found. (0x8007007E)' [C:\Projektai\ExternalByondSharp\ExtBySharp.Game\ExtBySharp.Game.csproj]
ExtBySharp.Generator is project containing HybridByondCodeGenerator DMNet.SpacemanDMM is project containing native bindings and wrapper for native DLL. libdreammaker.a and dreammaker.dll are native DLLs. ExtBySharp.Game is project for containing generator source files *.dm and *.dme and needs code to be generated for. I tried renfrecing project directly, but it didn't work, then I ended up packaging it as nuget package, and generator seems to load things, just it fails at loading native dlls, I tried putting them under analyzers/dotnet/cs, build/ and I am out of idea what to try.
13 replies