Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.

Commit 571f8f5

Browse files
committed
Bug 1690712 - Allow --enable-bootstrap in all configurations. r=firefox-build-system-reviewers,mhentges
And make it prioritize the bootstrap directory over system paths. Differential Revision: https://phabricator.services.mozilla.com/D103981
1 parent faaf1bb commit 571f8f5

File tree

1 file changed

+18
-12
lines changed

1 file changed

+18
-12
lines changed

moz.configure

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -208,12 +208,27 @@ def moz_fetches_dir(value):
208208
return value[0]
209209

210210

211-
@depends(developer_options, moz_fetches_dir)
212-
def bootstrap_search_path_order(developer_options, moz_fetches_dir):
211+
option(
212+
"--enable-bootstrap",
213+
nargs="?",
214+
choices=("install", "update"),
215+
help="Automatically update/bootstrap some toolchains when they are present but out of date",
216+
)
217+
218+
219+
@depends(developer_options, "--enable-bootstrap", moz_fetches_dir)
220+
def bootstrap_search_path_order(developer_options, bootstrap, moz_fetches_dir):
213221
if moz_fetches_dir:
214222
log.debug("Prioritizing MOZ_FETCHES_DIR in toolchain path.")
215223
return "prepend"
216224

225+
if bootstrap:
226+
log.debug(
227+
"Prioritizing mozbuild state dir in toolchain paths because "
228+
"bootstrap mode is enabled."
229+
)
230+
return "prepend"
231+
217232
if developer_options:
218233
log.debug(
219234
"Prioritizing mozbuild state dir in toolchain paths because "
@@ -239,16 +254,7 @@ def original_path():
239254
return environ["PATH"].split(os.pathsep)
240255

241256

242-
option(
243-
"--enable-bootstrap",
244-
nargs="?",
245-
choices=("install", "update"),
246-
when=developer_options,
247-
help="Automatically update/bootstrap some toolchains when they are present but out of date",
248-
)
249-
250-
251-
@depends("--enable-bootstrap", when=developer_options)
257+
@depends("--enable-bootstrap")
252258
def bootstrap(value):
253259
if value:
254260
# value here is either an empty tuple, or a tuple containing either

0 commit comments

Comments
 (0)