Stop supporting Perl releases prior to v5.6.2.  Tweak the code
to prevent locale from causing troubles where it cannot be used,
e.g. Android.