Description
openedon May 20, 2022
In our case, the native build is using a non-msbuild orchestrator and MSVC as the compiler. We like to use sourcelink becuase it makes things like dump diagnosis a lot more convenient, and we were leveraging the targets here to do the heavy lifting of getting the commit and writing the file. We were doing this in a NoTargets project since we don't really want any language targets to run, and most of the targets under _GenerateSourceLinkFile
run correctly. Only issue is it's guarded on DebugType
. Is it possible to safely remove the condition and have it generate the file (even if it needs a special prop, like debugType or GenerateSourceLinkFileAlways)? I tested removing the guard, and build both a NoTargets and a csproj SDK style one and both succeeded with no issues and the files contain the expected contents.