I got an error while compiling wireshark. erf.c erf.c(654) : error C2220: warning treated as error - no 'object' file generated erf.c(654) : warning C4244: '=' : conversion from 'gint64' to 'int', possible lo ss of data mp2t.c mp2t.c(121) : error C2220: warning treated as error - no 'object' file generated mp2t.c(121) : warning C4244: '=' : conversion from 'guint64' to 'int', possible loss of data Generating Code... NMAKE : fatal error U1077: 'cl' : return code '0x2' Stop. NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Platform SDK\Bin\nmake.e xe"' : return code '0x2' Stop. i find many post on internet and forum i found that it can be avoided by doing In the top-level Wireshark directory config.h: Comment out the following if warnings are not to be treated as errorsWARNINGS_ARE_ERRORS=-WX but in config.h i didn't find this tag. Wireshark version - 1.8.3 OS - Windows 7 Visual studio 2005. i followed http://www.codeproject.com/Articles/19426/Creating-Your-Own-Custom-Wireshark-Dissector link to build the code. asked 06 Nov '12, 22:10 ishan |
One Answer:
The instructions in the link you provided are based on a very old toolchain (VS2005) but look like they should work. I'm not aware of that many people building with VS2005 these days, and you may have more success with a more up to date toolchain, e.g. VS2010 Express. The definitive guide to building Wireshark is the Wireshark Developers Guide that is kept current by Wireshark Core Developers. You must follow each step in the Guide to the letter, omitting or varying any steps is likely to lead to build failures. Finally, have you made any modifications to the source files before attempting the build (apart from config.nmake)? If so, please try to complete a build with unmodified source files first just to prove your build environment. answered 07 Nov '12, 00:19 grahamb ♦ Thanks grahamb , i followed the steps there and i was able to install and build Wireshark. Two observation which i want to mention which will help users.
(07 Nov '12, 22:19) ishan |
WARNINGS_ARE_ERRORS is in config.nmake (for Windows builds). In the release versions (e.g., 1.8.3) then it should already be commented out. So I'm not sure why you're getting "warning treated as error"...