build(gradle): keep debug symbols in debug variant

Debug ZIPs now ship unstripped native libs sourced from
merged_native_libs instead of stripped_native_libs. Gives
meaningful stack traces for crash debugging on-device.
This commit is contained in:
Enginex0
2026-03-11 00:45:00 +01:00
parent 0280bcf189
commit 9896df93de
+7 -6
View File
@@ -121,8 +121,8 @@ androidComponents {
dependsOn("package${capitalized}")
} else {
dependsOn("minify${capitalized}WithR8")
}
dependsOn("strip${capitalized}DebugSymbols")
}
dependsOn(buildRustCertgen)
if (isDebug) {
@@ -140,12 +140,13 @@ androidComponents {
}
}
from(
project.layout.buildDirectory.dir(
val nativeLibsDir = if (isDebug) {
"intermediates/merged_native_libs/${variant.name}/merge${capitalized}NativeLibs/out/lib"
} else {
"intermediates/stripped_native_libs/${variant.name}/strip${capitalized}DebugSymbols/out/lib"
)
) {
into("lib") // Place them in the 'lib' subfolder of the staging directory.
}
from(project.layout.buildDirectory.dir(nativeLibsDir)) {
into("lib")
include("**/libinject.so", "**/libTEESimulator.so", "**/libsupervisor.so", "**/libcertgen.so")
}