mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-12-27 01:40:33 +05:00
tmp: get rid of pthread link
This commit is contained in:
parent
bedb532f34
commit
eecb991e2f
@ -31,8 +31,10 @@ if (DEFINED EMSCRIPTEN)
|
|||||||
add_link_options("-sWARN_ON_UNDEFINED_SYMBOLS=1" "-sWASM_BIGINT=1")
|
add_link_options("-sWARN_ON_UNDEFINED_SYMBOLS=1" "-sWASM_BIGINT=1")
|
||||||
list(APPEND CMAKE_FIND_ROOT_PATH "/")
|
list(APPEND CMAKE_FIND_ROOT_PATH "/")
|
||||||
message("Using Emscripten")
|
message("Using Emscripten")
|
||||||
add_compile_options(-sUSE_BOOST_HEADERS=1 -pthread)
|
add_compile_options(-sUSE_BOOST_HEADERS=1)
|
||||||
add_link_options(-sUSE_BOOST_HEADERS=1 -pthread)
|
add_link_options(-sUSE_BOOST_HEADERS=1)
|
||||||
|
# add_compile_options(-sUSE_BOOST_HEADERS=1 -pthread)
|
||||||
|
# add_link_options(-sUSE_BOOST_HEADERS=1 -pthread)
|
||||||
add_compile_definitions(__EMSCRIPTEN__)
|
add_compile_definitions(__EMSCRIPTEN__)
|
||||||
else()
|
else()
|
||||||
message("Not using Emscripten")
|
message("Not using Emscripten")
|
||||||
@ -127,7 +129,7 @@ ELSE()
|
|||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
# PThread
|
# PThread
|
||||||
FIND_PACKAGE(SalomePThread REQUIRED)
|
# FIND_PACKAGE(SalomePThread REQUIRED)
|
||||||
# SWIG
|
# SWIG
|
||||||
FIND_PACKAGE(SalomeSWIG REQUIRED)
|
FIND_PACKAGE(SalomeSWIG REQUIRED)
|
||||||
# Boost
|
# Boost
|
||||||
@ -352,7 +354,8 @@ INCLUDE(CMakePackageConfigHelpers)
|
|||||||
# They all have to be INSTALL'd with the option "EXPORT ${PROJECT_NAME}TargetGroup"
|
# They all have to be INSTALL'd with the option "EXPORT ${PROJECT_NAME}TargetGroup"
|
||||||
SET(_${PROJECT_NAME}_exposed_targets
|
SET(_${PROJECT_NAME}_exposed_targets
|
||||||
SMESHControls MeshDriver MeshDriverDAT MeshDriverGMF MeshDriverMED
|
SMESHControls MeshDriver MeshDriverDAT MeshDriverGMF MeshDriverMED
|
||||||
MeshDriverSTL MeshDriverUNV MEDWrapper
|
# MeshDriverSTL MeshDriverUNV MEDWrapper
|
||||||
|
MeshDriverSTL MeshDriverUNV
|
||||||
SMDS SMESHimpl SMESHEngine SMESHClient SMESHDS
|
SMDS SMESHimpl SMESHEngine SMESHClient SMESHDS
|
||||||
SMESHUtils StdMeshers StdMeshersEngine
|
SMESHUtils StdMeshers StdMeshersEngine
|
||||||
SalomeIDLSMESH SalomeIDLSPADDER
|
SalomeIDLSMESH SalomeIDLSPADDER
|
||||||
|
@ -26,7 +26,7 @@ SET(SUBDIRS_COMMON
|
|||||||
SMESHUtils
|
SMESHUtils
|
||||||
Controls
|
Controls
|
||||||
Driver
|
Driver
|
||||||
MEDWrapper
|
# MEDWrapper
|
||||||
DriverMED
|
DriverMED
|
||||||
DriverDAT
|
DriverDAT
|
||||||
DriverUNV
|
DriverUNV
|
||||||
@ -42,6 +42,10 @@ SET(SUBDIRS_COMMON
|
|||||||
Tools
|
Tools
|
||||||
)
|
)
|
||||||
|
|
||||||
|
IF (NOT DEFINED EMSCRIPTEN)
|
||||||
|
LIST(APPEND SUBDIRS_COMMON MEDWrapper)
|
||||||
|
endif()
|
||||||
|
|
||||||
##
|
##
|
||||||
# CGNS
|
# CGNS
|
||||||
##
|
##
|
||||||
|
@ -44,7 +44,7 @@ ADD_DEFINITIONS(
|
|||||||
SET(_link_LIBRARIES
|
SET(_link_LIBRARIES
|
||||||
${Boost_LIBRARIES}
|
${Boost_LIBRARIES}
|
||||||
MeshDriver
|
MeshDriver
|
||||||
MEDWrapper
|
# MEDWrapper
|
||||||
)
|
)
|
||||||
|
|
||||||
SET(_link_LIBRARIES_bin
|
SET(_link_LIBRARIES_bin
|
||||||
|
@ -82,7 +82,7 @@ SET(SMESHimpl_HEADERS
|
|||||||
SMESH_Gen.hxx
|
SMESH_Gen.hxx
|
||||||
SMESH_Mesh.hxx
|
SMESH_Mesh.hxx
|
||||||
SMESH_SequentialMesh.hxx
|
SMESH_SequentialMesh.hxx
|
||||||
SMESH_ParallelMesh.hxx
|
# SMESH_ParallelMesh.hxx
|
||||||
SMESH_subMesh.hxx
|
SMESH_subMesh.hxx
|
||||||
SMESH_subMeshEventListener.hxx
|
SMESH_subMeshEventListener.hxx
|
||||||
SMESH_Hypothesis.hxx
|
SMESH_Hypothesis.hxx
|
||||||
@ -109,7 +109,7 @@ SET(SMESHimpl_SOURCES
|
|||||||
SMESH_Gen.cxx
|
SMESH_Gen.cxx
|
||||||
SMESH_Mesh.cxx
|
SMESH_Mesh.cxx
|
||||||
SMESH_SequentialMesh.cxx
|
SMESH_SequentialMesh.cxx
|
||||||
SMESH_ParallelMesh.cxx
|
# SMESH_ParallelMesh.cxx
|
||||||
SMESH_subMesh.cxx
|
SMESH_subMesh.cxx
|
||||||
SMESH_Hypothesis.cxx
|
SMESH_Hypothesis.cxx
|
||||||
SMESH_Algo.cxx
|
SMESH_Algo.cxx
|
||||||
|
@ -73,13 +73,18 @@
|
|||||||
|
|
||||||
#include "Utils_ExceptHandlers.hxx"
|
#include "Utils_ExceptHandlers.hxx"
|
||||||
|
|
||||||
#if (!defined WIN32 && !defined __EMSCRIPTEN__)
|
#if (!defined __EMSCRIPTEN)
|
||||||
|
|
||||||
|
#if (!defined WIN32)
|
||||||
|
|
||||||
#include <boost/thread/thread.hpp>
|
#include <boost/thread/thread.hpp>
|
||||||
#include <boost/bind.hpp>
|
#include <boost/bind.hpp>
|
||||||
#else
|
#else
|
||||||
#include <pthread.h>
|
#include <pthread.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
#if (!defined WIN32 && !defined __EMSCRIPTEN__)
|
#if (!defined WIN32 && !defined __EMSCRIPTEN__)
|
||||||
#include <boost/filesystem.hpp>
|
#include <boost/filesystem.hpp>
|
||||||
namespace fs=boost::filesystem;
|
namespace fs=boost::filesystem;
|
||||||
@ -225,11 +230,16 @@ SMESH_Mesh::~SMESH_Mesh()
|
|||||||
|
|
||||||
if ( _meshDS ) {
|
if ( _meshDS ) {
|
||||||
// delete _meshDS, in a thread in order not to block closing a study with large meshes
|
// delete _meshDS, in a thread in order not to block closing a study with large meshes
|
||||||
#if (!defined WIN32 && !defined __EMSCRIPTEN__)
|
#if (!defined __EMSCRIPTEN)
|
||||||
|
#if (!defined WIN32)
|
||||||
boost::thread aThread(boost::bind( & deleteMeshDS, _meshDS ));
|
boost::thread aThread(boost::bind( & deleteMeshDS, _meshDS ));
|
||||||
#else
|
#else
|
||||||
pthread_t thread;
|
pthread_t thread;
|
||||||
int result=pthread_create(&thread, NULL, deleteMeshDS, (void*)_meshDS);
|
int result=pthread_create(&thread, NULL, deleteMeshDS, (void*)_meshDS);
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
deleteMeshDS(&_meshDS);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -72,7 +72,7 @@ SET(_link_LIBRARIES
|
|||||||
SMESHDS
|
SMESHDS
|
||||||
SMESHControls
|
SMESHControls
|
||||||
SMESHEngine
|
SMESHEngine
|
||||||
MEDWrapper
|
# MEDWrapper
|
||||||
)
|
)
|
||||||
|
|
||||||
# --- headers ---
|
# --- headers ---
|
||||||
|
Loading…
Reference in New Issue
Block a user