]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Preparation of the SALOME7.2.0 win32 version.
authorrnv <rnv@opencascade.com>
Mon, 24 Jun 2013 10:36:30 +0000 (10:36 +0000)
committerrnv <rnv@opencascade.com>
Mon, 24 Jun 2013 10:36:30 +0000 (10:36 +0000)
13 files changed:
CMakeLists.txt
adm_local/cmake_files/FindSalomeCAS.cmake
adm_local/cmake_files/FindSalomeVTK.cmake
doc/salome/gui/CMakeLists.txt
src/GuiHelpers/CMakeLists.txt
src/OBJECT/CMakeLists.txt
src/SALOME_PYQT/SALOME_PYQT_GUI/CMakeLists.txt
src/Session/CMakeLists.txt
src/TOOLSGUI/CMakeLists.txt
src/VTKViewer/CMakeLists.txt
src/VTKViewer/VTKViewer_PolyDataMapper.cxx
tools/dlgfactory/CMakeLists.txt
tools/vtkEDFOverloads/vtkEDFFactory.cxx

index 89f8d358225083b91c056ebc336e380404b006d3..6354fb3bf4612cbc52c5c28b3c43082c1b6c4388 100755 (executable)
@@ -70,11 +70,13 @@ SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${KERNEL_ROOT_DIR}/salome_adm/cmake_f
 
 find_package(PLATFORM)
 
-
 # Threads
-SET(CMAKE_THREAD_PREFER_PTHREAD)
-find_package(Threads REQUIRED)
-
+if(WINDOWS)
+  find_package(SalomePTHREAD REQUIRED)
+else(WINDOWS)
+  SET(CMAKE_THREAD_PREFER_PTHREAD)
+  find_package(Threads REQUIRED)
+endif(WINDOWS)
 
 # required prerequisites from KERNEL
 
index c2b4ac325f52feb9c4f24a925645e7dc5c158758..66a93e73a2d2ee08cd58e7e6115a7bb56028b9f6 100644 (file)
@@ -25,20 +25,12 @@ if(EXISTS ${CAS_ROOT_DIR})
   set(CMAKE_PROGRAM_PATH ${CAS_ROOT_DIR}/bin)
   if(WINDOWS)
     if(CMAKE_BUILD_TYPE STREQUAL Debug)
-      set(CMAKE_LIBRARY_PATH ${CAS_ROOT}/win32/libd)
+      set(CMAKE_LIBRARY_PATH ${CAS_ROOT_DIR}/win32/libd)
     else(CMAKE_BUILD_TYPE STREQUAL Debug)
-      set(CMAKE_LIBRARY_DIR ${CAS_ROOT}/win32/lib)
+      set(CMAKE_LIBRARY_PATH ${CAS_ROOT_DIR}/win32/lib)
     endif(CMAKE_BUILD_TYPE STREQUAL Debug)
   else(WINDOWS)
     set(CMAKE_LIBRARY_PATH ${CAS_ROOT_DIR}/lib)
   endif(WINDOWS)
 endif(EXISTS ${CAS_ROOT_DIR})
-find_package(CAS)
-
-IF(CAS_StdLPlugin)
-  SET(CAS_STDPLUGIN StdPlugin)
-ELSE(CAS_StdLPlugin)
-  IF(CAS_TKStdSchema)
-    SET(CAS_STDPLUGIN TKStdSchema)
-  ENDIF(CAS_TKStdSchema)
-ENDIF(CAS_StdLPlugin)
\ No newline at end of file
+find_package(CAS)
\ No newline at end of file
index 3f6ec83f5b0414f9c285fc18999ca6efc307c948..8f2d10d0736793c73c098faa387c127c93d92de2 100644 (file)
@@ -24,7 +24,7 @@ set(PARAVIEW_VERSION $ENV{PARAVIEW_VERSION} CACHE STRING "Version of Paraview")
 if(EXISTS ${PARAVIEW_ROOT_DIR})
   set(VTK_DIR ${PARAVIEW_ROOT_DIR}/lib/cmake/paraview-${PARAVIEW_VERSION} CACHE PATH "Path to directory including VTKConfig.cmake")
 endif(EXISTS ${PARAVIEW_ROOT_DIR})
-set(VTK_COMPONENTS vtkRenderingFreeTypeOpenGL vtkRenderingLOD vtkRenderingAnnotation vtkFiltersParallel vtkIOExport)
+set(VTK_COMPONENTS vtkRenderingFreeTypeOpenGL vtkRenderingLOD vtkRenderingAnnotation vtkFiltersParallel vtkIOExport vtkWrappingPython)
 find_package(VTK 6.0 REQUIRED COMPONENTS ${VTK_COMPONENTS} NO_MODULE)
 if (VTK_FOUND)
   message(STATUS "VTK version is ${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION}")
