• Andrew Grieve's avatar
    Android: Simplify GEN_JNI.java generation (no behavior change) · a48308c6
    Andrew Grieve authored
    Rather than generating a different ${Foo}Jni class for every
    target when use_hashed_jni_names=true, also have classes use
    org.chromium.base.natives.GEN_JNI.
    
    Then, at the final step, have GEN_JNI forward calls to J.N.$HASH.
    
    Makes a bit more work for R8 (it needs to inline all the GEN_JNI
    methods), but move the "hashed functions" logic to live in
    one spot at the end of the pipeline.
    
    A byproduct of this is that toggling use_hashed_jni_names no
    long requires all libraries to be recompiled (attached bug)
    
    Bug: 1073921
    Change-Id: I8df7c751b51d60e878f270c06e2e979dd9dbc821
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2162109Reviewed-by: default avatarMichael Thiessen <mthiesse@chromium.org>
    Commit-Queue: Andrew Grieve <agrieve@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#762036}
    a48308c6
rules.gni 186 KB