Salome HOME
First preliminary version
[tools/simanio.git] / scripts / run_salome_siman.sh
1 #!/bin/bash
2 xhost +
3 echo "parameters : $1  $2  $3" > /home/siman/check_params.txt
4 echo "$#" >> /home/siman/check_params.txt
5
6 if [ "$#" -ne 1 ] ; then 
7 echo  "Usage :
8 `basename $0` --siman-study=<studyID> --siman-scenario=<scenarioID> --siman-user=<userID>"
9 echo  "for example : 
10 `basename $0` --siman-study=1162 --siman-scenario=1163 --siman-user=8"
11 exit
12 fi
13
14
15 #echo dir1 = `dirname $0`
16 #echo dir2 = ${PWD}
17
18 echo "pwd = " ${PWD} >> /home/siman/check_params.txt
19 echo "display = " ${DISPLAY} >> /home/siman/check_params.txt
20
21 env_script=${PWD}/env_products.sh
22 echo script = $env_script
23
24 if [ -e $env_script ] ; then
25     echo
26     echo ">>> Setting SALOME environment" >> /home/siman/check_params.txt
27     echo ">>> Environment script = " $env_script >> /home/siman/check_params.txt
28     source $env_script >> /home/siman/check_params.txt
29     echo ">>> After products " >> /home/siman/check_params.txt
30     else
31     echo
32     echo '!!! Warning !!! Environment is not set.'
33     echo 'No environment file (env_products.sh) is found.'
34     echo 'Proceed with the current environment.'
35 fi
36
37 echo ">>> Setting SALOME-SAMAN environment" >> /home/siman/check_params.txt
38
39 export WSFCPP_HOME=${PWD}/wso2-wsf-cpp-2.1.0
40 #export PATH=${WSFCPP_HOME}/lib:${PATH}
41 export LD_LIBRARY_PATH=${WSFCPP_HOME}/lib:${LD_LIBRARY_PATH}
42 echo "WSFCPP_HOME = " ${WSFCPP_HOME} >> /home/siman/check_params.txt
43
44 export SIMANIO_ROOT_DIR=${PWD}/SIMANIO
45 export PATH=${SIMANIO_ROOT_DIR}/lib:${PATH}
46 export LD_LIBRARY_PATH=${SIMANIO_ROOT_DIR}/lib:${LD_LIBRARY_PATH}
47
48 export SIMAN_WS_HOST="172.22.2.65:8080"
49
50 echo "parameters 3: $1 $2 $3" >> /home/siman/check_params.txt
51
52 #export SALOME_ROOT_DIR=${PWD}
53
54 echo ">>> SALOME-SIMAN rurring" >> /home/siman/check_params.txt
55
56 echo "parameters 4: $1 $2 $3" >> /home/siman/check_params.txt
57
58 runSalome --siman $1 $2 $3 -k >> /home/siman/check_params.txt
59