You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
726 B

10 years ago
cmake_policy(SET CMP0015 NEW)
aux_source_directory(. SOURCES)
10 years ago
10 years ago
include_directories(BEFORE ${JSONCPP_INCLUDE_DIRS})
10 years ago
include_directories(BEFORE ..)
set(EXECUTABLE devcore)
file(GLOB HEADERS "*.h")
10 years ago
add_library(devcore ${SOURCES} ${HEADERS})
target_link_libraries(devcore PUBLIC ${JSONCPP_LIBRARIES} Boost::boost)
10 years ago
if (APPLE)
find_package(Threads REQUIRED)
target_link_libraries(${EXECUTABLE} PRIVATE ${CMAKE_THREAD_LIBS_INIT})
elseif (UNIX)
find_package(Threads REQUIRED)
target_link_libraries(${EXECUTABLE} PRIVATE ${CMAKE_THREAD_LIBS_INIT})
10 years ago
endif()
install( TARGETS ${EXECUTABLE} RUNTIME DESTINATION bin ARCHIVE DESTINATION lib LIBRARY DESTINATION lib )
install( FILES ${HEADERS} DESTINATION include/${EXECUTABLE} )