Skip to content

doc: Minor details to documentation for building A-S#7477

Merged
thesuzerain merged 3 commits into
mainfrom
building-doc-troubleshooting-macos
Jul 16, 2026
Merged

doc: Minor details to documentation for building A-S#7477
thesuzerain merged 3 commits into
mainfrom
building-doc-troubleshooting-macos

Conversation

@thesuzerain

@thesuzerain thesuzerain commented Jul 15, 2026

Copy link
Copy Markdown
Collaborator

This PR makes no changes aside from minor documentation additions for setup, so doesn't need changelog updates or any breaking changes (or changes at all for that matter).

Pull Request checklist

  • Breaking changes: This PR follows our breaking change policy
    • This PR follows the breaking change policy:
      • This PR has no breaking API changes, or
      • There are corresponding PRs for our consumer applications that resolve the breaking changes and have been approved
  • Quality: This PR builds and tests run cleanly
    • Note:
      • For changes that need extra cross-platform testing, consider adding [ci full] to the PR title.
      • If this pull request includes a breaking change, consider cutting a new release after merging.
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Changelog: This PR includes a changelog entry in CHANGELOG.md or an explanation of why it does not need one
    • Any breaking changes to Swift or Kotlin binding APIs are noted explicitly
  • Dependencies: This PR follows our dependency management guidelines
    • Any new dependencies are accompanied by a summary of the due diligence applied in selecting them.

Comment thread docs/building.md
```shell
export ANDROID_HOME=~/.mozbuild/android-sdk-linux
export ANDROID_SDK_ROOT=~/.mozbuild/android-sdk-linux
```

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not actually totally sure if the ANDROID_SDK_ROOT set is necessary here, but a later step here describes it being set here and it's not mentioned elsewhere on the page.

In the codebase I don't see any other uses of ANDROID_SDK_ROOT (aside from documentation or CI setting it) so I assume its deprecated/unused. If so, I can instead adjust the other step to remove the reference to this.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I never set ANDROID_SDK_ROOT just ANDROID_HOME. How about removing the reference from that other doc rather than adding one here?

@thesuzerain
thesuzerain marked this pull request as ready for review July 15, 2026 21:28

@bendk bendk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great, thanks for keeping these fresh. I had a couple suggestions, but feel free to push back on any/all of them.

Comment thread docs/building.md Outdated
1. Recent brew installations of Python do not contain a `python`/`pip` symlink. You may be able to run the following to create them:
```shell
brew uninstall python3
brew install python3

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the recent installations don't contain pip then how does uninstalling and re-installing fix it? I don't doubt that this works, I'm just curious why since I'm not a brew user.

@thesuzerain thesuzerain Jul 16, 2026

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm actually a little bit surprised it worked as well. I had assumed it was because of brew install python vs brew install python3, but on checking now, these are aliases. The reinstallation step in particular is noted here. it worked perfectly for me, but on reflection here it's unclear why- I have a couple thoughts but I'm unsure so I'll make a note and examine them later.

The source issue about the symlinks is pretty clear, though, and brew info python shows the intended symlinks, so for now I've changed my comment to give a better + more idiomatic solution more in line with what brew intends.

Comment thread docs/building.md
1. More recent version of Python (3.12+) have deprecated `distutils`, a dependency of the above script. If you encounter a ModuleNotFoundError, you can run first:
```shell
brew install python-setuptools
```

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm pretty sure I've seen this same issue, how about making this a bit more generic? I'm thinking something like "If you encounter a ModuleNotFoundError, then install setuptools on your system (for example brew install python-setuptools)"

Comment thread docs/building.md
```shell
export ANDROID_HOME=~/.mozbuild/android-sdk-linux
export ANDROID_SDK_ROOT=~/.mozbuild/android-sdk-linux
```

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I never set ANDROID_SDK_ROOT just ANDROID_HOME. How about removing the reference from that other doc rather than adding one here?

```bash
rm ../firefox-ios/MozillaRustComponents/Sources/MozillaRustComponentsWrapper/Generated/glean_sym.swift
```

@thesuzerain thesuzerain Jul 16, 2026

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've added this step per recent discussion. We could also the cp and rm in one command with something like:

find /some/folder -maxdepth 1 -name '*.swift' ! -name 'glean_sym.swift' -exec cp {} /other/folder/ \; but I like the clarity of separating them. Let me know what you think, I'm not tied to it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, I like this way of presenting it better as well.

@thesuzerain
thesuzerain requested a review from bendk July 16, 2026 17:15

@bendk bendk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, I think we're ready to merge this.

```bash
rm ../firefox-ios/MozillaRustComponents/Sources/MozillaRustComponentsWrapper/Generated/glean_sym.swift
```

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, I like this way of presenting it better as well.

Comment thread docs/building.md Outdated
Co-authored-by: bendk <bdk@mozilla.com>
@thesuzerain
thesuzerain added this pull request to the merge queue Jul 16, 2026
Merged via the queue into main with commit ed13f60 Jul 16, 2026
14 checks passed
@thesuzerain
thesuzerain deleted the building-doc-troubleshooting-macos branch July 16, 2026 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants