root/release-kits/shared/linux/rk @ 17401

Revision 17401, 1.8 KB (checked in by oranfry, 11 years ago)

up the memory available to java during release process

  • Property svn:executable set to *
Line 
1#pre checks
2
3if [ "$rk_name" == "" ]; then
4    echo "rk_name not set";
5    exit;
6elif [ "$RK_HOME" == "" ]; then
7    echo "RK_HOME not set";
8    exit
9fi
10
11function show_help {
12
13    echo "$rk_name - $rk_fullname"
14    echo "Helps you to create releases from the Repository"
15    echo
16    echo "usage: $rk_name [-sim] [-from <target>] [other-args]"
17    echo "  -sim"
18    echo "      simulation only, don't actually do anything"
19    echo
20    echo "  -help"
21    echo "      show this help screen"
22    echo
23    echo "  -from <target>"
24    echo "      start execution from the target with the given target address"
25    echo
26    echo "  -to <target>"
27    echo "      stop execution just before the target with the given target address"
28    echo
29    echo "  -descend <target>"
30    echo "      execute only the target with the given address, including subtargets"
31    echo
32    echo "  -cp"
33    echo "      show the classpath being used by $rk_name"
34
35}
36
37#work out the classpath
38CLASSPATH=$JAVA_HOME/lib/tools.jar
39for file in $RK_HOME/lib/*.jar; do
40    CLASSPATH=$CLASSPATH:$file
41done
42for file in $RK_HOME/packages/ant/lib/*.jar; do
43    CLASSPATH=$CLASSPATH:$file
44done
45for file in $RK_HOME/packages/ant-installer/lib/*.jar; do
46    CLASSPATH=$CLASSPATH:$file
47done
48CLASSPATH=$CLASSPATH:$RK_HOME/packages/ant-installer/classes
49
50export CLASSPATH
51
52#set ANT_HOME
53export ANT_HOME=$RK_HOME/packages/ant
54export ANT_OPTS=-Xmx800M
55
56#create the command
57toexec="$ANT_HOME/bin/ant -addressing -lib `pwd`/installer/classes -f $RK_HOME/ant-scripts/build.xml -Dbasedir=`pwd` -D$rk_name.home=$RK_HOME"
58
59#pass on the arguments
60while [ "$1" != "" ]; do
61
62    if [ "$1" == "-help" ]; then
63        show_help
64        exit
65    elif [ "$1" == "-cp" ]; then
66        echo $CLASSPATH
67        exit
68    elif [ "$1" == "-sim" ]; then
69        toexec="$toexec $1"
70        sim_mode=on
71    else
72        toexec="$toexec $1"
73    fi
74    shift
75
76done
77
78#create directories
79if [ "$sim_mode" != "on" ]; then
80    if [ ! -d "installer/classes" ]; then mkdir -p installer/classes; fi
81fi
Note: See TracBrowser for help on using the browser.