forked from dmikushin/binance-cxx-api
-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
31 lines (20 loc) · 826 Bytes
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
cmake_minimum_required(VERSION 3.1.0)
project(binance-cxx-api)
set(PROJECT_VERSION_MAJOR 0)
set(PROJECT_VERSION_MINOR 1)
set(PROJECT_VERSION_PATCH 0)
set(CMAKE_CXX_STANDARD 11)
# Manual build type selection (for debugging purposes)
#set(CMAKE_BUILD_TYPE Debug)
set(CMAKE_BUILD_TYPE Release)
# Search path for CMake include files.
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
find_package(CURL REQUIRED)
find_package(LibWebSockets REQUIRED)
find_package(JsonCpp REQUIRED)
file(GLOB_RECURSE LIBRARY_SRC "src/*.cpp" "include/*.h")
add_library(${PROJECT_NAME} SHARED ${LIBRARY_SRC})
target_link_libraries(${PROJECT_NAME} jsoncpp curl websockets)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include)
add_executable(example example.cpp)
target_link_libraries(example ${PROJECT_NAME})