<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Hi Anton,</div><div class=""><br class=""></div><div class="">Here are some suggestions.</div><div class=""><br class=""></div><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; font-size: small; line-height: 19px; background-color: rgb(255, 255, 255);" class="">-All you need to be able to invoke scan-build from an arbitrary location is to add the path to scan-build to your PATH environment variable.</span><div class=""><span style="background-color: rgb(255, 255, 255);" class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" size="2" class=""><span style="line-height: 19px;" class="">+To invoke scan-build from an arbitrary location, add the path to the folder containing scan-build.bat to your PATH environment variable.</span></font></span></div><div class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" size="2" class=""><span style="line-height: 19px; background-color: rgb(255, 255, 255);" class=""><br class=""></span></font></div><div class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" size="2" class=""><span style="line-height: 19px; background-color: rgb(255, 255, 255);" class="">New section uses a lot of bold, which makes it stand out from the rest of the page. How about something like this:</span></font></div><div class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" size="2" class=""><span style="line-height: 19px; background-color: rgb(255, 255, 255);" class=""><br class=""></span></font></div><div class=""><ul class="MailOutline"><li class=""><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class="">If getting </span><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class="">unexpected</span><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""> </span><font face="Lucida Grande" class=""><span style="color: rgb(34, 34, 34); line-height: 19px;" class="">"fatal error: no input files"</span><span style="color: rgb(34, 34, 34); line-height: 19px;" class=""> </span></font><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class="">while building with MSYS</span><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""> </span><tt style="line-height: 19px;" class="">make</tt><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""> from the Windows cmd, try one of the these solutions:</span></li><ul class=""><li class=""><i style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" class=""><span style="font-style: normal;" class="">Use MinGW</span><span style="font-style: normal;" class=""> </span><tt style="font-style: normal; color: rgb(0, 0, 0);" class="">mingw32-make</tt><span style="font-style: normal;" class=""> </span><span style="font-style: normal;" class="">instead of MSYS</span><span style="font-style: normal;" class=""> </span><tt style="font-style: normal; color: rgb(0, 0, 0);" class="">make and</tt><span style="font-style: normal;" class=""> exclude the path to MSYS from PATH to prevent</span><span style="font-style: normal;" class=""> </span><tt style="font-style: normal; color: rgb(0, 0, 0);" class="">mingw32-make</tt><span style="font-style: normal;" class=""> </span><span style="font-style: normal;" class="">from using MSYS utils. </span></font></i><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class="">MSYS utils are dependent on the MSYS runtime and they are not intended for being run from the Windows cmd. Specifically, makefile commands with backslashed quotes may be heavily corrupted when passed for execution.</span><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""> </span></li><li class=""><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class="">Run</span><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""> </span><tt style="line-height: 19px;" class="">make</tt><span style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Arial, Verdana, Helvetica, sans-serif; line-height: 19px;" class=""> from the sh shell:</span></li></ul></ul></div><div class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" class=""><span style="line-height: 19px;" class=""><br class=""></span></font><i class=""><font color="#222222" face="Lucida Grande, Lucida Sans Unicode, Arial, Verdana, Helvetica, sans-serif" class=""><span style="line-height: 19px;" class="">                     $scan-build [options] sh -c "make [options]”  // Use the proper formatting for this. like other invocations of scan build.</span></font></i><br class=""><font color="#222222" face="Lucida Grande" class=""><span style="line-height: 19px;" class=""><br class=""></span></font><div class=""><ul class="MailOutline"><li class=""><font face="Lucida Grande" class=""><font color="#222222" class=""><span style="line-height: 19px;" class="">If getting "Error : *** target pattern contains no `%’” while using </span></font><span style="color: rgb(34, 34, 34); line-height: 19px;" class="">GNU Make 3.81, try to use another version of make.</span></font></li></ul></div><div><br class=""></div><div>Please, don’t use <tt> instead of italics for the error messages.</div><div><br class=""></div><div>I’ve left out some links and explanations of why the errors happen. I think these are not essential to the user and we want to keep the section brief since the page contains simple scan-build use instructions.</div><div><br class=""></div><div>Thanks!</div><div>Anna.</div><div><br class=""></div><div>On Oct 30, 2014, at 11:03 AM, Anton Yartsev <<a href="mailto:anton.yartsev@gmail.com" class="">anton.yartsev@gmail.com</a>> wrote:<br class=""><blockquote type="cite" class=""><br class="Apple-interchange-newline"><div class=""><div class="moz-cite-prefix" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);">Attached is an updated patch.<br class=""><br class=""></div><blockquote cite="mid:BCD2FCEF-823E-4742-AE25-A8AF77618E5F@apple.com" type="cite" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class="">Anton,<div class=""><br class=""></div><div class="">I think the bulleted list might benefit from restructuring a bit to make it sound more like a recommendation on what needs to be done under different circumstances.</div></blockquote><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255); float: none; display: inline !important;" class="">Restructured the bulleted list, now it looks much more better.</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><blockquote cite="mid:BCD2FCEF-823E-4742-AE25-A8AF77618E5F@apple.com" type="cite" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><div class=""><br class=""></div><div class="">My understanding is that the most reliable way is to use MinGW instead of make. (This is addressed by the first bullet.)</div><div class=""><br class=""></div><div class="">However, some projects might get away with using make. In that case, the other recommendations (2d and 3d bullet) would apply.</div></blockquote><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255); float: none; display: inline !important;" class="">There are two reliable ways - either use pure MinGW or run make from the sh shell. The 2d bullet is really a recipe for healing a problem from the 1st bullet, eliminated it.</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255); float: none; display: inline !important;" class="">Pleas look at the updated list.</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255); float: none; display: inline !important;" class="">Thank you for looking at this!</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><blockquote cite="mid:BCD2FCEF-823E-4742-AE25-A8AF77618E5F@apple.com" type="cite" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);" class=""><div class=""><br class=""></div><div class="">Is this correct?</div><div class=""><br class=""></div><div class="">Thanks,</div><div class="">Anna.</div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Oct 20, 2014, at 1:49 PM, Anton Yartsev <<a moz-do-not-send="true" href="mailto:anton.yartsev@gmail.com" class="">anton.yartsev@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="moz-cite-prefix" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);">Updated the "For Windows Users" section with helpful hints, OK to commit?<br class=""><br class=""></div><blockquote cite="mid:FA0D7B98-DE03-4AA3-93E8-31B5EE056C60@apple.com" type="cite" class="" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);">Anton, <div class=""><br class=""></div><div class="">Thanks for the investigation.</div><div class=""><br class=""></div><div class="">Please, send the proposed wording as a patch. (Not sure if it would be possible to describe the symptoms of the problem.)</div><div class=""><div class=""><br class=""></div><div class="">Anna.</div><div class=""><div class=""><blockquote type="cite" class=""><div class="">On Oct 18, 2014, at 1:56 AM, Anton Yartsev <<a moz-do-not-send="true" href="mailto:anton.yartsev@gmail.com" class="">anton.yartsev@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div text="#000000" bgcolor="#FFFFFF" class=""><div class="moz-cite-prefix">As I was explained in the MSYS community the MSYS utils are dependent on the MSYS runtime and their usage from cmd.exe is unsupported. "You are welcome to try it, but if you observe odd behaviour, such as here, then you are out of luck".<br class=""><br class="">I performed several tests and found out that proper processing is performed with either running scan-build with MSYS make in the following way:<br class="">scan-build ... sh -c "make"<br class="">or with using mingw32-make and removal of MSYS from PATH (otherwise mingw32-make tries to use MSYS utils).<br class=""><br class="">from the MinGW FAQ:<br class="">"What's the difference between make and mingw32-make?<br class="">The "native" (i.e.: MSVCRT dependent) port of make is lacking in some functionality and has modified functionality due to the lack of POSIX on Win32. There also exists a version of make in the MSYS distribution that is dependent on the MSYS runtime. This port operates more as make was intended to operate and gives less headaches during execution. Based on this, the MinGW developers/maintainers/packagers decided it would be best to rename the native version so that both the "native" version and the MSYS version could be present at the same time without file name collision."<br class=""><br class="">Is it OK to add the recommendations to the<span class="Apple-converted-space"> </span><a moz-do-not-send="true" href="http://clang-analyzer.llvm.org/scan-build.html#scanbuild_forwindowsusers" class="">scan-build: running the analyzer from the command line</a>, "For Windows Users" section?<br class=""><br class=""></div><blockquote cite="mid:543FAD82.1010004@Gmail.com" type="cite" class="">Sorry, that's not a solution.<span class="Apple-converted-space"> </span><br class=""><br class=""><blockquote type="cite" class="">The goal of the patch is to pass unmodified arguments to compilers as they were written in the makefile. Arguments taken from @ARGV may be modified by the system and Perl, at least quotes and backslash sequences are processed. Using this arguments may cause compiler errors. Sometimes system+Perl corrupt arguments completely, for example, using perl from MSYS 1.0 on Windows I got:<span class="Apple-converted-space"> </span><br class="">Line from makefile:<span class="Apple-converted-space"> </span><br class="">  <span class="Apple-converted-space"> </span>$(CXX) -DMACRO=\"string\" file.cpp "asd dff ghh" -o file.exe<span class="Apple-converted-space"> </span><br class=""><br class="">arguments red from @ARGV by c++-analyzer:<span class="Apple-converted-space"> </span><br class=""> <span class="Apple-converted-space"> </span>"-DMACRO=\string\" file.cpp -o file.exe"<span class="Apple-converted-space"> </span><br class=""><br class="">Please review!<span class="Apple-converted-space"> </span><br class=""><br class=""></blockquote></blockquote><br class=""><pre class="moz-signature" cols="72">-- 
Anton</pre></div></div></blockquote></div><br class=""></div></div></blockquote><pre class="moz-signature" cols="72" style="font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);">-- 
Anton</pre><span id="cid:C39DC84B-5745-417F-A02E-B8EC3EA2B148@apple.com" class=""><scan-build.html.patch></span></div></blockquote></div><br class=""></div></blockquote><pre class="moz-signature" cols="72" style="font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255);">-- 
Anton</pre><span id="cid:6C73F8D6-7CDF-41BE-9924-B812D9F775AD"><scan-build.htmlv_02.patch></span></div></blockquote></div><br class=""></div></body></html>