diff options
Diffstat (limited to 'dev-java/swt/runtest.sh')
-rwxr-xr-x[-rw-r--r--] | dev-java/swt/runtest.sh | 25 |
1 files changed, 18 insertions, 7 deletions
diff --git a/dev-java/swt/runtest.sh b/dev-java/swt/runtest.sh index d212ecf..3d506bb 100644..100755 --- a/dev-java/swt/runtest.sh +++ b/dev-java/swt/runtest.sh @@ -1,7 +1,18 @@ -moz="${1}" -[[ -z ${moz} ]] && moz=xulrunner -[[ ! -e Snippet128.class ]] && javac -classpath $(java-config -p swt-3) Snippet128.java -#LD_PRELOAD="/usr/lib/${moz}/libxul.so" \ -MOZILLA_FIVE_HOME="/usr/lib/${moz}/" \ -LD_LIBRARY_PATH="$(java-config -i swt-3):${MOZILLA_FIVE_HOME}" \ - java -Djava-library.path=$(java-config -i swt-3) -cp $(java-config -p swt-3):. Snippet128 +#!/bin/bash +if [[ ${#} != 1 ]]; then + echo "Usage: $0 <swt-slot>" + echo "Example: $0 3.4" + exit +fi + +SLOT="${1}" + +echo "compiling..." +[[ ! -e Snippet128.class ]] && javac -classpath $(java-config -p swt-${SLOT}) Snippet128.java + +export CLASSPATH="." +gjl_package=swt-${SLOT} +gjl_main="Snippet128" +echo "Running..." +GJL_DEBUG=1 +source /usr/share/java-config-2/launcher/launcher.bash |