Salome HOME
Win32 compilation.
authorrnv <rnv@opencascade.com>
Tue, 12 Nov 2013 11:53:55 +0000 (11:53 +0000)
committerrnv <rnv@opencascade.com>
Tue, 12 Nov 2013 11:53:55 +0000 (11:53 +0000)
14 files changed:
src/bases/Test/basesTest.cxx
src/engine/Bloc.hxx
src/engine/SharedPtr.hxx
src/engine/Test/CMakeLists.txt
src/engine/Test/ContainerTest.cxx
src/engine/Test/RuntimeForEngineIntegrationTest.cxx
src/engine/Test/RuntimeForEngineTest.cxx
src/engine/Test/ToyNode.cxx
src/engine/Test/engineIntegrationTest.cxx
src/engine/Test/engineIntegrationTest.hxx
src/runtime/CppComponent.hxx
src/runtime/CppNode.hxx
src/runtime/Test/CMakeLists.txt
src/yacsloader/Test/CMakeLists.txt

index acd5135fda4ee2242d9eb0cc8072e16d1423ec55..851a6b6f201f15045984fe5b5a20d61fa51d6699 100644 (file)
@@ -55,6 +55,7 @@ void *BasesTest::th1_1(void *st)
   _var+=2;
   _s1.post();
   _s2.post();
+  return 0;
 }
 
 void *BasesTest::th1_2(void *st)
@@ -63,6 +64,7 @@ void *BasesTest::th1_2(void *st)
   _s2.wait();
   _glob<< myName << _var;
   _s2.post();
+  return 0;
 }
 
 void *BasesTest::th1_3(void *st)
@@ -70,6 +72,7 @@ void *BasesTest::th1_3(void *st)
   char myName=*((char *) st);
   _glob<< myName << _var++;
   _s1.post();
+  return 0;
 }
 
 void *BasesTest::th2_1(void *)
@@ -86,6 +89,7 @@ void *BasesTest::th2_1(void *)
       _m.unlock();
       Thread::sleep(100000);
     }
+  return 0;
 }
 
 void *BasesTest::myFunc(void *n)
@@ -103,7 +107,8 @@ void *BasesTest::myFunc(void *n)
       DEBTRACE("thread " << id << " frees " << i << " resources");
       free_resources(id, i);
     }
-}
+  return 0;
+ }
 
 void BasesTest::get_resources(int id, int amount)
 {
@@ -201,7 +206,7 @@ void BasesTest::test3()
     }
   
   for (i=0; i<THREAD_NUM; i++)
-    {
+    {      
       ths[i] = new Thread(myFunc, &id[i]);
       CPPUNIT_ASSERT(count_resources() == BasesTest::MAX_RESOURCE);
     }
index 9373de05a7ded521175351956b8e0c8f4706183a..a3aff21ee7790b4231162cda8a31c2a7f1142820 100644 (file)
@@ -121,12 +121,13 @@ namespace YACS
     template<bool direction>
     unsigned Bloc::appendIfAlreadyFound(std::list< std::vector<Node *> >& res, const std::vector<Node *>& startRes, Node *node, std::map<Node *, std::set<Node *> >& fastFinder)
     {
-      std::map<Node *, std::set<Node *> >::const_iterator iter=fastFinder.find(node);
+      std::map<Node *, std::set<Node *> >::iterator iter=fastFinder.find(node);
       if(iter==fastFinder.end())
         return 0;
       unsigned ret=0;
       std::vector<std::pair<std::set<Node *>::iterator, std::set<Node *>::iterator > > li;
-      li.push_back(std::pair<std::set<Node *>::iterator, std::set<Node *>::iterator>(((*iter).second).begin(),((*iter).second).end()));
+      std::pair<std::set<Node *>::iterator, std::set<Node *>::iterator> ipr(((*iter).second).begin(),((*iter).second).end());
+      li.push_back(ipr);
       std::vector<Node *> work(startRes);
       std::list< std::vector<Node *> >::iterator where=res.end(); where--;
       std::list< std::vector<Node *> >::iterator updates=where;
@@ -144,8 +145,9 @@ namespace YACS
                 }
               else
                 {
-                  const std::set<Node *>& s=fastFinder[*(li.back().first)];
-                  li.push_back(std::pair<std::set<Node *>::iterator, std::set<Node *>::iterator>(s.begin(),s.end()));
+                  std::set<Node *>& s=fastFinder[*(li.back().first)];
+                  std::pair<std::set<Node *>::iterator, std::set<Node *>::iterator> pr(s.begin(),s.end());
+                  li.push_back(pr);
                 }
             }
           else
