Make that define a cmake option.

This commit is contained in:
Chris Marsh
2017-07-25 13:40:30 -07:00
parent eb2f6f8edc
commit 7dcc2d45e3
3 changed files with 8 additions and 4 deletions

View File

@ -1,5 +1,11 @@
include_directories(${PROJECT_SOURCE_DIR}/include)
option(ENABLE_IO_THREAD "Start up a separate I/O thread, otherwise I'd need to call an update function" ON)
if (${ENABLE_IO_THREAD} EQUAL OFF)
add_definitions(-DDISCORD_DISABLE_IO_THREAD)
endif (${ENABLE_IO_THREAD} EQUAL OFF)
set(BASE_RPC_SRC ${PROJECT_SOURCE_DIR}/include/discord-rpc.h discord-rpc.cpp rpc_connection.h rpc_connection.cpp serialization.h serialization.cpp connection.h backoff.h)
if(WIN32)