aboutsummaryrefslogtreecommitdiffstats
path: root/tools/dicttool/etc/dicttool_aosp
diff options
context:
space:
mode:
authorJean Chalard <jchalard@google.com>2012-08-27 14:51:57 +0900
committerJean Chalard <jchalard@google.com>2013-06-19 20:08:54 +0900
commitd055cca7d28812a480eb49e8264f02d6b16fdfd5 (patch)
tree228c104830b2da403182d925cd216ec0c4abfe17 /tools/dicttool/etc/dicttool_aosp
parent286877b3afc6309b70c5216f05b94729aeb844f3 (diff)
downloadlatinime-d055cca7d28812a480eb49e8264f02d6b16fdfd5.tar.gz
latinime-d055cca7d28812a480eb49e8264f02d6b16fdfd5.tar.xz
latinime-d055cca7d28812a480eb49e8264f02d6b16fdfd5.zip
Add an initial test command to dicttool.
Also fix some warnings This is a preliminary change to help track b/8526576 Bug: 8526576 Change-Id: If2ed74bb92f9b5fb7bbaf9c4851d9d0b5514b405
Diffstat (limited to 'tools/dicttool/etc/dicttool_aosp')
-rwxr-xr-xtools/dicttool/etc/dicttool_aosp12
1 files changed, 11 insertions, 1 deletions
diff --git a/tools/dicttool/etc/dicttool_aosp b/tools/dicttool/etc/dicttool_aosp
index a4879a279..cc7111a2c 100755
--- a/tools/dicttool/etc/dicttool_aosp
+++ b/tools/dicttool/etc/dicttool_aosp
@@ -33,6 +33,7 @@ progdir=`pwd`
prog="${progdir}"/`basename "${prog}"`
cd "${oldwd}"
+classname=com.android.inputmethod.latin.dicttool.Dicttool
jarfile=dicttool_aosp.jar
frameworkdir="$progdir"
if [ ! -r "$frameworkdir/$jarfile" ]
@@ -51,12 +52,21 @@ then
exit 1
fi
+lib=junit.jar
+if [ ! -r "$frameworkdir/$lib" ]
+then
+ echo `basename "$prog"`": can't find lib $lib"
+ exit 1
+fi
+
if [ "$OSTYPE" = "cygwin" ] ; then
jarpath=`cygpath -w "$frameworkdir/$jarfile"`
+ libpath=`cygpath -w "$frameworkdir/$lib"`
progdir=`cygpath -w "$progdir"`
else
jarpath="$frameworkdir/$jarfile"
+ libpath="$frameworkdir/$lib"
fi
# might need more memory, e.g. -Xmx128M
-exec java -ea -jar "$jarpath" "$@"
+exec java -ea -classpath "$libpath":"$jarpath" "$classname" "$@"