Bug 818246 - Part 7: Move XPIDL_MODULE to moz.build; rs=gps
authorMike Shal <mshal@mozilla.com>
Mon, 11 Mar 2013 22:00:00 -0700
changeset 124639 57a08895caccb40e0e0fcb336b8e6ff2713f3cbc
parent 124638 b8f89bbfb7f1d0508107b63b7d1b17458b05bc9d
child 124640 570563fe3824d988ef2f638b31fb6497f0f4fdf4
push id1424
push userprouget@mozilla.com
push dateWed, 13 Mar 2013 17:07:57 +0000
treeherderfx-team@092fcca11bdb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgps
bugs818246
milestone22.0a1
Bug 818246 - Part 7: Move XPIDL_MODULE to moz.build; rs=gps
browser/components/Makefile.in
browser/components/moz.build
config/rules.mk
content/base/public/Makefile.in
content/base/public/moz.build
content/canvas/public/Makefile.in
content/canvas/public/moz.build
content/events/public/Makefile.in
content/events/public/moz.build
content/html/content/public/Makefile.in
content/html/content/public/moz.build
content/html/document/public/Makefile.in
content/html/document/public/moz.build
content/xslt/public/Makefile.in
content/xslt/public/moz.build
dom/activities/interfaces/Makefile.in
dom/activities/interfaces/moz.build
dom/alarm/Makefile.in
dom/alarm/moz.build
dom/audiochannel/Makefile.in
dom/audiochannel/moz.build
dom/battery/Makefile.in
dom/battery/moz.build
dom/bluetooth/Makefile.in
dom/bluetooth/moz.build
dom/browser-element/Makefile.in
dom/browser-element/moz.build
dom/camera/Makefile.in
dom/camera/moz.build
dom/cellbroadcast/interfaces/Makefile.in
dom/cellbroadcast/interfaces/moz.build
dom/cellbroadcast/src/Makefile.in
dom/cellbroadcast/src/moz.build
dom/contacts/Makefile.in
dom/contacts/moz.build
dom/devicestorage/Makefile.in
dom/devicestorage/moz.build
dom/file/Makefile.in
dom/file/moz.build
dom/fm/Makefile.in
dom/fm/moz.build
dom/icc/interfaces/Makefile.in
dom/icc/interfaces/moz.build
dom/indexedDB/Makefile.in
dom/indexedDB/moz.build
dom/interfaces/apps/Makefile.in
dom/interfaces/apps/moz.build
dom/interfaces/base/Makefile.in
dom/interfaces/base/moz.build
dom/interfaces/canvas/Makefile.in
dom/interfaces/canvas/moz.build
dom/interfaces/contacts/Makefile.in
dom/interfaces/contacts/moz.build
dom/interfaces/core/Makefile.in
dom/interfaces/core/moz.build
dom/interfaces/css/Makefile.in
dom/interfaces/css/moz.build
dom/interfaces/devicestorage/Makefile.in
dom/interfaces/devicestorage/moz.build
dom/interfaces/events/Makefile.in
dom/interfaces/events/moz.build
dom/interfaces/geolocation/Makefile.in
dom/interfaces/geolocation/moz.build
dom/interfaces/html/Makefile.in
dom/interfaces/html/moz.build
dom/interfaces/json/Makefile.in
dom/interfaces/json/moz.build
dom/interfaces/notification/Makefile.in
dom/interfaces/notification/moz.build
dom/interfaces/offline/Makefile.in
dom/interfaces/offline/moz.build
dom/interfaces/permission/Makefile.in
dom/interfaces/permission/moz.build
dom/interfaces/range/Makefile.in
dom/interfaces/range/moz.build
dom/interfaces/settings/Makefile.in
dom/interfaces/settings/moz.build
dom/interfaces/sidebar/Makefile.in
dom/interfaces/sidebar/moz.build
dom/interfaces/smil/Makefile.in
dom/interfaces/smil/moz.build
dom/interfaces/storage/Makefile.in
dom/interfaces/storage/moz.build
dom/interfaces/stylesheets/Makefile.in
dom/interfaces/stylesheets/moz.build
dom/interfaces/svg/Makefile.in
dom/interfaces/svg/moz.build
dom/interfaces/traversal/Makefile.in
dom/interfaces/traversal/moz.build
dom/interfaces/xbl/Makefile.in
dom/interfaces/xbl/moz.build
dom/interfaces/xpath/Makefile.in
dom/interfaces/xpath/moz.build
dom/interfaces/xul/Makefile.in
dom/interfaces/xul/moz.build
dom/media/Makefile.in
dom/media/moz.build
dom/messages/interfaces/Makefile.in
dom/messages/interfaces/moz.build
dom/mms/interfaces/Makefile.in
dom/mms/interfaces/moz.build
dom/mobilemessage/interfaces/Makefile.in
dom/mobilemessage/interfaces/moz.build
dom/network/interfaces/Makefile.in
dom/network/interfaces/moz.build
dom/payment/interfaces/Makefile.in
dom/payment/interfaces/moz.build
dom/permission/Makefile.in
dom/permission/moz.build
dom/power/Makefile.in
dom/power/moz.build
dom/quota/Makefile.in
dom/quota/moz.build
dom/system/Makefile.in
dom/system/gonk/Makefile.in
dom/system/gonk/moz.build
dom/system/moz.build
dom/telephony/Makefile.in
dom/telephony/moz.build
dom/time/Makefile.in
dom/time/moz.build
dom/voicemail/Makefile.in
dom/voicemail/moz.build
dom/wifi/Makefile.in
dom/wifi/moz.build
dom/workers/test/extensions/traditional/Makefile.in
dom/workers/test/extensions/traditional/moz.build
embedding/browser/webBrowser/Makefile.in
embedding/browser/webBrowser/moz.build
js/jsd/idl/Makefile.in
js/jsd/idl/moz.build
js/src/config/rules.mk
layout/base/Makefile.in
layout/base/moz.build
layout/forms/Makefile.in
layout/forms/moz.build
layout/printing/Makefile.in
layout/printing/moz.build
layout/xul/base/public/Makefile.in
layout/xul/base/public/moz.build
layout/xul/tree/Makefile.in
layout/xul/tree/moz.build
netwerk/cache/Makefile.in
netwerk/cache/moz.build
netwerk/cookie/Makefile.in
netwerk/cookie/moz.build
netwerk/dns/Makefile.in
netwerk/dns/moz.build
netwerk/ipc/Makefile.in
netwerk/ipc/moz.build
netwerk/protocol/about/Makefile.in
netwerk/protocol/about/moz.build
netwerk/protocol/file/Makefile.in
netwerk/protocol/file/moz.build
netwerk/protocol/ftp/Makefile.in
netwerk/protocol/ftp/moz.build
netwerk/protocol/http/Makefile.in
netwerk/protocol/http/moz.build
netwerk/protocol/res/Makefile.in
netwerk/protocol/res/moz.build
netwerk/protocol/viewsource/Makefile.in
netwerk/protocol/viewsource/moz.build
netwerk/protocol/websocket/Makefile.in
netwerk/protocol/websocket/moz.build
netwerk/protocol/wyciwyg/Makefile.in
netwerk/protocol/wyciwyg/moz.build
netwerk/sctp/datachannel/Makefile.in
netwerk/sctp/datachannel/moz.build
netwerk/sctp/src/Makefile.in
netwerk/sctp/src/moz.build
netwerk/socket/Makefile.in
netwerk/socket/moz.build
netwerk/srtp/src/Makefile.in
netwerk/srtp/src/moz.build
netwerk/streamconv/public/Makefile.in
netwerk/streamconv/public/moz.build
netwerk/wifi/Makefile.in
netwerk/wifi/moz.build
parser/xml/public/Makefile.in
parser/xml/public/moz.build
services/crypto/component/Makefile.in
services/crypto/component/moz.build
toolkit/components/commandlines/Makefile.in
toolkit/components/commandlines/moz.build
toolkit/components/remote/Makefile.in
toolkit/components/remote/moz.build
toolkit/components/startup/public/Makefile.in
toolkit/components/startup/public/moz.build
toolkit/profile/Makefile.in
toolkit/profile/moz.build
widget/android/Makefile.in
widget/android/moz.build
widget/cocoa/Makefile.in
widget/cocoa/moz.build
xpcom/base/Makefile.in
xpcom/base/moz.build
xpcom/components/Makefile.in
xpcom/components/moz.build
xpcom/ds/Makefile.in
xpcom/ds/moz.build
xpcom/io/Makefile.in
xpcom/io/moz.build
xpcom/reflect/xptinfo/public/Makefile.in
xpcom/reflect/xptinfo/public/moz.build
xpcom/system/Makefile.in
xpcom/system/moz.build
xpcom/threads/Makefile.in
xpcom/threads/moz.build
xpfe/components/autocomplete/public/Makefile.in
xpfe/components/autocomplete/public/moz.build
xpfe/components/directory/Makefile.in
xpfe/components/directory/moz.build
xpfe/components/windowds/Makefile.in
xpfe/components/windowds/moz.build
xulrunner/setup/Makefile.in
xulrunner/setup/moz.build
--- a/browser/components/Makefile.in
+++ b/browser/components/Makefile.in
@@ -5,18 +5,16 @@
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = browsercomps
-XPIDL_MODULE = browsercompsbase
-
 EXTRA_COMPONENTS = \
   BrowserComponents.manifest \
   $(NULL)
 
 EXTRA_PP_COMPONENTS = \
   nsBrowserContentHandler.js \
   nsBrowserGlue.js \
   $(NULL)
--- a/browser/components/moz.build
+++ b/browser/components/moz.build
@@ -26,8 +26,10 @@ if CONFIG['MOZ_SAFE_BROWSING']:
 TEST_DIRS += ['test']
 DIRS += ['build']
 
 XPIDL_SOURCES += [
     'nsIBrowserGlue.idl',
     'nsIBrowserHandler.idl',
 ]
 
+XPIDL_MODULE = 'browsercompsbase'
+
--- a/config/rules.mk
+++ b/config/rules.mk
@@ -15,16 +15,17 @@ endif
 # present. If they are, this is a violation of the separation of
 # responsibility between Makefile.in and mozbuild files.
 _MOZBUILD_EXTERNAL_VARIABLES := \
   DIRS \
   PARALLEL_DIRS \
   TEST_DIRS \
   TIERS \
   TOOL_DIRS \
