]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
PR: merge from branch BR_V3_1_0_CCRT tag mergeto_BR_auto_V310_06mar06
authorprascle <prascle>
Mon, 6 Mar 2006 14:01:04 +0000 (14:01 +0000)
committerprascle <prascle>
Mon, 6 Mar 2006 14:01:04 +0000 (14:01 +0000)
68 files changed:
bin/appliskel/killCurrentPort
bin/appliskel/runAppli
bin/appliskel/runConsole
bin/appliskel/runParam
bin/appliskel/runRemote.sh
bin/appliskel/runSession
bin/appliskel/runTests
bin/appliskel/searchFreePort.sh
bin/appliskel/setAppliPath.sh
bin/killSalomeWithPort.py
bin/launchConfigureParser.py
bin/runIDLparser.in
bin/runSalome.ksh [new file with mode: 0644]
bin/runSalome.py
salome_adm/unix/DEPRECATED/envScript.in
salome_adm/unix/DEPRECATED/make_conclude.in
salome_adm/unix/config_files/DEPRECATED/check_Salome.m4
salome_adm/unix/config_files/DEPRECATED/check_pthreads.m4
salome_adm/unix/config_files/DEPRECATED/install-sh
salome_adm/unix/config_files/ac_cxx_option.m4
salome_adm/unix/config_files/check_boost.m4
salome_adm/unix/config_files/check_cas.m4
salome_adm/unix/config_files/check_cppunit.m4
salome_adm/unix/config_files/check_msg2qm.m4
salome_adm/unix/config_files/check_omniorb.m4
salome_adm/unix/config_files/check_pyqt.m4
salome_adm/unix/config_files/check_qwt.m4
salome_adm/unix/config_files/check_sip.m4
salome_adm/unix/config_files/check_vtk.m4
src/Basics/BasicsGenericDestructor.cxx
src/Container/Container_i.cxx
src/Container/Container_init_python.cxx
src/Container/SALOME_Container.cxx
src/Container/SALOME_ContainerManagerServer.cxx
src/Container/SALOME_Container_i.hxx
src/LifeCycleCORBA/Launchers.cxx
src/LifeCycleCORBA/SALOME_LifeCycleCORBA.cxx
src/LifeCycleCORBA_SWIG/TestLifeCycleCORBA.py
src/MPIContainer/MPIContainer_i.cxx
src/ModuleCatalog/Makefile.am
src/ModuleGenerator/testIDLparser.in
src/ModuleGenerator/tests/test1.sh
src/ModuleGenerator/tests/test1b.sh
src/ModuleGenerator/tests/test2.sh
src/ModuleGenerator/tests/test3.sh
src/ModuleGenerator/tests/test4.sh
src/ModuleGenerator/tests/test5.sh
src/SALOMEDS/SALOMEDS_GenericAttribute_i.cxx
src/SALOMEDS/SALOMEDS_GenericAttribute_i.hxx
src/SALOMEDS/SALOMEDS_SObject_i.cxx
src/SALOMEDS/SALOMEDS_SObject_i.hxx
src/SALOMEDS/SALOMEDS_StudyManager_i.cxx
src/SALOMEDS/SALOMEDS_StudyManager_i.hxx
src/SALOMEDS/SALOMEDS_Study_i.cxx
src/SALOMEDS/SALOMEDS_Study_i.hxx
src/SALOMEDSImpl/SALOMEDSImpl_AttributeComment.cxx
src/SALOMEDSImpl/SALOMEDSImpl_AttributeDrawable.cxx
src/SALOMEDSImpl/SALOMEDSImpl_AttributeExpandable.cxx
src/SALOMEDSImpl/SALOMEDSImpl_AttributeIOR.cxx
src/SALOMEDSImpl/SALOMEDSImpl_AttributeInteger.cxx
src/SALOMEDSImpl/SALOMEDSImpl_StudyManager.cxx
src/SALOMELocalTrace/BaseTraceCollector.cxx
src/SALOMELocalTrace/LocalTraceBufferPool.cxx
src/TestContainer/Makefile.am
src/TestContainer/TestComponentPy.py
src/TestContainer/TestContainer.cxx
src/TestContainer/TestLogger.py [new file with mode: 0644]
src/Utils/Utils_SignalsHandler.cxx

index bca506068665d28b5d2063c0d9475c9579d85816..cfb87da7810f852668e91e2221227cb50591d6c8 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 # --- retrieve APPLI path, relative to $HOME, set ${APPLI}
 
@@ -14,7 +14,8 @@ myhost=`hostname`
 fileOmniConfig=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
 
 if [ -f $fileOmniConfig ]; then
-  export OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
+  OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
+  export OMNIORB_CONFIG
 fi
 
 currentPort=`${KERNEL_ROOT_DIR}/bin/salome/NSparam.py port`
index 1d86ad3d596273903687f570c706a0a420a8bf37..7146b6b82439d3fbff052b27e50076a30e9dd41a 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 # --- retrieve APPLI path, relative to $HOME, set ${APPLI}
 
index caeabbdd61319e13363aaad5944a21d032d5e8a9..1756189ff95eac46f0e4b49b19b4b6d8deb91fc9 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 # --- retrieve APPLI path, relative to $HOME, set ${APPLI}
 
index c858c670fcdea8da2a0c25c67fddc14dfae8a714..68e5a25c0612f9816755e8a38909ec68da996eb3 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 ./KillCurrentPort
 
index 594616a0709701485a25059c812642b114070f51..3ab5a1daf81fb0979802f97056f9bea8d73b04b2 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 # --- run command in SALOME environment from remote call, ssh or rsh
 #     - SALOME configuration is defined by :
 
 # --- set the OMNIORB_CONFIG file and environment relative to this run of SALOME
 
-export OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_$1_$2.cfg
-export NSHOST=$1
-export NSPORT=$2
+OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_$1_$2.cfg
+export OMNIORB_CONFIG
+NSHOST=$1
+export NSHOST
+NSPORT=$2
+export NSPORT
 initref="NameService=corbaname::"$1":$2"
 echo "ORBInitRef $initref" > $OMNIORB_CONFIG
 
@@ -41,4 +44,4 @@ echo "ORBInitRef $initref" > $OMNIORB_CONFIG
 
 shift 2
 
