Fix CR/LF and charset.
Add mac code.