+  XPIDL_MODULE \
   $(NULL)
 
 ifndef EXTERNALLY_MANAGED_MAKE_FILE
 # Using $(firstword) may not be perfect. But it should be good enough for most
 # scenarios.
 _current_makefile = $(CURDIR)/$(firstword $(MAKEFILE_LIST))
 
 $(foreach var,$(_MOZBUILD_EXTERNAL_VARIABLES),$(if $($(var)),\
--- a/content/base/public/Makefile.in
+++ b/content/base/public/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= content
-XPIDL_MODULE	= content_base
 GRE_MODULE	= 1
 
 EXPORTS		= \
 mozFlushType.h \
 nsIContent.h \
 nsIAttribute.h \
 nsIContentIterator.h \
 nsContentPolicyUtils.h \
--- a/content/base/public/moz.build
+++ b/content/base/public/moz.build
@@ -23,8 +23,10 @@ XPIDL_SOURCES += [
     'nsISelection.idl',
     'nsISelectionController.idl',
     'nsISelectionDisplay.idl',
     'nsISelectionListener.idl',
     'nsISelectionPrivate.idl',
     'nsIXMLHttpRequest.idl',
 ]
 
+XPIDL_MODULE = 'content_base'
+
--- a/content/canvas/public/Makefile.in
+++ b/content/canvas/public/Makefile.in
@@ -6,18 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= content
-XPIDL_MODULE = content_canvas
-
 EXPORTS_NAMESPACES = mozilla/ipc
 
 EXPORTS		= \
 		nsICanvasRenderingContextInternal.h \
 		nsICanvasElementExternal.h \
 		$(NULL)
 
 EXPORTS_mozilla/ipc = \
--- a/content/canvas/public/moz.build
+++ b/content/canvas/public/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsICanvasGLPrivate.idl',
 ]
 
+XPIDL_MODULE = 'content_canvas'
+
--- a/content/events/public/Makefile.in
+++ b/content/events/public/Makefile.in
@@ -6,18 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= content
-XPIDL_MODULE	= content_events
-
 EXPORTS		= \
 		nsMutationEvent.h \
 		nsIPrivateTextEvent.h \
 		nsIPrivateTextRange.h \
 		nsAsyncDOMEvent.h \
 		nsEventDispatcher.h \
 		nsEventStates.h \
 		nsEventNameList.h \
--- a/content/events/public/moz.build
+++ b/content/events/public/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIEventListenerService.idl',
 ]
 
+XPIDL_MODULE = 'content_events'
+
--- a/content/html/content/public/Makefile.in
+++ b/content/html/content/public/Makefile.in
@@ -6,18 +6,16 @@
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE       = content
-XPIDL_MODULE = content_html
-
 EXPORTS = \
 		nsIConstraintValidation.h \
 		nsIFormControl.h \
 		nsIForm.h \
 		nsIFormProcessor.h \
 		nsILink.h \
 		nsIRadioVisitor.h \
 		nsIRadioGroupContainer.h \
--- a/content/html/content/public/moz.build
+++ b/content/html/content/public/moz.build
@@ -5,8 +5,10 @@
 
 XPIDL_SOURCES += [
     'nsIFormSubmitObserver.idl',
     'nsIHTMLMenu.idl',
     'nsIMenuBuilder.idl',
     'nsIPhonetic.idl',
 ]
 
+XPIDL_MODULE = 'content_html'
+
--- a/content/html/document/public/Makefile.in
+++ b/content/html/document/public/Makefile.in
@@ -6,11 +6,9 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= content
-XPIDL_MODULE	= content_htmldoc
-
 include $(topsrcdir)/config/rules.mk
--- a/content/html/document/public/moz.build
+++ b/content/html/document/public/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIImageDocument.idl',
 ]
 
+XPIDL_MODULE = 'content_htmldoc'
+
--- a/content/xslt/public/Makefile.in
+++ b/content/xslt/public/Makefile.in
@@ -5,16 +5,14 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE       = content
-XPIDL_MODULE = content_xslt
-
 EXPORTS		= \
 		nsIDocumentTransformer.h \
 		$(NULL)
 
 include $(topsrcdir)/config/rules.mk
 
--- a/content/xslt/public/moz.build
+++ b/content/xslt/public/moz.build
@@ -8,8 +8,10 @@ XPIDL_SOURCES += [
     'nsIXSLTProcessor.idl',
     'nsIXSLTProcessorPrivate.idl',
     'txIEXSLTRegExFunctions.idl',
     'txIFunctionEvaluationContext.idl',
     'txINodeSet.idl',
     'txIXPathObject.idl',
 ]
 
+XPIDL_MODULE = 'content_xslt'
+
--- a/dom/activities/interfaces/Makefile.in
+++ b/dom/activities/interfaces/Makefile.in
@@ -4,17 +4,15 @@
 
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_activities
-
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/base \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/activities/interfaces/moz.build
+++ b/dom/activities/interfaces/moz.build
@@ -8,8 +8,10 @@ XPIDL_SOURCES += [
     'nsIActivityUIGlue.idl',
     'nsIDOMActivity.idl',
     'nsIDOMActivityHandlerDescription.idl',
     'nsIDOMActivityOptions.idl',
     'nsIDOMActivityRequestHandler.idl',
     'nsIDOMNavigatorActivities.idl',
 ]
 
+XPIDL_MODULE = 'dom_activities'
+
--- a/dom/alarm/Makefile.in
+++ b/dom/alarm/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH       = @DEPTH@
 topsrcdir   = @top_srcdir@
 srcdir      = @srcdir@
 VPATH       = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE              = dom
-XPIDL_MODULE        = dom_alarm
 LIBRARY_NAME        = domalarm_s
 LIBXUL_LIBRARY      = 1
 FORCE_STATIC_LIB    = 1
 GRE_MODULE          = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
--- a/dom/alarm/moz.build
+++ b/dom/alarm/moz.build
@@ -5,8 +5,10 @@
 
 TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsIAlarmHalService.idl',
     'nsIDOMAlarmsManager.idl',
 ]
 
+XPIDL_MODULE = 'dom_alarm'
+
--- a/dom/audiochannel/Makefile.in
+++ b/dom/audiochannel/Makefile.in
@@ -16,17 +16,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domaudiochannel_s
-XPIDL_MODULE     = dom_audiochannel
 LIBXUL_LIBRARY = 1
 FORCE_STATIC_LIB = 1
 EXPORT_LIBRARY = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 EXPORTS_NAMESPACES = \
--- a/dom/audiochannel/moz.build
+++ b/dom/audiochannel/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 TEST_TOOL_DIRS += ['tests']
 
 XPIDL_SOURCES += [
     'nsIAudioChannelAgent.idl',
 ]
 
+XPIDL_MODULE = 'dom_audiochannel'
+
--- a/dom/battery/Makefile.in
+++ b/dom/battery/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 LIBRARY_NAME     = dom_battery_s
-XPIDL_MODULE     = dom_battery
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 EXPORTS_NAMESPACES = mozilla/dom/battery
 
--- a/dom/battery/moz.build
+++ b/dom/battery/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsINavigatorBattery.idl',
 ]
 
+XPIDL_MODULE = 'dom_battery'
+
--- a/dom/bluetooth/Makefile.in
+++ b/dom/bluetooth/Makefile.in
@@ -30,17 +30,16 @@ EXPORTS_NAMESPACES = \
 
 EXPORTS_mozilla/dom/bluetooth = BluetoothCommon.h
 EXPORTS_mozilla/dom/bluetooth/ipc = BluetoothMessageUtils.h
 
 ifneq (,$(MOZ_B2G_BT))
 
 MODULE           = dom
 LIBRARY_NAME     = dombluetooth_s
-XPIDL_MODULE     = dom_bluetooth
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 
 CPPSRCS += \
   BluetoothService.cpp \
   BluetoothManager.cpp \
   BluetoothAdapter.cpp \
   BluetoothDevice.cpp \
--- a/dom/bluetooth/moz.build
+++ b/dom/bluetooth/moz.build
@@ -9,16 +9,17 @@
 #
 # Unless required by applicable law or agreed to in writing, software
 # distributed under the License is distributed on an "AS IS" BASIS,
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
 if CONFIG['MOZ_B2G_BT']:
+    XPIDL_MODULE = 'dom_bluetooth'
     XPIDL_SOURCES += [
         'nsIDOMNavigatorBluetooth.idl',
         'nsIDOMBluetoothManager.idl',
         'nsIDOMBluetoothAdapter.idl',
         'nsIDOMBluetoothDevice.idl',
         'nsIDOMBluetoothDeviceEvent.idl',
         'nsIDOMBluetoothDeviceAddressEvent.idl',
     ]
--- a/dom/browser-element/Makefile.in
+++ b/dom/browser-element/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = dom_browserelement_s
-XPIDL_MODULE     = dom_browserelement
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 EXPORTS = \
   nsOpenWindowEventDetail.h \
--- a/dom/browser-element/moz.build
+++ b/dom/browser-element/moz.build
@@ -5,8 +5,10 @@
 
 TEST_DIRS += ['mochitest']
 
 XPIDL_SOURCES += [
     'nsIAsyncScrollEventDetail.idl',
     'nsIOpenWindowEventDetail.idl',
 ]
 
+XPIDL_MODULE = 'dom_browserelement'
+
--- a/dom/camera/Makefile.in
+++ b/dom/camera/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domcamera_s
-XPIDL_MODULE     = dom_camera
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 CPPSRCS = \
   DOMCameraManager.cpp \
--- a/dom/camera/moz.build
+++ b/dom/camera/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMCameraManager.idl',
     'nsIDOMNavigatorCamera.idl',
 ]
 
+XPIDL_MODULE = 'dom_camera'
+
--- a/dom/cellbroadcast/interfaces/Makefile.in
+++ b/dom/cellbroadcast/interfaces/Makefile.in
@@ -4,18 +4,16 @@
 
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_cellbroadcast
-
 include $(topsrcdir)/dom/dom-config.mk
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/base \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
--- a/dom/cellbroadcast/interfaces/moz.build
+++ b/dom/cellbroadcast/interfaces/moz.build
@@ -6,8 +6,10 @@
 XPIDL_SOURCES += [
     'nsICellBroadcastProvider.idl',
     'nsIDOMMozCellBroadcast.idl',
     'nsIDOMMozCellBroadcastEvent.idl',
     'nsIDOMMozCellBroadcastMessage.idl',
     'nsINavigatorCellBroadcast.idl',
 ]
 
+XPIDL_MODULE = 'dom_cellbroadcast'
+
--- a/dom/cellbroadcast/src/Makefile.in
+++ b/dom/cellbroadcast/src/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 LIBRARY_NAME     = dom_cellbroadcast_s
-XPIDL_MODULE     = dom_cellbroadcast
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 EXPORTS_NAMESPACES = mozilla/dom
 
--- a/dom/cellbroadcast/src/moz.build
+++ b/dom/cellbroadcast/src/moz.build
@@ -1,5 +1,7 @@
 # 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/.
 
