[pango/msvc.improvements: 7/8] Visual Studio: Use -utf-8 when available
- From: Chun-wei Fan <fanchunwei src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pango/msvc.improvements: 7/8] Visual Studio: Use -utf-8 when available
- Date: Tue, 10 Mar 2020 08:24:30 +0000 (UTC)
commit e7160cc7e2e9a9867c5bcf7935d4e902c11a76a9
Author: Chun-wei Fan <fanchunwei src gnome org>
Date: Wed Jan 15 14:44:37 2020 +0800
Visual Studio: Use -utf-8 when available
This avoids the build erroring out on C4819 (Unicode handling issue in Visual
Studio compilers), notably when running on Chinese, Japanese and Korean
locales.
meson.build | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/meson.build b/meson.build
index d5321e60..f0aa84e3 100644
--- a/meson.build
+++ b/meson.build
@@ -57,8 +57,8 @@ common_ldflags = []
if cc.get_id() == 'msvc'
# Compiler options taken from msvc_recommended_pragmas.h
# in GLib, based on _Win32_Programming_ by Rector and Newcomer
- test_cflags = []
- add_project_arguments([ '-FImsvc_recommended_pragmas.h' ], language: 'c')
+ test_cflags = ['-FImsvc_recommended_pragmas', '-utf-8']
+ add_project_arguments(cc.get_supported_arguments(test_cflags), language: 'c')
test_c_only_flags = []
elif cc.get_id() == 'gcc' or cc.get_id() == 'clang'
test_c_only_flags = [
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]