index d1150711b97a93de8bab942d4b5c72709d8a19b3..a1dcf2cae32c915689bd870c584b8110e098d447 100644 (file)
@@ -53,6 +53,7 @@ SharedPtr<T> &SharedPtr<T>::operator=(const SharedPtr<T>& other)
   _ptr->decrRef();
   _ptr=other._ptr;
   _ptr->incrRef();
+  return *this;
 }
 
 template<class T>
index 681c9c113c16bf1e3e6df6ebb2da11eb2e5f822c..d39ec21ab87d2f6af2e6123840ccee1a9116806f 100644 (file)
@@ -35,6 +35,15 @@ SET(_link_LIBRARIES
   YACSBases
 )
 
+# additional preprocessor / compiler flags
+ADD_DEFINITIONS(
+  ${OMNIORB_DEFINITIONS}
+)
+
+IF(WIN32)
+  ADD_DEFINITIONS(-DNOGDI)
+ENDIF(WIN32)
+
 # --- sources ---
 
 SET(PluginOptEvTest1_SOURCES
index fce21bacba9f25eef74b4f5ff180a4092a4f399b..b640894087c72f0724a0ece306d7da29bacfae26 100644 (file)
@@ -49,7 +49,7 @@ bool ContainerTest::isAlreadyStarted(const ComponentInstance *inst) const
   return _alreadyStarted;
 }
 
-void ContainerTest::start(const ComponentInstance *inst) throw(Exception)
+void ContainerTest::start(const ComponentInstance *inst) throw(YACS::Exception)
 {
   if(_alreadyStarted)
     throw Exception("ContainerTest already started !!!!");
@@ -67,7 +67,7 @@ Container *ContainerTest::clone() const
     return new ContainerTest;
 }
 
-void ContainerTest::checkCapabilityToDealWith(const ComponentInstance *inst) const throw(Exception)
+void ContainerTest::checkCapabilityToDealWith(const ComponentInstance *inst) const throw(YACS::Exception)
 {
   if(inst->getKind()!=SUPPORTED_COMP_KIND)
     throw Exception("ContainerTest not compatible with this type of instance.");
@@ -87,7 +87,7 @@ bool ContainerTest2::isAlreadyStarted(const ComponentInstance *inst) const
   return _alreadyStarted;
 }
 
-void ContainerTest2::start(const ComponentInstance *inst) throw(Exception)
+void ContainerTest2::start(const ComponentInstance *inst) throw(YACS::Exception)
 {
   if(_alreadyStarted)
     throw Exception("ContainerTest already started !!!!");
@@ -110,7 +110,7 @@ void ContainerTest2::initAllContainers()
   _counter=0;
 }
 
-void ContainerTest2::checkCapabilityToDealWith(const ComponentInstance *inst) const throw(Exception)
+void ContainerTest2::checkCapabilityToDealWith(const ComponentInstance *inst) const throw(YACS::Exception)
 {
   if(inst->getKind()!=SUPPORTED_COMP_KIND)
     throw Exception("ContainerTest not compatible with this type of instance.");
index ec6e184f86e3cd0bc072edb156b02563130edd5d..6d2c4d9bc2094ec90e50bad9b10e5633fec55c09 100644 (file)
 
 #include "RuntimeForEngineIntegrationTest.hxx"
 #include "ComponentInstanceTest.hxx"
+#include "Exception.hxx"
 #include "ToyNode.hxx"
 #include "TypeCode.hxx"
 #include <sstream>
+#include <string.h>
+
 
-using namespace std;
 using namespace YACS::ENGINE;
 
 void RuntimeForEngineIntegrationTest::setRuntime()
@@ -32,17 +34,17 @@ void RuntimeForEngineIntegrationTest::setRuntime()
     Runtime::_singleton = new RuntimeForEngineIntegrationTest;
 }
 
