Support as many legacy encodings as possible