diff options
author | Kseniia Vasilchuk <vasilchukkseniia@gmail.com> | 2016-12-21 14:56:54 +0300 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2016-12-22 02:04:36 +0200 |
commit | 69e2ef099c2c235739f6ced60b8ffb8ccb1124fb (patch) | |
tree | 2d0cffe85960819b5a94509fd09d40d4b397f03b /mesonbuild/mesonlib.py | |
parent | 9d1e426bcc2980276f97453c570bc59d9c009c78 (diff) | |
download | meson-69e2ef099c2c235739f6ced60b8ffb8ccb1124fb.zip meson-69e2ef099c2c235739f6ced60b8ffb8ccb1124fb.tar.gz meson-69e2ef099c2c235739f6ced60b8ffb8ccb1124fb.tar.bz2 |
configure_file: Use utf-8 to write configured file
as a second part of
https://github.com/mesonbuild/meson/issues/1085
Diffstat (limited to 'mesonbuild/mesonlib.py')
-rw-r--r-- | mesonbuild/mesonlib.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/mesonlib.py b/mesonbuild/mesonlib.py index 5250cd3..c4f6769 100644 --- a/mesonbuild/mesonlib.py +++ b/mesonbuild/mesonlib.py @@ -318,7 +318,7 @@ def do_conf_file(src, dst, confdata): line = do_replacement(regex, line, confdata) result.append(line) dst_tmp = dst + '~' - with open(dst_tmp, 'w') as f: + with open(dst_tmp, 'w', encoding='utf-8') as f: f.writelines(result) shutil.copymode(src, dst_tmp) replace_if_different(dst, dst_tmp) |