Skip to content

Commit

Permalink
changes flag name
Browse files Browse the repository at this point in the history
  • Loading branch information
JhaShweta1 committed Jan 25, 2024
1 parent 8ce81c5 commit 0495d0d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
5 changes: 1 addition & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -194,11 +194,8 @@ endif()
# -------------------------------------------------------------------
# Common dependencies
#force -pthread during compilation for Emscripten
if (EMSCRIPTEN)
if (EMSCRIPTEN AND NOT EMSCRIPTEN_WITHOUT_PTHREAD)
set(THREADS_HAVE_PTHREAD_ARG TRUE)
if(EMSCRIPTEN_NO_PTHREAD)
set(THREADS_HAVE_PTHREAD_ARG FALSE)
endif()
endif()

set(THREADS_PREFER_PTHREAD_FLAG TRUE)
Expand Down
4 changes: 1 addition & 3 deletions cmake/compilers/Clang.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ if (EMSCRIPTEN)
set(TBB_EMSCRIPTEN 1)
set(TBB_COMMON_COMPILE_FLAGS ${TBB_COMMON_COMPILE_FLAGS} -fexceptions)
set(TBB_TEST_LINK_FLAGS ${TBB_COMMON_LINK_FLAGS} -fexceptions -sINITIAL_MEMORY=65536000 -sALLOW_MEMORY_GROWTH=1 -sEXIT_RUNTIME=1)
if (EMSCRIPTEN_NO_PTHREAD)
set_property(TARGET Threads::Threads PROPERTY INTERFACE_LINK_LIBRARIES)
else ()
if (NOT EMSCRIPTEN_WITHOUT_PTHREAD)
set_property(TARGET Threads::Threads PROPERTY INTERFACE_LINK_LIBRARIES "-pthread")
endif()
endif()
Expand Down

0 comments on commit 0495d0d

Please sign in to comment.