+#export OMNIORB_USER_PATH="${HOME}/.salomeConfig/USERS"
+export OMNIORB_USER_PATH="${HOME}/${APPLI}/USERS"
+
+# --- set the OMNIORB_CONFIG file and environment relative to this run of SALOME
+# Usage: writeConfigFile PORT HOST
+function writeConfigFile
+{
+ if [ $# -ne 2 ]; then
+ echo "Usage: $0 PORT HOST"
+ return
+ fi
+ export NSPORT=$1
+ export NSHOST=$2
+
+ # Get (in bash) the configuration filename from (Python) ORBConfigFile return values
+ RETURN_VALUES=$(${KERNEL_ROOT_DIR}/bin/salome/envSalome.py python ${KERNEL_ROOT_DIR}/bin/salome/ORBConfigFile.py ${OMNIORB_USER_PATH} ${NSHOST} ${NSPORT} with_username=${USER})
+ export OMNIORB_CONFIG=$(echo ${RETURN_VALUES} | cut -d' ' -f1)
+}
+
+