From eb441dd9a3e78c00900bad57e93e464ad70d22b3 Mon Sep 17 00:00:00 2001 From: Nicolas Geoffray Date: Fri, 31 Oct 2014 15:34:50 +0000 Subject: [PATCH] Fix armv8 testing with default ANDROID_ROOT. Change-Id: I68ac57240783822972a3f49dd54de01ef60e637d --- test/etc/run-test-jar | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/test/etc/run-test-jar b/test/etc/run-test-jar index 39f28c877..9ecc885a6 100755 --- a/test/etc/run-test-jar +++ b/test/etc/run-test-jar @@ -305,6 +305,14 @@ if [ "$HOST" = "n" ]; then adb push $TEST_NAME-ex.jar $DEX_LOCATION >/dev/null 2>&1 fi + LD_LIBRARY_PATH= + if [ "$ANDROID_ROOT" != "/system" ]; then + # Current default installation is dalvikvm 64bits and dex2oat 32bits, + # so we can only use LD_LIBRARY_PATH when testing on a local + # installation. + LD_LIBRARY_PATH=$ANDROID_ROOT/$LIBRARY_DIRECTORY + fi + # Create a script with the command. The command can get longer than the longest # allowed adb command and there is no way to get the exit status from a adb shell # command. @@ -312,7 +320,7 @@ if [ "$HOST" = "n" ]; then export ANDROID_DATA=$DEX_LOCATION && \ export DEX_LOCATION=$DEX_LOCATION && \ export ANDROID_ROOT=$ANDROID_ROOT && \ - export LD_LIBRARY_PATH=$ANDROID_ROOT/$LIBRARY_DIRECTORY && \ + export LD_LIBRARY_PATH=$LD_LIBRARY_PATH && \ $mkdir_cmdline && \ $dex2oat_cmdline && \ $dalvikvm_cmdline" -- 2.11.0