Make some portability changes to the code, to allow it to run on Visual Studio.

There are a few seeming quirks between clang++ and MSVC++ compiler -- at least the current version of the compiler -- which required some minor tweaking to the code, in order to allow it work work in a similar amanner to the way it ran (successfuly) on Linux.

The most noteworthy of these, of course, is providing a relavent path for the temporary file to be saved.