Bug 1392677: Silence unused-function warning draft
authorTom Ritter <tom@mozilla.com>
Tue, 22 Aug 2017 11:34:58 -0500
changeset 650567 9b5d46c503ad508cf89ac9dd46e3b0924915c7f8
parent 650485 ea187507f20bca3b2f7f80fc0855e43f147e1e0d
child 650568 eac8d605508062de53005f0bb3f6735750169905
child 650607 7b4eb88928de39650eb9882191f9621608d8e64e
push id75442
push userbmo:tom@mozilla.com
push dateTue, 22 Aug 2017 16:35:52 +0000
bugs1392677
milestone57.0a1
Bug 1392677: Silence unused-function warning nsCrashOnException.cpp:18:1: error: 'int mozilla::ReportException(EXCEPTION_POINTERS*)' defined but not used [-Werror=unused-function] I promise you it is called, you just can't figure out where. MozReview-Commit-ID: GwDuSvYg4Gb
xpcom/base/moz.build
old mode 100644
new mode 100755
--- a/xpcom/base/moz.build
+++ b/xpcom/base/moz.build
@@ -179,16 +179,19 @@ GENERATED_FILES["ErrorNamesInternal.h"].
 GENERATED_FILES["error_list.rs"].script = "ErrorList.py:error_list_rs"
 
 if CONFIG['OS_ARCH'] == 'Linux':
     SOURCES += [
         'LinuxUtils.cpp',
         'SystemMemoryReporter.cpp',
     ]
 
+if CONFIG['GNU_CXX']:
+    CXXFLAGS += ['-Wno-unused-function']
+
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
     SOURCES += [
         'nsMacUtilsImpl.cpp',
     ]
 elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
     SOURCES += [
         'nsCrashOnException.cpp',
     ]