1

I know that this question is almost the same with this , but I still don't understand how to do it in command prompt. Here is what I'm doing:

  1. I need to compile old source code of 7z archivation tool, so I downloaded it.

  2. Now I am running nmake in the 7z_version/CPP/7zip and it shows me errors:

C2220: warning treated as error - no 'object' file generated.

So here is the question: how to disable this warning? I am using VS comand prompt, because IDE cannot understand the project folder.

Community
  • 1
  • 1
Mr Davron
  • 97
  • 1
  • 7

1 Answers1

1

It's actually not a warning, but an error (about the warning being treated as an error). So either you fix the original warning (should be printed a bit earlier in the build log) or you modify the compiler options to not treat warnings as errors: remove the /WX flag, or if the project file is msbuild based then set TreatWarningAsError to false.

edit this is nmake based, remove -WX from line 26 in CPP\Build.mak

stijn
  • 34,664
  • 13
  • 111
  • 163