summaryrefslogtreecommitdiff
path: root/test/run-test
diff options
context:
space:
mode:
Diffstat (limited to 'test/run-test')
-rwxr-xr-xtest/run-test18
1 files changed, 17 insertions, 1 deletions
diff --git a/test/run-test b/test/run-test
index 27c700e89e..c926c115e2 100755
--- a/test/run-test
+++ b/test/run-test
@@ -90,6 +90,22 @@ fi
export JACK="$JACK -g -cp $JACK_CLASSPATH"
+# Zipalign is not on the PATH in some configs, auto-detect it.
+if [ -z "$ZIPALIGN" ]; then
+ if which zipalign >/dev/null; then
+ ZIPALIGN="zipalign";
+ else
+ # TODO: Add a dependency for zipalign in Android.run-test.mk
+ # once it doesn't depend on libandroidfw (b/35246701)
+ case "$OSTYPE" in
+ darwin*) ZIPALIGN="$ANDROID_BUILD_TOP/prebuilts/sdk/tools/darwin/bin/zipalign" ;;
+ linux*) ZIPALIGN="$ANDROID_BUILD_TOP/prebuilts/sdk/tools/linux/bin/zipalign" ;;
+ *) echo "Can't find zipalign: unknown: $OSTYPE" >&2;;
+ esac
+ fi
+fi
+export ZIPALIGN
+
info="info.txt"
build="build"
run="run"
@@ -495,7 +511,7 @@ elif [ "$runtime" = "art" ]; then
run_args="${run_args} --runtime-option -Djava.library.path=${ANDROID_HOST_OUT}/lib${suffix64}:${ANDROID_HOST_OUT}/nativetest${suffix64}"
else
guess_target_arch_name
- run_args="${run_args} --runtime-option -Djava.library.path=/data/nativetest${suffix64}/art/${target_arch_name}:${android_root}/lib${suffix64}"
+ run_args="${run_args} --runtime-option -Djava.library.path=/data/nativetest${suffix64}/art/${target_arch_name}"
run_args="${run_args} --boot /data/art-test/core${image_suffix}${pic_image_suffix}${multi_image_suffix}.art"
fi
if [ "$relocate" = "yes" ]; then