All: Clean up pthreads in CMakeList

This commit is contained in:
Jeffrey Pfau 2015-02-20 23:18:18 -08:00
parent 07feb10f6d
commit d794b24566
1 changed files with 4 additions and 2 deletions

View File

@ -110,8 +110,10 @@ if(WIN32)
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/windows/*.c)
source_group("Windows-specific code" FILES ${OS_SRC})
else()
add_definitions(-DUSE_PTHREADS -D_GNU_SOURCE)
list(APPEND OS_LIB pthread)
add_definitions(-DUSE_PTHREADS)
if(NOT APPLE)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pthread")
endif()
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/posix/*.c)
source_group("POSIX-specific code" FILES ${OS_SRC})
endif()