+XPIDL_MODULE = 'dom_cellbroadcast'
+
--- a/dom/contacts/Makefile.in
+++ b/dom/contacts/Makefile.in
@@ -12,17 +12,16 @@ VPATH            = \
 include $(DEPTH)/config/autoconf.mk
 
 VPATH += $(srcdir)/fallback
 
 MODULE         = dom
 LIBRARY_NAME   = jsdomcontacts_s
 LIBXUL_LIBRARY = 1
 
-XPIDL_MODULE   = dom_contacts
 GRE_MODULE     = 1
 
 EXTRA_COMPONENTS =        \
   ContactManager.js       \
   ContactManager.manifest \
   $(NULL)
 
 EXTRA_JS_MODULES =   \
--- a/dom/contacts/moz.build
+++ b/dom/contacts/moz.build
@@ -1,6 +1,9 @@
 # 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/.
 
 TEST_DIRS += ['tests']
+
+XPIDL_MODULE = 'dom_contacts'
+
--- a/dom/devicestorage/Makefile.in
+++ b/dom/devicestorage/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domdevicestorage_s
-XPIDL_MODULE     = dom_devicestorage
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 include $(topsrcdir)/dom/dom-config.mk
 
--- a/dom/devicestorage/moz.build
+++ b/dom/devicestorage/moz.build
@@ -1,6 +1,9 @@
 # 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/.
 
 TEST_DIRS += ['test', 'ipc']
+
+XPIDL_MODULE = 'dom_devicestorage'
+
--- a/dom/file/Makefile.in
+++ b/dom/file/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domfile_s
-XPIDL_MODULE     = dom_file
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 include $(topsrcdir)/dom/dom-config.mk
 
--- a/dom/file/moz.build
+++ b/dom/file/moz.build
@@ -7,8 +7,10 @@ TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsIDOMArchiveRequest.idl',
     'nsIDOMFileHandle.idl',
     'nsIDOMFileRequest.idl',
     'nsIDOMLockedFile.idl',
 ]
 
+XPIDL_MODULE = 'dom_file'
+
--- a/dom/fm/Makefile.in
+++ b/dom/fm/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = ../..
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domfm_s
-XPIDL_MODULE     = dom_fm
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 CPPSRCS += \
   FMRadio.cpp \
   nsFMRadioSettings.cpp \
--- a/dom/fm/moz.build
+++ b/dom/fm/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMFMRadio.idl',
     'nsIFMRadio.idl',
 ]
 
+XPIDL_MODULE = 'dom_fm'
+
--- a/dom/icc/interfaces/Makefile.in
+++ b/dom/icc/interfaces/Makefile.in
@@ -4,17 +4,15 @@
 
 DEPTH            = ../../..
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_icc
-
 include $(topsrcdir)/dom/dom-config.mk
 
 include $(topsrcdir)/config/rules.mk
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/icc/interfaces/moz.build
+++ b/dom/icc/interfaces/moz.build
@@ -5,8 +5,10 @@
 
 XPIDL_SOURCES += [
     'SimToolKit.idl',
     'nsIDOMICCCardLockErrorEvent.idl',
     'nsIDOMIccManager.idl',
     'nsIIccProvider.idl',
 ]
 
+XPIDL_MODULE = 'dom_icc'
+
--- a/dom/indexedDB/Makefile.in
+++ b/dom/indexedDB/Makefile.in
@@ -6,17 +6,16 @@ DEPTH = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir = @srcdir@
 VPATH = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = dom
 LIBRARY_NAME = dom_indexeddb_s
-XPIDL_MODULE = dom_indexeddb
 LIBXUL_LIBRARY = 1
 FORCE_STATIC_LIB = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 EXPORTS_NAMESPACES = mozilla/dom/indexedDB
 
--- a/dom/indexedDB/moz.build
+++ b/dom/indexedDB/moz.build
@@ -17,8 +17,10 @@ XPIDL_SOURCES += [
     'nsIIDBObjectStore.idl',
     'nsIIDBOpenDBRequest.idl',
     'nsIIDBRequest.idl',
     'nsIIDBTransaction.idl',
     'nsIIDBVersionChangeEvent.idl',
     'nsIIndexedDatabaseManager.idl',
 ]
 
+XPIDL_MODULE = 'dom_indexeddb'
+
--- a/dom/interfaces/apps/Makefile.in
+++ b/dom/interfaces/apps/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_apps
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/interfaces/apps/moz.build
+++ b/dom/interfaces/apps/moz.build
@@ -7,8 +7,10 @@ XPIDL_SOURCES += [
     'mozIApplication.idl',
     'mozIApplicationClearPrivateDataParams.idl',
     'nsIAppsService.idl',
     'nsIDOMApplicationRegistry.idl',
     'nsIDOMApplicationRegistry2.idl',
     'nsIDOMMozApplicationEvent.idl',
 ]
 
+XPIDL_MODULE = 'dom_apps'
+
--- a/dom/interfaces/base/Makefile.in
+++ b/dom/interfaces/base/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_base
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/interfaces/base/moz.build
+++ b/dom/interfaces/base/moz.build
@@ -52,8 +52,10 @@ else:
         'nsIDOMCryptoLegacy.idl',
     ]
 
 if CONFIG['MOZ_B2G']:
     XPIDL_SOURCES += [
         'nsIDOMWindowB2G.idl',
     ]
 
+XPIDL_MODULE = 'dom_base'
+
--- a/dom/interfaces/canvas/Makefile.in
+++ b/dom/interfaces/canvas/Makefile.in
@@ -6,12 +6,11 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_canvas
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
--- a/dom/interfaces/canvas/moz.build
+++ b/dom/interfaces/canvas/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMCanvasRenderingContext2D.idl',
     'nsIDOMWebGLRenderingContext.idl',
 ]
 
+XPIDL_MODULE = 'dom_canvas'
+
--- a/dom/interfaces/contacts/Makefile.in
+++ b/dom/interfaces/contacts/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_contacts
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/interfaces/contacts/moz.build
+++ b/dom/interfaces/contacts/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIDOMContactManager.idl',
     'nsIDOMContactProperties.idl',
     'nsIDOMMozContactChangeEvent.idl',
 ]
 
+XPIDL_MODULE = 'dom_contacts'
+
--- a/dom/interfaces/core/Makefile.in
+++ b/dom/interfaces/core/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_core
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/core/moz.build
+++ b/dom/interfaces/core/moz.build
@@ -22,8 +22,10 @@ XPIDL_SOURCES += [
     'nsIDOMProcessingInstruction.idl',
     'nsIDOMText.idl',
     'nsIDOMUserDataHandler.idl',
     'nsIDOMXMLDocument.idl',
     'nsIDocumentRegister.idl',
     'nsIInlineEventHandlers.idl',
 ]
 
+XPIDL_MODULE = 'dom_core'
+
--- a/dom/interfaces/css/Makefile.in
+++ b/dom/interfaces/css/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_css
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/stylesheets \
   $(NULL)
--- a/dom/interfaces/css/moz.build
+++ b/dom/interfaces/css/moz.build
@@ -24,8 +24,10 @@ XPIDL_SOURCES += [
     'nsIDOMCSSValueList.idl',
     'nsIDOMCounter.idl',
     'nsIDOMElementCSSInlineStyle.idl',
     'nsIDOMMozCSSKeyframeRule.idl',
     'nsIDOMMozCSSKeyframesRule.idl',
     'nsIDOMRect.idl',
 ]
 
+XPIDL_MODULE = 'dom_css'
+
--- a/dom/interfaces/devicestorage/Makefile.in
+++ b/dom/interfaces/devicestorage/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domdevicestorage_s
-XPIDL_MODULE     = dom_devicestorage
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 include $(topsrcdir)/config/rules.mk
 
 
--- a/dom/interfaces/devicestorage/moz.build
+++ b/dom/interfaces/devicestorage/moz.build
@@ -5,8 +5,10 @@
 
 XPIDL_SOURCES += [
     'nsIDOMDeviceStorage.idl',
     'nsIDOMDeviceStorageChangeEvent.idl',
     'nsIDOMDeviceStorageCursor.idl',
     'nsIDOMNavigatorDeviceStorage.idl',
 ]
 
+XPIDL_MODULE = 'dom_devicestorage'
+
--- a/dom/interfaces/events/Makefile.in
+++ b/dom/interfaces/events/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_events
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/events/moz.build
+++ b/dom/interfaces/events/moz.build
@@ -44,8 +44,10 @@ XPIDL_SOURCES += [
     'nsIDOMSmartCardEvent.idl',
     'nsIDOMTouchEvent.idl',
     'nsIDOMTransitionEvent.idl',
     'nsIDOMUIEvent.idl',
     'nsIDOMUserProximityEvent.idl',
     'nsIDOMWheelEvent.idl',
 ]
 
+XPIDL_MODULE = 'dom_events'
+
--- a/dom/interfaces/geolocation/Makefile.in
+++ b/dom/interfaces/geolocation/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_geolocation
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/geolocation/moz.build
+++ b/dom/interfaces/geolocation/moz.build
@@ -9,8 +9,10 @@ XPIDL_SOURCES += [
     'nsIDOMGeoPositionCallback.idl',
     'nsIDOMGeoPositionCoords.idl',
     'nsIDOMGeoPositionError.idl',
     'nsIDOMGeoPositionErrorCallback.idl',
     'nsIDOMNavigatorGeolocation.idl',
     'nsIGeolocation.idl',
 ]
 
+XPIDL_MODULE = 'dom_geolocation'
+
--- a/dom/interfaces/html/Makefile.in
+++ b/dom/interfaces/html/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_html
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/core \
   $(NULL)
--- a/dom/interfaces/html/moz.build
+++ b/dom/interfaces/html/moz.build
@@ -74,8 +74,10 @@ XPIDL_SOURCES += [
     'nsIDOMHTMLVideoElement.idl',
     'nsIDOMMediaError.idl',
     'nsIDOMMozBrowserFrame.idl',
     'nsIDOMTimeRanges.idl',
     'nsIDOMValidityState.idl',
     'nsIMozBrowserFrame.idl',
 ]
 
+XPIDL_MODULE = 'dom_html'
+
--- a/dom/interfaces/json/Makefile.in
+++ b/dom/interfaces/json/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_json
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/json/moz.build
+++ b/dom/interfaces/json/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIJSON.idl',
 ]
 
+XPIDL_MODULE = 'dom_json'
+
--- a/dom/interfaces/notification/Makefile.in
+++ b/dom/interfaces/notification/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_notification
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/notification/moz.build
+++ b/dom/interfaces/notification/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMDesktopNotification.idl',
     'nsIDOMNavigatorDesktopNotification.idl',
 ]
 
+XPIDL_MODULE = 'dom_notification'
+
--- a/dom/interfaces/offline/Makefile.in
+++ b/dom/interfaces/offline/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_offline
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/offline/moz.build
+++ b/dom/interfaces/offline/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMLoadStatus.idl',
     'nsIDOMOfflineResourceList.idl',
 ]
 
+XPIDL_MODULE = 'dom_offline'
+
--- a/dom/interfaces/permission/Makefile.in
+++ b/dom/interfaces/permission/Makefile.in
@@ -5,16 +5,15 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_permissionsettings
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/permission/moz.build
+++ b/dom/interfaces/permission/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMPermissionSettings.idl',
     'nsIPermissionPromptService.idl',
 ]
 
+XPIDL_MODULE = 'dom_permissionsettings'
+
--- a/dom/interfaces/range/Makefile.in
+++ b/dom/interfaces/range/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_range
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/range/moz.build
+++ b/dom/interfaces/range/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMRange.idl',
 ]
 
+XPIDL_MODULE = 'dom_range'
+
--- a/dom/interfaces/settings/Makefile.in
+++ b/dom/interfaces/settings/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_settings
 GRE_MODULE     = 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/interfaces/settings/moz.build
+++ b/dom/interfaces/settings/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIDOMMozSettingsEvent.idl',
     'nsIDOMSettingsManager.idl',
     'nsISettingsService.idl',
 ]
 
+XPIDL_MODULE = 'dom_settings'
+
--- a/dom/interfaces/sidebar/Makefile.in
+++ b/dom/interfaces/sidebar/Makefile.in
@@ -6,12 +6,11 @@
 DEPTH           = @DEPTH@
 topsrcdir       = @top_srcdir@
 srcdir          = @srcdir@
 VPATH           = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE          = dom
-XPIDL_MODULE    = dom_sidebar
 GRE_MODULE      = 1
 
 include $(topsrcdir)/config/rules.mk
--- a/dom/interfaces/sidebar/moz.build
+++ b/dom/interfaces/sidebar/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsISidebar.idl',
     'nsIWebContentHandlerRegistrar.idl',
 ]
 
+XPIDL_MODULE = 'dom_sidebar'
+
--- a/dom/interfaces/smil/Makefile.in
+++ b/dom/interfaces/smil/Makefile.in
@@ -7,18 +7,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_smil
-
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/core \
   -I$(topsrcdir)/dom/interfaces/events \
   -I$(topsrcdir)/dom/interfaces/svg \
   $(NULL)
--- a/dom/interfaces/smil/moz.build
+++ b/dom/interfaces/smil/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMTimeEvent.idl',
 ]
 
+XPIDL_MODULE = 'dom_smil'
+
--- a/dom/interfaces/storage/Makefile.in
+++ b/dom/interfaces/storage/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH          = @DEPTH@
 topsrcdir      = @top_srcdir@
 srcdir         = @srcdir@
 VPATH          = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
-XPIDL_MODULE   = dom_storage
 GRE_MODULE     = 1
 
 EXPORTS =                                      \
        nsPIDOMStorage.h                        \
        $(NULL)
 
 include $(topsrcdir)/config/rules.mk
 
--- a/dom/interfaces/storage/moz.build
+++ b/dom/interfaces/storage/moz.build
@@ -8,8 +8,10 @@ XPIDL_SOURCES += [
     'nsIDOMStorageEvent.idl',
     'nsIDOMStorageIndexedDB.idl',
     'nsIDOMStorageItem.idl',
     'nsIDOMStorageManager.idl',
     'nsIDOMStorageObsolete.idl',
     'nsIDOMToString.idl',
 ]
 
+XPIDL_MODULE = 'dom_storage'
+
--- a/dom/interfaces/stylesheets/Makefile.in
+++ b/dom/interfaces/stylesheets/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_stylesheets
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/stylesheets/moz.build
+++ b/dom/interfaces/stylesheets/moz.build
@@ -5,8 +5,10 @@
 
 XPIDL_SOURCES += [
     'nsIDOMLinkStyle.idl',
     'nsIDOMMediaList.idl',
     'nsIDOMStyleSheet.idl',
     'nsIDOMStyleSheetList.idl',
 ]
 
+XPIDL_MODULE = 'dom_stylesheets'
+
--- a/dom/interfaces/svg/Makefile.in
+++ b/dom/interfaces/svg/Makefile.in
@@ -8,17 +8,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_svg
-
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/core \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/interfaces/svg/moz.build
+++ b/dom/interfaces/svg/moz.build
@@ -19,8 +19,10 @@ XPIDL_SOURCES += [
     'nsIDOMSVGNumber.idl',
     'nsIDOMSVGRect.idl',
     'nsIDOMSVGStringList.idl',
     'nsIDOMSVGURIReference.idl',
     'nsIDOMSVGUnitTypes.idl',
     'nsIDOMSVGZoomEvent.idl',
 ]
 
+XPIDL_MODULE = 'dom_svg'
+
--- a/dom/interfaces/traversal/Makefile.in
+++ b/dom/interfaces/traversal/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_traversal
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/traversal/moz.build
+++ b/dom/interfaces/traversal/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIDOMNodeFilter.idl',
     'nsIDOMNodeIterator.idl',
     'nsIDOMTreeWalker.idl',
 ]
 
+XPIDL_MODULE = 'dom_traversal'
+
--- a/dom/interfaces/xbl/Makefile.in
+++ b/dom/interfaces/xbl/Makefile.in
@@ -6,16 +6,15 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_xbl
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/interfaces/xbl/moz.build
+++ b/dom/interfaces/xbl/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMDocumentXBL.idl',
 ]
 
+XPIDL_MODULE = 'dom_xbl'
+
--- a/dom/interfaces/xpath/Makefile.in
+++ b/dom/interfaces/xpath/Makefile.in
@@ -5,16 +5,14 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_xpath
-
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/core \
   $(NULL)
--- a/dom/interfaces/xpath/moz.build
+++ b/dom/interfaces/xpath/moz.build
@@ -7,8 +7,10 @@ XPIDL_SOURCES += [
     'nsIDOMNSXPathExpression.idl',
     'nsIDOMXPathEvaluator.idl',
     'nsIDOMXPathExpression.idl',
     'nsIDOMXPathNSResolver.idl',
     'nsIDOMXPathNamespace.idl',
     'nsIDOMXPathResult.idl',
 ]
 
+XPIDL_MODULE = 'dom_xpath'
+
--- a/dom/interfaces/xul/Makefile.in
+++ b/dom/interfaces/xul/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= dom
-XPIDL_MODULE	= dom_xul
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/core \
   -I$(topsrcdir)/dom/interfaces/events \
--- a/dom/interfaces/xul/moz.build
+++ b/dom/interfaces/xul/moz.build
@@ -21,8 +21,10 @@ XPIDL_SOURCES += [
     'nsIDOMXULPopupElement.idl',
     'nsIDOMXULRelatedElement.idl',
     'nsIDOMXULSelectCntrlEl.idl',
     'nsIDOMXULSelectCntrlItemEl.idl',
     'nsIDOMXULTextboxElement.idl',
     'nsIDOMXULTreeElement.idl',
 ]
 
+XPIDL_MODULE = 'dom_xul'
+
--- a/dom/media/Makefile.in
+++ b/dom/media/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 relativesrcdir   = @relativesrcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
-XPIDL_MODULE     = dom_media
 LIBRARY_NAME     = dom_media_s
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 include $(topsrcdir)/dom/dom-config.mk
--- a/dom/media/moz.build
+++ b/dom/media/moz.build
@@ -10,8 +10,10 @@ TEST_DIRS += ['tests/mochitest']
 
 XPIDL_SOURCES += [
     'nsIDOMMediaStream.idl',
     'nsIDOMNavigatorUserMedia.idl',
     'nsIDOMRTCPeerConnection.idl',
     'nsIMediaManager.idl',
 ]
 
+XPIDL_MODULE = 'dom_media'
+
--- a/dom/messages/interfaces/Makefile.in
+++ b/dom/messages/interfaces/Makefile.in
@@ -4,17 +4,15 @@
 
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_messages
-
 include $(topsrcdir)/dom/dom-config.mk
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/messages/interfaces/moz.build
+++ b/dom/messages/interfaces/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIDOMNavigatorSystemMessages.idl',
     'nsISystemMessagesInternal.idl',
 ]
 
+XPIDL_MODULE = 'dom_messages'
+
--- a/dom/mms/interfaces/Makefile.in
+++ b/dom/mms/interfaces/Makefile.in
@@ -4,11 +4,9 @@
 
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_mms
-
 include $(topsrcdir)/config/rules.mk
--- a/dom/mms/interfaces/moz.build
+++ b/dom/mms/interfaces/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIMmsService.idl',
     'nsIWapPushApplication.idl',
 ]
 
+XPIDL_MODULE = 'dom_mms'
+
--- a/dom/mobilemessage/interfaces/Makefile.in
+++ b/dom/mobilemessage/interfaces/Makefile.in
@@ -4,18 +4,16 @@
 
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_mobilemessage
-
 include $(topsrcdir)/dom/dom-config.mk
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/base \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
--- a/dom/mobilemessage/interfaces/moz.build
+++ b/dom/mobilemessage/interfaces/moz.build
@@ -17,8 +17,10 @@ XPIDL_SOURCES += [
     'nsISmsService.idl',
 ]
 
 if CONFIG['MOZ_B2G_RIL']:
     XPIDL_SOURCES += [
         'nsIRilMobileMessageDatabaseService.idl',
     ]
 
+XPIDL_MODULE = 'dom_mobilemessage'
+
--- a/dom/network/interfaces/Makefile.in
+++ b/dom/network/interfaces/Makefile.in
@@ -4,18 +4,16 @@
 
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_network
-
 include $(topsrcdir)/dom/dom-config.mk
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   -I$(topsrcdir)/dom/interfaces/events \
   $(NULL)
--- a/dom/network/interfaces/moz.build
+++ b/dom/network/interfaces/moz.build
@@ -18,8 +18,10 @@ if CONFIG['MOZ_B2G_RIL']:
         'nsIDOMMobileConnection.idl',
         'nsIMobileConnectionProvider.idl',
         'nsINavigatorMobileConnection.idl',
         'nsIDOMNetworkStatsManager.idl',
         'nsIDOMNetworkStats.idl',
         'nsIDOMCFStateChangeEvent.idl',
     ]
 
+XPIDL_MODULE = 'dom_network'
+
--- a/dom/payment/interfaces/Makefile.in
+++ b/dom/payment/interfaces/Makefile.in
@@ -4,14 +4,12 @@
 
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
-XPIDL_MODULE = dom_payment
-
 include $(topsrcdir)/config/rules.mk
 XPIDL_FLAGS += \
   -I$(topsrcdir)/dom/interfaces/base \
   $(NULL)
