Closed Bug 1722492 Opened 4 years ago Closed 4 years ago

bootstrap script fails to detect JDK on macOS because /usr/libexec/java_home may return a JRE

Categories

(Firefox Build System :: General, enhancement)

enhancement

Tracking

(firefox92 fixed)

RESOLVED FIXED
92 Branch
Tracking Status
firefox92 --- fixed

People

(Reporter: robwu, Assigned: robwu)

References

Details

Attachments

(1 file)

The logic to detect the JDK at https://searchfox.org/mozilla-central/rev/072710086ddfe25aa2962c8399fefb2304e8193b/python/mozboot/mozboot/util.py#147-179 just picks the default Java runtime, and gives up if it is not a JDK. This logic was introduced in bug 1670264.

We can do better than that, by listing all runtimes and choosing the JDK if any (ignoring JRE).

https://bugzilla.mozilla.org/show_bug.cgi?id=1670264#c21

There's an easy long-term fix here that we briefly discussed earlier: bootstrap should run libexec and parse out the correct JDK.

That was an excellent idea ;)
Patch is up ^ :)

See Also: → 1670264
Pushed by rob@robwu.nl: https://hg.mozilla.org/integration/autoland/rev/e1971f491335 Use JDK on macOS if available r=nalexander
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 92 Branch
Regressions: 1722960
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: