X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=salome_run.sh;h=164a02e3cb7193633eab39c85ca9c91e46dde976;hb=3ada52ad6bce1f69571d9dea97f6631f155681d7;hp=78609177af1cff3586a7f2959390aced63849001;hpb=0b06415cbaab3da89567c28ea4a7ae6ecf50511b;p=modules%2Fshaper.git diff --git a/salome_run.sh b/salome_run.sh index 78609177a..164a02e3c 100755 --- a/salome_run.sh +++ b/salome_run.sh @@ -1,13 +1,22 @@ -#!/bin/sh +#!/bin/bash -e -export ROOT_DIR=$(pwd)/.. -export ROOT_DIR=`cd "${ROOT_DIR}";pwd` +a_dir=$(dirname $0) -source ${ROOT_DIR}/sources/linux_env.sh +cd ${a_dir} -# Correcting path which defined with error -export LD_LIBRARY_PATH=${KERNEL_ROOT_DIR}/lib/salome:${LD_LIBRARY_PATH} -export SalomeAppConfig=${ROOT_DIR}/install/share/salome/resources/newgeom:${GUI_ROOT_DIR}/share/salome/resources/gui +if [ "$#" = 1 ]; then + export SALOME_PORT="$1" +elif [ -z ${SALOME_PORT} ]; then + export SALOME_PORT=2900 +fi -${PYTHONBIN} "${KERNEL_ROOT_DIR}/bin/salome/envSalome.py" -${PYTHONBIN} "${KERNEL_ROOT_DIR}/bin/salome/runSalome.py" +echo "Run SALOME on port ${SALOME_PORT}" + +source ${a_dir}/env.sh +source ${a_dir}/env_salome.sh + +set -x +e + +${a_dir}/salome_kill.sh + +${KERNEL_ROOT_DIR}/bin/salome/runSalome.py --port=${SALOME_PORT} -r ./test.squish/shared/testdata/SalomeApp.xml 2>&1 >/dev/null