Closed Bug 1693943 Opened 5 years ago Closed 3 years ago

error message when using `--with-macos-sdk` for artifact builds is ambiguous

Categories

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

defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: bugzilla, Unassigned)

References

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:85.0) Gecko/20100101 Firefox/85.0

Steps to reproduce:

I'm using macOS Big Sur 11.2.1.

Following the instructions at:

https://firefox-source-docs.mozilla.org/setup/macos_build.html

I downloaded the 10.12 SDK, copied it to the correct location, and added:

ac_add_options --with-macos-sdk=$HOME/.mozbuild/macos-sdk/MacOSX10.12.sdk

to mozconfig, as directed in the instructions.

Actual results:

When running ./mach build I got an error saying:

mozbuild.configure.options.InvalidOptionError: --with-macos-sdk is not available in this configuration

I commented out the line from mozconfig and tried again. This time it worked. So... yeah.

Expected results:

Following the setup instructions at:

https://firefox-source-docs.mozilla.org/setup/macos_build.html

should have resulted in a successful build.

If the parts of the setup instructions regarding --with-macos-sdk are outdated, they should be updated or removed.

I initially commented about this on bug #1349228.

According to the response I got on https://bugzilla.mozilla.org/show_bug.cgi?id=1349228, this error is apparently due to the fact that I added --enable-artifact-builds at the suggestion of the build output. I guess I would update my suggestion here to say that whatever message suggested I add that should either note the incompatibility if --with-macos-sdk is present or just not pose itself in the first place. And the error output for InvalidOptionError could stand to be more explanatory in this instance.

To clarify: if the main thing to be changed here is the macOS build-environment setup instructions, it would be useful to have a counterindication for --enable-artifact-builds after the instruction to use --with-macos-sdk, or some other caveat along those lines.

Summary: macos sdk → MacOS SDK says --with-macos-sdk is not available in this configuration
Component: Generated Documentation → General

Mitch has updated the docs in the last month, so --with-macos-sdk is no longer unconditionally recommended. We could still improve the error messaging here.

Priority: -- → P5
Summary: MacOS SDK says --with-macos-sdk is not available in this configuration → error message when using `--with-macos-sdk` for artifact builds is ambiguous

It is non-trivial to find out why a specific option is not available in many cases, including this one.

With :glandium's changes in bug 1522986 the MacOS SDK is now automatically bootstrapped, and there's no longer a reference to the --with-macos-sdk flag in the docs. Given that, I don't think there's anything else left to do here, so I'll be closing this.

Severity: -- → S4
Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
See Also: → 1522986
You need to log in before you can comment on or make changes to this bug.