--- a/dom/payment/interfaces/moz.build
+++ b/dom/payment/interfaces/moz.build
@@ -5,8 +5,10 @@
 
 XPIDL_SOURCES += [
     'nsIDOMNavigatorPayment.idl',
     'nsIDOMPaymentRequestInfo.idl',
     'nsIPaymentFlowInfo.idl',
     'nsIPaymentUIGlue.idl',
 ]
 
+XPIDL_MODULE = 'dom_payment'
+
--- a/dom/permission/Makefile.in
+++ b/dom/permission/Makefile.in
@@ -7,17 +7,16 @@ topsrcdir = @top_srcdir@
 srcdir = @srcdir@
 VPATH = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = dom
 LIBRARY_NAME   = jsdompermissionsettings_s
 
-XPIDL_MODULE   = dom_permissionsettings
 GRE_MODULE     = 1
 
 EXTRA_COMPONENTS =        \
   PermissionSettings.js       \
   PermissionSettings.manifest \
   PermissionPromptService.js \
   PermissionPromptService.manifest \
   $(NULL)
--- a/dom/permission/moz.build
+++ b/dom/permission/moz.build
@@ -1,6 +1,9 @@
 # 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/.
 
 TEST_DIRS += ['tests']
+
+XPIDL_MODULE = 'dom_permissionsettings'
+
--- a/dom/power/Makefile.in
+++ b/dom/power/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 LIBRARY_NAME     = dom_power_s
-XPIDL_MODULE     = dom_power
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 include $(topsrcdir)/dom/dom-config.mk
 
--- a/dom/power/moz.build
+++ b/dom/power/moz.build
@@ -7,8 +7,10 @@ TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsIDOMPowerManager.idl',
     'nsIDOMWakeLock.idl',
     'nsIDOMWakeLockListener.idl',
     'nsIPowerManagerService.idl',
 ]
 
+XPIDL_MODULE = 'dom_power'
+
--- a/dom/quota/Makefile.in
+++ b/dom/quota/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = ../..
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domquota_s
-XPIDL_MODULE     = dom_quota
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 EXPORTS_NAMESPACES = mozilla/dom/quota
 
 CPPSRCS = \
--- a/dom/quota/moz.build
+++ b/dom/quota/moz.build
@@ -1,5 +1,7 @@
 # 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/.
 
+XPIDL_MODULE = 'dom_quota'
+
--- a/dom/system/Makefile.in
+++ b/dom/system/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH       = @DEPTH@
 topsrcdir   = @top_srcdir@
 srcdir      = @srcdir@
 VPATH       = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE          = dom
-XPIDL_MODULE    = dom_system
 LIBRARY_NAME    = domsystem_s
 LIBXUL_LIBRARY  = 1
 FAIL_ON_WARNINGS := 1
 
 DEFINES += -DDLL_PREFIX=\"$(DLL_PREFIX)\" -DDLL_SUFFIX=\"$(DLL_SUFFIX)\"
 
 CPPSRCS     = \
   nsDeviceSensors.cpp \
--- a/dom/system/gonk/Makefile.in
+++ b/dom/system/gonk/Makefile.in
@@ -18,17 +18,16 @@ srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 relativesrcdir   = @relativesrcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domsystemgonk_s
-XPIDL_MODULE     = dom_system_gonk
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 CPPSRCS = \
   SystemWorkerManager.cpp \
--- a/dom/system/gonk/moz.build
+++ b/dom/system/gonk/moz.build
@@ -21,8 +21,10 @@ XPIDL_SOURCES += [
     'nsISystemWorkerManager.idl',
     'nsIVolume.idl',
     'nsIVolumeMountLock.idl',
     'nsIVolumeService.idl',
     'nsIVolumeStat.idl',
     'nsIWorkerHolder.idl',
 ]
 
+XPIDL_MODULE = 'dom_system_gonk'
+
--- a/dom/system/moz.build
+++ b/dom/system/moz.build
@@ -16,8 +16,10 @@ if CONFIG['MOZ_B2G_RIL']:
     DIRS += ['gonk']
 
 TEST_DIRS += ['tests']
 
 XPIDL_SOURCES += [
     'nsIOSFileConstantsService.idl',
 ]
 
+XPIDL_MODULE = 'dom_system'
+
--- a/dom/telephony/Makefile.in
+++ b/dom/telephony/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domtelephony_s
-XPIDL_MODULE     = dom_telephony
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 CPPSRCS = \
   Telephony.cpp \
--- a/dom/telephony/moz.build
+++ b/dom/telephony/moz.build
@@ -6,8 +6,10 @@
 XPIDL_SOURCES += [
     'nsIDOMCallEvent.idl',
     'nsIDOMNavigatorTelephony.idl',
     'nsIDOMTelephony.idl',
     'nsIDOMTelephonyCall.idl',
     'nsITelephonyProvider.idl',
 ]
 
+XPIDL_MODULE = 'dom_telephony'
+
--- a/dom/time/Makefile.in
+++ b/dom/time/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = ../..
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = dom_time_s
-XPIDL_MODULE     = dom_time
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS := 1
 endif # !_MSC_VER
 
 include $(topsrcdir)/dom/dom-config.mk
 
--- a/dom/time/moz.build
+++ b/dom/time/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIDOMNavigatorTime.idl',
     'nsIDOMTimeManager.idl',
     'nsITimeService.idl',
 ]
 
+XPIDL_MODULE = 'dom_time'
+
--- a/dom/voicemail/Makefile.in
+++ b/dom/voicemail/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domvoicemail_s
-XPIDL_MODULE     = dom_voicemail
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 EXPORTS_NAMESPACES = mozilla/dom
 EXPORTS_mozilla/dom = \
--- a/dom/voicemail/moz.build
+++ b/dom/voicemail/moz.build
@@ -6,8 +6,10 @@
 XPIDL_SOURCES += [
     'nsIDOMMozVoicemail.idl',
     'nsIDOMMozVoicemailEvent.idl',
     'nsIDOMMozVoicemailStatus.idl',
     'nsINavigatorVoicemail.idl',
     'nsIVoicemailProvider.idl',
 ]
 
+XPIDL_MODULE = 'dom_voicemail'
+
--- a/dom/wifi/Makefile.in
+++ b/dom/wifi/Makefile.in
@@ -6,17 +6,16 @@ DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = dom
 LIBRARY_NAME     = domwifi_s
-XPIDL_MODULE     = dom_wifi
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 
 include $(topsrcdir)/dom/dom-config.mk
 
 EXTRA_COMPONENTS = \
   WifiWorker.js \
   WifiWorker.manifest \
--- a/dom/wifi/moz.build
+++ b/dom/wifi/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIDOMMozWifiConnectionInfoEvent.idl',
     'nsIDOMMozWifiStatusChangeEvent.idl',
     'nsIWifi.idl',
 ]
 
+XPIDL_MODULE = 'dom_wifi'
+
--- a/dom/workers/test/extensions/traditional/Makefile.in
+++ b/dom/workers/test/extensions/traditional/Makefile.in
@@ -5,18 +5,16 @@
 DEPTH            = @DEPTH@
 topsrcdir        = @top_srcdir@
 srcdir           = @srcdir@
 VPATH            = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 XPI_NAME = worker
-XPIDL_MODULE = WorkerTest
-
 EXTRA_COMPONENTS = \
   WorkerTest.js \
   WorkerTest.manifest \
   $(NULL)
 
 DIST_FILES = \
   install.rdf \
   worker.js \
--- a/dom/workers/test/extensions/traditional/moz.build
+++ b/dom/workers/test/extensions/traditional/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIWorkerTest.idl',
 ]
 
+XPIDL_MODULE = 'WorkerTest'
+
--- a/embedding/browser/webBrowser/Makefile.in
+++ b/embedding/browser/webBrowser/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= webbrwsr
-XPIDL_MODULE	= webBrowser_core
 LIBRARY_NAME	= nsWebBrowser_s
 GRE_MODULE	= 1
 LIBXUL_LIBRARY	= 1
 
 
 
 EXPORTS         = \
                 nsCTooltipTextProvider.h \
--- a/embedding/browser/webBrowser/moz.build
+++ b/embedding/browser/webBrowser/moz.build
@@ -23,8 +23,10 @@ XPIDL_SOURCES += [
 
 if CONFIG['NS_PRINTING']:
     XPIDL_SOURCES += [
         'nsIPrintingPrompt.idl',
         'nsIPrintingPromptService.idl',
         'nsIWebBrowserPrint.idl',
     ]
 
+XPIDL_MODULE = 'webBrowser_core'
+
--- a/js/jsd/idl/Makefile.in
+++ b/js/jsd/idl/Makefile.in
@@ -6,11 +6,9 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= jsdebug
-XPIDL_MODULE = jsdservice
-
 include $(topsrcdir)/config/rules.mk
--- a/js/jsd/idl/moz.build
+++ b/js/jsd/idl/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'jsdIDebuggerService.idl',
 ]
 
+XPIDL_MODULE = 'jsdservice'
+
--- a/js/src/config/rules.mk
+++ b/js/src/config/rules.mk
@@ -15,16 +15,17 @@ endif
 # present. If they are, this is a violation of the separation of
 # responsibility between Makefile.in and mozbuild files.
 _MOZBUILD_EXTERNAL_VARIABLES := \
   DIRS \
   PARALLEL_DIRS \
   TEST_DIRS \
   TIERS \
   TOOL_DIRS \
+  XPIDL_MODULE \
   $(NULL)
 
 ifndef EXTERNALLY_MANAGED_MAKE_FILE
 # Using $(firstword) may not be perfect. But it should be good enough for most
 # scenarios.
 _current_makefile = $(CURDIR)/$(firstword $(MAKEFILE_LIST))
 
 $(foreach var,$(_MOZBUILD_EXTERNAL_VARIABLES),$(if $($(var)),\
--- a/layout/base/Makefile.in
+++ b/layout/base/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= layout
-XPIDL_MODULE	= layout_base
 GRE_MODULE	= 1
 LIBRARY_NAME	= gkbase_s
 LIBXUL_LIBRARY	= 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS = 1
 endif # !_MSC_VER
 
 
--- a/layout/base/moz.build
+++ b/layout/base/moz.build
@@ -9,8 +9,10 @@ XPIDL_SOURCES += [
     'nsIStyleSheetService.idl',
 ]
 
 if not CONFIG['MOZ_XUL']:
     XPIDL_SOURCES += [
         'nsIBoxObject.idl',
     ]
 
+XPIDL_MODULE = 'layout_base'
+
--- a/layout/forms/Makefile.in
+++ b/layout/forms/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= layout
-XPIDL_MODULE	= layout_forms
 LIBRARY_NAME	= gkforms_s
 LIBXUL_LIBRARY	= 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS = 1
 endif # !_MSC_VER
 
 EXPORTS		= \
 		nsIListControlFrame.h \
--- a/layout/forms/moz.build
+++ b/layout/forms/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsICapturePicker.idl',
 ]
 
+XPIDL_MODULE = 'layout_forms'
+
--- a/layout/printing/Makefile.in
+++ b/layout/printing/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= layout
-XPIDL_MODULE	= layout_printing
 GRE_MODULE	= 1
 LIBRARY_NAME	= gkprinting_s
 LIBXUL_LIBRARY	= 1
 ifndef _MSC_VER
 FAIL_ON_WARNINGS = 1
 endif # !_MSC_VER
 
 CPPSRCS		= \
--- a/layout/printing/moz.build
+++ b/layout/printing/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIPrintProgress.idl',
     'nsIPrintProgressParams.idl',
     'nsIPrintStatusFeedback.idl',
 ]
 
