1#! /bin/bash 2 3export HOST_UID=jogamp 4# jogamp02 - 10.1.0.122 5export HOST_IP=10.1.0.122 6#export HOST_IP=10.1.0.52 7export HOST_RSYNC_ROOT=PROJECTS/JOGL 8 9export TARGET_UID=jogamp 10#export TARGET_IP=panda02 11export TARGET_IP=jautab03 12export TARGET_ADB_PORT=5555 13export TARGET_ROOT=jogamp-test 14 15export BUILD_DIR=../build-android-armv6 16 17if [ -e /opt-linux-x86/android-sdk-linux_x86 ] ; then 18 export ANDROID_HOME=/opt-linux-x86/android-sdk-linux_x86 19 export PATH=$ANDROID_HOME/platform-tools:$PATH 20fi 21 22#TSTCLASS=jogamp.android.launcher.LauncherUtil 23#TSTCLASS=com.jogamp.opengl.test.android.LauncherUtil 24#TSTCLASS=com.jogamp.android.launcher.NEWTLauncherMain 25#TSTCLASS=com.jogamp.nativewindow.NativeWindowVersion 26#TSTCLASS=com.jogamp.opengl.JoglVersion 27#TSTCLASS=com.jogamp.newt.NewtVersion 28#TSTCLASS=com.jogamp.newt.opengl.GLWindow 29#TSTCLASS=com.jogamp.opengl.test.junit.jogl.offscreen.TestOffscreen01GLPBufferNEWT 30#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestGLSLSimple01NEWT 31#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestGLSLShaderState01NEWT 32#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestGLSLShaderState02NEWT 33#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestRulerNEWT01 34#TSTCLASS=com.jogamp.opengl.test.junit.graph.demos.GPUTextNewtDemo01 35#TSTCLASS=com.jogamp.opengl.test.junit.graph.demos.GPUTextNewtDemo02 36#TSTCLASS=com.jogamp.opengl.test.junit.jogl.demos.gl2es1.gears.newt.TestGearsGL2ES1NEWT 37TSTCLASS=com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT 38 39#D_FLAGS="\&newt.debug=all\&jogl.debug=all\&nativewindow.debug=all" 40#D_FLAGS="\&newt.debug=all\&jogl.debug=all" 41#D_FLAGS="\&newt.debug=all" 42 43 44M_FLAGS="\&arg=$TSTCLASS\ 45\&arg=filtertrace=true\ 46\&arg=haltOnError=false\ 47\&arg=haltOnFailure=false\ 48\&arg=showoutput=true\ 49\&arg=outputtoformatters=true\ 50\&arg=logfailedtests=true\ 51\&arg=logtestlistenerevents=true\ 52\&arg=formatter=org.apache.tools.ant.taskdefs.optional.junit.PlainJUnitResultFormatter\ 53\&arg=formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,/sdcard/$TARGET_ROOT/$TSTCLASS.xml\ 54" 55 56LOGFILE=`basename $0 .sh`.log 57 58#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall jogamp.android.launcher 59#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.common 60#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jogamp-android-launcher.apk 61#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/gluegen-rt-android-armeabi.apk 62 63#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.opengl 64#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jar/jogl-all-android-armeabi.apk 65 66#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.opengl.test 67#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jar/jogl-test-android.apk 68 69SHELL_CMD="\ 70cd /sdcard ; \ 71if [ -e $TARGET_ROOT ] ; then rm -r $TARGET_ROOT ; fi ; \ 72mkdir $TARGET_ROOT ; cd $TARGET_ROOT ; \ 73setprop log.redirect-stdio true ; setprop log.redirect-stderr true ; \ 74am kill-all ; \ 75am start -W -S -a android.intent.action.MAIN -n jogamp.android.launcher/jogamp.android.launcher.MainLauncher -d launch://jogamp.org/org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner/?pkg=com.jogamp.opengl.test$D_FLAGS$M_FLAGS \ 76" 77 78adb connect $TARGET_IP:$TARGET_ADB_PORT 79adb -s $TARGET_IP:$TARGET_ADB_PORT logcat -c 80adb -s $TARGET_IP:$TARGET_ADB_PORT shell $SHELL_CMD 2>&1 | tee $LOGFILE 81adb -s $TARGET_IP:$TARGET_ADB_PORT logcat -d 2>&1 | tee -a $LOGFILE 82 83