-${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile $HOME/$APPLI/.bashrc -c "$*"
+${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/sh --rcfile $HOME/$APPLI/.bashrc -c "$*"
index 22d3fdd0fb3307419a4e8f9ff1e3ef810454d9f0..1f99cce7bc74406b78178ccb00cc9223b07ffaa6 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 # Useful shell to run executable progs or shells under Salome env
 # Use it with args to run a program : runSession python -i myprog.py
@@ -19,19 +19,22 @@ myhost=`hostname`
 fileOmniConfig=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
 
 if [ -f $fileOmniConfig ]; then
-  export OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
+  OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
+  export OMNIORB_CONFIG
 
   # --- set environment variables for port and hostname of NamingService
 
-  export NSHOST=`${KERNEL_ROOT_DIR}/bin/salome/NSparam.py host`
-  export NSPORT=`${KERNEL_ROOT_DIR}/bin/salome/NSparam.py port`
+  NSHOST=`${KERNEL_ROOT_DIR}/bin/salome/NSparam.py host`
+  export NSHOST
+  NSPORT=`${KERNEL_ROOT_DIR}/bin/salome/NSparam.py port`
+  export NSPORT
 fi
 
 # --- invoque shell with or without args
 
 if [ $# -ne 0 ] ; then
-    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile ${HOME}/${APPLI}/.bashrc -c "$*"
+    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/sh --rcfile ${HOME}/${APPLI}/.bashrc -c "$*"
 else
 
-    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile ${HOME}/${APPLI}/.bashrc
+    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/sh --rcfile ${HOME}/${APPLI}/.bashrc
 fi
index 755825d797a7588da6480fdbdbaa56faaec88d91..4ff2bc186ac254a1110a01e36aa2ea8cc31a19d1 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 # --- retrieve APPLI path, relative to $HOME, set ${APPLI}
 
@@ -21,13 +21,16 @@ searchFreePort() {
         if [ -z "$aRes" ]; then
             echo ${NSPORT} - Ok
            local myhost=`hostname`
-            export OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_${NSPORT}.cfg
+            OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_${NSPORT}.cfg
+            export OMNIORB_CONFIG
            export NSPORT
-            export NSHOST=${myhost}
+            NSHOST=${myhost}
+            export NSHOST
             local initref="NameService=corbaname::"`hostname`":$NSPORT"
             #echo "ORBInitRef $initref" > $OMNIORB_CONFIG
             echo "InitRef = $initref" > $OMNIORB_CONFIG
-            export LAST_RUNNING_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_test.cfg
+            LAST_RUNNING_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_test.cfg
+            export LAST_RUNNING_CONFIG
            rm ${LAST_RUNNING_CONFIG}
             ln -s ${OMNIORB_CONFIG} ${LAST_RUNNING_CONFIG}
             break
@@ -55,10 +58,10 @@ fi
 searchFreePort
 
 if [ $# -ne 0 ] ; then
-    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile ${HOME}/${APPLI}/.bashrc -c "$*"
+    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/sh --rcfile ${HOME}/${APPLI}/.bashrc -c "$*"
 else
 
-    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile ${HOME}/${APPLI}/.bashrc
+    ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/sh --rcfile ${HOME}/${APPLI}/.bashrc
 fi
 
 rm ${OMNIORB_CONFIG}
index 8108a93dcb542cfbfda619145807e065d289d56e..7333b1ce7288bdc4ef3163638507ef70ebae7ba1 100755 (executable)
@@ -1,10 +1,11 @@
-#!/bin/bash
+#!/bin/sh
 
 # --- define port for CORBA naming service
 
 searchFreePort() {
     echo -n "Searching for a free port for naming service: "
-    export NSPORT=2810
+    NSPORT=2810
+    export NSPORT
     local limit=$NSPORT
     let limit=limit+100
     while [ 1 ]
@@ -13,13 +14,16 @@ searchFreePort() {
         if [ -z "$aRes" ]; then
             echo ${NSPORT} - Ok
            local myhost=`hostname`
-            export OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_${NSPORT}.cfg
+            OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_${NSPORT}.cfg
+            export OMNIORB_CONFIG
            export NSPORT
-            export NSHOST=${myhost}
+            NSHOST=${myhost}
+            export NSHOST
             local initref="NameService=corbaname::"`hostname`":$NSPORT"
             #echo "ORBInitRef $initref" > $OMNIORB_CONFIG
             echo "InitRef = $initref" > $OMNIORB_CONFIG
-            export LAST_RUNNING_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
+            LAST_RUNNING_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
+            export LAST_RUNNING_CONFIG
            rm ${LAST_RUNNING_CONFIG}
             ln -s ${OMNIORB_CONFIG} ${LAST_RUNNING_CONFIG}
             break
index d9361ae526f8e48649ebe958af9ed80eb77aab2c..99078065a7388689c2fc51183d32698ae04b356f 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 # --- retrieve APPLI path, relative to $HOME, set ${APPLI}
 #     on sarge, "which" gives not allways the absolute path...
index e52a25f883fec97a6273a12c1389926f73042fc2..9f0cd0dd9c9a317c94214935d2b23d9ef5bc7e88 100755 (executable)
@@ -34,7 +34,21 @@ def killMyPort(port):
         pass
         
     if found:
-        a = os.system("pid=`ps -eo pid,command | egrep \"[0-9] omniNames -start "+str(port)+"\" | sed -e \"s%[^0-9]*\([0-9]*\) .*%\\1%g\"`; kill -9 $pid >& /dev/null")
+        cmd = 'pid=`ps -eo pid,command | egrep "[0-9] omniNames -start '+str(port)+'"` ; echo $pid > /tmp/logs/'+os.getenv('USER')+"/_"+port+'_Pid_omniNames.log'
+        a = os.system(cmd)
+        try:
+            fpidomniNames=open('/tmp/logs/'+os.getenv('USER')+"/_"+port+'_Pid_omniNames.log')
+            prc = fpidomniNames.read()
+            fpidomniNames.close()
+            if prc != None :
+                for field in prc.split(" ") :
+                    if field == "omniNames" :
+                        if pidfield != "egrep" :
+                            print 'stop process '+pidfield+' : omniNames'
+                            os.system('kill -9 '+pidfield)
+                    pidfield = field
+        except:
+            pass
         try:
             process_ids=pickle.load(fpid)
             fpid.close()
index a9d0c273ca2fdb6f1e67db623b5a7b0e8775b302..99540b3f3232a17a4c01db63d5ab0b1c6a0df06e 100755 (executable)
@@ -161,6 +161,17 @@ class xml_parser:
 # -     command line
 
 config_var = appname+'Config'
+# set resources variables if not yet set
+if os.getenv("GUI_ROOT_DIR"):
+    if not os.getenv("SUITRoot"): os.environ["SUITRoot"] =  os.getenv("GUI_ROOT_DIR") + "/share/salome"
+    if not os.getenv("SalomeAppConfig"): os.environ["SalomeAppConfig"] =  os.getenv("GUI_ROOT_DIR") + "/share/salome/resources"
+    pass
+else :
+    if not os.getenv("SUITRoot"):
+        os.environ["SUITRoot"] = ""
+    if not os.getenv("SalomeAppConfig"):
+        os.environ["SalomeAppConfig"] = ""
+
 dirs = os.environ[config_var]
 dirs = re.split('[;|:]', dirs )
 dirs.reverse() # reverse order, like in "path" variable - FILO-style processing
index 3957369af8c24ea6acb06d29f1ef3ed052f64b69..cb41a7488a97de871752dca5c5481ec601250be5 100644 (file)
@@ -1,4 +1,4 @@
-#! /bin/bash
+#! /bin/sh
 
 # print the help message ====================================
 
diff --git a/bin/runSalome.ksh b/bin/runSalome.ksh
new file mode 100644 (file)
index 0000000..9702886
--- /dev/null
@@ -0,0 +1,77 @@
+#!/bin/ksh
+
+searchFreePort() {
+    echo -n "Searching for a free port for naming service: "
+    NSPORT=2810
+    export NSPORT
+    local limit=$NSPORT
+    let limit=limit+100
+    while [ 1 ]
+    do
+        aRes=`netstat -ltn | grep -E :${NSPORT}`
+        if [ -z "$aRes" ]; then
+            echo ${NSPORT} - Ok
+           local myhost=`hostname`
+            OMNIORB_CONFIG=${HOME}/.omniORB_${myhost}_${NSPORT}.cfg
+            export OMNIORB_CONFIG
+           local initref="NameService=corbaname::"`hostname`":$NSPORT"
+           export NSPORT
+           if [[ `python -c "import CORBA; print CORBA.ORB_ID"` = "omniORB4" ]]; then
+                echo "InitRef = $initref" > $OMNIORB_CONFIG
+           else
+               echo "ORBInitRef $initref" > $OMNIORB_CONFIG
+           fi
+            break
+        fi
+        echo -n "${NSPORT} "
+        if [[ $NSPORT -eq $limit ]] ; then
+            echo
+            echo "Can't find a free port to launch omniNames"
+            echo "Try to kill the running servers and then launch SALOME again."
+            exit
+        fi
+        let NSPORT=NSPORT+1
+    done
+}
+
+searchFreePort
+
+if [[ "$*" = "-nothing" ]]; then
+    echo "port:$NSPORT"
+elif [ $# -ne 0 ] ; then
+    python -i ${KERNEL_ROOT_DIR}/bin/salome/runSalome.py $* 
+else
+    python ${KERNEL_ROOT_DIR}/bin/salome/runSalome.py
+fi
+
+# -----------------------------------------------------------------------------
+# examples:
+# ---------
+#  $: ${KERNEL_ROOT_DIR}/bin/salome/runSalome
+#
+#     - parameters for launching are taken from $HOME/.salome/salome.launch;
+#     - if the config file does not exist, it is created with default values.
+#
+#  
+#  $: ${KERNEL_ROOT_DIR}/bin/salome/runSalome --modules=GEOM,SMESH,VISU,SUPERV,MED --embedded=registry,study,moduleCatalog,cppContainer --standalone=pyContainer,supervContainer --xterm --killall
+#
+#     parameters from command line supersede those from $HOME/.salome/salome.launch
+#
+# Some CORBA servers can be launched in the SALOME_Session_Server's process
+# (embedded = same process) or in a separate process (standalone):
+# --> registry,study,moduleCatalog,cppContainer
+# Other CORBA servers could only be launched in separate process (standalone):
+# --> pyContainer,supervContainer
+#
+# $: ${KERNEL_ROOT_DIR}/bin/salome/runSalome -h
+#    help
+# -----------------------------------------------------------------------------
+#
+# l'option -i permet de garder l'interpreteur python ouvert :
+# par defaut, les differents serveurs ouvrent des fenêtres xterm
+# (cf. runSalome.py)
+# le serveur Logger n'est pas obligatoire (commenté dans runSalome.py)
+# 
+# -----------------------------------------------------------------------------
+# Example on CCRT (without ihm) :
+# ${KERNEL_ROOT_DIR}/bin/salome/runSalome.py --terminal --modules=MED,CALCULATOR,COMPONENT --standalone=registry,study,moduleCatalog,cppContainer,pyContainer,supervContainer --killall
index 98ff0a19fe5369b9677d5d09d3f29ede95ef21a4..7961b2878d91955f9b0927c08b717ca5fa4df2ba 100755 (executable)
@@ -56,8 +56,9 @@ def get_config():
     modules_list = []
     if args.has_key("modules"):
         modules_list += args["modules"]
-    # KERNEL must be last in the list to locate it at the first place in PATH 
-    modules_list[:0] = ["GUI"]
+    # KERNEL must be last in the list to locate it at the first place in PATH
+    if args["gui"] :
+        modules_list[:0] = ["GUI"]
     modules_list[:0] = ["KERNEL"]
     modules_list.reverse()
 
@@ -103,7 +104,8 @@ def set_env(args, modules_list, modules_root_dir):
     
     python_version="python%d.%d" % sys.version_info[0:2]
     modules_root_dir_list = []
-    modules_list = modules_list[:] + ["GUI"] 
+    if args["gui"] :
+        modules_list = modules_list[:] + ["GUI"] 
     modules_list = modules_list[:] + ["KERNEL"] 
     for module in modules_list :
         if modules_root_dir.has_key(module):
@@ -187,10 +189,10 @@ def set_env(args, modules_list, modules_root_dir):
     # set environment for SUPERV module
     os.environ["ENABLE_MACRO_NODE"]="1"
     # set resources variables if not yet set
-    if os.getenv("GUI_ROOT_DIR"):
-        if not os.getenv("SUITRoot"): os.environ["SUITRoot"] =  os.getenv("GUI_ROOT_DIR") + "/share/salome"
-        if not os.getenv("SalomeAppConfig"): os.environ["SalomeAppConfig"] =  os.getenv("GUI_ROOT_DIR") + "/share/salome/resources"
-        pass   
+    # Done now by launchConfigureParser.py
+    #if os.getenv("GUI_ROOT_DIR"):
+        #if not os.getenv("SUITRoot"): os.environ["SUITRoot"] =  os.getenv("GUI_ROOT_DIR") + "/share/salome"
+        #if not os.getenv("SalomeAppConfig"): os.environ["SalomeAppConfig"] =  os.getenv("GUI_ROOT_DIR") + "/share/salome/resources"
 
     # set CSF_PluginDefaults variable only if it is not customized
     # by the user
@@ -324,7 +326,11 @@ class CatalogServer(Server):
         cata_path=[]
         list_modules = modules_list[:]
         list_modules.reverse()
-        for module in ["KERNEL", "GUI"] + list_modules:
+        if self.args["gui"] :
+            list_modules = ["KERNEL", "GUI"] + list_modules
+        else :
+            list_modules = ["KERNEL"] + list_modules
+        for module in list_modules:
             if modules_root_dir.has_key(module):
                 module_root_dir=modules_root_dir[module]
                 module_cata=module+"Catalog.xml"
@@ -431,7 +437,11 @@ class SessionServer(Server):
         cata_path=[]
         list_modules = modules_list[:]
         list_modules.reverse()
-        for module in ["KERNEL", "GUI"] + list_modules:
+        if self.args["gui"] :
+            list_modules = ["KERNEL", "GUI"] + list_modules
+        else :
+            list_modules = ["KERNEL"] + list_modules
+        for module in list_modules:
             module_root_dir=modules_root_dir[module]
             module_cata=module+"Catalog.xml"
             #print "   ", module_cata
@@ -439,7 +449,7 @@ class SessionServer(Server):
                 glob.glob(os.path.join(module_root_dir,"share",
                                        salome_subdir,"resources",
                                        module_cata)))
-        if 'moduleCatalog' in self.args['embedded']:
+        if (self.args["gui"]) & ('moduleCatalog' in self.args['embedded']):
             self.CMD=self.SCMD1 + [string.join(cata_path,':')] + self.SCMD2
         else:
             self.CMD=self.SCMD1 + self.SCMD2
@@ -452,23 +462,26 @@ class ContainerManagerServer(Server):
         self.initArgs()
         self.SCMD1=['SALOME_ContainerManagerServer']
         self.SCMD2=[]
-        if 'registry' in self.args['embedded']:
-            self.SCMD1+=['--with','Registry',
-                         '(','--salome_session','theSession',')']
-        if 'moduleCatalog' in self.args['embedded']:
-            self.SCMD1+=['--with','ModuleCatalog','(','-common']
-            self.SCMD2+=['-personal',
-                         '${HOME}/Salome/resources/CatalogModulePersonnel.xml',')']
-        if 'study' in self.args['embedded']:
-            self.SCMD2+=['--with','SALOMEDS','(',')']
-        if 'cppContainer' in self.args['embedded']:
-            self.SCMD2+=['--with','Container','(','FactoryServer',')']
+        if args["gui"] :
+            if 'registry' in self.args['embedded']:
+                self.SCMD1+=['--with','Registry',
+                             '(','--salome_session','theSession',')']
+            if 'moduleCatalog' in self.args['embedded']:
+                self.SCMD1+=['--with','ModuleCatalog','(','-common']
+                self.SCMD2+=['-personal',
+                             '${HOME}/Salome/resources/CatalogModulePersonnel.xml',')']
+            if 'study' in self.args['embedded']:
+                self.SCMD2+=['--with','SALOMEDS','(',')']
+            if 'cppContainer' in self.args['embedded']:
+                self.SCMD2+=['--with','Container','(','FactoryServer',')']
         
     def setpath(self,modules_list,modules_root_dir):
         cata_path=[]
         list_modules = modules_list[:]
         list_modules.reverse()
-        for module in ["KERNEL", "GUI"] + list_modules:
+        if self.args["gui"] :
+            list_modules = ["GUI"] + list_modules
+        for module in ["KERNEL"] + list_modules:
             if modules_root_dir.has_key(module):
                 module_root_dir=modules_root_dir[module]
                 module_cata=module+"Catalog.xml"
@@ -479,7 +492,7 @@ class ContainerManagerServer(Server):
                                            module_cata)))
                 pass
             pass
-        if 'moduleCatalog' in self.args['embedded']:
+        if (self.args["gui"]) & ('moduleCatalog' in self.args['embedded']):
             self.CMD=self.SCMD1 + [string.join(cata_path,':')] + self.SCMD2
         else:
             self.CMD=self.SCMD1 + self.SCMD2
@@ -503,7 +516,13 @@ class NotifyServer(Server):
 
 def startGUI():
     """Salome Session Graphic User Interface activation"""
+    import Engines
     import SALOME
+    import SALOMEDS
+    import SALOME_ModuleCatalog
+    reload(Engines)
+    reload(SALOME)
+    reload(SALOMEDS)
     import SALOME_Session_idl
     session=clt.waitNS("/Kernel/Session",SALOME.Session)
     session.GetInterface()
@@ -544,7 +563,7 @@ def startSalome(args, modules_list, modules_root_dir):
     # attente de la disponibilite du Registry dans le Naming Service
     #
 
-    if 'registry' not in args['embedded']:
+    if ('registry' not in args['embedded']) | (args["gui"] == 0) :
         myServer=RegistryServer(args)
         myServer.run()
         clt.waitNSPID("/Registry",myServer.PID)
@@ -555,7 +574,7 @@ def startSalome(args, modules_list, modules_root_dir):
     #
     
 
-    if 'moduleCatalog' not in args['embedded']:
+    if ('moduleCatalog' not in args['embedded']) | (args["gui"] == 0):
         cataServer=CatalogServer(args)
         cataServer.setpath(modules_list,modules_root_dir)
         cataServer.run()
@@ -568,7 +587,7 @@ def startSalome(args, modules_list, modules_root_dir):
     #
 
     #print "ARGS = ",args
-    if 'study' not in args['embedded']:
+    if ('study' not in args['embedded']) | (args["gui"] == 0):
         print "RunStudy"
         myServer=SalomeDSServer(args)
         myServer.run()
@@ -629,17 +648,24 @@ def startSalome(args, modules_list, modules_root_dir):
     # Lancement Session Server
     #
 
-    mySessionServ = SessionServer(args)
-    mySessionServ.setpath(modules_list,modules_root_dir)
-    mySessionServ.run()
+    if args["gui"]:
+        mySessionServ = SessionServer(args)
+        mySessionServ.setpath(modules_list,modules_root_dir)
+        mySessionServ.run()
 ##----------------        
 
-    # Attente de la disponibilite du Session Server dans le Naming Service
-    #
+        # Attente de la disponibilite du Session Server dans le Naming Service
+        #
 
-    import SALOME
-    import SALOME_Session_idl
-    session=clt.waitNSPID("/Kernel/Session",mySessionServ.PID,SALOME.Session)
+        import Engines
+        import SALOME
+        import SALOMEDS
+        import SALOME_ModuleCatalog
+        reload(Engines)
+        reload(SALOME)
+        reload(SALOMEDS)
+        import SALOME_Session_idl
+        session=clt.waitNSPID("/Kernel/Session",mySessionServ.PID,SALOME.Session)
 
     end_time = os.times()
     print
index eaa69845d612311bdea06cff8927f6245bcb461b..3a057431252a5fb880f4171b10b99452d769a4f5 100644 (file)
@@ -6,16 +6,20 @@ SALOME_HOME_DIR=`pwd`
 cd $EXEC_DIR
 
 export SALOME_HOME_DIR      
-export SALOME_SRC_DIR=@ROOT_SRCDIR@
-export ORB_HOME_DIR=@CORBA_ROOT@
+SALOME_SRC_DIR=@ROOT_SRCDIR@
+export SALOME_SRC_DIR
+ORB_HOME_DIR=@CORBA_ROOT@
+export ORB_HOME_DIR
 
-export LD_LIBRARY_PATH=${SALOME_HOME_DIR}/lib:${LD_LIBRARY_PATH}
+LD_LIBRARY_PATH=${SALOME_HOME_DIR}/lib:${LD_LIBRARY_PATH}
+export LD_LIBRARY_PATH
 
 # echo $SALOME_HOME_DIR = SALOME_HOME_DIR
 # echo $SALOME_SRC_DIR = SALOME_SRC_DIR
 
 PYVTK_PATH=@VTKPY_MODULES@
-export PYTHONPATH=${PYTHONPATH}:${SALOME_HOME_DIR}/idl:${SALOME_HOME_DIR}/bin:${SALOME_HOME_DIR}/lib:${PYVTK_PATH}:${EXEC_DIR}
+PYTHONPATH=${PYTHONPATH}:${SALOME_HOME_DIR}/idl:${SALOME_HOME_DIR}/bin:${SALOME_HOME_DIR}/lib:${PYVTK_PATH}:${EXEC_DIR}
+export PYTHONPATH
 
 MICORC=/dev/null
 export MICORC
index adce12a218eee82c3850d4de3c44911977a9ac82..890d757086826569dba0aef1a2fe4fdb005350b9 100644 (file)
@@ -59,7 +59,7 @@ $(LIB_BUILD): $(top_builddir)/lib/salome/%.la: %.la
        ln -sf $(patsubst %.la, %.so, $(CURDIR)/.libs/$<).0 \
              $(patsubst %.la, %.so, $@).0 || true
 
-       if ! test -z $(LIB_SWIG) ; then \
+       if test "X$(LIB_SWIG)" != "X"; then \
           ln -sf $(patsubst %.la,%.so, $(CURDIR)/.libs/$<) $(top_builddir)/lib/salome/_$(LIB_SWIG) || true;\
        fi;
 
@@ -177,7 +177,7 @@ install: $(LIB) $(BIN) $(TEST_PROGS) $(libdir) $(includedir) $(bindir) $(datadir
              ($(LT_INSTALL_LIB) $$f $(libdir)/. || exit 1);                  \
           fi;                                                                \
        done
-       @if ! test -z $(LIB_SWIG) ; then                                      \
+       @if test "X$(LIB_SWIG)" != "X"; then                                  \
          (cd $(libdir); ln -sf $(patsubst %.so, %cmodule.so, $(LIB_SWIG)) _$(LIB_SWIG)  || true); \
         fi;                                                                  
        @for f in X $(BIN); do                                                \
@@ -371,8 +371,6 @@ distclean: clean
 .ui.cxx:
        $(UIC) -o $@ -i $*.h $<
 
-
-
 #pattern rules
 %_moc.cxx : %.h
        $(MOC) $< -o $@
@@ -383,7 +381,6 @@ distclean: clean
 $(top_builddir)/share/salome/resources/%.qm: %.po
        $(MSG2QM) $< $@ ; \
 
-
 #------------------------------------------------------------------------------
 # The following section of this makefile contains dependencies between the
 # source files and the header files.  If GNU make and GCC are being used then
index ff12fd6c3b4075ea2abb85697be545360db669be..d598c99f98e4abe3ad33ac30fb9c2cbd9835d0da 100644 (file)
@@ -33,7 +33,7 @@ AC_ARG_WITH(salome,
            --with-salome=DIR root directory path of SALOME installation,
            SALOME_DIR="$withval",SALOME_DIR="")
 
-if test "x$SALOME_DIR" == "x" ; then
+if test "x$SALOME_DIR" = "x" ; then
 
 # no --with-salome-dir option used
 
@@ -59,10 +59,10 @@ if test -f ${SALOME_DIR}/bin/libMEDMEM_Swig.py  ; then
    Salome_ok=yes
    AC_MSG_RESULT(Using Salome distribution in ${SALOME_DIR})
 
-   if test "x$SALOME_ROOT_DIR" == "x" ; then
+   if test "x$SALOME_ROOT_DIR" = "x" ; then
       SALOME_ROOT_DIR=${SALOME_DIR}
    fi
-   if test "x$SALOME_SITE_DIR" == "x" ; then
+   if test "x$SALOME_SITE_DIR" = "x" ; then
       SALOME_SITE_DIR=${SALOME_ROOT_DIR}
    fi
    AC_SUBST(SALOME_ROOT_DIR)
index 80aef2aad184d0e6509be9383e3422b254bf336c..eb511eca3ab55040b6696d5c654e5b010365bc4f 100644 (file)
@@ -38,9 +38,15 @@ if test $flag = no; then
   AC_CHECK_LIB(posix4,nanosleep, LIBS_PTHREADS="-lposix4",LIBS_PTHREADS="")
   AC_CHECK_LIB(pthread,pthread_mutex_lock, 
                LIBS_PTHREADS="-lpthread $LIBS_PTHREADS",LIBS_PTHREADS="")
+else
+    case $host_os in
+      osf*)
+        LIBS_PTHREADS="-lpthread $LIBS_PTHREADS"
+        ;;
+    esac
 fi
 
-if test $flag = no && x$LIBS_PTHREADS = x; then
+if test $flag = no && test x$LIBS_PTHREADS = x; then
   threads_ok=no
 else
   threads_ok=yes
index 56ccb7b5fbfb0db5d208aab9a4b9122dad44653d..51319e83edab3ad2aeec387ecd4f75aaa3f0a14b 100755 (executable)
@@ -33,7 +33,7 @@ done
 if test x$dirParams = "xyes"; then
 mkdir -p $dirPath
 else
-cp $args $dirPath
+cp -f $args $dirPath
 for arg in $args; do
 myArg=`basename $arg`
 if test x$chmodParams != x; then
index 72ea0ab112824338a063a7c3e6d063a015f86911..d1f43ea6aad3261cdfbf6536c5cc9ce06dbe2628 100644 (file)
@@ -32,13 +32,14 @@ int main() { return 0; }
 EOF
   $CXX $1 conftest.cxx > conftest.log 2>&1
   var=`echo $1 | sed -e "s, .*$,," | sed -e "s,^-,,"`
-  if ! grep -e $var conftest.log > /dev/null 2>&1 ; then
+#CCRT  if ! grep -e $var conftest.log > /dev/null 2>&1 ; then
+  if grep -e $var conftest.log > /dev/null 2>&1 ; then
+    AC_MSG_RESULT(no)
+    eval $4
+  else
     AC_MSG_RESULT(yes)
     $2="${$2} $1"
     eval $3
-  else
-    AC_MSG_RESULT(no)
-    eval $4
   fi
 ])
 
index e15447648dfffe1b68a8efa17d8eb6a7280be932..6176ef192eb06c95fb816dd2737b3fe2060c9f7e 100644 (file)
@@ -37,7 +37,7 @@ BOOST_LIBTHREAD=""
 
 boost_ok=no
 
-if test -z ${BOOSTDIR}; then
+if test -z "${BOOSTDIR}"; then
   AC_CHECK_HEADER(boost/shared_ptr.hpp,boost_ok=yes,boost_ok=no)
   if test boost_ok = no ; then
     AC_MSG_WARN(You must provide BOOSTDIR variable)
index 2a0a0ccb954af251e3e771bb5d8fdcffde6a9b46..7acf7f8f8713841401100cdf2a83c055ac850990 100644 (file)
@@ -75,7 +75,7 @@ esac
 
 AC_MSG_CHECKING(for OpenCascade directories)
 
-if test -z $CASROOT; then
+if test -z "$CASROOT"; then
   AC_MSG_RESULT(CASROOT not defined)
   for d in `echo $LD_LIBRARY_PATH | sed -e "s/:/ /g"` ; do
     if test -f $d/libTKernel.so ; then
@@ -101,7 +101,7 @@ fi
 
 
 dnl were is OCC ?
-if test -z $CASROOT; then
+if test -z "$CASROOT"; then
   AC_MSG_WARN(You must provide CASROOT variable : see OCC installation manual)
 else
   occ_ok=yes
index d000a1d87e122a5fa240571a04eb94d34e82c224..9de130c26bd2796d0b935ed4b928738abb3776a6 100644 (file)
@@ -19,7 +19,7 @@ AC_ARG_WITH(cppunit_inc,
       AC_MSG_RESULT("select $withval as path to CPPUNIT includes")
     ])
 
-if test -z $CPPUNITHOME; then
+if test -z "$CPPUNITHOME"; then
   AC_MSG_RESULT(CPPUNITHOME not defined)
   exits_ok=no  
   if test "x$exits_ok" = "xno"; then
@@ -43,12 +43,12 @@ if test -z $CPPUNITHOME; then
      done
   fi
   if test "x$exits_ok" = "xyes"; then
-     if test -z $CPPUNIT_INCLUDES; then
+     if test -z "$CPPUNIT_INCLUDES"; then
         CPPUNIT_INCLUDES=$CPPUNITHOME"/include"
      fi
   fi
 else
-  if test -z $CPPUNIT_INCLUDES; then
+  if test -z "$CPPUNIT_INCLUDES"; then
      CPPUNIT_INCLUDES="$CPPUNITHOME/include"
   fi           
 fi
index 8d0c5474f5ce7a297f17a1c9e1659d54dd8d4aa2..db3b35910059a2bb885ab852864a3b075c28b167 100755 (executable)
@@ -13,7 +13,7 @@ AC_ARG_WITH(msg2qm,
            [  --with-msg2qm=DIR               root directory path of MSG2QM installation],
            MSG2QM_DIR="$withval",MSG2QM_DIR="")
 
-if test "x$MSG2QM_DIR" == "x" ; then
+if test "x$MSG2QM_DIR" = "x" ; then
 
 # no --with-MSG2QM-dir option used
 
index 7a6b6fd6dd8416103438511d68c22247d6dd81a5..392a70aa05caa11513e79e038a48436d6318af09 100644 (file)
@@ -70,6 +70,12 @@ then
       ;;
   esac
   case $build_os in
+    osf*)
+      AC_DEFINE(__osf1__)
+      __OSVERSION__=5
+      AC_DEFINE(__OSVERSION__)
+      OMNIORB_CXXFLAGS="$OMNIORB_CXXFLAGS -D__osf1__"
+      ;;
     solaris*)
       AC_DEFINE(__sunos__)
       __OSVERSION__=5