+XPIDL_MODULE = 'layout_printing'
+
--- a/layout/xul/base/public/Makefile.in
+++ b/layout/xul/base/public/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= layout
-XPIDL_MODULE	= layout_xul
 GRE_MODULE	= 1
 
 EXPORTS		= \
 		nsPIBoxObject.h \
 		nsIScrollbarMediator.h \
 		nsXULPopupManager.h \
 		$(NULL)
 
--- a/layout/xul/base/public/moz.build
+++ b/layout/xul/base/public/moz.build
@@ -11,8 +11,10 @@ XPIDL_SOURCES += [
     'nsIIFrameBoxObject.idl',
     'nsIListBoxObject.idl',
     'nsIMenuBoxObject.idl',
     'nsIPopupBoxObject.idl',
     'nsIScrollBoxObject.idl',
     'nsISliderListener.idl',
 ]
 
+XPIDL_MODULE = 'layout_xul'
+
--- a/layout/xul/tree/Makefile.in
+++ b/layout/xul/tree/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= layout
-XPIDL_MODULE	= layout_xul_tree
 LIBRARY_NAME	= gkxultree_s
 LIBXUL_LIBRARY  = 1
 FAIL_ON_WARNINGS = 1
 
 CPPSRCS		= \
 		nsTreeBodyFrame.cpp \
 		nsTreeBoxObject.cpp \
 		nsTreeColFrame.cpp \
--- a/layout/xul/tree/moz.build
+++ b/layout/xul/tree/moz.build
@@ -6,8 +6,10 @@
 XPIDL_SOURCES += [
     'nsITreeBoxObject.idl',
     'nsITreeColumns.idl',
     'nsITreeContentView.idl',
     'nsITreeSelection.idl',
     'nsITreeView.idl',
 ]
 
+XPIDL_MODULE = 'layout_xul_tree'
+
--- a/netwerk/cache/Makefile.in
+++ b/netwerk/cache/Makefile.in
@@ -8,17 +8,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = nkcache
 LIBRARY_NAME   = nkcache_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_cache
 GRE_MODULE     = 1
 FAIL_ON_WARNINGS := 1
 
 FORCE_STATIC_LIB = 1
 
 EXPORTS = \
   nsCacheService.h \
   nsApplicationCacheService.h \
--- a/netwerk/cache/moz.build
+++ b/netwerk/cache/moz.build
@@ -7,8 +7,10 @@ XPIDL_SOURCES += [
     'nsICache.idl',
     'nsICacheEntryDescriptor.idl',
     'nsICacheListener.idl',
     'nsICacheService.idl',
     'nsICacheSession.idl',
     'nsICacheVisitor.idl',
 ]
 
+XPIDL_MODULE = 'necko_cache'
+
--- a/netwerk/cookie/Makefile.in
+++ b/netwerk/cookie/Makefile.in
@@ -8,17 +8,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 relativesrcdir = @relativesrcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 # export required interfaces, even if --disable-cookies has been given
 MODULE       = necko
-XPIDL_MODULE = necko_cookie
 GRE_MODULE   = 1
 FAIL_ON_WARNINGS := 1
 
 ifdef NECKO_COOKIES
 LIBRARY_NAME     = neckocookie_s
 LIBXUL_LIBRARY   = 1
 FORCE_STATIC_LIB = 1
 CPPSRCS = \
--- a/netwerk/cookie/moz.build
+++ b/netwerk/cookie/moz.build
@@ -7,8 +7,10 @@ XPIDL_SOURCES += [
     'nsICookie.idl',
     'nsICookie2.idl',
     'nsICookieManager.idl',
     'nsICookieManager2.idl',
     'nsICookiePermission.idl',
     'nsICookieService.idl',
 ]
 
+XPIDL_MODULE = 'necko_cookie'
+
--- a/netwerk/dns/Makefile.in
+++ b/netwerk/dns/Makefile.in
@@ -8,17 +8,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = neckodns_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_dns
 GRE_MODULE     = 1
 FAIL_ON_WARNINGS := 1
 
 CPPSRCS = \
   DNS.cpp \
   nsIDNService.cpp \
   nsHostResolver.cpp \
   nsDNSService2.cpp \
--- a/netwerk/dns/moz.build
+++ b/netwerk/dns/moz.build
@@ -7,8 +7,10 @@ XPIDL_SOURCES += [
     'nsIDNSListener.idl',
     'nsIDNSRecord.idl',
     'nsIDNSService.idl',
     'nsIEffectiveTLDService.idl',
     'nsIIDNService.idl',
     'nsPIDNSService.idl',
 ]
 
+XPIDL_MODULE = 'necko_dns'
+
--- a/netwerk/ipc/Makefile.in
+++ b/netwerk/ipc/Makefile.in
@@ -11,18 +11,16 @@ FAIL_ON_WARNINGS := 1
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = necko
 
 LIBRARY_NAME = neckoipc_s
 LIBXUL_LIBRARY = 1
 FORCE_STATIC_LIB = 1
 EXPORT_LIBRARY = 1
-XPIDL_MODULE   = necko_ipc
-
 EXPORTS_NAMESPACES = mozilla/net
 
 EXPORTS_mozilla/net = \
   NeckoParent.h       \
   NeckoChild.h        \
   NeckoCommon.h       \
   NeckoMessageUtils.h \
   ChannelEventQueue.h \
--- a/netwerk/ipc/moz.build
+++ b/netwerk/ipc/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIRemoteOpenFileListener.idl',
 ]
 
+XPIDL_MODULE = 'necko_ipc'
+
--- a/netwerk/protocol/about/Makefile.in
+++ b/netwerk/protocol/about/Makefile.in
@@ -9,17 +9,16 @@ srcdir    = @srcdir@
 VPATH     = @srcdir@
 FAIL_ON_WARNINGS := 1
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkabout_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_about
 GRE_MODULE     = 1
 
 FORCE_STATIC_LIB = 1
 
 EXPORTS = nsAboutProtocolUtils.h
 
 CPPSRCS = \
   nsAboutProtocolHandler.cpp \
--- a/netwerk/protocol/about/moz.build
+++ b/netwerk/protocol/about/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIAboutModule.idl',
 ]
 
+XPIDL_MODULE = 'necko_about'
+
--- a/netwerk/protocol/file/Makefile.in
+++ b/netwerk/protocol/file/Makefile.in
@@ -9,17 +9,16 @@ srcdir    = @srcdir@
 VPATH     = @srcdir@
 FAIL_ON_WARNINGS = 1
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkfile_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_file
 GRE_MODULE     = 1
 
 FORCE_STATIC_LIB = 1
 
 CPPSRCS = \
   nsFileProtocolHandler.cpp \
   nsFileChannel.cpp \
   $(NULL)
--- a/netwerk/protocol/file/moz.build
+++ b/netwerk/protocol/file/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIFileChannel.idl',
     'nsIFileProtocolHandler.idl',
 ]
 
+XPIDL_MODULE = 'necko_file'
+
--- a/netwerk/protocol/ftp/Makefile.in
+++ b/netwerk/protocol/ftp/Makefile.in
@@ -9,17 +9,16 @@ srcdir    = @srcdir@
 VPATH     = @srcdir@
 FAIL_ON_WARNINGS = 1
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkftp_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_ftp
 GRE_MODULE     = 1
 
 FORCE_STATIC_LIB = 1
 
 EXPORTS = ftpCore.h
 
 EXPORTS_NAMESPACES = mozilla/net
 
--- a/netwerk/protocol/ftp/moz.build
+++ b/netwerk/protocol/ftp/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIFTPChannel.idl',
 ]
 
+XPIDL_MODULE = 'necko_ftp'
+
--- a/netwerk/protocol/http/Makefile.in
+++ b/netwerk/protocol/http/Makefile.in
@@ -8,17 +8,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkhttp_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_http
 GRE_MODULE     = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS := 1
 
 EXPORTS_NAMESPACES = mozilla/net
 
 EXPORTS_mozilla/net = \
   HttpBaseChannel.h \
--- a/netwerk/protocol/http/moz.build
+++ b/netwerk/protocol/http/moz.build
@@ -12,8 +12,10 @@ XPIDL_SOURCES += [
     'nsIHttpChannelAuthProvider.idl',
     'nsIHttpChannelChild.idl',
     'nsIHttpChannelInternal.idl',
     'nsIHttpEventSink.idl',
     'nsIHttpHeaderVisitor.idl',
     'nsIHttpProtocolHandler.idl',
 ]
 
+XPIDL_MODULE = 'necko_http'
+
--- a/netwerk/protocol/res/Makefile.in
+++ b/netwerk/protocol/res/Makefile.in
@@ -8,17 +8,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkres_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_res
 GRE_MODULE     = 1
 FAIL_ON_WARNINGS = 1
 
 FORCE_STATIC_LIB = 1
 
 CPPSRCS = \
   nsResProtocolHandler.cpp \
   $(NULL)
--- a/netwerk/protocol/res/moz.build
+++ b/netwerk/protocol/res/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIResProtocolHandler.idl',
 ]
 
+XPIDL_MODULE = 'necko_res'
+
--- a/netwerk/protocol/viewsource/Makefile.in
+++ b/netwerk/protocol/viewsource/Makefile.in
@@ -9,17 +9,16 @@ srcdir    = @srcdir@
 VPATH     = @srcdir@
 FAIL_ON_WARNINGS = 1
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkviewsource_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_viewsource
 GRE_MODULE     = 1
 
 FORCE_STATIC_LIB = 1
 
 CPPSRCS = \
   nsViewSourceHandler.cpp \
   nsViewSourceChannel.cpp \
   $(NULL)
--- a/netwerk/protocol/viewsource/moz.build
+++ b/netwerk/protocol/viewsource/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIViewSourceChannel.idl',
 ]
 
