Google announced the launch of a new Android toolchain, cleverly called "Jack and Jill." Jack stands for Java Android Compiler Kit, and Jill stands for Jack Intermediate Library Linker. See what I mean? Clever, right?
These are the two tools that are the core of the toolchain, which is aimed at improving build times and simplifying application development by reducing dependencies on other tools.
"When the new toolchain is enabled, Jill will translate any libraries you are referencing to a new Jack library file (.jack)," explains Android Developer Programs engineer Paul Rashidi. "This prepares them to be quickly merged with other .jack files. The Android Gradle plugin and Jack collect any .jack library files, along with your source code, and compiles them into a set of dex files. During the process, Jack also handles any requested code minification. The output is then assembled into an APK file as normal. We also include support for multiple dex files, if you have enabled that support."
"We are making the transition to Jack as smooth as possible by supporting minification (shrinking and/or obfuscation), as well as repackaging (i.e. similar to tools like jarjar), while using the same input files as you are used to," says Rashidi. "Minification is available in the Gradle plugin immediately and repackaging will follow. You should continue to use the 'minifyEnabled true' directive to reduce the size of your app among all other optimizations you would normally use."
Google is making an early, experimental version of Jack and Jill available for testing with non-production versions of apps. Jack and Jill are available in the 21.1.1+ Build Tools for Android Studio. Gradle support is available in the Android 1.0.0+ Gradle plugin. As Google notes, you'll want to make sure you're using these versions of the tooling, and then add one line in your build.gradle file. You can perform a build of your app to get a newly built APK. More here.
Image via Google