Closed Bug 1208120 Opened 7 years ago Closed 4 years ago

Move Android Proguard build rules to


(Firefox Build System :: Android Studio and Gradle Integration, defect)

Not set


(firefox44 affected)

Tracking Status
firefox44 --- affected


(Reporter: nalexander, Unassigned)


(Blocks 1 open bug)


Right now we have a single Proguard consumer, ad-hoc in mobile/android/base/  It defines a two-phase Proguard optimization process.  The first phase strips debug information from library JARs; the second phase does the actual optimization (with a variable number of passes).  Each phase utilizes different Proguard .cfg files.

We'd like to simplify the Fennec build, and expose Proguard to the b2gdroid build.

This ticket tracks extracting the relevant definitions and pushing the Make rules into

Bug 709230 added the main phase.  Bug 1106593 added the stripping phase.  Bug 1093218 is relevant.
I propose the following simple ontology:

ANDROID_PROGUARD_JARS = [Path] (maps to -injars)
ANDROID_PROGUARD_LIBRARY_JARS = [Path] (maps to -libraryjars)
ANDROID_PROGUARD_PASSES = Integer (maps to -optimizationpasses)
ANDROID_PROGUARD_CFGS = [Path] (maps to @ arguments)

The library stripping .cfg is not Fennec specific, so we can extract it to a central place and use it for Fennec and b2gdroid.

The tricky things here:
* the two phases;
* multiple inputs mapping to multiple outputs;
* (optional) allowing multiple PG invocations (with ANDROID_PROGUARD_TARGETS or similar).
Summary: Move Proguard build rules to → Move Android Proguard build rules to
We're not going to do this; Proguard is handled by Gradle, and --without-gradle is going to die soon: Bug 1414415.
Closed: 4 years ago
Resolution: --- → WONTFIX
Product: Firefox for Android → Firefox Build System
You need to log in before you can comment on or make changes to this bug.