(#18986) Write to the console using Unicode Win32 APIs

Previously, puppet on windows could not output unicode characters to the
console reliably, such as the box drawing characters used by the module
tool when displaying dependencies.

Ruby 1.8 uses the ANSI Win32 APIs, e.g. WriteConsole, to write to the
console. However, it uses the current console codepage. So if the current
codepage cannot handle the unicode character we're trying to write, e.g.
cp1252, then it displays garbage.

Ruby 1.9 uses the Unicode Win32 APIs, e.g. WriteConsoleW. As such, it can
correctly write unicode output, without being sensitive to the current
codepage.

However, because puppet writes ANSI escape sequences, we use the
win32console gem to color the output. This win32console gem redefines the
stdout and stderr streams to accomplish this, and sadly uses ANSI versions
of Win32 APIs to write to the console. So it has the same problems as ruby
1.8.

This commit overrides the win32console classes, Console and IO, to ensure
the Unicode APIs are used. This enables us to display ANSI escape
sequences and unicode characters that may not be compatible with the
current codepage.

Longer term we should think about removing win32console gem altogether and
moving to ruby 1.9, as these hacks would no longer be required. Though
doing so would mean losing color output, or taking more drastic measures
like ansicon.
Merge pull request #1440 from joshcooper/ticket/master/18986-unicode-console

(#18986) Write to the console using Unicode Win32 APIs
Explicitly require Win32API

Previously, puppet could not be loaded in ruby 1.9 on Windows. The issue
is that commit cd7d52a7b caused Win32API to be called during puppet's
bootstrapping process, before Puppet.features.microsoft_windows? is
invoked, which normally handles loading Windows specific gems.

In ruby 1.8, this is not an issue because Win32API is always loaded by
ruby itself. But in ruby 1.9, it must be explicitly loaded, which this
commit does.