lib/ucs2_string: Add ucs2 -> utf8 helper functions