+XPIDL_MODULE = 'necko_viewsource'
+
--- a/netwerk/protocol/websocket/Makefile.in
+++ b/netwerk/protocol/websocket/Makefile.in
@@ -7,17 +7,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkwebsocket_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_websocket
 GRE_MODULE     = 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS = 1
 
 EXPORTS_NAMESPACES = mozilla/net
 
 CPPSRCS = \
   WebSocketChannel.cpp \
--- a/netwerk/protocol/websocket/moz.build
+++ b/netwerk/protocol/websocket/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIWebSocketChannel.idl',
     'nsIWebSocketListener.idl',
 ]
 
+XPIDL_MODULE = 'necko_websocket'
+
--- a/netwerk/protocol/wyciwyg/Makefile.in
+++ b/netwerk/protocol/wyciwyg/Makefile.in
@@ -7,17 +7,16 @@ topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= necko
 LIBRARY_NAME	= nkwyciwyg_s
 LIBXUL_LIBRARY	= 1
-XPIDL_MODULE	= necko_wyciwyg
 GRE_MODULE	= 1
 FORCE_STATIC_LIB = 1
 FAIL_ON_WARNINGS = 1
 
 EXPORTS_NAMESPACES = mozilla/net
 
 EXPORTS_mozilla/net += \
   WyciwygChannelParent.h \
--- a/netwerk/protocol/wyciwyg/moz.build
+++ b/netwerk/protocol/wyciwyg/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIWyciwygChannel.idl',
 ]
 
+XPIDL_MODULE = 'necko_wyciwyg'
+
--- a/netwerk/sctp/datachannel/Makefile.in
+++ b/netwerk/sctp/datachannel/Makefile.in
@@ -8,17 +8,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nkdatachan_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_datachan
 GRE_MODULE     = 1
 FORCE_STATIC_LIB = 1
 
 EXPORTS_NAMESPACES = mozilla/net
 
 CPPSRCS = \
   DataChannel.cpp \
   $(NULL)
--- a/netwerk/sctp/datachannel/moz.build
+++ b/netwerk/sctp/datachannel/moz.build
@@ -1,5 +1,7 @@
 # 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/.
 
+XPIDL_MODULE = 'necko_datachan'
+
--- a/netwerk/sctp/src/Makefile.in
+++ b/netwerk/sctp/src/Makefile.in
@@ -12,17 +12,16 @@ VPATH     = \
   @srcdir@/netinet6 \
   $(NULL)
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = nksctp_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_sctp
 GRE_MODULE     = 1
 FORCE_STATIC_LIB = 1
 
 EXPORTS_NAMESPACES = mozilla/net
 
 XPIDLSRCS = \
   $(NULL)
 
--- a/netwerk/sctp/src/moz.build
+++ b/netwerk/sctp/src/moz.build
@@ -1,5 +1,7 @@
 # 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/.
 
+XPIDL_MODULE = 'necko_sctp'
+
--- a/netwerk/socket/Makefile.in
+++ b/netwerk/socket/Makefile.in
@@ -7,17 +7,16 @@ DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 FAIL_ON_WARNINGS := 1
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
-XPIDL_MODULE   = necko_socket
 LIBRARY_NAME   = neckosocket_s
 LIBXUL_LIBRARY = 1
 
 FORCE_STATIC_LIB = 1
 
 CPPSRCS = \
   nsSocketProviderService.cpp \
   nsSOCKSSocketProvider.cpp \
--- a/netwerk/socket/moz.build
+++ b/netwerk/socket/moz.build
@@ -6,8 +6,10 @@
 XPIDL_SOURCES += [
     'nsISOCKSSocketInfo.idl',
     'nsISSLSocketControl.idl',
     'nsISocketProvider.idl',
     'nsISocketProviderService.idl',
     'nsITransportSecurityInfo.idl',
 ]
 
+XPIDL_MODULE = 'necko_socket'
+
--- a/netwerk/srtp/src/Makefile.in
+++ b/netwerk/srtp/src/Makefile.in
@@ -18,17 +18,16 @@ VPATH = \
   @srcdir@/crypto/rng \
   $(NULL)
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = necko
 LIBRARY_NAME = nksrtp_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE = necko_srtp
 GRE_MODULE = 1
 FORCE_STATIC_LIB = 1
 
 EXPORTS_NAMESPACES = mozilla/net
 
 CSRCS := \
   ekt.c \
   srtp.c \
--- a/netwerk/srtp/src/moz.build
+++ b/netwerk/srtp/src/moz.build
@@ -1,5 +1,7 @@
 # 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/.
 
+XPIDL_MODULE = 'necko_srtp'
+
--- a/netwerk/streamconv/public/Makefile.in
+++ b/netwerk/streamconv/public/Makefile.in
@@ -7,16 +7,15 @@ DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 FAIL_ON_WARNINGS := 1
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= necko
-XPIDL_MODULE	= necko_strconv
 GRE_MODULE	= 1
 
 include $(topsrcdir)/config/rules.mk
 
 DEFINES += -DIMPL_NS_NET
 
 XPIDL_FLAGS += -I$(topsrcdir)/netwerk/base/public
--- a/netwerk/streamconv/public/moz.build
+++ b/netwerk/streamconv/public/moz.build
@@ -12,8 +12,10 @@ XPIDL_SOURCES += [
     'nsITXTToHTMLConv.idl',
 ]
 
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
     XPIDL_SOURCES += [
         'nsIAppleFileDecoder.idl',
     ]
 
+XPIDL_MODULE = 'necko_strconv'
+
--- a/netwerk/wifi/Makefile.in
+++ b/netwerk/wifi/Makefile.in
@@ -7,17 +7,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = necko
 LIBRARY_NAME   = neckowifi_s
 LIBXUL_LIBRARY = 1
-XPIDL_MODULE   = necko_wifi
 GRE_MODULE     = 1
 
 FORCE_STATIC_LIB = 1
 
 ifneq ($(OS_ARCH),Darwin)
 # osx_corewlan.mm has warnings I don't understand.
 FAIL_ON_WARNINGS := 1
 endif
--- a/netwerk/wifi/moz.build
+++ b/netwerk/wifi/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIWifiAccessPoint.idl',
     'nsIWifiListener.idl',
     'nsIWifiMonitor.idl',
 ]
 
+XPIDL_MODULE = 'necko_wifi'
+
--- a/parser/xml/public/Makefile.in
+++ b/parser/xml/public/Makefile.in
@@ -5,11 +5,9 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = xml
-XPIDL_MODULE = saxparser
-
 include $(topsrcdir)/config/rules.mk
--- a/parser/xml/public/moz.build
+++ b/parser/xml/public/moz.build
@@ -11,8 +11,10 @@ XPIDL_SOURCES += [
     'nsISAXErrorHandler.idl',
     'nsISAXLexicalHandler.idl',
     'nsISAXLocator.idl',
     'nsISAXMutableAttributes.idl',
     'nsISAXXMLFilter.idl',
     'nsISAXXMLReader.idl',
 ]
 
+XPIDL_MODULE = 'saxparser'
+
--- a/services/crypto/component/Makefile.in
+++ b/services/crypto/component/Makefile.in
@@ -7,18 +7,16 @@ topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 FAIL_ON_WARNINGS := 1
 
 MODULE := services-crypto
-XPIDL_MODULE := services-crypto-component
-
 LIBRARY_NAME := services-crypto
 EXPORT_LIBRARY := 1
 IS_COMPONENT := 1
 MODULE_NAME := nsServicesCryptoModule
 LIBXUL_LIBRARY := 1
 MOZILLA_INTERNAL_API := 1
 
 CPPSRCS := \
--- a/services/crypto/component/moz.build
+++ b/services/crypto/component/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 TEST_DIRS += ['tests']
 
 XPIDL_SOURCES += [
     'nsISyncJPAKE.idl',
 ]
 
+XPIDL_MODULE = 'services-crypto-component'
+
--- a/toolkit/components/commandlines/Makefile.in
+++ b/toolkit/components/commandlines/Makefile.in
@@ -5,17 +5,16 @@
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = toolkitcomps
-XPIDL_MODULE = commandlines
 LIBRARY_NAME = commandlines
 SHORT_LIBNAME = cmdlines
 EXPORT_LIBRARY = 1
 IS_COMPONENT = 1
 MODULE_NAME = CommandLineModule
 LIBXUL_LIBRARY = 1
 
 CPPSRCS = \
--- a/toolkit/components/commandlines/moz.build
+++ b/toolkit/components/commandlines/moz.build
@@ -7,8 +7,10 @@ TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsICommandLine.idl',
     'nsICommandLineHandler.idl',
     'nsICommandLineRunner.idl',
     'nsICommandLineValidator.idl',
 ]
 
+XPIDL_MODULE = 'commandlines'
+
--- a/toolkit/components/remote/Makefile.in
+++ b/toolkit/components/remote/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE         = toolkitcomps
-XPIDL_MODULE   = toolkitremote
 LIBRARY_NAME	 = remoteservice
 EXPORT_LIBRARY = 1
 IS_COMPONENT   = 1
 MODULE_NAME    = RemoteServiceModule
 
 LIBXUL_LIBRARY = 1
 
 
--- a/toolkit/components/remote/moz.build
+++ b/toolkit/components/remote/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIRemoteService.idl',
 ]
 
+XPIDL_MODULE = 'toolkitremote'
+
--- a/toolkit/components/startup/public/Makefile.in
+++ b/toolkit/components/startup/public/Makefile.in
@@ -7,11 +7,9 @@ topsrcdir  = @top_srcdir@
 srcdir     = @srcdir@
 VPATH      = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 # note: everything depends on appcomps, so to avoid confusion these IDL files are
 # exported there, not toolkitcomps, which would be more logical
 MODULE       = appcomps
-XPIDL_MODULE = appstartup
-
 include $(topsrcdir)/config/rules.mk
--- a/toolkit/components/startup/public/moz.build
+++ b/toolkit/components/startup/public/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIAppStartup.idl',
     'nsIUserInfo.idl',
 ]
 
+XPIDL_MODULE = 'appstartup'
+
--- a/toolkit/profile/Makefile.in
+++ b/toolkit/profile/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir = @srcdir@
 VPATH = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = xulapp
-XPIDL_MODULE = toolkitprofile
 LIBRARY_NAME = profile_s
 FORCE_STATIC_LIB = 1
 LIBXUL_LIBRARY = 1
 
 CPPSRCS = \
   nsProfileLock.cpp \
   nsToolkitProfileService.cpp \
   $(NULL)
