This is some code to get an environment variable from inside Qt, however, it seems Qt's QProcessEnvironment::systemEnvironment()
only reflect a new environment variable change after reboot. So I am thinking about using getenv.
However I got "error C2220: warning treated as error - no 'object' file generated"
from this :
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
const QString ENGINE_ROOT = env.value("ENGINE_ROOT", "") != "" ?
env.value("ENGINE_ROOT","") : QString(getenv("ENGINE_ROOT"));
Don't tell me something like disable /WX or lower W4 to W3, I don't want to hear this, I want to know exactly what cause
no 'object' file generated
.
"error C2220: warning treated as error - no 'object' file generated"
The error already answers your question:
If you want to know what the original warning means, then you need to ask us about that warning.