If I have a <ProjectReference> reference, is there any way to pass a conditional compilation value to that project? Something like this (I know <DefineConstants> doesn't exist like this, it's just to illustrate the need):
<ProjectReference Include="..\DataProducer\DataProducer.csproj">
<DefineConstants>WAS_SET</DefineConstants>
<ProjectReference>
Therefore, if there's a class in that project like this:
public sealed class ProduceValue
{
public string Produce()
{
#if WAS_SET
return "WAS SET";
#else
return "NOTHING WAS SET";
#endif
}
}
Then by passing that value during compilation or not, I could get different output.