--- a/toolkit/profile/moz.build
+++ b/toolkit/profile/moz.build
@@ -6,8 +6,10 @@
 TEST_DIRS += ['test']
 
 XPIDL_SOURCES += [
     'nsIProfileMigrator.idl',
     'nsIToolkitProfile.idl',
     'nsIToolkitProfileService.idl',
 ]
 
+XPIDL_MODULE = 'toolkitprofile'
+
--- a/widget/android/Makefile.in
+++ b/widget/android/Makefile.in
@@ -6,17 +6,16 @@ DEPTH           = @DEPTH@
 topsrcdir       = @top_srcdir@
 srcdir          = @srcdir@
 VPATH           = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE          = widget
 LIBRARY_NAME    = widget_android
-XPIDL_MODULE	= widget_android
 EXPORT_LIBRARY  = 1
 IS_COMPONENT    = 1
 MODULE_NAME     = nsWidgetAndroidModule
 GRE_MODULE      = 1
 LIBXUL_LIBRARY  = 1
 FAIL_ON_WARNINGS := 1
 
 ifdef MOZ_ONLY_TOUCH_EVENTS
--- a/widget/android/moz.build
+++ b/widget/android/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIAndroidBridge.idl',
 ]
 
+XPIDL_MODULE = 'widget_android'
+
--- a/widget/cocoa/Makefile.in
+++ b/widget/cocoa/Makefile.in
@@ -10,17 +10,16 @@ VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= widget
 LIBRARY_NAME	= widget_mac
 EXPORT_LIBRARY	= 1
 IS_COMPONENT	= 1
 MODULE_NAME	= nsWidgetMacModule
-XPIDL_MODULE	= widget_cocoa
 GRE_MODULE	= 1
 LIBXUL_LIBRARY = 1
 
 
 
 EXPORTS = \
 		mozView.h \
 		nsChangeObserver.h \
--- a/widget/cocoa/moz.build
+++ b/widget/cocoa/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsPIWidgetCocoa.idl',
 ]
 
+XPIDL_MODULE = 'widget_cocoa'
+
--- a/xpcom/base/Makefile.in
+++ b/xpcom/base/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= xpcom
-XPIDL_MODULE	= xpcom_base
 LIBRARY_NAME	= xpcombase_s
 GRE_MODULE	= 1
 MOZILLA_INTERNAL_API =1
 LIBXUL_LIBRARY = 1
 
 # TODO: we do this in crashreporter and storage/src too, should be centralized
 ifeq ($(OS_ARCH),Linux)
 DEFINES += -DXP_LINUX
--- a/xpcom/base/moz.build
+++ b/xpcom/base/moz.build
@@ -29,8 +29,10 @@ XPIDL_SOURCES += [
     'nsrootidl.idl',
 ]
 
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
     XPIDL_SOURCES += [
         'nsIMacUtils.idl',
     ]
 
+XPIDL_MODULE = 'xpcom_base'
+
--- a/xpcom/components/Makefile.in
+++ b/xpcom/components/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= xpcom
-XPIDL_MODULE	= xpcom_components
 LIBRARY_NAME	= xpcomcomponents_s
 GRE_MODULE	= 1
 LIBXUL_LIBRARY = 1
 MOZILLA_INTERNAL_API = 1
 
 EXPORTS_NAMESPACES = mozilla
 
 EXPORTS	= \
--- a/xpcom/components/moz.build
+++ b/xpcom/components/moz.build
@@ -8,8 +8,10 @@ XPIDL_SOURCES += [
     'nsIClassInfo.idl',
     'nsIComponentManager.idl',
     'nsIComponentRegistrar.idl',
     'nsIFactory.idl',
     'nsIModule.idl',
     'nsIServiceManager.idl',
 ]
 
+XPIDL_MODULE = 'xpcom_components'
+
--- a/xpcom/ds/Makefile.in
+++ b/xpcom/ds/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= xpcom
-XPIDL_MODULE	= xpcom_ds
 LIBRARY_NAME	= xpcomds_s
 GRE_MODULE	= 1
 LIBXUL_LIBRARY	= 1
 MOZILLA_INTERNAL_API = 1
 
 
 CPPSRCS		= \
 		nsArray.cpp \
--- a/xpcom/ds/moz.build
+++ b/xpcom/ds/moz.build
@@ -30,8 +30,10 @@ XPIDL_SOURCES += [
     'nsIWritablePropertyBag2.idl',
 ]
 
 if CONFIG['OS_ARCH'] == 'WINNT':
     XPIDL_SOURCES += [
         'nsIWindowsRegKey.idl',
     ]
 
+XPIDL_MODULE = 'xpcom_ds'
+
--- a/xpcom/io/Makefile.in
+++ b/xpcom/io/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= xpcom
-XPIDL_MODULE	= xpcom_io
 LIBRARY_NAME	= xpcomio_s
 GRE_MODULE	= 1
 MOZILLA_INTERNAL_API = 1
 LIBXUL_LIBRARY  = 1
 
 # work around bug 408258
 ifdef GNU_CC 
 ifneq ($(OS_ARCH), Darwin)
--- a/xpcom/io/moz.build
+++ b/xpcom/io/moz.build
@@ -41,8 +41,10 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'os2'
     XPIDL_SOURCES += [
         'nsILocalFileOS2.idl',
     ]
 elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
     XPIDL_SOURCES += [
         'nsILocalFileMac.idl',
     ]
 
+XPIDL_MODULE = 'xpcom_io'
+
--- a/xpcom/reflect/xptinfo/public/Makefile.in
+++ b/xpcom/reflect/xptinfo/public/Makefile.in
@@ -7,18 +7,16 @@ DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= xpcom
 
-XPIDL_MODULE = xpcom_xpti
-
 GRE_MODULE	= 1
 
 EXPORTS		= \
 		xptinfo.h \
 		$(NULL)
 
 EXPORTS		:= $(addprefix $(srcdir)/, $(EXPORTS))
 
--- a/xpcom/reflect/xptinfo/public/moz.build
+++ b/xpcom/reflect/xptinfo/public/moz.build
@@ -3,8 +3,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIInterfaceInfo.idl',
     'nsIInterfaceInfoManager.idl',
 ]
 
+XPIDL_MODULE = 'xpcom_xpti'
+
--- a/xpcom/system/Makefile.in
+++ b/xpcom/system/Makefile.in
@@ -5,11 +5,9 @@
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE          = xpcom
-XPIDL_MODULE    = xpcom_system
-
 include $(topsrcdir)/config/rules.mk
--- a/xpcom/system/moz.build
+++ b/xpcom/system/moz.build
@@ -16,8 +16,10 @@ XPIDL_SOURCES += [
     'nsIXULRuntime.idl',
 ]
 
 if CONFIG['MOZ_CRASHREPORTER']:
     XPIDL_SOURCES += [
         'nsICrashReporter.idl',
     ]
 
+XPIDL_MODULE = 'xpcom_system'
+
--- a/xpcom/threads/Makefile.in
+++ b/xpcom/threads/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= xpcom
-XPIDL_MODULE	= xpcom_threads
 LIBRARY_NAME	= xpcomthreads_s
 GRE_MODULE	= 1
 MOZILLA_INTERNAL_API = 1
 LIBXUL_LIBRARY = 1
 
 EXPORTS_NAMESPACES = mozilla
 
 CPPSRCS		= \
--- a/xpcom/threads/moz.build
+++ b/xpcom/threads/moz.build
@@ -12,8 +12,10 @@ XPIDL_SOURCES += [
     'nsISupportsPriority.idl',
     'nsIThread.idl',
     'nsIThreadInternal.idl',
     'nsIThreadManager.idl',
     'nsIThreadPool.idl',
     'nsITimer.idl',
 ]
 
+XPIDL_MODULE = 'xpcom_threads'
+
--- a/xpfe/components/autocomplete/public/Makefile.in
+++ b/xpfe/components/autocomplete/public/Makefile.in
@@ -6,12 +6,10 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= appcomps
-XPIDL_MODULE	= xpautocomplete
-
 include $(topsrcdir)/config/rules.mk
 
--- a/xpfe/components/autocomplete/public/moz.build
+++ b/xpfe/components/autocomplete/public/moz.build
@@ -4,8 +4,10 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 XPIDL_SOURCES += [
     'nsIAutoCompleteListener.idl',
     'nsIAutoCompleteResults.idl',
     'nsIAutoCompleteSession.idl',
 ]
 
+XPIDL_MODULE = 'xpautocomplete'
+
--- a/xpfe/components/directory/Makefile.in
+++ b/xpfe/components/directory/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE		= appcomps
-XPIDL_MODULE	= directory
 LIBRARY_NAME	= directory_s
 LIBXUL_LIBRARY	= 1
 
 CPPSRCS		= nsDirectoryViewer.cpp
 
 # we don't want the shared lib, but we want to force the creation of a
 # static lib.
 FORCE_STATIC_LIB = 1
--- a/xpfe/components/directory/moz.build
+++ b/xpfe/components/directory/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIHTTPIndex.idl',
 ]
 
+XPIDL_MODULE = 'directory'
+
--- a/xpfe/components/windowds/Makefile.in
+++ b/xpfe/components/windowds/Makefile.in
@@ -6,17 +6,16 @@
 DEPTH		= @DEPTH@
 topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE           = appcomps
-XPIDL_MODULE     = windowds
 LIBRARY_NAME     = windowds
 MODULE_NAME      = nsWindowDataSourceModule
 LIBXUL_LIBRARY   = 1
 IS_COMPONENT     = 1
 EXPORT_LIBRARY   = 1
 
 
 CPPSRCS = nsWindowDataSource.cpp
--- a/xpfe/components/windowds/moz.build
+++ b/xpfe/components/windowds/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIWindowDataSource.idl',
 ]
 
+XPIDL_MODULE = 'windowds'
+
--- a/xulrunner/setup/Makefile.in
+++ b/xulrunner/setup/Makefile.in
@@ -5,16 +5,14 @@
 DEPTH     = @DEPTH@
 topsrcdir = @top_srcdir@
 srcdir    = @srcdir@
 VPATH     = @srcdir@
 
 include $(DEPTH)/config/autoconf.mk
 
 MODULE = xulrunner
-XPIDL_MODULE = xulapp_setup
-
 EXTRA_COMPONENTS = nsXULAppInstall.manifest
 EXTRA_PP_COMPONENTS = nsXULAppInstall.js
 
 DEFINES = -DBIN_SUFFIX=$(BIN_SUFFIX)
 
 include $(topsrcdir)/config/rules.mk
--- a/xulrunner/setup/moz.build
+++ b/xulrunner/setup/moz.build
@@ -2,8 +2,10 @@
 # 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/.
 
 XPIDL_SOURCES += [
     'nsIXULAppInstall.idl',
 ]
 
+XPIDL_MODULE = 'xulapp_setup'
+