Skip to content

Commit

Permalink
Don't set pthread flag on MSVC
Browse files Browse the repository at this point in the history
  • Loading branch information
slipher committed Jul 10, 2024
1 parent 0b20fdc commit 89a6dd5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,9 @@ else()
set_cxx_flag("-g3" DEBUG)
set_cxx_flag("-g3" RELWITHDEBINFO)

set_cxx_flag("-pthread")
set_linker_flag("-pthread")

if (USE_EXTRA_OPTIMIZATION)
# CMake already sets the -O3 flag on Release build and -O[1-3s] already sets the -fomit-frame-pointer flag.
set_cxx_flag("-Og" DEBUG)
Expand All @@ -122,8 +125,6 @@ else()
endif()

if (BUILD_SHARED_LIBCRN OR BUILD_STATIC_LIBCRN OR BUILD_CRUNCH OR BUILD_EXAMPLES)
set_cxx_flag("-pthread")
set_linker_flag("-pthread")
add_subdirectory(crnlib crnlib)
endif()

Expand Down

0 comments on commit 89a6dd5

Please sign in to comment.