index ee024efaf8fc2c8caa136b4e12028a1dfe9d430c..2b6ae67ea9f4aaea8f487c2617c7fc2bd52d9af1 100644 (file)
@@ -37,47 +37,47 @@ if test "x$PYUIC" != x; then
   dnl try withval value
   AC_CHECK_FILE($PYUIC,pyqt_uic_ok=yes,pyqt_uic_ok=no)
 fi
-if test "x$pyqt_uic_ok" == "xno"; then
+if test "x$pyqt_uic_ok" = "xno"; then
   dnl try ${PYQTDIR}
   if test "x${PYQTDIR}" != "x"; then
     if test -d ${PYQTDIR} ; then
       AC_CHECK_FILE(${PYQTDIR}/pyuic,pyqt_uic_ok=yes,pyqt_uic_ok=no)
-      if test "x$pyqt_uic_ok" == "xyes"; then
+      if test "x$pyqt_uic_ok" = "xyes"; then
         PYUIC="${PYQTDIR}/pyuic"
       fi
     fi
   fi   
 fi
-if test "x$pyqt_uic_ok" == "xno"; then
+if test "x$pyqt_uic_ok" = "xno"; then
   dnl try ${SIPDIR}
   if test "x${SIPDIR}" != "x"; then
     if test -d ${SIPDIR} ; then
       AC_CHECK_FILE(${SIPDIR}/pyuic,pyqt_uic_ok=yes,pyqt_uic_ok=no)
