This is for Visual Studio 2015, C++
I have one project that is compiled as a library and has some #if - #else
statements
#ifdef DXTK
//...
#elif defined DXUT
//...
#else
//...
#endif
I have two different solutions (with a separate executable project each) that both include this library as a project.
I need to #define DXUT
in one executable project and #define DXTK
in the other
But the problem is, my definitions in pre-processor for the executable projects (not the library) do not affect the library project's #if - #else
statements
I know one recommendation is to create different configurations for the library project and use one in one solution, and another in the other.
But is there a way to pass the preprocessor definition in the entire solution?
I tried adding /DDXUT
to C/C++ -> Command Line
for the executable projects, but it did not work.
How can I do this without creating a new configuration for each project?