-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun-java
executable file
·76 lines (69 loc) · 2.19 KB
/
run-java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#! /bin/sh
root=`dirname $0`;
classpath="$root/dist/kcae.jar"
classpath="${classpath}:$root/ext/asm-3.0.jar"
classpath="${classpath}:$root/ext/asm-tree-3.0.jar"
classpath="${classpath}:$root/ext/commons-io-2.3.jar"
classpath="${classpath}:$root/ext/commons-lang3-3.1.jar"
classpath="${classpath}:$root/ext/commons-logging-1.1.1.jar"
classpath="${classpath}:$root/ext/commons-logging-adapters-1.1.1.jar"
classpath="${classpath}:$root/ext/commons-logging-api-1.1.1.jar"
classpath="${classpath}:$root/ext/findbugs-annotations-2.0.1-rc2.jar"
classpath="${classpath}:$root/ext/guava-13.0.1.jar"
classpath="${classpath}:$root/ext/jackson-core-asl-1.9.7.jar"
classpath="${classpath}:$root/ext/jackson-mapper-asl-1.9.7.jar"
classpath="${classpath}:$root/ext/jakarta-oro-2.0.8.jar"
classpath="${classpath}:$root/ext/jsr305.jar"
classpath="${classpath}:$root/ext/jython-2.7a2.jar"
classpath="${classpath}:$root/ext/log4j-1.2.9.jar"
logger="org.apache.commons.logging.impl.Log4JLogger"
log_property="-Dorg.apache.commons.logging.Log=$logger"
#python_properties="-Dpython.verbose=debug"
tool=java
assertions="-enableassertions"
use_gui=1
while [ $# -gt 0 ]; do
case "$1" in
-classpath )
shift;
if [ $# -eq 0 ]; then
echo "-classpath requires a path argument" 1>&2;
exit 1;
fi;
classpath="${classpath}:$1";
shift;;
-debug )
tool=jdb;
shift;;
-nw )
use_gui=0;
shift;;
-disableassertions )
assertions="";
shift;;
-compile )
tool=javac;
use_gui=0;
assertions="";
log_property="";
python_properties="";
shift;;
* )
break;
esac;
done;
if [ $use_gui -ne 0 ]; then
$tool -Dapple.awt.application.name="Kanga CAE" \
-Dapple.laf.useScreenMenuBar=true \
-Dapple.awt.graphics.UseQuartz=true \
$log_property \
$python_properties \
$assertions \
-classpath "$classpath" \
"$@"
else
$tool $log_property $python_properties \
$assertions \
-classpath "$classpath" \
"$@"
fi;