index 1abb0f4c3ec12441dbf3e98d41a1cb8dba405c18..c39cf66a756006f87d3cfaa37f6bfa7b31c0093a 100755 (executable)
@@ -34,6 +34,6 @@ ADD_CUSTOM_TARGET(usr_docs ${DOXYGEN_EXECUTABLE})
 
 ADD_DEPENDENCIES(usr_docs html_docs)
 
-INSTALL(CODE "EXECUTE_PROCESS(COMMAND \"${CMAKE_COMMAND}\" --build ${CMAKE_BINARY_DIR} --target usr_docs)")
+INSTALL(CODE "EXECUTE_PROCESS(COMMAND \"${DOXYGEN_EXECUTABLE}\" WORKING_DIRECTORY \"${CMAKE_CURRENT_BINARY_DIR}\")")
 INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/GUI DESTINATION share/doc/salome/gui)
 INSTALL(FILES images/head.png DESTINATION share/doc/salome/gui/GUI) 
index 7fda47fd224ce393c5ace450c277f08d0fc5e013..8bf278a4a16d68518ba34e4f6b0ddae2fd72037c 100755 (executable)
@@ -44,7 +44,7 @@ SET(SalomeGuiHelpers_SOURCES
 ADD_DEFINITIONS(${CAS_DEFINITIONS} ${QT_DEFINITIONS} ${BOOST_DEFINITIONS} ${OMNIORB_DEFINITIONS})
 
 ADD_LIBRARY(SalomeGuiHelpers ${SalomeGuiHelpers_SOURCES} ${GUI_HEADERS_MOC})
-TARGET_LINK_LIBRARIES(SalomeGuiHelpers SalomeApp ${SalomeKernelHelpers} ${CORBA_LIBS})
+TARGET_LINK_LIBRARIES(SalomeGuiHelpers SalomeApp ${KERNEL_SalomeKernelHelpers} ${CORBA_LIBS})
 INSTALL(TARGETS SalomeGuiHelpers DESTINATION ${GUI_salomelib_LIBS})
 
 FILE(GLOB COMMON_HEADERS_HXX "${CMAKE_CURRENT_SOURCE_DIR}/*.hxx")
index d0eeb0d711c1a9b0966b833b0231aa700551cbcc..4fafadc38e31839bfe4564e22f2ccfe5dfb92187 100755 (executable)
@@ -27,7 +27,8 @@ INCLUDE_DIRECTORIES(
 SET(COMMON_LIBS
   ${QT_LIBRARIES}
   ${CAS_LDPATH}
-  ${TKV3d}
+  ${CAS_KERNEL}
+  ${CAS_TKV3d}
 )
 
 SET(SalomeObject_SOURCES
index df2eab7382a5f1fa5da6680df74a58fd620bb715..8346300b788c6fe75a21a68017abd324705ab7c9 100755 (executable)
@@ -49,6 +49,7 @@ SET(COMMON_LIBS
   ${VTK_LIBRARIES}
   ${OPENGL_LIBRARIES}
   ${PLATFORM_LIBS}
+  ${OMNIORB_LIBRARIES}
   PyInterp
   SalomeApp
   OCCViewer
index 77dda275edb6c6fc3ecc21a77d79341c46d84d91..6a7e9c91a11ae4061396af4947735e7811640e68 100755 (executable)
@@ -51,6 +51,7 @@ SET(COMMON_LIBS
   ${KERNEL_SalomeLauncher}
   ${KERNEL_Registry}
   ${KERNEL_SALOMEBasics}
+  ${OMNIORB_LIBRARIES}
   suit
   Event
   SalomeIDLGUI
index 46cc1eff5f1f2e62c38f18f211bd468ebedaab03..4f4e3b0f94f160255e62ef457ead9e10d913de54 100755 (executable)
@@ -34,10 +34,11 @@ SET(COMMON_LIBS
   ${QT_LIBRARIES}
   suit
   ${CAS_KERNEL}
-  ${SalomeIDLKernel}
-  ${SALOMELocalTrace}
-  ${SalomeNS}
-  ${OpUtil}
+  ${KERNEL_SalomeIDLKernel}
+  ${KERNEL_SALOMELocalTrace}
+  ${KERNEL_SalomeNS}
+  ${KERNEL_OpUtil}
+  ${OMNIORB_LIBRARIES}
   SalomeIDLGUI
 )
 
index 7ae0a27badca4b0fb0980bbb954688fcd794ca37..c1cfaf9c84a00741a80440596532a5edd5a7699c 100755 (executable)
@@ -30,7 +30,7 @@ INCLUDE_DIRECTORIES(
 
 ADD_DEFINITIONS(${CAS_DEFINITIONS} ${QT_DEFINITIONS})
 
-SET(COMMON_LIBS ${QT_LIBRARIES} ${OPENGL_LIBRARIES} ${VTK_LIBRARIES} ${CAS_KERNEL} qtx suit ${SALOMELocalTrace})
+SET(COMMON_LIBS ${QT_LIBRARIES} ${OPENGL_LIBRARIES} ${VTK_LIBRARIES} ${CAS_KERNEL} qtx suit ${KERNEL_SALOMELocalTrace})
 
 SET(GUI_HEADERS   
   VTKViewer_RenderWindow.h
index b032653e3e574d6cef7127ba689fbea42428e214..dc0e23331e1aded43c5f79169d95e797cb875ca0 100644 (file)
@@ -97,6 +97,13 @@ static PFNGLDELETEBUFFERSARBPROC            vglDeleteBuffersARB           = NULL
 #define GL_GetProcAddress( x )   wglGetProcAddress( (const LPCSTR)x )
 #endif
 
+#ifdef WIN32
+  #ifdef max
+    #undef max
+  #endif
+#endif
+
+
 bool InitializeBufferExtensions()
 {
   vglGenBuffersARB = (PFNGLGENBUFFERSARBPROC)GL_GetProcAddress( "glGenBuffersARB" );
index 8510d1f926a1845c65666f51a0822aefe553746f..47c976b56bca91cf19b18ec6ac3f99647199216c 100755 (executable)
@@ -59,11 +59,11 @@ SET(GenericDialog_FORMS
 ADD_DEFINITIONS(${QT_DEFINITIONS})
 
 ADD_CUSTOM_COMMAND( OUTPUT QDialogTest.cxx  QDialogTest.h  QDialogTest.ui
-  COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/dlgfactory.py -s -n QDialogTest -t qdialog
+  COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/dlgfactory.py -s -n QDialogTest -t qdialog
   )
 
 ADD_CUSTOM_COMMAND( OUTPUT GDialogTest.cxx  GDialogTest.h  GDialogTest.ui
-  COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/dlgfactory.py -s -n GDialogTest -t gdialog
+  COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/dlgfactory.py -s -n GDialogTest -t gdialog
   )
 
 QT4_WRAP_UI(qtester_FORMS_HEADERS ${qtester_FORMS} )
index 25c153de83803b3f1fbb0db253b1754f170facd0..d138b45d4d26910ce77951b61b3dbae386ff77d6 100755 (executable)
@@ -44,4 +44,36 @@ const char* vtkEDFFactory::GetDescription()
   return "VTK EDF Factory";
 }
 
+#ifdef WIN32
+  //rnv: workaround to avoid definition __declspec( dllimport )
+  //for the vtkGetFactoryCompilerUsed(), vtkGetFactoryVersion()
+  //and vtkLoad(). This happens because a bug in the 
+  //vtkObjectFactory.h file. 
+  //This workaround will be removed in the future. 
+  #ifdef VTK_FACTORY_INTERFACE_IMPLEMENT
+    #undef VTK_FACTORY_INTERFACE_IMPLEMENT
+
+    #define VTK_FACTORY_INTERFACE_IMPLEMENT(factoryName)  \
+    extern "C"                                      \
+    VTKEDF_OVERLOADS_EXPORT                         \
+    const char* vtkGetFactoryCompilerUsed()         \
+    {                                               \
+      return VTK_CXX_COMPILER;                      \
+    }                                               \
+    extern "C"                                      \
+    VTKEDF_OVERLOADS_EXPORT                         \
+    const char* vtkGetFactoryVersion()              \
+    {                                               \
+      return VTK_SOURCE_VERSION;                    \
+    }                                               \
+    extern "C"                                      \
+    VTKEDF_OVERLOADS_EXPORT                         \
+    vtkObjectFactory* vtkLoad()                     \
+    {                                               \
+      return factoryName ::New();                   \
+    }
+  #endif
+#endif
+
+
 VTK_FACTORY_INTERFACE_IMPLEMENT(vtkEDFFactory);