summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@wolfbeast.com>2019-12-19 17:40:52 +0100
committerwolfbeast <mcwerewolf@wolfbeast.com>2019-12-19 17:40:52 +0100
commit977340dc53c451b4d28e304cd4cec8d518e3dd54 (patch)
tree1ac10f7a1221fa95643901dba03b4f890838ebe3 /config
parente2d734ebefff48d444a009ef654a76f7a9e9dc58 (diff)
downloaduxp-977340dc53c451b4d28e304cd4cec8d518e3dd54.tar.gz
Issue mcp-graveyard/UXP#1316 - Reduce compiler warnings in ICU
This add a few disabled compiler warnings to the compiler flags on MSVC and specifically filters out the RTTI disabling CL flag to prevent CLI override warnings. This resolves #1316
Diffstat (limited to 'config')
-rw-r--r--config/external/icu/common/Makefile.in12
-rw-r--r--config/external/icu/defs.mozbuild11
-rw-r--r--config/external/icu/i18n/Makefile.in12
3 files changed, 35 insertions, 0 deletions
diff --git a/config/external/icu/common/Makefile.in b/config/external/icu/common/Makefile.in
new file mode 100644
index 0000000000..89ad2e8b84
--- /dev/null
+++ b/config/external/icu/common/Makefile.in
@@ -0,0 +1,12 @@
+# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
+# vim: set filetype=python:
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+include $(topsrcdir)/config/rules.mk
+
+ifdef _MSC_VER
+CXXFLAGS := $(filter-out -GR-,$(CXXFLAGS))
+CFLAGS := $(filter-out -GR-,$(CFLAGS))
+endif
diff --git a/config/external/icu/defs.mozbuild b/config/external/icu/defs.mozbuild
index 666bd4f6d6..ad5b29378c 100644
--- a/config/external/icu/defs.mozbuild
+++ b/config/external/icu/defs.mozbuild
@@ -47,3 +47,14 @@ if CONFIG['CLANG_CL']:
'-Wno-macro-redefined',
'-Wno-microsoft-include',
]
+
+if CONFIG['_MSC_VER'] and not CONFIG['CLANG_CL']:
+ CFLAGS += [
+ '-wd4005', # 'WIN32_LEAN_AND_MEAN' : macro redefinition
+ '-wd4996', # The compiler encountered a deprecated declaration.
+ ]
+ CXXFLAGS += [
+ '-wd4005', # 'WIN32_LEAN_AND_MEAN' : macro redefinition
+ '-wd4333', # '>>' : right shift by too large amount, data loss
+ '-wd4996', # The compiler encountered a deprecated declaration.
+ ]
diff --git a/config/external/icu/i18n/Makefile.in b/config/external/icu/i18n/Makefile.in
new file mode 100644
index 0000000000..89ad2e8b84
--- /dev/null
+++ b/config/external/icu/i18n/Makefile.in
@@ -0,0 +1,12 @@
+# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
+# vim: set filetype=python:
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+include $(topsrcdir)/config/rules.mk
+
+ifdef _MSC_VER
+CXXFLAGS := $(filter-out -GR-,$(CXXFLAGS))
+CFLAGS := $(filter-out -GR-,$(CFLAGS))
+endif