]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
To use native BOOST libraries
authorapo <apo@opencascade.com>
Fri, 17 Feb 2006 08:24:52 +0000 (08:24 +0000)
committerapo <apo@opencascade.com>
Fri, 17 Feb 2006 08:24:52 +0000 (08:24 +0000)
adm_local/unix/make_commence.in
src/CONVERTOR/Makefile.in
src/OBJECT/Makefile.in
src/OBJECT/VISU_Actor.h
src/OBJECT/VISU_ActorFactory.h
src/OBJECT/VISU_BoostSignals.h [new file with mode: 0644]
src/VISU_I/Makefile.in
src/VISU_I/VISU_Prs3d_i.hh
src/VISU_I/VISU_Result_i.hh

index e38b5b7a623fde37994ee3050beff8a7e27a0326..a143c7bbe397fef470a4189f27603b7ba2851441 100644 (file)
@@ -37,8 +37,8 @@ CXX_DEPEND_FLAG = @CXX_DEPEND_FLAG@
 # BOOST Library
 
 BOOST_CPPFLAGS = @BOOST_CPPFLAGS@
+BOOST_LIBSUFFIX = @BOOST_LIBSUFFIX@
 BOOST_LIBS = @BOOST_LIBS@
-BOOST_LIBTHREAD = @BOOST_LIBTHREAD@
 
 # JAVA
 
index 9f3ea401d50c0634e88f4baddda2a358d160cbb5..36847c3406014ec5ac14ac039d1a961ab8d38408 100644 (file)
@@ -64,7 +64,7 @@ CPPFLAGS+= -ftemplate-depth-32 $(VTK_INCLUDES) $(HDF5_INCLUDES) $(QT_INCLUDES) \
        $(BOOST_CPPFLAGS)
 
 LDFLAGS+= $(VTK_LIBS) $(QT_LIBS) \
-       $(BOOST_LIBS) -lboost_thread${BOOST_LIBTHREAD} \
+       $(BOOST_LIBS) -lboost_thread${BOOST_LIBSUFFIX} \
        -L${MED_ROOT_DIR}/lib/salome -lMEDWrapper \
        -L${GUI_ROOT_DIR}/lib/salome -lVTKViewer
 
index 0499046fc70b8a03afe29b286810e74545a2da73..0a5cbee80f117cbc7b06b3ede4824e97d5f128ef 100644 (file)
@@ -33,6 +33,7 @@ VPATH=.:@srcdir@:@top_srcdir@/idl
 @COMMENCE@
 
 EXPORT_HEADERS = \
+       VISU_BoostSignals.h \
        VISU_ActorFactory.h \
        VISU_GaussPtsSettings.h \
        VISU_GaussPtsActorFactory.h \
@@ -76,7 +77,7 @@ LDFLAGS+= \
        -L${KERNEL_ROOT_DIR}/lib/salome 
 
 LIBS+=  \
-       -lboost_signals${BOOST_LIBTHREAD} \
+       -lboost_signals${BOOST_LIBSUFFIX} \
        -lSalomeObject \
        -lVisuPipeLine \
        -lSVTK
index 96302c1e588a2eed2a6368c4d8566124c13b4c4b..09d4d4bbc41f22280a2bb6f759736e5f950e9de6 100644 (file)
 
 #include "SALOME_Actor.h"
 #include "VISU_ActorFactory.h"
+#include "VISU_BoostSignals.h"
 
 #include <string>
 #include <vtkSmartPointer.h>
-#include <boost/signals/signal1.hpp>
-#include <boost/signals/trackable.hpp>
 
 class vtkProp;
 class vtkProperty;
@@ -60,7 +59,7 @@ namespace VISU
 //----------------------------------------------------------------------------
 class VTKOCC_EXPORT VISU_Actor : 
   public SALOME_Actor,
