Unify the 32-bit and 64-bit installer build processes.

Use the same .wxs file for both builds. The MSM files is still generated
differently, but this is a step in the right direction.
Merge 32-bit and 64-bit .wxs files used to build the .MSM files on Windows
Using tolower() requires ctype.h with some compilers.

gcc and MSVC were happy without it, but clang warns.
Silence misc issues flagged up by Clang's static analyzer, scan-build