moz.build 8.18 KB
Newer Older
1
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
2
3
4
5
6
# 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/.

7
include("../components/telemetry/telemetry-constants.mozbuild")
8

9
10
with Files("**"):
    BUG_COMPONENT = ("Toolkit", "General")
11

12
13
with Files("docs/**"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
14

15
16
with Files("subprocess/**"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
17

18
19
with Files("tests/browser/*AsyncPrefs*"):
    BUG_COMPONENT = ("Core", "Security: Process Sandboxing")
20

21
22
with Files("tests/browser/*Finder*"):
    BUG_COMPONENT = ("Toolkit", "Find Toolbar")
23

24
25
with Files("tests/xpcshell/test_Color.js"):
    BUG_COMPONENT = ("Toolkit", "Find Toolbar")
26

27
28
with Files("tests/xpcshell/test_DeferredTask.js"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
29

30
31
with Files("tests/xpcshell/test_FinderIterator.js"):
    BUG_COMPONENT = ("Toolkit", "Find Toolbar")
32

33
34
with Files("tests/xpcshell/test_Integration.js"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
35

36
37
with Files("tests/xpcshell/test_JSONFile.js"):
    BUG_COMPONENT = ("Toolkit", "Form Manager")
38

39
40
with Files("tests/xpcshell/test_Match*.js"):
    BUG_COMPONENT = ("WebExtensions", "General")
41

42
43
with Files("tests/xpcshell/test_NewTabUtils.js"):
    BUG_COMPONENT = ("Firefox", "New Tab Page")
44

45
46
with Files("tests/xpcshell/test_UpdateUtils*.js"):
    BUG_COMPONENT = ("Toolkit", "Application Update")
47

48
49
with Files("AsyncPrefs.jsm"):
    BUG_COMPONENT = ("Core", "Security: Process Sandboxing")
50

51
52
with Files("CharsetMenu.jsm"):
    BUG_COMPONENT = ("Firefox", "Toolbars and Customization")
53

54
55
with Files("Color.jsm"):
    BUG_COMPONENT = ("Toolkit", "Find Toolbar")
56

57
58
with Files("Console.jsm"):
    BUG_COMPONENT = ("DevTools", "Console")
59

60
61
with Files("DateTimePicker*.jsm"):
    BUG_COMPONENT = ("Core", "Layout: Form Controls ")
62

63
64
with Files("DeferredTask.jsm"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
65

66
67
68
with Files("E10SUtils.jsm"):
    BUG_COMPONENT = ("Core", "Security: Process Sandboxing")

69
70
71
with Files("nsIE10SUtils.idl"):
    BUG_COMPONENT = ("Core", "Security: Process Sandboxing")

72
73
with Files("Finder*.jsm"):
    BUG_COMPONENT = ("Toolkit", "Find Toolbar")
74

75
76
with Files("FormLikeFactory.jsm"):
    BUG_COMPONENT = ("Toolkit", "Password Manager")
77

78
79
with Files("IndexedDB.jsm"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
80

81
82
with Files("InlineSpellChecker*.jsm"):
    BUG_COMPONENT = ("Core", "Spelling checker")
83

84
85
with Files("Integration.jsm"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
86

87
88
with Files("JSONFile.jsm"):
    BUG_COMPONENT = ("Toolkit", "Form Manager")
89

90
91
with Files("LightweightThemeConsumer.jsm"):
    BUG_COMPONENT = ("Firefox", "Toolbars and Customization")
92

93
94
with Files("NLP.jsm"):
    BUG_COMPONENT = ("Toolkit", "Find Toolbar")
95

96
97
with Files("NewTabUtils.jsm"):
    BUG_COMPONENT = ("Firefox", "Tabbed Browser")
98

99
100
with Files("ObjectUtils.jsm"):
    BUG_COMPONENT = ("Toolkit", "Telemetry")
101

102
103
104
with Files("offlineAppCache.jsm"):
    BUG_COMPONENT = ("Toolkit", "Preferences")

105
106
with Files("PageMenu.jsm"):
    BUG_COMPONENT = ("Firefox", "Menus")
107

108
109
with Files("PermissionsUtils.jsm"):
    BUG_COMPONENT = ("Toolkit", "Add-ons Manager")
110

111
112
with Files("PopupNotifications.jsm"):
    BUG_COMPONENT = ("Toolkit", "Notifications and Alerts")
113

114
115
with Files("PrivateBrowsingUtils.jsm"):
    BUG_COMPONENT = ("Firefox", "Private Browsing")
116

117
118
with Files("Promise*.jsm"):
    BUG_COMPONENT = ("Toolkit", "Async Tooling")
119

120
121
with Files("ResponsivenessMonitor.jsm"):
    BUG_COMPONENT = ("Firefox", "Migration")
122

123
124
with Files("ShortcutUtils.jsm"):
    BUG_COMPONENT = ("Firefox", "Toolbars and Customization")
125

126
127
with Files("Sqlite.jsm"):
    BUG_COMPONENT = ("Toolkit", "Storage")
128

129
130
131
with Files("SubDialog.jsm"):
    BUG_COMPONENT = ("Toolkit", "Notifications and Alerts")

132
133
with Files("UpdateUtils.jsm"):
    BUG_COMPONENT = ("Toolkit", "Application Update")
134

135
136
with Files("WindowsRegistry.jsm"):
    BUG_COMPONENT = ("Toolkit", "General")
137
138


139
140
141
XPCSHELL_TESTS_MANIFESTS += ["tests/xpcshell/xpcshell.ini"]
BROWSER_CHROME_MANIFESTS += ["tests/browser/browser.ini"]
MOCHITEST_CHROME_MANIFESTS += ["tests/chrome/chrome.ini"]
142

143
TESTING_JS_MODULES += [
144
145
146
147
    "tests/modules/MockDocument.jsm",
    "tests/modules/OSKeyStoreTestUtils.jsm",
    "tests/modules/PromiseTestUtils.jsm",
    "tests/modules/Task.jsm",
148
    "tests/xpcshell/RegionTestUtils.jsm",
149
    "tests/xpcshell/TestIntegration.jsm",
150
151
]

152
SPHINX_TREES["toolkit_modules"] = "docs"
153

154
155
with Files("docs/**"):
    SCHEDULES.exclusive = ["docs"]
156

157
EXTRA_JS_MODULES += [
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
    "AboutPagesUtils.jsm",
    "ActorManagerParent.jsm",
    "AppMenuNotifications.jsm",
    "AsyncPrefs.jsm",
    "BinarySearch.jsm",
    "BrowserUtils.jsm",
    "CanonicalJSON.jsm",
    "CertUtils.jsm",
    "CharsetMenu.jsm",
    "Color.jsm",
    "Console.jsm",
    "ContentDOMReference.jsm",
    "CreditCard.jsm",
    "DateTimePickerPanel.jsm",
    "DeferredTask.jsm",
    "Deprecated.jsm",
    "E10SUtils.jsm",
    "EventEmitter.jsm",
    "FileUtils.jsm",
    "FindBarContent.jsm",
    "Finder.jsm",
    "FinderHighlighter.jsm",
    "FinderIterator.jsm",
    "FinderParent.jsm",
    "FirstStartup.jsm",
    "FormLikeFactory.jsm",
    "Geometry.jsm",
    "HiddenFrame.jsm",
    "Http.jsm",
    "IgnoreLists.jsm",
    "IndexedDB.jsm",
    "InlineSpellChecker.jsm",
    "InlineSpellCheckerContent.jsm",
    "Integration.jsm",
    "JSONFile.jsm",
    "Log.jsm",
    "NewTabUtils.jsm",
    "NLP.jsm",
    "ObjectUtils.jsm",
    "offlineAppCache.jsm",
    "OsEnvironment.jsm",
    "OSKeyStore.jsm",
    "PageMenu.jsm",
    "PermissionsUtils.jsm",
    "PopupNotifications.jsm",
    "Preferences.jsm",
    "PrivateBrowsingUtils.jsm",
    "ProfileAge.jsm",
    "Promise-backend.js",
    "Promise.jsm",
    "PromiseUtils.jsm",
    "Region.jsm",
    "RemotePageAccessManager.jsm",
    "ResetProfile.jsm",
    "ResponsivenessMonitor.jsm",
    "ServiceRequest.jsm",
    "Services.jsm",
    "ShortcutUtils.jsm",
    "Sqlite.jsm",
    "SubDialog.jsm",
    "Timer.jsm",
    "Troubleshoot.jsm",
    "UpdateUtils.jsm",
    "WebChannel.jsm",
222
]
223

224
if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
225
    EXTRA_JS_MODULES += [
226
        "PropertyListUtils.jsm",
227
228
    ]

229
EXTRA_JS_MODULES.third_party.jsesc += ["third_party/jsesc/jsesc.js"]
230
EXTRA_JS_MODULES.sessionstore += [
231
232
233
234
    "sessionstore/PrivacyFilter.jsm",
    "sessionstore/PrivacyLevel.jsm",
    "sessionstore/SessionHistory.jsm",
    "sessionstore/Utils.jsm",
235
]
236

237
EXTRA_JS_MODULES.third_party.fathom += ["third_party/fathom/fathom.jsm"]
238

239
240
if CONFIG["MOZ_WIDGET_TOOLKIT"] in ("windows", "gtk"):
    DEFINES["MENUBAR_CAN_AUTOHIDE"] = 1
241

242
243
if CONFIG["MOZ_WIDGET_TOOLKIT"] in ("windows", "gtk", "cocoa"):
    DEFINES["HAVE_SHELL_SERVICE"] = 1
244

245
EXTRA_PP_JS_MODULES += [
246
    "AppConstants.jsm",
247
248
]

249
if "Android" != CONFIG["OS_TARGET"]:
250
    EXTRA_JS_MODULES += [
251
252
253
254
        "GMPExtractorWorker.js",
        "GMPInstallManager.jsm",
        "GMPUtils.jsm",
        "LightweightThemeConsumer.jsm",
255
    ]
256
257

    DIRS += [
258
        "subprocess",
259
    ]
260
else:
261
    DEFINES["ANDROID"] = True
262
263
264
265
266
    if not CONFIG["TOR_BROWSER_VERSION"]:
        EXTRA_JS_MODULES += [
            "secondscreen/RokuApp.jsm",
            "secondscreen/SimpleServiceDiscovery.jsm",
        ]
267

268

269
if CONFIG["MOZ_WIDGET_TOOLKIT"] == "windows":
270
    EXTRA_JS_MODULES += [
271
        "WindowsRegistry.jsm",
272
273
    ]

274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
for var in (
    "ANDROID_PACKAGE_NAME",
    "MOZ_APP_NAME",
    "MOZ_APP_BASENAME",
    "MOZ_APP_VERSION",
    "MOZ_APP_VERSION_DISPLAY",
    "MOZ_BING_API_CLIENTID",
    "MOZ_BING_API_KEY",
    "MOZ_GOOGLE_LOCATION_SERVICE_API_KEY",
    "MOZ_GOOGLE_SAFEBROWSING_API_KEY",
    "MOZ_MACBUNDLE_NAME",
    "MOZ_MOZILLA_API_KEY",
    "MOZ_WIDGET_TOOLKIT",
    "DLL_PREFIX",
    "DLL_SUFFIX",
    "DEBUG_JS_MODULES",
    "OMNIJAR_NAME",
):
    DEFINES[var] = CONFIG[var]

for var in (
    "MOZ_ALLOW_ADDON_SIDELOAD",
    "MOZ_SYSTEM_NSS",
    "MOZ_UNSIGNED_APP_SCOPE",
    "MOZ_UNSIGNED_SYSTEM_SCOPE",
    "MOZ_UPDATER",
):
301
302
    if CONFIG[var]:
        DEFINES[var] = True
303

304
305
306
if CONFIG["TOR_BROWSER_UPDATE"]:
    DEFINES["TOR_BROWSER_UPDATE"] = 1

307
JAR_MANIFESTS += ["jar.mn"]
308

309
DEFINES["TOPOBJDIR"] = TOPOBJDIR
310
311

XPIDL_SOURCES += [
312
313
314
    "nsIBrowserWindowTracker.idl",
    "nsIE10SUtils.idl",
    "nsIRegion.idl",
315
316
]

317
XPIDL_MODULE = "toolkit_modules"