-ElementaryNode* RuntimeForEngineIntegrationTest::createNode(const string& implementation, const string& name) throw(Exception)
+ElementaryNode* RuntimeForEngineIntegrationTest::createNode(const std::string& implementation, const std::string& name) throw (YACS::Exception)
 {
   if (implementation == ToyNode::MY_IMPL_NAME)
     return new ToyNode(name);
   else if(implementation == LimitNode::MY_IMPL_NAME)
     return new LimitNode(name);
-  string what="RuntimeForEngineIntegrationTest does not handle this implementation: " + implementation;
-  throw Exception(what);
+  std::string what="RuntimeForEngineIntegrationTest does not handle this implementation: " + implementation;
+  throw YACS::Exception(what);
 }
 
-InputPort* RuntimeForEngineIntegrationTest::createInputPort(const string& name, const string& impl, Node * node, TypeCode * type)
+InputPort* RuntimeForEngineIntegrationTest::createInputPort(const std::string& name, const std::string& impl, Node * node, TypeCode * type)
 {
   if(impl == ToyNode::MY_IMPL_NAME)
     {
@@ -52,12 +54,12 @@ InputPort* RuntimeForEngineIntegrationTest::createInputPort(const string& name,
     }
   else if(impl == LimitNode::MY_IMPL_NAME)
     throw Exception("InputPort creation not allowed for LimitNode");
-  ostringstream msg;
+  std::ostringstream msg;
   msg << "Cannot create " << impl << " OutputPort" ;
-  throw Exception(msg.str());
+  throw YACS::Exception(msg.str());
 }
 
-OutputPort* RuntimeForEngineIntegrationTest::createOutputPort(const string& name, const string& impl, Node * node, TypeCode * type)
+OutputPort* RuntimeForEngineIntegrationTest::createOutputPort(const std::string& name, const std::string& impl, Node * node, TypeCode * type)
 {
   if(impl == ToyNode::MY_IMPL_NAME)
     {
@@ -67,12 +69,12 @@ OutputPort* RuntimeForEngineIntegrationTest::createOutputPort(const string& name
     }
   else if(impl == LimitNode::MY_IMPL_NAME)
     throw Exception("OutputPort creation not allowed for LimitNode");
-  stringstream msg;
+  std::stringstream msg;
   msg << "Cannot create " << impl << " OutputPort" ;
   throw Exception(msg.str());
 }
 
-InputPort* RuntimeForEngineIntegrationTest::adapt(InputPort* source, const string& impl,TypeCode * type,bool init) throw (ConversionException)
+InputPort* RuntimeForEngineIntegrationTest::adapt(InputPort* source, const std::string& impl,TypeCode * type,bool init) throw (ConversionException)
 {
   return new ProxyPort(source);
 }
@@ -90,7 +92,7 @@ ComponentInstance* RuntimeForEngineIntegrationTest::createComponentInstance(cons
     return new ComponentInstanceTest2(name);
   else
     {
-      string msg("RuntimeForEngineIntegrationTest::createComponentInstance : Unable to crate component with kind \"");
+      std::string msg("RuntimeForEngineIntegrationTest::createComponentInstance : Unable to crate component with kind \"");
       msg+=kind; msg+="\"";
       throw Exception(msg);
     }
index efe10df03aafb4ec2e5313008860ca3d64c5dd0b..ae471cce9fe85cad5e2cd7ae07953bb23aad694f 100644 (file)
@@ -54,7 +54,7 @@ InputPort *TestElemInputPort::clone(Node *newHelder) const
   return new TestElemInputPort(*this,newHelder);
 }
 
-void *TestElemInputPort::get() const throw(Exception)
+void *TestElemInputPort::get() const throw(YACS::Exception)
 {
   stringstream msg;
   msg << "Not implemented (" << __FILE__ << ":" << __LINE__ << ")";
@@ -106,7 +106,7 @@ void RuntimeForEngineTest::setRuntime()
     Runtime::_singleton = new RuntimeForEngineTest;
 }
 
-ElementaryNode* RuntimeForEngineTest::createNode(const string& implementation, const string& name) throw(Exception)
+ElementaryNode* RuntimeForEngineTest::createNode(const string& implementation, const string& name) throw(YACS::Exception)
 {
   return new TestElemNode(name);
 }
index e55b2ca562c643bcfd6fd7b38c98260757e12744..630b5ed6d8a19bded8bdce659427427cc60fbd09 100644 (file)
@@ -77,7 +77,7 @@ bool InputToyPort::edIsManuallyInitialized() const
   return _initData!=0;
 }
 
-void *InputToyPort::get() const throw(Exception)
+void *InputToyPort::get() const throw(YACS::Exception)
 {
   return (void *)_data;
 }
@@ -215,7 +215,7 @@ int ToyNode::getNumberOfOutputPorts() const
   return ElementaryNode::getNumberOfInputPorts()+1;
 }
 