-  public boost::BOOST_SIGNALS_NAMESPACE::trackable
+  public boost::signalslib::trackable
 {
  public:
   vtkTypeMacro(VISU_Actor,SALOME_Actor);
index 9a9bc12f4e43e9dd71552dc4c649e2a945da0482..7395f1e13f1624dd2b7b226c2acd98bb21aa8b5f 100644 (file)
@@ -29,7 +29,7 @@
 #ifndef VISU_ACTOR_FACTORY_H
 #define VISU_ACTOR_FACTORY_H
 
-#include <boost/signals/trackable.hpp>
+#include "VISU_BoostSignals.h"
 
 class VISU_Actor;
 
@@ -46,7 +46,7 @@ namespace VISU
     This interface inherits from boost::bsignals::trackable in order to provide automatic 
     diconnection from defined signals if the object is destroyed.
   */
-  struct TActorFactory: public virtual boost::BOOST_SIGNALS_NAMESPACE::trackable
+  struct TActorFactory: public virtual boost::signalslib::trackable
   {
     //! Just to make this class virtual
     virtual 
diff --git a/src/OBJECT/VISU_BoostSignals.h b/src/OBJECT/VISU_BoostSignals.h
new file mode 100644 (file)
index 0000000..9723e36
--- /dev/null
@@ -0,0 +1,56 @@
+//  VISU OBJECT : interactive object for VISU entities implementation
+//
+//  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
+// 
+//  This library is free software; you can redistribute it and/or 
+//  modify it under the terms of the GNU Lesser General Public 
+//  License as published by the Free Software Foundation; either 
+//  version 2.1 of the License. 
+// 
+//  This library is distributed in the hope that it will be useful, 
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of 
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
+//  Lesser General Public License for more details. 
+// 
+//  You should have received a copy of the GNU Lesser General Public 
+//  License along with this library; if not, write to the Free Software 
+//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA 
+// 
+//  See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 
+//
+//
+//
+//  File   : 
+//  Author : 
+//  Module : VISU
+//  $Header$
+
+#ifndef VISU_BOOST_SIGNALS_H
+#define VISU_BOOST_SIGNALS_H
+
+#ifdef signals
+#  ifndef QOBJECTDEFS_H
+#    error "Cannot recover the siganlas macro definition"
+#  else
+#    define EXTERNAL_SIGNALS_DEFINITION
+#    undef signals
+#  endif
+#endif
+
+#include <boost/signals.hpp>
+
+namespace boost {
+  namespace signalslib = BOOST_SIGNALS_NAMESPACE;
+}
+
+#ifdef EXTERNAL_SIGNALS_DEFINITION
+#  undef EXTERNAL_SIGNALS_DEFINITION
+#  ifdef QT_MOC_CPP
+#    define signals signals
+#  else
+#    define signals protected
+#  endif
+#endif
+
+#endif //VISU_BOOST_SIGNALS_H
index a8182da9408c0fa813a0485c0e962686cc4af1a4..bc8b50a427da0e7ee6611c3ffafe1e26a7d0a251 100644 (file)
@@ -112,7 +112,7 @@ LDFLAGS  += \
        -L${GUI_ROOT_DIR}/lib/salome \
        -L${MED_ROOT_DIR}/lib/salome 
 
-LIBS+=  -lboost_signals${BOOST_LIBTHREAD} \
+LIBS+=  -lboost_signals${BOOST_LIBSUFFIX} \
        -lSalomeHDFPersist \
        -lSalomeGenericObj \
        -lSalomeContainer \
index efdd55565bbb61f4428683202ad045c6bb29e1cc..c83955f5bd1c983865b51111269a06ff7371c9ed 100644 (file)
@@ -35,7 +35,6 @@
 #include "SALOME_GenericObj_i.hh"
 #include "SALOME_InteractiveObject.hxx"
 
-#include <boost/signals/signal0.hpp>
 #include <vtkSmartPointer.h>
 
 class VISU_PipeLine;
index 24fa919b5c0de1cf704da63dc82637a934cc476d..27ec5e085c7b347531dd12f9205f55d70fc9592d 100644 (file)
 #define __VISU_RESULT_I_H__
 
 #include "VISUConfig.hh"
+#include "VISU_BoostSignals.h"
 #include "SALOME_GenericObj_i.hh"
 
-#include <boost/signals/trackable.hpp>
-#include <boost/signals/signal0.hpp>
-
 #include <gp_Dir.hxx>
 #include <vector>
 
@@ -41,7 +39,7 @@ class VISU_Convertor;
 namespace VISU
 {
   //----------------------------------------------------------------------------
-  class MinMaxCunsomer: public virtual boost::BOOST_SIGNALS_NAMESPACE::trackable
+  class MinMaxCunsomer: public virtual boost::signalslib::trackable
   {
   protected:
     bool myMinMaxIsInitilized;