summaryrefslogtreecommitdiffstats
path: root/make
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-01-19 07:04:56 +0100
committerSven Gothel <[email protected]>2013-01-19 07:04:56 +0100
commit50f997557b91a2f014ef0c2ea848c5c326d0cfb2 (patch)
tree360dcb881196ad517b38d6ab9a694ec1abf10bb3 /make
parent34687193484b2404d83eebf5d008b71d54e52286 (diff)
NEWT/Android: Full Lifecycle for WindowDriver; Using static ViewGroup; AWTRobotUtil: More tolerant for non AWT env.; Fix adb-launch-*
- NEWT/Android WindowDriver - Full Lifecycle, remove refs on closeNative() - Respect isFullscreen() - Using static ViewGroup if available and surface not ready, allows running from main() - AWTRobotUtil: More tolerant for non AWT env. - Check for NEWT first - Only use AWT iff available, which allows running on Android - Fix adb-launch-* - Launch main/junit tests
Diffstat (limited to 'make')
-rw-r--r--make/scripts/adb-launch-junit.sh82
-rw-r--r--make/scripts/adb-launch-main.sh66
-rwxr-xr-xmake/scripts/tests.sh4
3 files changed, 115 insertions, 37 deletions
diff --git a/make/scripts/adb-launch-junit.sh b/make/scripts/adb-launch-junit.sh
new file mode 100644
index 000000000..e53e76456
--- /dev/null
+++ b/make/scripts/adb-launch-junit.sh
@@ -0,0 +1,82 @@
+#! /bin/bash
+
+export HOST_UID=jogamp
+# jogamp02 - 10.1.0.122
+export HOST_IP=10.1.0.122
+#export HOST_IP=10.1.0.52
+export HOST_RSYNC_ROOT=PROJECTS/JOGL
+
+export TARGET_UID=jogamp
+#export TARGET_IP=panda02
+export TARGET_IP=jautab03
+export TARGET_ADB_PORT=5555
+export TARGET_ROOT=jogamp-test
+
+export BUILD_DIR=../build-android-armv6
+
+if [ -e /opt-linux-x86/android-sdk-linux_x86 ] ; then
+ export ANDROID_HOME=/opt-linux-x86/android-sdk-linux_x86
+ export PATH=$ANDROID_HOME/platform-tools:$PATH
+fi
+
+#TSTCLASS=jogamp.android.launcher.LauncherUtil
+#TSTCLASS=com.jogamp.opengl.test.android.LauncherUtil
+#TSTCLASS=com.jogamp.android.launcher.NEWTLauncherMain
+#TSTCLASS=com.jogamp.nativewindow.NativeWindowVersion
+#TSTCLASS=com.jogamp.opengl.JoglVersion
+#TSTCLASS=com.jogamp.newt.NewtVersion
+#TSTCLASS=com.jogamp.newt.opengl.GLWindow
+#TSTCLASS=com.jogamp.opengl.test.junit.jogl.offscreen.TestOffscreen01GLPBufferNEWT
+#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestGLSLSimple01NEWT
+#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestGLSLShaderState01NEWT
+#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestGLSLShaderState02NEWT
+#TSTCLASS=com.jogamp.opengl.test.junit.jogl.glsl.TestRulerNEWT01
+#TSTCLASS=com.jogamp.opengl.test.junit.graph.demos.GPUTextNewtDemo01
+#TSTCLASS=com.jogamp.opengl.test.junit.graph.demos.GPUTextNewtDemo02
+#TSTCLASS=com.jogamp.opengl.test.junit.jogl.demos.gl2es1.gears.newt.TestGearsGL2ES1NEWT
+TSTCLASS=com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT
+
+#D_FLAGS="\&newt.debug=all\&jogl.debug=all\&nativewindow.debug=all"
+#D_FLAGS="\&newt.debug=all\&jogl.debug=all"
+#D_FLAGS="\&newt.debug=all"
+
+
+M_FLAGS="\&arg=$TSTCLASS\
+\&arg=filtertrace=true\
+\&arg=haltOnError=false\
+\&arg=haltOnFailure=false\
+\&arg=showoutput=true\
+\&arg=outputtoformatters=true\
+\&arg=logfailedtests=true\
+\&arg=logtestlistenerevents=true\
+\&arg=formatter=org.apache.tools.ant.taskdefs.optional.junit.PlainJUnitResultFormatter\
+\&arg=formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,/sdcard/$TARGET_ROOT/$TSTCLASS.xml\
+"
+
+LOGFILE=`basename $0 .sh`.log
+
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall jogamp.android.launcher
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.common
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jogamp-android-launcher.apk
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/gluegen-rt-android-armeabi.apk
+
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall javax.media.opengl
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jar/jogl-all-android-armeabi.apk
+
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.opengl.test
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jar/jogl-test-android.apk
+
+SHELL_CMD="\
+cd /sdcard ; \
+if [ -e $TARGET_ROOT ] ; then rm -r $TARGET_ROOT ; fi ; \
+mkdir $TARGET_ROOT ; cd $TARGET_ROOT ; \
+setprop log.redirect-stdio true ; setprop log.redirect-stderr true ; \
+am kill-all ; \
+am 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 \
+"
+
+adb connect $TARGET_IP:$TARGET_ADB_PORT
+adb -s $TARGET_IP:$TARGET_ADB_PORT logcat -c
+adb -s $TARGET_IP:$TARGET_ADB_PORT shell $SHELL_CMD 2>&1 | tee $LOGFILE
+adb -s $TARGET_IP:$TARGET_ADB_PORT logcat -d 2>&1 | tee -a $LOGFILE
+
diff --git a/make/scripts/adb-launch-main.sh b/make/scripts/adb-launch-main.sh
index e40cfeb11..12dcab1e4 100644
--- a/make/scripts/adb-launch-main.sh
+++ b/make/scripts/adb-launch-main.sh
@@ -2,15 +2,15 @@
export HOST_UID=jogamp
# jogamp02 - 10.1.0.122
-#export HOST_IP=10.1.0.122
-export HOST_IP=10.1.0.52
+export HOST_IP=10.1.0.122
+#export HOST_IP=10.1.0.52
export HOST_RSYNC_ROOT=PROJECTS/JOGL
export TARGET_UID=jogamp
#export TARGET_IP=panda02
-export TARGET_IP=jautab01
+export TARGET_IP=jautab03
export TARGET_ADB_PORT=5555
-export TARGET_ROOT=/data/projects
+export TARGET_ROOT=jogamp-test
export BUILD_DIR=../build-android-armv6
@@ -36,42 +36,38 @@ fi
#TSTCLASS=com.jogamp.opengl.test.junit.jogl.demos.gl2es1.gears.newt.TestGearsGL2ES1NEWT
TSTCLASS=com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT
+#D_FLAGS="\&newt.debug=all\&jogl.debug=all\&nativewindow.debug=all"
+#D_FLAGS="\&newt.debug=all\&jogl.debug=all"
+D_FLAGS="\&newt.debug=all"
+
+#Screen: 1280 x 752
+#M_FLAGS="\&arg=-time\&arg=100000\&arg=-width\&arg=1280\&arg=-height\&arg=752"
+M_FLAGS="\&arg=-time\&arg=100000\&arg=-fullscreen"
+
LOGFILE=`basename $0 .sh`.log
-RSYNC_EXCLUDES="--delete-excluded \
- --exclude 'build-x86*/' --exclude 'build-linux*/' --exclude 'build-win*/' --exclude 'build-mac*/' \
- --exclude 'classes/' --exclude 'src/' --exclude '.git/' --exclude '*-java-src.zip' \
- --exclude 'gensrc/' --exclude 'doc/' --exclude 'jnlp-files' --exclude 'archive/' \
- --exclude 'android-sdk/' --exclude 'resources/' --exclude 'scripts/' \
- --exclude 'stub_includes/' --exclude 'nbproject/' --exclude '*.log' --exclude '*.zip' --exclude '*.7z' \
- --exclude 'make/lib/external/'"
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall jogamp.android.launcher
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.common
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jogamp-android-launcher.apk
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/gluegen-rt-android-armeabi.apk
-echo "#! /system/bin/sh" > $BUILD_DIR/jogl-targetcommand.sh
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall javax.media.opengl
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jar/jogl-all-android-armeabi.apk
-echo "\
-rsync -av --delete --delete-after $RSYNC_EXCLUDES \
- $HOST_UID@$HOST_IP::$HOST_RSYNC_ROOT/gluegen \
- $HOST_UID@$HOST_IP::$HOST_RSYNC_ROOT/jogl \
- $TARGET_ROOT ; \
-cd $TARGET_ROOT/jogl/make ;
-export LD_LIBRARY_PATH=/system/lib:$TARGET_ROOT/gluegen/make/$BUILD_DIR/obj:$TARGET_ROOT/jogl/make/$BUILD_DIR/lib ; \
-# export BOOTCLASSPATH=/system/framework/core.jar:/system/framework/bouncycastle.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/android.policy.jar:/system/framework/services.jar ;
-setprop log.redirect-stdio true ; setprop log.redirect-stderr true ; \
-am start -a android.intent.action.MAIN -n jogamp.android.launcher/jogamp.android.launcher.MainLauncher -d launch://jogamp.org/$TSTCLASS/?pkg=com.jogamp.opengl.test\&newt.debug=all\&jogl.debug=all\&nativewindow.debug=all \
-# \
-#dalvikvm \
-# -Xjnigreflimit:2000 \
-# -cp ../../gluegen/make/$BUILD_DIR/jogamp.android-launcher.apk:../../gluegen/make/lib/ant-junit-all.apk:../../gluegen/make/$BUILD_DIR/gluegen-rt-android-armeabi.apk:$BUILD_DIR/jar/jogl.all-android-armeabi.apk:$BUILD_DIR/jar/jogl.test.apk \
-# -Dgluegen.root=../../gluegen \
-# -Drootrel.build=build-android-armv6 \
-# com.android.internal.util.WithFramework \
-# $TSTCLASS \
-" >> $BUILD_DIR/jogl-targetcommand.sh
+#adb -s $TARGET_IP:$TARGET_ADB_PORT uninstall com.jogamp.opengl.test
+#adb -s $TARGET_IP:$TARGET_ADB_PORT install $BUILD_DIR/jar/jogl-test-android.apk
+SHELL_CMD="\
+cd /sdcard ; \
+if [ -e $TARGET_ROOT ] ; then rm -r $TARGET_ROOT ; fi ; \
+mkdir $TARGET_ROOT ; cd $TARGET_ROOT ; \
+setprop log.redirect-stdio true ; setprop log.redirect-stderr true ; \
+am kill-all ; \
+am start -W -S -a android.intent.action.MAIN -n jogamp.android.launcher/jogamp.android.launcher.MainLauncher -d launch://jogamp.org/$TSTCLASS/?pkg=com.jogamp.opengl.test$D_FLAGS$M_FLAGS \
+"
-chmod ugo+x $BUILD_DIR/jogl-targetcommand.sh
adb connect $TARGET_IP:$TARGET_ADB_PORT
-adb -s $TARGET_IP:$TARGET_ADB_PORT push $BUILD_DIR/jogl-targetcommand.sh $TARGET_ROOT/jogl-targetcommand.sh
-adb -s $TARGET_IP:$TARGET_ADB_PORT shell su -c $TARGET_ROOT/jogl-targetcommand.sh 2>&1 | tee $LOGFILE
-
+adb -s $TARGET_IP:$TARGET_ADB_PORT logcat -c
+adb -s $TARGET_IP:$TARGET_ADB_PORT shell $SHELL_CMD 2>&1 | tee $LOGFILE
+adb -s $TARGET_IP:$TARGET_ADB_PORT logcat -d 2>&1 | tee -a $LOGFILE
diff --git a/make/scripts/tests.sh b/make/scripts/tests.sh
index 46e6c63a9..a2cca3211 100755
--- a/make/scripts/tests.sh
+++ b/make/scripts/tests.sh
@@ -279,7 +279,7 @@ function testawtswt() {
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestGLDebug00NEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestGLDebug01NEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestBug669RecursiveGLContext01NEWT $*
-testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestBug669RecursiveGLContext02NEWT $*
+#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestBug669RecursiveGLContext02NEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextListNEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextListNEWT2 $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextVBOES1NEWT $*
@@ -295,7 +295,7 @@ testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestBug669RecursiveGLContext02
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.ect.TestExclusiveContext11VSyncAnimNEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.ect.TestExclusiveContext12FPSAnimNEWT $*
#testawt com.jogamp.opengl.test.junit.jogl.demos.es2.awt.TestGearsES2AWT $*
-#testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $*
+testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestGLAutoDrawableDelegateOnOffscrnCapsNEWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestGLAutoDrawableFactoryOffscrnCapsNEWT $*