-OutputPort *ToyNode::getOutputPort(const std::string& name) const throw(Exception)
+OutputPort *ToyNode::getOutputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_FOR_NB)
     return (OutputPort *)&_nbOfInputsPort;
@@ -331,7 +331,7 @@ std::list<InputPort *> SeqToyNode::getSetOfInputPort() const
   return ret;
 }
 
-InputPort *SeqToyNode::getInputPort(const std::string& name) const throw(Exception)
+InputPort *SeqToyNode::getInputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_NBOFELTS_INSEQ_INPRT)
     return (InputPort *)&_inIntValue;
@@ -351,7 +351,7 @@ std::list<OutputPort *> SeqToyNode::getSetOfOutputPort() const
   return ret;
 }
 
-OutputPort *SeqToyNode::getOutputPort(const std::string& name) const throw(Exception)
+OutputPort *SeqToyNode::getOutputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_SEQ_OUTPRT)
     return (OutputPort *)&_seqOut;
@@ -414,7 +414,7 @@ std::list<InputPort *> Seq2ToyNode::getSetOfInputPort() const
   return ret;
 }
 
-InputPort *Seq2ToyNode::getInputPort(const std::string& name) const throw(Exception)
+InputPort *Seq2ToyNode::getInputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_SEQ_INPRT1)
     return (InputPort *)&_inValue1;
@@ -436,7 +436,7 @@ std::list<OutputPort *> Seq2ToyNode::getSetOfOutputPort() const
   return ret;
 }
 
-OutputPort *Seq2ToyNode::getOutputPort(const std::string& name) const throw(Exception)
+OutputPort *Seq2ToyNode::getOutputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_SEQ_OUTPRT)
     return (OutputPort *)&_seqOut;
@@ -514,7 +514,7 @@ std::list<InputPort *> Seq3ToyNode::getSetOfInputPort() const
   return ret;
 }
 
-InputPort *Seq3ToyNode::getInputPort(const std::string& name) const throw(Exception)
+InputPort *Seq3ToyNode::getInputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_SEQ_INPRT1)
     return (InputPort *)&_inValue1;
@@ -536,7 +536,7 @@ std::list<OutputPort *> Seq3ToyNode::getSetOfOutputPort() const
   return ret;
 }
 
-OutputPort *Seq3ToyNode::getOutputPort(const std::string& name) const throw(Exception)
+OutputPort *Seq3ToyNode::getOutputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_SEQ_OUTPRT)
     return (OutputPort *)&_seqOut;
@@ -581,7 +581,7 @@ bool InputLimitPort::edIsManuallyInitialized() const
   return _initData!=0;
 }
 
-void *InputLimitPort::get() const throw(Exception)
+void *InputLimitPort::get() const throw(YACS::Exception)
 {
   if(!_data)
     {
@@ -705,7 +705,7 @@ std::list<OutputPort *> LimitNode::getSetOfOutputPort() const
   return ret;
 }
 
-InputPort *LimitNode::getInputPort(const std::string& name) const throw(Exception)
+InputPort *LimitNode::getInputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_FOR_SWPORT)
     return (InputPort *)&_entry;
