Fixed caching compiler output when invoked from Visual Studio IDE
Fixed caching compiler output when invoked from Visual Studio IDE

It turns out that the Visual Studio IDE invokes cl.exe (i.e. clcache)
with a special 'VS_UNICODE_OUTPUT' environment variable. If this
variable is set, it apparently makes cl.exe write its output as UTF-16
to some secret named pipes which the IDE reads from. Alas, it also keeps
cl.exe from writing output to stdout - something which we rely on.

This appears to be a known quirk, looking at e.g.

  https://blogs.msdn.microsoft.com/freik/2006/04/05/how-to-get-cl-exe-proxy-filters-like-stlfilt-working-under-vs2005/

Which sums it up:

  So, if you're writing a cl.exe proxy, prior to invoking the original
  cl.exe, undefine VS_UNICODE_OUTPUT. This successfully tricks cl.exe into
  thinking you're just compiling from the command line, and you're
  back in business (with non-Unicode messages, though).

webmaster128/clcache,webmaster128/clcache,webmaster128/clcache