-      if test "x$pyqt_uic_ok" == "xyes"; then
+      if test "x$pyqt_uic_ok" = "xyes"; then
         PYUIC="${SIPDIR}/pyuic"
       fi
     fi
   fi   
 fi
-if test "x$pyqt_uic_ok" == "xno"; then
+if test "x$pyqt_uic_ok" = "xno"; then
   dnl try ${PYTHONHOME}/bin
   if test "x${PYTHONHOME}" != "x"; then
     if test -d ${PYTHONHOME}/bin ; then
       AC_CHECK_FILE(${PYTHONHOME}/bin/pyuic,pyqt_uic_ok=yes,pyqt_uic_ok=no)
-      if test "x$pyqt_uic_ok" == "xyes"; then
+      if test "x$pyqt_uic_ok" = "xyes"; then
         PYUIC="${PYTHONHOME}/bin/pyuic"
       fi
     fi
   fi   
 fi
-if test "x$pyqt_uic_ok" == "xno"; then
+if test "x$pyqt_uic_ok" = "xno"; then
   dnl try /usr/bin
   AC_CHECK_FILE(/usr/bin/pyuic,pyqt_uic_ok=yes,pyqt_uic_ok=no)
-  if test "x$pyqt_uic_ok" == "xyes"; then
+  if test "x$pyqt_uic_ok" = "xyes"; then
     PYUIC="/usr/bin/pyuic"
   fi
 fi
-if test "x$pyqt_uic_ok" == "xno"; then
+if test "x$pyqt_uic_ok" = "xno"; then
   pyqt_ok=no
 fi
 