@@ -713,7 +713,7 @@ InputPort *LimitNode::getInputPort(const std::string& name) const throw(Exceptio
     return ElementaryNode::getInputPort(name);
 }
 
-OutputPort *LimitNode::getOutputPort(const std::string& name) const throw(Exception)
+OutputPort *LimitNode::getOutputPort(const std::string& name) const throw(YACS::Exception)
 {
   if(name==NAME_FOR_SWPORT)
     return (OutputPort *)&_switchPort;
index f2c3822c5bd418c75d7777ac7e9d6c462b0328a8..cb38a3d0922bf68fd759fe320ece7b62d3fbc2a7 100644 (file)
@@ -2593,11 +2593,11 @@ void EngineIntegrationTest::testForOptimizerLoop1()
   CPPUNIT_ASSERT(!info.areWarningsOrErrors());
   exe.RunW(graph);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)o2_1)->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() or 7==(int)opt->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() || 7==(int)opt->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((DynParaLoop *)(opt))->getNumberOfBranchesCreatedDyn());
   exe.RunW(graph);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)o2_1)->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() or 7==(int)opt->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() || 7==(int)opt->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((DynParaLoop *)(opt))->getNumberOfBranchesCreatedDyn());
   Bloc *clone=(Bloc *)graph->clone(0);
   delete graph;
@@ -2605,11 +2605,11 @@ void EngineIntegrationTest::testForOptimizerLoop1()
   CPPUNIT_ASSERT(!info.areWarningsOrErrors());
   exe.RunW(clone);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)(clone->getOutPort("T2.o1")))->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() or 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() || 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfBranchesCreatedDyn());
   exe.RunW(clone);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)(clone->getOutPort("T2.o1")))->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() or 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() || 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfBranchesCreatedDyn());
   delete clone;
 }
@@ -2645,11 +2645,11 @@ void EngineIntegrationTest::testForOptimizerLoop2()
   CPPUNIT_ASSERT(!info.areWarningsOrErrors());
   exe.RunW(graph);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)o2_1)->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() or 7==(int)opt->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() || 7==(int)opt->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((DynParaLoop *)(opt))->getNumberOfBranchesCreatedDyn());
   exe.RunW(graph);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)o2_1)->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() or 7==(int)opt->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)opt->getNumberOfEltsConsumed() || 7==(int)opt->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((DynParaLoop *)(opt))->getNumberOfBranchesCreatedDyn());
   Bloc *clone=(Bloc *)graph->clone(0);
   delete graph;
@@ -2657,11 +2657,11 @@ void EngineIntegrationTest::testForOptimizerLoop2()
   CPPUNIT_ASSERT(!info.areWarningsOrErrors());
   exe.RunW(clone);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)(clone->getOutPort("T2.o1")))->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() or 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() || 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfBranchesCreatedDyn());
   exe.RunW(clone);
   CPPUNIT_ASSERT_DOUBLES_EQUAL(45.6,((OutputToyPort*)(clone->getOutPort("T2.o1")))->get()->getDoubleValue(),DBL_PRECISION_COMPARE );
-  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() or 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
+  CPPUNIT_ASSERT(8==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed() || 7==(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfEltsConsumed());
   CPPUNIT_ASSERT_EQUAL(2,(int)((OptimizerLoop *)(clone->getChildByName("myOptWthAlgSync")))->getNumberOfBranchesCreatedDyn());
   delete clone;
 }
