The project I am working on uses a lot of scripts (.bat) to define some stuff finally used by CMake, which is called at the end.
When CMake is called, a value is defined and passed as argument :
cmake -D PLATFORM=%PLATFORM% (the value may be x86 or x64)
I am now trying to use a library through the FetchContent feature.
The problem is that library has a CMake script which uses/defines also PLATFORM, but with an other meaning :
Both meanings are legitimate, but how avoiding this conflict ? I guess I could simply rename PLATFORM in my scripts/CMakeLists.txt (although it annoys me), but I think this kind of situation may happen frequently.
Is there a good way to resolve that ?