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
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
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}")
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)
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")
SET(COMMON_LIBS
${QT_LIBRARIES}
${CAS_LDPATH}
- ${TKV3d}
+ ${CAS_KERNEL}
+ ${CAS_TKV3d}
)
SET(SalomeObject_SOURCES
${VTK_LIBRARIES}
${OPENGL_LIBRARIES}
${PLATFORM_LIBS}
+ ${OMNIORB_LIBRARIES}
PyInterp
SalomeApp
OCCViewer
${KERNEL_SalomeLauncher}
${KERNEL_Registry}
${KERNEL_SALOMEBasics}
+ ${OMNIORB_LIBRARIES}
suit
Event
SalomeIDLGUI
${QT_LIBRARIES}
suit
${CAS_KERNEL}
- ${SalomeIDLKernel}
- ${SALOMELocalTrace}
- ${SalomeNS}
- ${OpUtil}
+ ${KERNEL_SalomeIDLKernel}
+ ${KERNEL_SALOMELocalTrace}
+ ${KERNEL_SalomeNS}
+ ${KERNEL_OpUtil}
+ ${OMNIORB_LIBRARIES}
SalomeIDLGUI
)
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
#define GL_GetProcAddress( x ) wglGetProcAddress( (const LPCSTR)x )
#endif
+#ifdef WIN32
+ #ifdef max
+ #undef max
+ #endif
+#endif
+
+
bool InitializeBufferExtensions()
{
vglGenBuffersARB = (PFNGLGENBUFFERSARBPROC)GL_GetProcAddress( "glGenBuffersARB" );
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} )
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);