chroot-test: Clean up linkerconfig's dependencies
Because linkerconfig declares its dependencies as "required", no needs
to list them as make targets in buildbot-build.sh.
Because vndk-related libraries.txt files are now read from relevent vndk
apex, no needs to rename them in chroot according to vndk version.
Bug: 145184886
Bug: 149376737
Bug: 147737840
Test: art/tools/run-gtests.sh
Merged-In: I62c99c99117d6b5c5ab4bf9da8796584061b91ef
Change-Id: I62c99c99117d6b5c5ab4bf9da8796584061b91ef
(cherry picked from commit 69efda0772090bd844ba5200e3be6c0bdf2c8aac)
diff --git a/tools/buildbot-build.sh b/tools/buildbot-build.sh
index 71180a2..17c68f6 100755
--- a/tools/buildbot-build.sh
+++ b/tools/buildbot-build.sh
@@ -83,8 +83,6 @@
# Targets required to generate a linker configuration on device within the
# chroot environment.
make_command+=" linkerconfig"
- make_command+=" llndk.libraries.txt vndksp.libraries.txt vndkcore.libraries.txt"
- make_command+=" vndkprivate.libraries.txt vndkcorevariant.libraries.txt sanitizer.libraries.txt"
# Additional targets needed for the chroot environment.
make_command+=" crash_dump event-log-tags"
fi
diff --git a/tools/buildbot-sync.sh b/tools/buildbot-sync.sh
index 4b5ee86..de83c50 100755
--- a/tools/buildbot-sync.sh
+++ b/tools/buildbot-sync.sh
@@ -110,51 +110,6 @@
# Location of the generated linker configuration file.
ld_generated_config_file_location=$(dirname "$ld_generated_config_file_path")
-# Return the file name passed as argument with the VNDK version of the "host
-# system" inserted before the file name's extension, if applicable. This mimics
-# the logic used in Bionic linker's `Config::get_vndk_version_string`.
-insert_vndk_version_string() {
- local file_path="$1"
- local vndk_version=$(adb shell getprop "ro.vndk.version")
- if [[ -n "$vndk_version" ]] && [[ "$vndk_version" != current ]]; then
- # Insert the VNDK version after the last period (and add another period).
- file_path=$(echo "$file_path" \
- | sed -e "s/^\\(.*\\)\\.\\([^.]\\)/\\1.${vndk_version}.\\2/")
- fi
- echo "$file_path"
-}
-
-# Adjust the names of the following files (sync'd to the device with the
-# previous `adb push` command) depending on the VNDK version of the "host
-# system":
-#
-# /system/etc/llndk.libraries.R.txt
-# /system/etc/vndkcore.libraries.R.txt
-# /system/etc/vndkprivate.libraries.R.txt
-# /system/etc/vndksp.libraries.R.txt
-#
-# Note that `/system/etc/vndkcorevariant.libraries.txt` does not have a version
-# number.
-#
-# See `build/soong/cc/vndk.go` and `packages/modules/vndk/Android.bp` for more
-# information.
-vndk_libraries_txt_file_names="llndk.libraries.txt \
- vndkcore.libraries.txt \
- vndkprivate.libraries.txt \
- vndksp.libraries.txt"
-for file_name in $vndk_libraries_txt_file_names; do
- pattern="$(basename $file_name .txt)\*.txt"
- adb shell find "$ART_TEST_CHROOT/system/etc" -maxdepth 1 -name "$pattern" | \
- while read src_file_name; do
- dst_file_name="$ART_TEST_CHROOT/system/etc/$(insert_vndk_version_string "$file_name")"
- if [[ "$src_file_name" != "$dst_file_name" ]]; then
- echo -e "${green}Renaming VNDK libraries file in chroot environment:" \
- "\`$src_file_name\` -> \`$dst_file_name\`${nc}"
- adb shell mv -f "$src_file_name" "$dst_file_name"
- fi
- done
-done
-
# Generate linker configuration files on device.
echo -e "${green}Generating linker configuration files on device in" \
"\`$ld_generated_config_file_path\`${nc}..."