office-gobmx/solenv/bin/checkapi
Jens-Heiner Rechtien 72fba2cc5f CWS-TOOLING: integrate CWS perftest09b
2009-07-22 08:34:25 +0200 lla  r274216 : #i103694# use bash as shell
2009-07-21 12:33:51 +0200 lla  r274178 : #160203#
2009-07-20 13:42:20 +0200 lla  r274124 : #106358# add helper tool to get access to rpm in the environment for SOI
2009-07-20 12:43:26 +0200 lla  r274119 : #i103656# compatiblity
2009-07-29 13:59:06 +00:00

71 lines
1.7 KiB
Bash
Executable file

#!/bin/bash
PS=":"
# cygwin:
if [ "$GUI" = "WNT" ]; then
PS=";"
fi
JARFOLDER=$SOLARVERSION/$INPATH/bin$UPDMINOREXT
SOLVER_LIB=$SOLARVERSION/$INPATH/lib$UPDMINOREXT
# it is possible to give an other OOoRunner.jar
if [ -n "$RUNNERJAR" ]; then
myCLASSPATH=$RUNNERJAR
else
myCLASSPATH=$JARFOLDER/OOoRunner.jar
fi
myCLASSPATH=$myCLASSPATH${PS}${JARFOLDER}/ridl.jar${PS}\
${JARFOLDER}/unoil.jar${PS}\
${JARFOLDER}/jurt.jar${PS}\
${JARFOLDER}/juh.jar${PS}\
${JARFOLDER}/java_uno.jar
myCLASSPATH=$myCLASSPATH${PS}\
/net/unoapi/export/unoapi/bin/mysql.jar${PS}\
$SOLVER_LIB
if [ -n "$JAVAI" ]; then
JAVABIN=$JAVAI
elif [ -n "$JAVA_HOME" ]; then
if [ "$OS$CPUNAME$CPU" = SOLARISSPARCU ]; then
JAVABIN=$JAVA_HOME/bin/sparcv9/java
else
JAVABIN=$JAVA_HOME/bin/java
fi
else
# there seems to be some machines without real java
JAVABIN=$(which java)
if [ -z "$JAVABIN" ]; then
echo "please set environment variable JAVA_HOME"
exit 1
fi
fi
if [ x${USER}x = xx ]; then
if [ x${LOGNAME}x = xx ]; then
echo "ERROR: could not determine username. Please export variable USER" >&2
exit $EXIT_FAILURE
else
USER=$LOGNAME
export USER
fi
fi
PARAM="-cs pipe,name=$USER -SRC_ROOT $SRC_ROOT"
if [ -n "$RUNNERPROPS" ]; then
PARAM="$PARAM -runnerini $RUNNERPROPS"
fi
DEBUG_THE_API=""
if [ -n "$DEBUGAPI" ]; then
export DEBUGAPI="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=9002,suspend=y"
DEBUG_THE_API=$DEBUGAPI
fi
COMMAND="$JAVABIN -Xmx120m $DEBUG_THE_API -cp $myCLASSPATH org.openoffice.Runner $PARAM $*"
echo $COMMAND
$COMMAND
# if COMMAND fails, it returns also the exitcode