Build AARs faster

This allows the debug and release AARs to be built individually. 
Previously when you tried to build only one of them (through 
build-aar), both AARs would still be created. Now when you want to 
build only one of them, the Gradle portion of the build will take ~1/2 
the time that it previously did.

These changes also fix the bug where an AAR could be created without 
.so files in it, and the bug where the debug and release AARs would be 
exactly the same (where one overwrote the other).
This commit is contained in:
Rashad Sookram 2022-05-16 14:25:00 -04:00 committed by Jim Gustafson
parent d3e1a0209c
commit a6aab73f5a
2 changed files with 1 additions and 4 deletions
bin
publish/android

View file

@ -331,7 +331,7 @@ def CreateAar(dry_run, extra_gradle_args, version, gradle_dir,
if compile_only is True:
return
gradle_args.append('assemble')
gradle_args.extend(('debug:assembleDebug' if build_type == 'debug' else 'release:assembleRelease' for build_type in build_types))
if install_local is True:
gradle_args.append('installArchives')

View file

@ -1,8 +1,5 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
// Disable the stripping task itself because it can't distinguish between debug/release.
project.gradle.startParameter.excludedTaskNames.add("stripDebugDebugSymbols")
buildscript {
repositories {
jcenter()