Revert "Install jni symlinks in Soong"

Revert submission 3088867

Reason for revert: On cf_auto build, we are seeing a symlink of jni lib pointing to lib64/libcarservicejni.so, which does not exist on the device.

Reverted changes: /q/submissionid:3088867
Bug: b/341335305

Change-Id: Ie4ff26fe47e1a0ab5e97b185c61cb94473cc5fb8
This commit is contained in:
Yu Shan
2024-05-17 20:09:23 +00:00
parent d5e435d749
commit b7646e4d4f
4 changed files with 167 additions and 22 deletions

View File

@@ -17,6 +17,7 @@ package java
import (
"fmt"
"io"
"strings"
"android/soong/android"
@@ -412,6 +413,23 @@ func (app *AndroidApp) AndroidMkEntries() []android.AndroidMkEntries {
if app.embeddedJniLibs {
jniSymbols := app.JNISymbolsInstalls(app.installPathForJNISymbols.String())
entries.SetString("LOCAL_SOONG_JNI_LIBS_SYMBOLS", jniSymbols.String())
} else {
for _, jniLib := range app.jniLibs {
entries.AddStrings("LOCAL_SOONG_JNI_LIBS_"+jniLib.target.Arch.ArchType.String(), jniLib.name)
var partitionTag string
// Mimic the creation of partition_tag in build/make,
// which defaults to an empty string when the partition is system.
// Otherwise, capitalize with a leading _
if jniLib.partition == "system" {
partitionTag = ""
} else {
split := strings.Split(jniLib.partition, "/")
partitionTag = "_" + strings.ToUpper(split[len(split)-1])
}
entries.AddStrings("LOCAL_SOONG_JNI_LIBS_PARTITION_"+jniLib.target.Arch.ArchType.String(),
jniLib.name+":"+partitionTag)
}
}
if len(app.jniCoverageOutputs) > 0 {