@@ -86,7 +86,7 @@ pyqt_lib_ok=no
 if test "x${PYQTDIR}" != "x"; then
   dnl try {PYQTDIR}
   AC_CHECK_FILE(${PYQTDIR}/libqtcmodule.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-  if test "x$pyqt_lib_ok" == "xyes"; then
+  if test "x$pyqt_lib_ok" = "xyes"; then
     if test "x${PYQTDIR}" = "x/usr/lib"
     then
       PYQT_LIBS="-lqtcmodule"
@@ -95,7 +95,7 @@ if test "x${PYQTDIR}" != "x"; then
     fi
   else 
     AC_CHECK_FILE(${PYQTDIR}/qt.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-    if test "x$pyqt_lib_ok" == "xyes"; then
+    if test "x$pyqt_lib_ok" = "xyes"; then
       if test "x${PYQTDIR}" = "x/usr/lib"
       then
         PYQT_LIBS=""
@@ -104,41 +104,41 @@ if test "x${PYQTDIR}" != "x"; then
       fi
     fi
   fi
-  if test "x$pyqt_lib_ok" == "xno"; then
+  if test "x$pyqt_lib_ok" = "xno"; then
     dnl try {PYQTDIR}/lib
     if test -d {PYQTDIR}/lib; then
       AC_CHECK_FILE(${PYQTDIR}/lib/libqtcmodule.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-      if test "x$pyqt_lib_ok" == "xyes"; then
+      if test "x$pyqt_lib_ok" = "xyes"; then
         PYQT_LIBS="-L${PYQTDIR}/lib -lqtcmodule"
       else 
         AC_CHECK_FILE(${PYQTDIR}/lib/qt.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-        if test "x$pyqt_lib_ok" == "xyes"; then
+        if test "x$pyqt_lib_ok" = "xyes"; then
           PYQT_LIBS="-L${PYQTDIR}/lib"
         fi
       fi
     fi
   fi
-  if test "x$pyqt_lib_ok" == "xno"; then
+  if test "x$pyqt_lib_ok" = "xno"; then
     dnl try {PYQTDIR}/lib/python${PYTHON_VERSION}/site-packages
     if test -d {PYQTDIR}/lib/python${PYTHON_VERSION}/site-packages; then
       AC_CHECK_FILE(${PYQTDIR}/lib/python${PYTHON_VERSION}/site-packages/libqtcmodule.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-      if test "x$pyqt_lib_ok" == "xyes"; then
+      if test "x$pyqt_lib_ok" = "xyes"; then
         PYQT_LIBS="-L${PYQTDIR}/lib/python${PYTHON_VERSION}/site-packages -lqtcmodule"
       else 
         AC_CHECK_FILE(${PYQTDIR}/lib/python${PYTHON_VERSION}/site-packages/qt.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-        if test "x$pyqt_lib_ok" == "xyes"; then
+        if test "x$pyqt_lib_ok" = "xyes"; then
           PYQT_LIBS="-L${PYQTDIR}/lib/python${PYTHON_VERSION}/site-packages"
         fi
       fi
     fi
   fi
 fi
-if test "x$pyqt_lib_ok" == "xno"; then
+if test "x$pyqt_lib_ok" = "xno"; then
   dnl try ${SIPDIR}
   if test "x${SIPDIR}" != "x"; then
     if test -d ${SIPDIR} ; then
       AC_CHECK_FILE(${SIPDIR}/libqtcmodule.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-      if test "x$pyqt_lib_ok" == "xyes"; then
+      if test "x$pyqt_lib_ok" = "xyes"; then
         if test "x${SIPDIR}" = "x/usr/lib"
         then
           PYQT_LIBS="-lqtcmodule"
@@ -147,7 +147,7 @@ if test "x$pyqt_lib_ok" == "xno"; then
         fi
       else 
         AC_CHECK_FILE(${SIPDIR}/qt.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-        if test "x$pyqt_lib_ok" == "xyes"; then
+        if test "x$pyqt_lib_ok" = "xyes"; then
           if test "x${SIPDIR}" = "x/usr/lib"
           then
             PYQT_LIBS=""
@@ -159,35 +159,35 @@ if test "x$pyqt_lib_ok" == "xno"; then
     fi
   fi
 fi
-if test "x$pyqt_lib_ok" == "xno"; then
+if test "x$pyqt_lib_ok" = "xno"; then
   dnl try ${PYTHONHOME}/lib/python${PYTHON_VERSION}/site-packages
   if test "x${PYTHONHOME}" != "x"; then
     if test -d ${PYTHONHOME}/lib/python${PYTHON_VERSION}/site-packages ; then
       AC_CHECK_FILE(${PYTHONHOME}/lib/python${PYTHON_VERSION}/site-packages/libqtcmodule.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-      if test "x$pyqt_lib_ok" == "xyes"; then
+      if test "x$pyqt_lib_ok" = "xyes"; then
         PYQT_LIBS="-L${PYTHONHOME}/lib/python${PYTHON_VERSION}/site-packages -lqtcmodule"
       else 
         AC_CHECK_FILE(${PYTHONHOME}/lib/python${PYTHON_VERSION}/site-packages/qt.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-        if test "x$pyqt_lib_ok" == "xyes"; then
+        if test "x$pyqt_lib_ok" = "xyes"; then
           PYQT_LIBS="-L${PYTHONHOME}/lib/python${PYTHON_VERSION}/site-packages"
         fi
       fi
     fi
   fi   
 fi
-if test "x$pyqt_lib_ok" == "xno"; then
+if test "x$pyqt_lib_ok" = "xno"; then
   dnl try /usr/lib/python${PYTHON_VERSION}/site-packages
   AC_CHECK_FILE(/usr/lib/python${PYTHON_VERSION}/site-packages/libqtcmodule.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-  if test "x$pyqt_lib_ok" == "xyes"; then
+  if test "x$pyqt_lib_ok" = "xyes"; then
     PYQT_LIBS="-L/usr/lib/python${PYTHON_VERSION}/site-packages -lqtcmodule"
   else 
     AC_CHECK_FILE(/usr/lib/python${PYTHON_VERSION}/site-packages/qt.so,pyqt_lib_ok=yes,pyqt_lib_ok=no)
-    if test "x$pyqt_lib_ok" == "xyes"; then
+    if test "x$pyqt_lib_ok" = "xyes"; then
       PYQT_LIBS="-L/usr/lib/python${PYTHON_VERSION}/site-packages"
     fi
   fi
 fi
-if test "x$pyqt_lib_ok" == "xno"; then
+if test "x$pyqt_lib_ok" = "xno"; then
   pyqt_ok=no
 fi
 
@@ -196,60 +196,60 @@ pyqt_sips_ok=no
 dnl try ${PYQT_SIPS} or ${PYQT_SIPS}/qt
 if test "x${PYQT_SIPS}" != "x"; then
   AC_CHECK_FILE(${PYQT_SIPS}/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-  if test "x$pyqt_sips_ok" == "xno"; then
+  if test "x$pyqt_sips_ok" = "xno"; then
     AC_CHECK_FILE(${PYQT_SIPS}/qt/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-    if test "x$pyqt_sips_ok" == "xyes"; then
+    if test "x$pyqt_sips_ok" = "xyes"; then
       PYQT_SIPS="${PYQT_SIPS}/qt"
     fi
   fi
 fi
-if test "x$pyqt_sips_ok" == "xno"; then
+if test "x$pyqt_sips_ok" = "xno"; then
   dnl try ${PYQTDIR}/sip
   if test "x${PYQTDIR}" != "x"; then
     if test -d ${PYQTDIR}/sip ; then
       AC_CHECK_FILE(${PYQTDIR}/sip/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-      if test "x$pyqt_sips_ok" == "xyes"; then
+      if test "x$pyqt_sips_ok" = "xyes"; then
         PYQT_SIPS="${PYQTDIR}/sip"
       else
         AC_CHECK_FILE(${PYQTDIR}/sip/qt/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-        if test "x$pyqt_sips_ok" == "xyes"; then
+        if test "x$pyqt_sips_ok" = "xyes"; then
           PYQT_SIPS="${PYQTDIR}/sip/qt"
         fi
       fi
     fi
   fi
 fi
-if test "x$pyqt_sips_ok" == "xno"; then
+if test "x$pyqt_sips_ok" = "xno"; then
   dnl try ${SIPDIR}/sip
   if test "x${SIPDIR}" != "x"; then
     if test -d ${SIPDIR}/sip ; then
       AC_CHECK_FILE(${SIPDIR}/sip/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-      if test "x$pyqt_sips_ok" == "xyes"; then
+      if test "x$pyqt_sips_ok" = "xyes"; then
         PYQT_SIPS="${SIPDIR}/sip"
       else
         AC_CHECK_FILE(${SIPDIR}/sip/qt/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-        if test "x$pyqt_sips_ok" == "xyes"; then
+        if test "x$pyqt_sips_ok" = "xyes"; then
           PYQT_SIPS="${SIPDIR}/sip/qt"
         fi
       fi
     fi
   fi
 fi
-if test "x$pyqt_sips_ok" == "xno"; then
+if test "x$pyqt_sips_ok" = "xno"; then
   dnl try /usr/share/sip
   if test -d /usr/share/sip ; then
     AC_CHECK_FILE(/usr/share/sip/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-    if test "x$pyqt_sips_ok" == "xyes"; then
+    if test "x$pyqt_sips_ok" = "xyes"; then
       PYQT_SIPS="/usr/share/sip"
     else
       AC_CHECK_FILE(/usr/share/sip/qt/qglobal.sip,pyqt_sips_ok=yes,pyqt_sips_ok=no)
-      if test "x$pyqt_sips_ok" == "xyes"; then
+      if test "x$pyqt_sips_ok" = "xyes"; then
         PYQT_SIPS="/usr/share/sip/qt"
       fi
     fi
   fi
 fi
-if test "x$pyqt_sips_ok" == "xno"; then
+if test "x$pyqt_sips_ok" = "xno"; then
   pyqt_ok=no
 else
   PYQT_INCLUDES="-I$PYQT_SIPS"
index 13bf909147ba480271412e1db79e227c3a09d191..abfccc740f4e0c788be2c3860d52a50113834eec 100644 (file)
@@ -21,7 +21,7 @@ AC_ARG_WITH(qwt_inc,
       AC_MSG_RESULT("select $withval as path to QWT includes")
     ])
 
-if test -z $QWTHOME; then
+if test -z "$QWTHOME"; then
   AC_MSG_RESULT(QWTHOME not defined)
   exits_ok=no  
   if test "x$exits_ok" = "xno"; then
@@ -45,7 +45,7 @@ if test -z $QWTHOME; then
      done
   fi
   if test "x$exits_ok" = "xyes"; then
-     if test -z $QWT_INCLUDES; then
+     if test -z "$QWT_INCLUDES"; then
         QWT_INCLUDES=$QWTHOME"/include/qwt"
         if test ! -f $QWT_INCLUDES/qwt.h ; then
           QWT_INCLUDES=$QWTHOME"/include"
@@ -56,7 +56,7 @@ if test -z $QWTHOME; then
      fi
   fi
 else
-  if test -z $QWT_INCLUDES; then
+  if test -z "$QWT_INCLUDES"; then
      QWT_INCLUDES="$QWTHOME/include"
   fi           
 fi
index 245f2382ee200c658920e7c611dfef42445ea64a..4158e9988c635740c8042746ae77a6e2f0ad0f62 100644 (file)
@@ -53,33 +53,33 @@ else
     if test "x$SIPDIR" != "x" ; then
         dnl look for sip.h in ${SIPDIR}
         AC_CHECK_FILE(${SIPDIR}/sip.h,sip_ok=yes,sip_ok=no)
-       if test "x$sip_ok" == "xyes" ; then
+       if test "x$sip_ok" = "xyes" ; then
            SIP_INCLUDES="-I${SIPDIR}"
        fi
-        if test "x$sip_ok" == "xno" ; then
+        if test "x$sip_ok" = "xno" ; then
             dnl look for sip.h in ${SIPDIR}/include/python${PYTHON_VERSION}
            if test -d ${SIPDIR}/include/python${PYTHON_VERSION} ; then
                AC_CHECK_FILE(${SIPDIR}/include/python${PYTHON_VERSION}/sip.h,sip_ok=yes,sip_ok=no)
-               if test "x$sip_ok" == "xyes" ; then
+               if test "x$sip_ok" = "xyes" ; then
                    SIP_INCLUDES="-I${SIPDIR}/include/python${PYTHON_VERSION}"
                fi
            fi
        fi
     fi
-    if test "x$sip_ok" == "xno" ; then
+    if test "x$sip_ok" = "xno" ; then
         dnl look for sip.h in ${PYTHON_PREFIX}/include/python${PYTHON_VERSION}
        if test -d ${PYTHON_PREFIX}/include/python${PYTHON_VERSION} ; then
             AC_CHECK_FILE(${PYTHON_PREFIX}/include/python${PYTHON_VERSION}/sip.h,sip_ok=yes,sip_ok=no)
-           if test "x$sip_ok" == "xyes" ; then
+           if test "x$sip_ok" = "xyes" ; then
                SIP_INCLUDES="${PYTHON_INCLUDES}"
             fi
        fi
     fi
-    if test "x$sip_ok" == "xno" ; then
+    if test "x$sip_ok" = "xno" ; then
         dnl look for sip.h in /usr/include/python${PYTHON_VERSION}
        if test -d /usr/include/python${PYTHON_VERSION} ; then
             AC_CHECK_FILE(/usr/include/python${PYTHON_VERSION}/sip.h,sip_ok=yes,sip_ok=no)
-           if test "x$sip_ok" == "xyes" ; then
+           if test "x$sip_ok" = "xyes" ; then
                SIP_INCLUDES="/usr/include/python${PYTHON_VERSION}"
             fi
        fi
@@ -90,7 +90,7 @@ else
     if test "x$SIPDIR" != "x" ; then
         dnl look for (lib)sip.so in ${SIPDIR}
         AC_CHECK_FILE(${SIPDIR}/libsip.so,sip_lib_ok=yes,sip_lib_ok=no)
-       if test "x$sip_lib_ok" == "xyes" ; then
+       if test "x$sip_lib_ok" = "xyes" ; then
             if test "x${SIPDIR}" = "x/usr/lib"
             then
               SIP_LIBS="-lsip"
@@ -99,7 +99,7 @@ else
             fi
        else
            AC_CHECK_FILE(${SIPDIR}/sip.so,sip_lib_ok=yes,sip_lib_ok=no)
-           if test "x$sip_lib_ok" == "xyes" ; then
+           if test "x$sip_lib_ok" = "xyes" ; then
               if test "x${SIPDIR}" = "x/usr/lib"
               then
                 SIP_LIBS=""
@@ -109,50 +109,50 @@ else
            fi
        fi
 
-        if test "x$sip_lib_ok" == "xno" ; then
+        if test "x$sip_lib_ok" = "xno" ; then
             dnl look for (lib)sip.so in ${SIPDIR}/lib/python${PYTHON_VERSION}/site-packages
            if test -d ${SIPDIR}/lib/python${PYTHON_VERSION}/site-packages ; then
                AC_CHECK_FILE(${SIPDIR}/lib/python${PYTHON_VERSION}/site-packages/libsip.so,sip_lib_ok=yes,sip_lib_ok=no)
-               if test "x$sip_lib_ok" == "xyes" ; then
+               if test "x$sip_lib_ok" = "xyes" ; then
                    SIP_LIBS="-L${SIPDIR}/lib/python${PYTHON_VERSION}/site-packages -lsip"
                else
                    AC_CHECK_FILE(${SIPDIR}/lib/python${PYTHON_VERSION}/site-packages/sip.so,sip_lib_ok=yes,sip_lib_ok=no)
-                   if test "x$sip_lib_ok" == "xyes" ; then
+                   if test "x$sip_lib_ok" = "xyes" ; then
                        SIP_LIBS="-L${SIPDIR}/lib/python${PYTHON_VERSION}/site-packages"
                    fi
                fi
            fi
        fi
     fi
-    if test "x$sip_lib_ok" == "xno" ; then
+    if test "x$sip_lib_ok" = "xno" ; then
         dnl look for (lib)sip.so in ${PYTHON_PREFIX}/lib/python${PYTHON_VERSION}/site-packages
        if test -d ${PYTHON_PREFIX}/lib/python${PYTHON_VERSION}/site-packages ; then
             AC_CHECK_FILE(${PYTHON_PREFIX}/lib/python${PYTHON_VERSION}/site-packages/libsip.so,sip_lib_ok=yes,sip_lib_ok=no)
-           if test "x$sip_lib_ok" == "xyes" ; then
+           if test "x$sip_lib_ok" = "xyes" ; then
                SIP_LIBS="-L${PYTHON_PREFIX}/lib/python${PYTHON_VERSION}/site-packages -lsip"
            else
                AC_CHECK_FILE(${PYTHON_PREFIX}/lib/python${PYTHON_VERSION}/site-packages/sip.so,sip_lib_ok=yes,sip_lib_ok=no)
-                if test "x$sip_lib_ok" == "xyes" ; then
+                if test "x$sip_lib_ok" = "xyes" ; then
                    SIP_LIBS="-L${PYTHON_PREFIX}/lib/python${PYTHON_VERSION}/site-packages"
                 fi
            fi
        fi
     fi
-    if test "x$sip_lib_ok" == "xno" ; then
+    if test "x$sip_lib_ok" = "xno" ; then
         dnl look for (lib)sip.so in /usr/lib/python${PYTHON_VERSION}/site-packages
        if test -d /usr/lib/python${PYTHON_VERSION}/site-packages ; then
             AC_CHECK_FILE(/usr/lib/python${PYTHON_VERSION}/site-packages/libsip.so,sip_lib_ok=yes,sip_lib_ok=no)
-           if test "x$sip_lib_ok" == "xyes" ; then
+           if test "x$sip_lib_ok" = "xyes" ; then
                SIP_LIBS="-L$/usr/lib/python${PYTHON_VERSION}/site-packages -lsip"
            else
                AC_CHECK_FILE(/usr/lib/python${PYTHON_VERSION}/site-packages/sip.so,sip_lib_ok=yes,sip_lib_ok=no)
-                if test "x$sip_lib_ok" == "xyes" ; then
+                if test "x$sip_lib_ok" = "xyes" ; then
                    SIP_LIBS="-L/usr/lib/python${PYTHON_VERSION}/site-packages"
                fi
             fi
        fi
     fi
-    if test "x$sip_lib_ok" == "xno" ; then
+    if test "x$sip_lib_ok" = "xno" ; then
         sip_ok=no
     fi
 fi
index df9245b5de903be1c160a1b0b9c6b232ded6f716..5d06c91329e57f56790c92caaf4f3616ab925aad 100644 (file)
@@ -74,7 +74,7 @@ LOCAL_INCLUDES="$OGL_INCLUDES"
 LOCAL_LIBS="-lvtkCommon -lvtkGraphics -lvtkImaging -lvtkFiltering -lvtkIO -lvtkRendering -lvtkHybrid $OGL_LIBS $LXLIB -lX11 -lXt"
 TRY_LINK_LIBS="-lvtkCommon $OGL_LIBS $LXLIB -lX11 -lXt"
 
-if test -z $VTKHOME
+if test -z "$VTKHOME"
 then 
    AC_MSG_WARN(undefined VTKHOME variable which specify where vtk was compiled)
    if test -f /usr/include/vtk/vtkPlane.h ; then
@@ -83,7 +83,7 @@ then
    fi
 fi
 
-if test ! -z $VTKHOME
+if test ! -z "$VTKHOME"
 then
    LOCAL_INCLUDES="-I$VTKHOME/include/vtk $LOCAL_INCLUDES"
    LOCAL_LIBS="-L$VTKHOME/lib/vtk $LOCAL_LIBS"
index 91585a2ae1d1a92b4162e9f6b4c195575bfcde75..39d190bd880d00e84565d197bb4e73a652d8482d 100644 (file)
@@ -37,7 +37,9 @@ using namespace std;
 void HouseKeeping();
 
 std::list<PROTECTED_DELETE*> PROTECTED_DELETE::_objList;
-pthread_mutex_t PROTECTED_DELETE::_listMutex;
+//CCRT
+pthread_mutex_t PROTECTED_DELETE::_listMutex = PTHREAD_MUTEX_INITIALIZER ;
+//pthread_mutex_t PROTECTED_DELETE::_listMutex ;
 
 std::list<GENERIC_DESTRUCTOR*> *GENERIC_DESTRUCTOR::Destructors = 0;
 static bool atExitSingletonDone = false ;
index 48b3ac787f6d87481e090fd2f0a8d2116819ebf8..96779e09fd65fdb2080c6f9162ce8f69ef3c2f06 100644 (file)
 //  $Header$
 
 //#define private public
-#include <SALOMEconfig.h>
-#ifndef WNT
-#include CORBA_SERVER_HEADER(SALOME_Component)
-#else
-#include <SALOME_Component.hh>
-#endif
-#include <pthread.h>  // must be before Python.h !
-#include <Python.h>
-#include "SALOME_Container_i.hxx"
-#include "SALOME_Component_i.hxx"
-#include "SALOME_NamingService.hxx"
-#include "OpUtil.hxx"
 #include <string.h>
 #include <stdio.h>
+#include <time.h>
+#include <sys/time.h>
 #ifndef WNT
 #include <dlfcn.h>
 #include <unistd.h>
 #include <process.h>
 int SIGUSR1 = 1000;
 #endif
-#include "Container_init_python.hxx"
 
 #include "utilities.h"
+#include <SALOMEconfig.h>
+#ifndef WNT
+#include CORBA_SERVER_HEADER(SALOME_Component)
+#else
+#include <SALOME_Component.hh>
+#endif
+#include <pthread.h>  // must be before Python.h !
+#include "SALOME_Container_i.hxx"
+#include "SALOME_Component_i.hxx"
+#include "SALOME_NamingService.hxx"
+#include "OpUtil.hxx"
+
+#include <Python.h>
+#include "Container_init_python.hxx"
+
 using namespace std;
 
 bool _Sleeping = false ;
@@ -96,7 +100,7 @@ Engines_Container_i::Engines_Container_i () :
 //=============================================================================
 
 Engines_Container_i::Engines_Container_i (CORBA::ORB_ptr orb, 
-                                         PortableServer::POA_ptr poa,
+                                         PortableServer::POA_var poa,
                                          char *containerName ,
                                           int argc , char* argv[],
                                          bool activAndRegist,
@@ -307,10 +311,12 @@ Engines_Container_i::load_component_Library(const char* componentName)
     }
   
   void* handle;
-#ifndef WNT
-  handle = dlopen( impl_name.c_str() , RTLD_LAZY ) ;
-#else
+#if defined( WNT )
   handle = dlopen( impl_name.c_str() , 0 ) ;
+//#elif defined( __osf1__ )
+//  handle = dlopen( impl_name.c_str() , RTLD_NOW ) ;
+#else
+  handle = dlopen( impl_name.c_str() , RTLD_LAZY ) ;
 #endif
   if ( handle )
     {
index 7a4e585275ec41032421a6703d2b045ddd242362..427d03ec497b9ce0ecaaa24fb4319739c5feedf5 100644 (file)
 //  Module : KERNEL
 //  $Header$
 
-#include "Container_init_python.hxx"
+#include <time.h>
+#include <sys/time.h>
 
 #include "utilities.h"
+
+#include "Container_init_python.hxx"
+
 using namespace std;
 
 PyThreadState *KERNEL_PYTHON::_gtstate = 0;
index d7c62076e9cf741175307c1124efc2388045b837..2639ef800d6a92c657e1f4190927aa5b71e61063 100644 (file)
 #endif
 
 #include <iostream>
+#include <strstream>
 #include <string>
 #include <stdio.h>
+#include <time.h>
+#include <sys/time.h>
+#include <dlfcn.h>
 
 #ifndef WNT
 #include <unistd.h>
@@ -66,7 +70,7 @@ int main(int argc, char* argv[])
   //CORBA::ORB_var orb = CORBA::ORB_init( argc , argv ) ;
   ORB_INIT &init = *SINGLETON_<ORB_INIT>::Instance() ;
   ASSERT(SINGLETON_<ORB_INIT>::IsAlreadyExisting());
-  CORBA::ORB_var orb = init(0 , 0 ) ;
+  CORBA::ORB_ptr orb = init(0 , 0 ) ;
          
   //  LocalTraceCollector *myThreadTrace = SALOMETraceCollector::instance(orb);
   INFOS_COMPILATION;
@@ -105,9 +109,9 @@ int main(int argc, char* argv[])
 
       // add new container to the kill list
 #ifndef WNT
-      char aCommand[40];
-      sprintf(aCommand, "addToKillList.py %d SALOME_Container", getpid());
-      system(aCommand);
+      ostrstream aCommand ;
+      aCommand << "addToKillList.py " << getpid() << " SALOME_Container" << ends ;
+      system(aCommand.str());
 #endif
       
       Engines_Container_i * myContainer 
@@ -119,10 +123,9 @@ int main(int argc, char* argv[])
       Utils_Timer timer;
       timer.Start();
       timer.Stop();
-      MESSAGE("SALOME_Registry_Server.cxx - orb->run()");
       timer.ShowAbsolute();
 #endif
-      
+
       HandleServerSideSignals(orb);
       
     }
index d6f42160808e8720aa154c7b15dd020d1cc45358..0faa4f1d3a50c6e915573b914a2c9ad61354d4c1 100644 (file)
@@ -26,7 +26,7 @@ int main(int argc, char* argv[])
   PortableServer::POAManager_var pman;
   CORBA::Object_var obj;
 
-  CORBA::ORB_var orb = CORBA::ORB_init( argc , argv ) ;
+  CORBA::ORB_ptr orb = CORBA::ORB_init( argc , argv ) ;
   //  LocalTraceCollector *myThreadTrace = SALOMETraceCollector::instance(orb);
   INFOS_COMPILATION;
   BEGIN_OF(argv[0]);
index be21173b0f1bb1983902818828fac09539d092c4..b3b6db4f3e4f2a2860d5693d8b19a230b5ee754c 100644 (file)
@@ -67,7 +67,7 @@ class CONTAINER_EXPORT Engines_Container_i:
 public:
   Engines_Container_i();
   Engines_Container_i(CORBA::ORB_ptr orb, 
-                     PortableServer::POA_ptr poa,
+                     PortableServer::POA_var poa,
                      char * containerName ,
                       int argc, char* argv[],
                      bool activAndRegist = true,
index 3400d4474cbc538dcde1293c98d527e35bb8a48d..048c32c818c76a3a2408a5762f1df562d145b867 100644 (file)
 //
 // See http://www.salome-platform.org/
 //
-#include <Launchers.hxx>
+
+#include <time.h>
+#include <sys/time.h>
+
 #include "utilities.h"
 
+#include <Launchers.hxx>
+
 using namespace std;
 
 static int Launchers_IsLoaded = 0;
index f5d7d6fc36d7331b5eecab0d3c8a1c4a1ba3c95b..60e22e9098573cea5e3ab979006336ec102a27de 100644 (file)
 #include <sstream>
 #include <iomanip>
 
+#include <time.h>
+#include <sys/time.h>
+
 #include "OpUtil.hxx"
 #include "utilities.h"
-#include "Launchers.hxx"
 
 #include <ServiceUnreachable.hxx>
 
@@ -46,6 +48,8 @@
 #include "SALOME_ContainerManager.hxx"
 #include "SALOME_Component_i.hxx"
 #include "SALOME_NamingService.hxx"
+#include "Launchers.hxx"
+
 using namespace std;
 
 IncompatibleComponent::IncompatibleComponent( void ):
index 147e072d4882a284736a1cd16e025aaceac31b3a..a03a556be24d4470b88a6bab18682dc320f44060 100644 (file)
@@ -1,18 +1,65 @@
 
+#from TestLifeCycleCORBA import *
+
+import os
 import Engines
 import LifeCycleCORBA
 
+host = os.getenv( 'HOST' )
+
 lcc = LifeCycleCORBA.LifeCycleCORBA()
 
-#obj=lcc.FindOrLoad_Component("FactoryServer","SalomeTestComponent")
-#comp=obj._narrow(Engines.TestComponent)
-#comp.Coucou(1)
+try :
+    obj=lcc.FindOrLoad_Component("FactoryServer","SalomeTestComponent")
+    comp=obj._narrow(Engines.TestComponent)
+    comp.Coucou(1)
+    param={}
+    #param['hostname']='cli76cc'
+    param['hostname']=host
+    param['container_name']='FactoryServer'
+    comp=lcc.FindOrLoad_Component(param,'SalomeTestComponent')
+    engine=lcc.FindComponent(param,'SalomeTestComponent')
+    engine.Coucou(1)
+except :
+    print 'lcc.FindOrLoad_Component("FactoryServer","SalomeTestComponent") failed'
+
+import sys
+import CORBA
+import CosNaming
+orb = CORBA.ORB_init(sys.argv, CORBA.ORB_ID)
+obj = orb.resolve_initial_references("NameService")
+rootContext = obj._narrow(CosNaming.NamingContext)
+context_name=[]
+context_name.append(CosNaming.NameComponent( 'ContainerManager' , 'object' ) )
+ContainerManager = rootContext.resolve( context_name )
+
+try :
+    myContainerparamsCPP = Engines.MachineParameters( 'myContainer' , host , 'osf' , 0 , 0 , 0 , 0 , 0 )
+    computerlistCPP = [host]
+    containerCPP = ContainerManager.FindOrStartContainer( myContainerparamsCPP , computerlistCPP )
+    containerCPP.ping()
+    ComponentparamsCPP={}
+    ComponentparamsCPP['hostname']=host
+    ComponentparamsCPP['container_name']='myContainer'
+    compCPP=lcc.FindOrLoad_Component(ComponentparamsCPP,'SalomeTestComponent')
+    compCPP.Coucou(1)
+    engineCPP=lcc.FindComponent(ComponentparamsCPP,'SalomeTestComponent')
+    engineCPP.Coucou(1)
+except :
+    print 'ContainerManager.FindOrStartContainer( myContainerparams , computerlist ) C++ failed'
 
-param={}
-param['hostname']='cli76cc'
-param['container_name']='myContainer'
-smesh=lcc.FindOrLoad_Component(param,'PYHELLO')
+try :
+    myContainerparamsPy = Engines.MachineParameters( 'myContainerPy' , host , 'osf' , 0 , 0 , 0 , 0 , 0 )
+    computerlistPy = [host]
+    containerPy = ContainerManager.FindOrStartContainer( myContainerparamsPy , computerlistPy )
+    containerPy.ping()
+    ComponentparamsPy={}
+    ComponentparamsPy['hostname']=host
+    ComponentparamsPy['container_name']='myContainerPy'
+    compPy=lcc.FindOrLoad_Component(ComponentparamsPy,'SALOME_TestComponentPy')
+    compPy.Coucou(1)
+    enginePy=lcc.FindComponent(ComponentparamsPy,'SALOME_TestComponentPy')
+    enginePy.Coucou(1)
+except :
+    print 'ContainerManager.FindOrStartContainer( myContainerparams , computerlist ) Python failed'
 
-container=lcc.FindContainer('myContainer')
-engine=lcc.FindComponent(param,'HELLO')
-geom=lcc.LoadComponent(param,'GEOM')
index dfeb178e13579d792ccfb0b10b30e9d79103abae..1acd943e3338a9650d4d51486e07460db7df829b 100644 (file)
@@ -33,6 +33,8 @@
 #include "Utils_SINGLETON.hxx"
 #include "OpUtil.hxx"
 #include "utilities.h"
+#include <time.h>
+#include <sys/time.h>
 #include <pthread.h>  // must be before Python.h !
 #include <Python.h>
 #include "Container_init_python.hxx"
index 414ae3c10322e186c70fb1adb51068d913890d57..5a810d7940750caa9ac7995662d7abac3b26ca13 100644 (file)
@@ -79,7 +79,6 @@ libSalomeCatalog_la_SOURCES =\
        SALOME_ModuleCatalog_Acomponent_impl.cxx
 
 libSalomeCatalog_la_CPPFLAGS =\
-       -ftemplate-depth-32 \
        $(COMMON_CPPFLAGS)
 
 libSalomeCatalog_la_LDFLAGS = -no-undefined -version-info=0:0:0
index 94eccf70c1e2208d97cf9a92ab670d552ff83618..64709e7acc97b149d2ebe60f0d1aefa65d35b1ad 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 ROOT_SRCDIR=@ROOT_SRCDIR@
 export ROOT_SRCDIR
index 6b659696ee96a30b44aecc736efb1eb53c563855..2fbd7754c97c7c02f497f756f75644de521ace81 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 #  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
index e3e41193dce7393298a6a5f9d75096c870c67de5..ad837a02c1ccf0212fe7919158919336eb33a87e 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 #  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
index d534140fb7886da10f932a5dc520d99951f2e635..0a61ddef3cfaac7fe181f5f57f71c36c93fc789c 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 #  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
index 3689eb1624efa41cfc4f4ccfa6cdb32b3db840be..fe726682ebeac9b0c77679f39ce6acbe3b52ce10 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 #  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
index d7a0bb83def79909b2de83cbbf7bd109ac08ba03..c6314373c8b66ccd0fd7e00c11a2878731db4a5c 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 #  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
index 41b76c091589d47654d4b4b24d60444779677b7d..69a2a20dcfc8dc291e7cacdd44076124e79aad79 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 #
 #  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
index dcfc754948b8c23c9f4c4d8da241e7da7e719709..c3a37cdd5835909ad594adde3e0c3298729d8e1f 100644 (file)
@@ -131,7 +131,7 @@ SALOMEDS::GenericAttribute_ptr SALOMEDS_GenericAttribute_i::CreateAttribute
 //===========================================================================
 //   PRIVATE FUNCTIONS
 //===========================================================================
-long SALOMEDS_GenericAttribute_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
+CORBA::Long SALOMEDS_GenericAttribute_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
 {
 #ifdef WIN32
   long pid = (long)_getpid();
index def9134a6cb35f7e97580444e9d67e617e6706a7..16694f7e871376801d7ef94bd688f56775ad1a3e 100644 (file)
@@ -57,7 +57,7 @@ public:
 
   static SALOMEDS::GenericAttribute_ptr CreateAttribute(const Handle(TDF_Attribute)& theAttr, CORBA::ORB_ptr theOrb);  
 
-  virtual long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
+  virtual CORBA::Long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
 };
 
 #endif
index 1a8a25c919d1cda6c2f7b66ed7697602d9803a6c..ef0b64640972fad333b55d186107bc653296e56f 100644 (file)
@@ -205,7 +205,7 @@ CORBA::Boolean SALOMEDS_SObject_i::ReferencedObject(SALOMEDS::SObject_out obj)
  *  Purpose  :
  */
 //============================================================================
-CORBA::Boolean SALOMEDS_SObject_i::FindSubObject(long atag, SALOMEDS::SObject_out obj)
+CORBA::Boolean SALOMEDS_SObject_i::FindSubObject(CORBA::Long atag, SALOMEDS::SObject_out obj)
 {
   SALOMEDS::Locker lock;
   Handle(SALOMEDSImpl_SObject) aSubObj;
@@ -318,7 +318,7 @@ char* SALOMEDS_SObject_i::GetIOR()
 //===========================================================================
 //   PRIVATE FUNCTIONS
 //===========================================================================
-long SALOMEDS_SObject_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
+CORBA::Long SALOMEDS_SObject_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
 {
 #ifdef WIN32
   long pid = (long)_getpid();
index 4a04250d53a2bc48af8a8046e260ffe497298d09..c4e4318fdec1e7dd7221263aff3709e7a2c9af7f 100644 (file)
@@ -60,7 +60,7 @@ public:
   virtual SALOMEDS::SObject_ptr    GetFather() ;
   virtual CORBA::Boolean FindAttribute(SALOMEDS::GenericAttribute_out anAttribute, const char* aTypeOfAttribute);
   virtual CORBA::Boolean ReferencedObject(SALOMEDS::SObject_out obj) ;
-  virtual CORBA::Boolean FindSubObject(long atag, SALOMEDS::SObject_out obj );
+  virtual CORBA::Boolean FindSubObject(CORBA::Long atag, SALOMEDS::SObject_out obj );
 
   virtual SALOMEDS::Study_ptr    GetStudy() ;
   virtual char* Name();
@@ -76,7 +76,7 @@ public:
   virtual CORBA::Short Tag();
   virtual CORBA::Short Depth();
 
-  virtual long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
+  virtual CORBA::Long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
 };
 
 #endif
index 1bcaf8caa05b8e323aad1f724a23ec6fde43d7ec..0a12c883b74b3a071b7310e888c8b137ec9f4315 100644 (file)
@@ -456,7 +456,7 @@ PortableServer::POA_ptr SALOMEDS_StudyManager_i::GetPOA(const SALOMEDS::Study_pt
 //===========================================================================
 //   PRIVATE FUNCTIONS
 //===========================================================================
-long SALOMEDS_StudyManager_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
+CORBA::Long SALOMEDS_StudyManager_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
 {
 #ifdef WIN32
   long pid = (long)_getpid();
index ef428ed4cef3803db4afe9f3b4de200115a2703d..2fd96175072f85077673c7ef943aaa62ffee7786 100644 (file)
@@ -142,7 +142,7 @@ public:
   
   void ping(){};
 
-  virtual long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
+  virtual CORBA::Long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
 
   static PortableServer::POA_ptr GetPOA(const SALOMEDS::Study_ptr theStudy);
 };
index 6db403acb979fea4d1cff81947d79957bf042df3..1679b02d713af91f8348ac06cdb83b3bd885e289 100644 (file)
@@ -751,7 +751,7 @@ CORBA::Boolean SALOMEDS_Study_i::DumpStudy(const char* thePath, const char* theB
 //===========================================================================
 //   PRIVATE FUNCTIONS
 //===========================================================================
-long SALOMEDS_Study_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
+CORBA::Long SALOMEDS_Study_i::GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal)
 {
 #ifdef WIN32
   long pid = (long)_getpid();
index b107192164779353c481d697ee7eaee60367b4a3..33af33eeb2ec3644e1920a435c08816573ac7859 100644 (file)
@@ -283,6 +283,6 @@ public:
 
   virtual Handle(SALOMEDSImpl_Study) GetImpl() { return _impl; }
 
-  virtual long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
+  virtual CORBA::Long GetLocalImpl(const char* theHostname, CORBA::Long thePID, CORBA::Boolean& isLocal);
 };
 #endif
index 46d73cf32a6ec4598a30d9d2dad067144514c3b3..55716777c05bd1c230646626b8a4cc7bbf8b7969 100644 (file)
 //  Author : Sergey RUIN
 //  Module : SALOME
 
+#include "SALOMEDSImpl_AttributeComment.hxx"
+
 #ifndef WNT
 using namespace std;
 #endif
-#include "SALOMEDSImpl_AttributeComment.hxx"
 
 IMPLEMENT_STANDARD_HANDLE( SALOMEDSImpl_AttributeComment, SALOMEDSImpl_GenericAttribute )
 IMPLEMENT_STANDARD_RTTIEXT( SALOMEDSImpl_AttributeComment, SALOMEDSImpl_GenericAttribute )
index c0679aa92ff19bb952846bbea7a82e516279ad55..340bd3f7c8c9dd7484e2ed2ff7787c8244204421 100644 (file)
 //  Author : Sergey RUIN
 //  Module : SALOME
 
+#include "SALOMEDSImpl_AttributeDrawable.hxx"
+
 #ifndef WNT
 using namespace std;
 #endif
-#include "SALOMEDSImpl_AttributeDrawable.hxx"
 
 IMPLEMENT_STANDARD_HANDLE( SALOMEDSImpl_AttributeDrawable, SALOMEDSImpl_GenericAttribute )
 IMPLEMENT_STANDARD_RTTIEXT( SALOMEDSImpl_AttributeDrawable, SALOMEDSImpl_GenericAttribute )
index 5f4bc9c73093d41b4eae959585801fab0e72cff7..743fa016b217d2d885697113c23b09ea2b5c25c5 100644 (file)
 //  Author : Sergey RUIN
 //  Module : SALOME
 
+#include "SALOMEDSImpl_AttributeExpandable.hxx"
+
 #ifndef WNT
 using namespace std;
 #endif
-#include "SALOMEDSImpl_AttributeExpandable.hxx"
 
 IMPLEMENT_STANDARD_HANDLE( SALOMEDSImpl_AttributeExpandable, SALOMEDSImpl_GenericAttribute )
 IMPLEMENT_STANDARD_RTTIEXT( SALOMEDSImpl_AttributeExpandable, SALOMEDSImpl_GenericAttribute )
index 85b8355a694a95b593e651aa01a6deab8d173b3c..c5b1553bef0e5518126ff431cf41e799066cf7d4 100644 (file)
 //  Author : Sergey RUIN
 //  Module : SALOME
 
-#ifndef WNT
-using namespace std;
-#endif
 #include "SALOMEDSImpl_AttributeIOR.hxx"
 #include <TCollection_AsciiString.hxx>
 #include "SALOMEDSImpl_Study.hxx"
 #include <Standard_GUID.hxx>
 
+#ifndef WNT
+using namespace std;
+#endif
+
 IMPLEMENT_STANDARD_HANDLE( SALOMEDSImpl_AttributeIOR, SALOMEDSImpl_GenericAttribute )
 IMPLEMENT_STANDARD_RTTIEXT( SALOMEDSImpl_AttributeIOR, SALOMEDSImpl_GenericAttribute )
 
index dee0c253d97ef47b37570d3f3082a998f2363a34..99075680c82aeacc54d49ef6ff08f4dfe95ee7bf 100644 (file)
 //  Author : Sergey RUIN
 //  Module : SALOME
 
+#include "SALOMEDSImpl_AttributeInteger.hxx"
+
 #ifndef WNT
 using namespace std;
 #endif
-#include "SALOMEDSImpl_AttributeInteger.hxx"
 
 IMPLEMENT_STANDARD_HANDLE( SALOMEDSImpl_AttributeInteger,  SALOMEDSImpl_GenericAttribute)
 IMPLEMENT_STANDARD_RTTIEXT( SALOMEDSImpl_AttributeInteger, SALOMEDSImpl_GenericAttribute )
index ebf67aeca7c1caa8739666e4af8b3221db0b6e26..f4a25f644a80812211a11b140d01d9fe799d307b 100644 (file)
@@ -23,8 +23,6 @@
 
 #include "SALOMEDSImpl_StudyManager.hxx"
 
-using namespace std;
-
 #include <CDF_Session.hxx>
 #include <CDF_DirectoryIterator.hxx>
 #include <TDF_Label.hxx>
@@ -52,6 +50,8 @@ using namespace std;
 #include <iostream>
 #include <stdlib.h>
 
+using namespace std;
+
 IMPLEMENT_STANDARD_HANDLE( SALOMEDSImpl_StudyManager, MMgt_TShared )
 IMPLEMENT_STANDARD_RTTIEXT( SALOMEDSImpl_StudyManager, MMgt_TShared )
 
@@ -153,16 +153,16 @@ Handle(SALOMEDSImpl_Study) SALOMEDSImpl_StudyManager::Open(const TCollection_Asc
   }
   catch (HDFexception)
     {
-#ifndef WNT
-      char eStr[strlen(aUrl.ToCString())+17];
-#else
+//#ifndef WNT
+//      char eStr[strlen(aUrl.ToCString())+17];
+//#else
          char *eStr;
          eStr = new char[strlen(aUrl.ToCString())+17];
-#endif
+//#endif
       sprintf(eStr,"Can't open file %s",aUrl.ToCString());
-#ifdef WNT
+//#ifdef WNT
          delete [] eStr;
-#endif
+//#endif
       _errorCode = TCollection_AsciiString(eStr);
       return NULL;
     }
@@ -195,11 +195,11 @@ Handle(SALOMEDSImpl_Study) SALOMEDSImpl_StudyManager::Open(const TCollection_Asc
   }
   catch (HDFexception)
     {
-#ifndef WNT
-      char eStr[strlen(aUrl.ToCString())+17];
-#else
+//#ifndef WNT
+//      char eStr[strlen(aUrl.ToCString())+17];
+//#else
          char *eStr = new char [strlen(aUrl.ToCString())+17];
-#endif
+//#endif
       sprintf(eStr,"Can't open file %s", aUrl.ToCString());
       _errorCode = TCollection_AsciiString(eStr);
       return NULL;
index de612189795aa8d5146864424325996766a9b9ca..d70735f676d9632006f6558b41bfab5c33e68c95 100644 (file)
 #include <fstream>
 #include <cstdlib>
 
-using namespace std;
-
 #include "BaseTraceCollector.hxx"
 #include "LocalTraceBufferPool.hxx"
 
+using namespace std;
+
 // Class attributes initialisation, for class method BaseTraceCollector::run
 
 BaseTraceCollector* BaseTraceCollector::_singleton = 0;
-pthread_mutex_t BaseTraceCollector::_singletonMutex;
+pthread_mutex_t BaseTraceCollector::_singletonMutex = PTHREAD_MUTEX_INITIALIZER ;
 sem_t BaseTraceCollector::_sem;
 int BaseTraceCollector::_threadToClose = 0;
 pthread_t* BaseTraceCollector::_threadId = 0; // used to control single run
index c7d321ec6597dbb7093f1f8e1547a5fcf7efdcfc..a6ffdb3c038fadae280734dffb10562e3076276a 100644 (file)
@@ -51,12 +51,12 @@ using namespace std;
 // Class static attributes initialisation
 
 LocalTraceBufferPool* LocalTraceBufferPool::_singleton = 0;
-#ifndef WNT
-pthread_mutex_t LocalTraceBufferPool::_singletonMutex;
-#else
+//#ifndef WNT
+//pthread_mutex_t LocalTraceBufferPool::_singletonMutex;
+//#else
 pthread_mutex_t LocalTraceBufferPool::_singletonMutex =
   PTHREAD_MUTEX_INITIALIZER;
-#endif
+//#endif
 BaseTraceCollector *LocalTraceBufferPool::_myThreadTrace = 0;
 
 // ============================================================================
index d7d61756a58c7660647cc9e750433fa46f90b24c..9d8599c85ee52c7ddb0cfd0ce974c5177b77b09c 100644 (file)
@@ -36,7 +36,10 @@ include $(top_srcdir)/salome_adm/unix/make_common_starter.am
 #
 # header files  
 # Scripts to be installed
-dist_salomescript_DATA = SALOME_TestComponentPy.py TestComponentPy.py
+dist_salomescript_DATA = \
+       SALOME_TestComponentPy.py \
+       TestComponentPy.py \
+       TestLogger.py
 
 #
 # ===============================================================
index 2dacf6dbbd5e886165a12cbda5abebbef970e5d8..c1f467441c0075a60ddc9f83182c98131dfdd5cd 100755 (executable)
@@ -62,7 +62,7 @@ except CosNaming.NamingContext.NotFound, ex:
     sys.exit(1)
 
 container = obj._narrow(Engines.Container)
-print container._get_machineName()
+print container.getHostName()
 comp = container.load_impl("SALOME_TestComponentPy","SALOME_TestComponentPy")
 print comp._get_instanceName()
 comp.ping()
index 06b543ea70b2fccc8fb8847743aa1f213363dfe4..b5604d9d1fe38b4a000ce7247cd95834030b557b 100644 (file)
@@ -80,7 +80,7 @@ int main (int argc, char * argv[])
 {
   // Initializing omniORB
   ORB_INIT &init = *SINGLETON_<ORB_INIT>::Instance() ;
-  CORBA::ORB_var &orb = init( argc , argv ) ;
+  CORBA::ORB_ptr orb = init( argc , argv ) ;
   //  LocalTraceCollector *myThreadTrace = SALOMETraceCollector::instance(orb);
 
   try
@@ -93,6 +93,7 @@ int main (int argc, char * argv[])
 
       CORBA::Object_var obj = _NS.Resolve(containerName.c_str()) ;
       Engines::Container_var iGenFact = Engines::Container::_narrow(obj);
+      iGenFact->ping() ;
 
       int nbInstances = 5;
 
diff --git a/src/TestContainer/TestLogger.py b/src/TestContainer/TestLogger.py
new file mode 100644 (file)
index 0000000..2d1aa7e
--- /dev/null
@@ -0,0 +1,5 @@
+
+from SALOME_utilities import *
+
+MESSAGE("TestLogger.py : It's OK")
+
index c96747334c6e902cfcf845b5758733a2171b7a62..019633f8a02a0b77cc4064351cfbb8375dc9e137 100644 (file)
@@ -82,7 +82,9 @@ Utils_SignalsHandler::Utils_SignalsHandler()
   StoreSignalHandler(mySigHandlerCont,SIGHUP); // floating point exception
   StoreSignalHandler(mySigHandlerCont,SIGQUIT); // quit
   StoreSignalHandler(mySigHandlerCont,SIGBUS); // bus error
+#ifndef __osf1__
   StoreSignalHandler(mySigHandlerCont,SIGSTKFLT); // stack fault.
+#endif
 #endif
   StoreSignalHandler(mySigHandlerCont,SIGFPE); // floating point exception  
   StoreSignalHandler(mySigHandlerCont,SIGINT); // interrupt