Use win32 newlines in templated files on windows

Fixes #4355
Merge pull request #5507 from UtahDave/template_win_newlines

Use win32 newlines in templated files on windows