+ build smesh7 on Windows
This commit is contained in:
parent
3814251020
commit
8a97a9eb12
13
src/3rdParty/salomesmesh/CMakeLists.txt
vendored
13
src/3rdParty/salomesmesh/CMakeLists.txt
vendored
|
@ -35,6 +35,7 @@ include_directories(
|
||||||
${ZLIB_INCLUDE_DIR}
|
${ZLIB_INCLUDE_DIR}
|
||||||
${VTK_INCLUDE_DIR}
|
${VTK_INCLUDE_DIR}
|
||||||
${HDF5_INCLUDE_DIR}
|
${HDF5_INCLUDE_DIR}
|
||||||
|
${MEDFILE_INCLUDE_DIRS}
|
||||||
${BOOST_INCLUDE_DIR}
|
${BOOST_INCLUDE_DIR}
|
||||||
)
|
)
|
||||||
link_directories(${OCC_LIBRARY_DIR})
|
link_directories(${OCC_LIBRARY_DIR})
|
||||||
|
@ -138,7 +139,7 @@ ELSE(UNIX)
|
||||||
######### Windows ###########
|
######### Windows ###########
|
||||||
#MESSAGE("-- Windows system detected")
|
#MESSAGE("-- Windows system detected")
|
||||||
IF(MSVC)
|
IF(MSVC)
|
||||||
ADD_DEFINITIONS(-DWNT -DWIN32 -D_WINDOWS -DCSFDB -DUSE_CLOCK -DMSDOS -DNO_ONEXIT -DNO_My_ctype -DNO_ISATTY -DNO_FPINIT /wd4290 /wd4251 /wd4018 /wd4800 /wd4996 /wd4244 /wd4806 /wd4275 /wd4005 /wd4099 /wd4101 /wd4267 /wd4390)
|
ADD_DEFINITIONS(-DWNT -DWIN32 -D_WINDOWS -DCSFDB -DUSE_CLOCK -DMSDOS -DNO_ONEXIT -DNO_My_ctype -DNO_ISATTY -DNO_FPINIT /wd4290 /wd4251 /wd4018 /wd4800 /wd4996 /wd4244 /wd4806 /wd4275 /wd4005 /wd4099 /wd4101 /wd4267 /wd4390 /wd4503 /wd4436)
|
||||||
ELSE(MSVC)
|
ELSE(MSVC)
|
||||||
ADD_DEFINITIONS(-DWNT -DWIN32 -D_WINDOWS -DCSFDB)
|
ADD_DEFINITIONS(-DWNT -DWIN32 -D_WINDOWS -DCSFDB)
|
||||||
ENDIF(MSVC)
|
ENDIF(MSVC)
|
||||||
|
@ -156,7 +157,7 @@ TARGET_LINK_LIBRARIES(SMDS ${SMESH_LIBS} ${HDF5_C_STATIC_LIBRARY} ${VTK_LIBRARIE
|
||||||
|
|
||||||
SET_BIN_DIR(SMDS SMDS)
|
SET_BIN_DIR(SMDS SMDS)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
set_target_properties(SMDS PROPERTIES COMPILE_FLAGS "-DSMDS_EXPORTS")
|
set_target_properties(SMDS PROPERTIES COMPILE_FLAGS "-DSMDS_EXPORTS -DUTILS_EXPORTS")
|
||||||
endif(WIN32)
|
endif(WIN32)
|
||||||
|
|
||||||
|
|
||||||
|
@ -169,7 +170,7 @@ TARGET_LINK_LIBRARIES(Driver ${SMESH_LIBS})
|
||||||
|
|
||||||
SET_BIN_DIR(Driver Driver)
|
SET_BIN_DIR(Driver Driver)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
set_target_properties(Driver PROPERTIES COMPILE_FLAGS "-DMESHDRIVER_EXPORTS")
|
set_target_properties(Driver PROPERTIES COMPILE_FLAGS "-DMESHDRIVER_EXPORTS -DSMESHUtils_EXPORTS")
|
||||||
endif(WIN32)
|
endif(WIN32)
|
||||||
|
|
||||||
|
|
||||||
|
@ -189,7 +190,7 @@ TARGET_LINK_LIBRARIES(DriverSTL ${SMESH_LIBS} Driver SMDS ${Boost_LIBRARIES})
|
||||||
|
|
||||||
SET_BIN_DIR(DriverSTL DriverSTL)
|
SET_BIN_DIR(DriverSTL DriverSTL)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
set_target_properties(DriverSTL PROPERTIES COMPILE_FLAGS "-DMESHDRIVERSTL_EXPORTS")
|
set_target_properties(DriverSTL PROPERTIES COMPILE_FLAGS "-DMESHDRIVERSTL_EXPORTS -DBASICS_EXPORT -DSMESHUtils_EXPORTS -DBASICS_EXPORTS")
|
||||||
endif(WIN32)
|
endif(WIN32)
|
||||||
|
|
||||||
|
|
||||||
|
@ -264,7 +265,7 @@ TARGET_LINK_LIBRARIES(SMESH SMDS SMESHDS Driver DriverSTL DriverDAT DriverUNV $
|
||||||
|
|
||||||
SET_BIN_DIR(SMESH SMESH)
|
SET_BIN_DIR(SMESH SMESH)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
set_target_properties(SMESH PROPERTIES COMPILE_FLAGS "-DSMESH_EXPORTS -DSMESHCONTROLS_EXPORTS -DSMESHimpl_EXPORTS")
|
set_target_properties(SMESH PROPERTIES COMPILE_FLAGS "-DSMESH_EXPORTS -DSMESHCONTROLS_EXPORTS -DSMESHimpl_EXPORTS -DMESHDriverGMF_EXPORTS -DMESHDRIVERMED_EXPORTS -DMEDWRAPPER_EXPORTS -DMEDWRAPPER_BASE_EXPORTS -DMEDWRAPPER_FACTORY_EXPORTS -DSMESHUtils_EXPORTS -DUTILS_EXPORTS")
|
||||||
endif(WIN32)
|
endif(WIN32)
|
||||||
|
|
||||||
|
|
||||||
|
@ -342,7 +343,7 @@ TARGET_LINK_LIBRARIES(StdMeshers SMESH ${SMESH_LIBS} MEFISTO2)
|
||||||
|
|
||||||
SET_BIN_DIR(StdMeshers StdMeshers)
|
SET_BIN_DIR(StdMeshers StdMeshers)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
set_target_properties(StdMeshers PROPERTIES COMPILE_FLAGS "-DSTDMESHERS_EXPORTS")
|
set_target_properties(StdMeshers PROPERTIES COMPILE_FLAGS "-DSTDMESHERS_EXPORTS -DSMESHUtils_EXPORTS")
|
||||||
else(WIN32)
|
else(WIN32)
|
||||||
set_target_properties(StdMeshers PROPERTIES COMPILE_FLAGS "${StdMeshers_CFLAGS}")
|
set_target_properties(StdMeshers PROPERTIES COMPILE_FLAGS "${StdMeshers_CFLAGS}")
|
||||||
endif(WIN32)
|
endif(WIN32)
|
||||||
|
|
3
src/3rdParty/salomesmesh/inc/MED_Wrapper.hxx
vendored
3
src/3rdParty/salomesmesh/inc/MED_Wrapper.hxx
vendored
|
@ -986,7 +986,7 @@ namespace MED
|
||||||
TWrapper * operator-> () const;
|
TWrapper * operator-> () const;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#if 0
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
//! To specialize the SharedPtr for TWrapper
|
//! To specialize the SharedPtr for TWrapper
|
||||||
template<>
|
template<>
|
||||||
|
@ -1047,6 +1047,7 @@ namespace MED
|
||||||
|
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
typedef SharedPtr<TWrapper> PWrapper;
|
typedef SharedPtr<TWrapper> PWrapper;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -82,14 +82,14 @@ namespace nglib {
|
||||||
//#include <ngexception.hpp>
|
//#include <ngexception.hpp>
|
||||||
namespace netgen {
|
namespace netgen {
|
||||||
#ifdef NETGEN_V5
|
#ifdef NETGEN_V5
|
||||||
extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, MeshingParameters&, int, int);
|
DLL_HEADER extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, MeshingParameters&, int, int);
|
||||||
#else
|
#else
|
||||||
extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
|
DLL_HEADER extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
|
||||||
#endif
|
#endif
|
||||||
//extern void OCCSetLocalMeshSize(OCCGeometry & geom, Mesh & mesh);
|
//extern void OCCSetLocalMeshSize(OCCGeometry & geom, Mesh & mesh);
|
||||||
extern MeshingParameters mparam;
|
DLL_HEADER extern MeshingParameters mparam;
|
||||||
extern volatile multithreadt multithread;
|
DLL_HEADER extern volatile multithreadt multithread;
|
||||||
extern bool merge_solids;
|
DLL_HEADER extern bool merge_solids;
|
||||||
}
|
}
|
||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
|
@ -65,12 +65,12 @@ namespace nglib {
|
||||||
//#include <meshtype.hpp>
|
//#include <meshtype.hpp>
|
||||||
namespace netgen {
|
namespace netgen {
|
||||||
#ifdef NETGEN_V5
|
#ifdef NETGEN_V5
|
||||||
extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, MeshingParameters&, int, int);
|
DLL_HEADER extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, MeshingParameters&, int, int);
|
||||||
#else
|
#else
|
||||||
extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
|
DLL_HEADER extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
|
||||||
#endif
|
#endif
|
||||||
extern MeshingParameters mparam;
|
DLL_HEADER extern MeshingParameters mparam;
|
||||||
extern void OCCSetLocalMeshSize(OCCGeometry & geom, Mesh & mesh);
|
DLL_HEADER extern void OCCSetLocalMeshSize(OCCGeometry & geom, Mesh & mesh);
|
||||||
}
|
}
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
|
@ -76,12 +76,12 @@ namespace nglib {
|
||||||
}
|
}
|
||||||
namespace netgen {
|
namespace netgen {
|
||||||
#ifdef NETGEN_V5
|
#ifdef NETGEN_V5
|
||||||
extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, MeshingParameters&, int, int);
|
DLL_HEADER extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, MeshingParameters&, int, int);
|
||||||
#else
|
#else
|
||||||
extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
|
DLL_HEADER extern int OCCGenerateMesh (OCCGeometry&, Mesh*&, int, int, char*);
|
||||||
#endif
|
#endif
|
||||||
extern MeshingParameters mparam;
|
DLL_HEADER extern MeshingParameters mparam;
|
||||||
extern volatile multithreadt multithread;
|
DLL_HEADER extern volatile multithreadt multithread;
|
||||||
}
|
}
|
||||||
using namespace nglib;
|
using namespace nglib;
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
|
@ -78,7 +78,9 @@
|
||||||
#include <boost/thread/thread.hpp>
|
#include <boost/thread/thread.hpp>
|
||||||
#include <boost/bind.hpp>
|
#include <boost/bind.hpp>
|
||||||
#else
|
#else
|
||||||
#include <pthread.h>
|
#include <boost/thread/thread.hpp>
|
||||||
|
#include <boost/bind.hpp>
|
||||||
|
//#include <pthread.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
@ -221,8 +223,9 @@ SMESH_Mesh::~SMESH_Mesh()
|
||||||
#ifndef WIN32
|
#ifndef WIN32
|
||||||
boost::thread aThread(boost::bind( & deleteMeshDS, _myMeshDS ));
|
boost::thread aThread(boost::bind( & deleteMeshDS, _myMeshDS ));
|
||||||
#else
|
#else
|
||||||
pthread_t thread;
|
boost::thread aThread(boost::bind( & deleteMeshDS, _myMeshDS ));
|
||||||
int result=pthread_create(&thread, NULL, deleteMeshDS, (void*)_myMeshDS);
|
// pthread_t thread;
|
||||||
|
// int result=pthread_create(&thread, NULL, deleteMeshDS, (void*)_myMeshDS);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user