index 0c9736e2a5affefe2aef56b034b618094992e7e7..bb72ba46b2858d5e0c290084b122e17d30285b72 100644 (file)
@@ -132,8 +132,8 @@ namespace YACS
     template<class T>
     void EngineIntegrationTest::checkSetsEqual(const std::set<T>& setToTest1, const std::set<T>& setToTest2)
     {
-      typename std::set<T>::iterator iter1=setToTest1.begin();
-      typename std::set<T>::iterator iter2=setToTest2.begin();
+      typename std::set<T>::const_iterator iter1=setToTest1.begin();
+      typename std::set<T>::const_iterator iter2=setToTest2.begin();
       CPPUNIT_ASSERT_EQUAL_MESSAGE("Sets can't be equal : size different", (int)setToTest1.size(), (int)setToTest2.size());
       for(;iter1!=setToTest1.end();iter1++,iter2++)
         CPPUNIT_ASSERT_MESSAGE("Sets can't be equal : value different", *iter1==*iter2);
@@ -142,7 +142,7 @@ namespace YACS
     template<class T>
     void EngineIntegrationTest::checkSetsNotEqual(const std::set<T *>& setToTest1, const std::set<T *>&setToTest2)
     {
-      typename std::set<T *>::iterator iter1=setToTest1.begin();
+      typename std::set<T *>::const_iterator iter1=setToTest1.begin();
       CPPUNIT_ASSERT_EQUAL_MESSAGE("Sets can't be equal : size different", (int)setToTest1.size(), (int)setToTest2.size());
       for(;iter1!=setToTest1.end();iter1++)
         CPPUNIT_ASSERT_MESSAGE("Elements is in set : not expected.",setToTest2.find(*iter1)==setToTest2.end());
index 6a51004628759983e99ef73c6a81ef0a4c148ad0..7f35516ae02d4b253d6b71b02b0e26e1cbbb19e6 100644 (file)
@@ -22,6 +22,7 @@
 
 #include <string>
 #include "ComponentInstance.hxx"
+#include "YACSRuntimeSALOMEExport.hxx"
 
 namespace YACS 
 {
@@ -40,7 +41,7 @@ namespace YACS
     typedef void (*TerminateFunction)(void **);
     typedef void (*PingFunction) ();
         
-    class CppComponent : public ComponentInstance {
+    class YACSRUNTIMESALOME_EXPORT CppComponent : public ComponentInstance {
       public:
 
         CppComponent(const std::string & name);
index ba7eabde9e9ea8b856b8c9f99e274c70cbcc538b..a96c629b067076a782ed53b59c2811c09761b18f 100644 (file)
@@ -21,6 +21,7 @@
 #define _CPPNODE_HXX_
 
 #include "ServiceNode.hxx"
+#include "YACSRuntimeSALOMEExport.hxx"
 
 namespace YACS
 {
@@ -42,7 +43,7 @@ namespace YACS
  * \ingroup Nodes
  *
  */
-    class CppNode : public YACS::ENGINE::ServiceNode 
+    class YACSRUNTIMESALOME_EXPORT CppNode : public YACS::ENGINE::ServiceNode 
     {
     protected:
       Node *simpleClone(ComposedNode *father, bool editionOnly) const;
index f39fc7732c95e064330325d65e76d97dcd3b6a25..408ebe184d737e7f40b599d81cb34db032a545c2 100644 (file)
@@ -39,9 +39,15 @@ INCLUDE_DIRECTORIES(
 # additional preprocessor / compiler flags
 ADD_DEFINITIONS(
   ${PTHREAD_DEFINITIONS}
+  ${OMNIORB_DEFINITIONS}
   -DUSE_CPPUNIT
 )
 
+IF(WIN32)
+  ADD_DEFINITIONS(-DNOGDI)
+ENDIF(WIN32)
+
+
 # --- sources ---
 
 # idl files
index 6515eb24bc66e5aa523a65c308e3c93475099a25..5e83614ec50f21b5905e6fabd8c7612a615797af 100644 (file)
@@ -37,6 +37,16 @@ INCLUDE_DIRECTORIES(
   ${CMAKE_CURRENT_BINARY_DIR}
 )
 
+# additional preprocessor / compiler flags
+ADD_DEFINITIONS(
+  ${OMNIORB_DEFINITIONS}
+)
+
+IF(WIN32)
+  ADD_DEFINITIONS(-DNOGDI)
+ENDIF(WIN32)
+
+
 # --- sources ---
 
 # idl files