build on Android with a non-NDK clang

RESOLVED FIXED in Firefox 63

Status

enhancement
RESOLVED FIXED
2 years ago
Last year

People

(Reporter: froydnj, Assigned: froydnj)

Tracking

(Blocks 1 bug)

Trunk
mozilla63
All
Android
Dependency tree / graph

Firefox Tracking Flags

(firefox60 wontfix, firefox61 wontfix, firefox62 wontfix, firefox63 fixed)

Details

Attachments

(1 attachment)

The clang in the NDK works, but we would like to run static analysis on our Android code, and it's unclear whether the NDK clang supports plugins, even on an unofficial basis.  The clang headers are there, so presumably one *can* compile plugins, but it seems like a not-great idea to depend on functionality that's not explicitly supported.

Compiling with our own clang also means one less compiler to test with, which is nice for a variety of reasons.

Using a different clang is a two-line change to a mozconfig, but there are a variety of issues to sort through first.
Depends on: 1435502
Depends on: 1435712
Product: Core → Firefox Build System
This enables us to do things like reliably build the static analysis plugin, as
well as reducing compiler diversity a bit.
Attachment #8979937 - Flags: review?(core-build-config-reviews)
Assignee: nobody → nfroyd
Comment on attachment 8979937 [details] [diff] [review]
use our own clang rather than the NDK clang to build Android

Review of attachment 8979937 [details] [diff] [review]:
-----------------------------------------------------------------

If you're happy with it in try and tests, fine by me.  We can roll back if we see Nightly crashes.
Attachment #8979937 - Flags: review?(core-build-config-reviews) → review+
Nathan, can you land this? this is going to be necessary for LTO on Android.
Flags: needinfo?(nfroyd)
Pushed by nfroyd@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/de5e21062a40
use our own clang rather than the NDK clang to build Android; r=nalexander
(In reply to Mike Hommey [:glandium] from comment #3)
> Nathan, can you land this? this is going to be necessary for LTO on Android.

Done.
Flags: needinfo?(nfroyd)
https://hg.mozilla.org/mozilla-central/rev/de5e21062a40
Status: NEW → RESOLVED
Closed: Last year
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
You need to log in before you can comment on or make changes to this bug.