[Android] Fix 'run' action for compile script

Geoffrey Métais git at videolan.org
Thu Mar 31 15:29:59 CEST 2016


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Mar 31 15:28:15 2016 +0200| [1ebdb48b7d74c3c9efaab7c83176a180d7fb36ad] | committer: Geoffrey Métais

Fix 'run' action for compile script

> https://code.videolan.org/videolan/vlc-android/commit/1ebdb48b7d74c3c9efaab7c83176a180d7fb36ad
---

 compile.sh | 13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/compile.sh b/compile.sh
index cb92f27..7505bb6 100755
--- a/compile.sh
+++ b/compile.sh
@@ -202,7 +202,12 @@ if [ "$BUILD_LIBVLC" = 1 ];then
     RUN=0
     CHROME_OS=0
 else
-    TARGET="assemble${PLATFORM}${GRADLE_ABI}${BUILDTYPE}"
+    if [ "$RUN" = 1 ]; then
+        ACTION="install"
+    else
+        ACTION="assemble"
+    fi
+    TARGET="${ACTION}${PLATFORM}${GRADLE_ABI}${BUILDTYPE}"
     PASSWORD_KEYSTORE="$PASSWORD_KEYSTORE" ./gradlew $TARGET
 fi
 
@@ -213,11 +218,9 @@ if [ "$RUN" = 1 ]; then
     export PATH=${ANDROID_SDK}/platform-tools/:$PATH
     adb wait-for-device
     if [ "$RELEASE" = 1 ]; then
-        adb install -r vlc-android/build/outputs/apk/vlc-android-vanilla-release.apk
-        adb shell am start -n org.videolan.vlc/org.videolan.vlc.gui.MainActivity
+        adb shell am start -n org.videolan.vlc/org.videolan.vlc.StartActivity
     else
-        adb install -r vlc-android/build/outputs/apk/vlc-android-vanilla-debug.apk
-        adb shell am start -n org.videolan.vlc.debug/org.videolan.vlc.gui.MainActivity
+        adb shell am start -n org.videolan.vlc.debug/org.videolan.vlc.StartActivity
     fi
 fi
 



More information about the Android mailing list