Make perlbug Unicode-aware.
Try to do input in whatever the locale wants and output raw in
hopes that will best survive mail transport.
Except when reading in a patch file, we'll also use raw for input
because there may be multiple encodings in the patch, and we'll
also use raw for input when reading in the report file that we've
written out raw.
We attempt to detect the locale encoding using the private and
undocumented _get_locale_encoding() function of the deprecated
encoding pragma module. But it's what the open pragma does and
we protect ourselves by checking that it's available and falling
back to an empty layer specification ("<:") if we can't load that
function. That should also give us something workable when there
is no dynamic loading, such as under miniperl.