Salome HOME
bdc57c59df21e01e134907c0fb67498db170a627
[modules/med.git] / src / MedClient / test / environ / runTestMedCorba.in
1 #! /bin/bash
2 # Copyright (C) 2007-2013  CEA/DEN, EDF R&D, OPEN CASCADE
3 #
4 # Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
5 # CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 #
7 # This library is free software; you can redistribute it and/or
8 # modify it under the terms of the GNU Lesser General Public
9 # License as published by the Free Software Foundation; either
10 # version 2.1 of the License.
11 #
12 # This library is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 # Lesser General Public License for more details.
16 #
17 # You should have received a copy of the GNU Lesser General Public
18 # License along with this library; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
20 #
21 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 #
23  
24 PYTHON_VERSION=python@PYTHON_VERSION@                                                                 
25
26 if test -n $MED_ROOT_DIR
27 then
28   export PATH=$MED_ROOT_DIR/bin/salome:${PATH}
29   export LD_LIBRARY_PATH=$MED_ROOT_DIR/lib@LIB_LOCATION_SUFFIX@/salome${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
30   export PYTHONPATH=${MED_ROOT_DIR}/lib@LIB_LOCATION_SUFFIX@/salome:${MED_ROOT_DIR}/lib@LIB_LOCATION_SUFFIX@/$PYTHON_VERSION/site-packages/salome:${MED_ROOT_DIR}/share/salome/resources/med:${PYTHONPATH}
31   # add bin, because some script are in (SALOME_SWIG) !!!!
32   export PYTHONPATH=${MED_ROOT_DIR}/bin/salome:${PYTHONPATH}
33 fi
34 if test -n $MED_ROOT_DIR
35 then
36   export PATH=$MED_ROOT_DIR/bin/salome:${PATH}
37   export LD_LIBRARY_PATH=$MED_ROOT_DIR/lib@LIB_LOCATION_SUFFIX@/salome${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
38   export PYTHONPATH=${MED_ROOT_DIR}/lib@LIB_LOCATION_SUFFIX@/salome:${MED_ROOT_DIR}/lib@LIB_LOCATION_SUFFIX@/$PYTHON_VERSION/site-packages/salome:${MED_ROOT_DIR}/share/salome/resources/med:${PYTHONPATH}
39 fi
40
41 mkdir -p resultats
42 ((python $1 2>&1 1>&3 | tee resultats/$1_err) 3>&1 1>&2 | tee resultats/$1_out ) 2>&1
43