Closed Bug 1368655 Opened 2 years ago Closed 2 years ago

Selecting No when boostrap asks to build stylo downloads clang


(Firefox Build System :: General, defect, P3)



(firefox55 fixed)

Tracking Status
firefox55 --- fixed


(Reporter: past, Assigned: froydnj)


(Blocks 1 open bug)



(1 file)

Launching 'mach bootstrap' on both Windows and macOS and selecting No (2) when asked to about downloading stylo packages, still downloads clang.tar.bz2:

$ mach bootstrap
mach bootstrap is not fully implemented in MozillaBuild

Please choose the version of Firefox you want to build:
1. Firefox for Desktop Artifact Mode
2. Firefox for Desktop
3. Firefox for Android Artifact Mode
4. Firefox for Android

Note on Artifact Mode:

Firefox for Desktop and Android supports a fast build mode called
artifact mode. Artifact mode downloads pre-built C++ components rather
than building them locally, trading bandwidth for time.

Artifact builds will be useful to many developers who are not working
with compiled code. If you want to work on look-and-feel of Firefox,
you want "Firefox for Desktop Artifact Mode".

Similarly, if you want to work on the look-and-feel of Firefox for Android,
you want "Firefox for Android Artifact Mode".

To work on the Gecko technology platform, you would need to opt to full,
non-artifact mode. Gecko is Mozilla's web rendering engine, similar to Edge,
Blink, and WebKit. Gecko is implemented in C++ and JavaScript. If you
want to work on web rendering, you want "Firefox for Desktop", or
"Firefox for Android".

If you don't know what you want, start with just Artifact Mode of the desired
platform. Your builds will be much shorter than if you build Gecko as well.
But don't worry! You can always switch configurations later.

You can learn more about Artifact mode builds at

Your choice: 1
info: updating existing rustup installation

info: component 'rust-std' for target 'i686-pc-windows-msvc' is up to date
Running pip to ensure Mercurial is up-to-date...
Requirement already up-to-date: Mercurial in c:\mozilla-build-3.0pre1\python\lib\site-packages
Your version of Python (2.7.13) is new enough.
Your version of Rust (1.17.0) is new enough.
Rust supports i686-pc-windows-msvc, x86_64-pc-windows-msvc targets.

Stylo is an experimental rewrite of the Gecko style system in Rust to
be faster and make better use of modern computer hardware.

Would you like to download packages for working on Stylo?  If you're
not sure, select "No".

  1. Yes
  2. No

Your choice: 2
 0:00.97 Downloading clang.tar.bz2
 0:00.97 Downloading to temporary location c:\Users\Panagiotis Astithas\.mozbuild\toolchains\44dee70d525ea93952af27f943d1cc773311970c31d971d2bc2e3437cce0c899f3a03ddd8e42e86f1b4fd9ab1c4bc1767cdb0406eb4b3934ae4fc272dab830dc
 0:00.97 Downloaded artifact to c:\Users\Panagiotis Astithas\.mozbuild\toolchains\44dee70d525ea93952af27f943d1cc773311970c31d971d2bc2e3437cce0c899f3a03ddd8e42e86f1b4fd9ab1c4bc1767cdb0406eb4b3934ae4fc272dab830dc
 0:02.33 rm tree: c:\Users\Panagiotis Astithas\.mozbuild\clang
 0:05.24 untarring "c:\Users\Panagiotis Astithas\.mozbuild\clang.tar.bz2"

Your system should be ready to build Firefox for Desktop Artifact Mode!

Paste the lines between the chevrons (>>> and <<<) into your mozconfig file:

# Automatically download and use compiled C++ components:
ac_add_options --enable-artifact-builds
Nathan, do we care that mach bootstrap is downloading clang even when the user selects No? Since Stylo will soon part of the default build configuration, developers will need to download clang eventually. Maybe we should just remove the "Would you like to download packages for working on Stylo?" prompt now instead of fixing the download.
Flags: needinfo?(nfroyd)
Priority: -- → P3
BTW, are we downloading clang even when it's installed locally?
Running bootstrap twice keeps downloading clang, if that is what you mean. Even on macOS with Apple clang installed by default.
(In reply to Chris Peterson [:cpeterson] from comment #1)
> Nathan, do we care that mach bootstrap is downloading clang even when the
> user selects No?

I think we care until Stylo is made mandatory.  Perhaps we want to indicate that the user should add --disable-stylo if they don't download Stylo packages, too.
Flags: needinfo?(nfroyd)
Might as well fix this.
Attachment #8873540 - Flags: review?(giles)
Assignee: nobody → nfroyd
Comment on attachment 8873540 [details] [diff] [review]
only download Stylo packages if the user wanted Stylo

Review of attachment 8873540 [details] [diff] [review]:

I think there's also some confusion in that it says it's downloading when it's really checking the cache.
Attachment #8873540 - Flags: review?(giles) → review+
Pushed by
only download Stylo packages if the user wanted Stylo; r=rillian
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.