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