King_DuckZ
21476e0a5d
Character conversion relies on the setlocale(LC_TYPE, "") in main(), but maybe there are better ways of doing this.
31 lines
592 B
CMake
31 lines
592 B
CMake
project (wordreference CXX)
|
|
|
|
find_package(CURL REQUIRED)
|
|
find_package(Boost 1.32.0 REQUIRED program_options)
|
|
|
|
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DJSON_DEBUG")
|
|
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}")
|
|
|
|
include_directories(SYSTEM
|
|
${CURL_INCLUDE_DIRS}
|
|
${Boost_INCLUDE_DIRS}
|
|
)
|
|
include_directories(
|
|
src/
|
|
../libjson/
|
|
)
|
|
link_directories(
|
|
${Boost_LIBRARY_DIRS}
|
|
)
|
|
|
|
add_executable(${PROJECT_NAME}
|
|
src/main.cpp
|
|
src/WordReference.cpp
|
|
src/HttpReader.cpp
|
|
src/CharConv.cpp
|
|
)
|
|
target_link_libraries(${PROJECT_NAME}
|
|
${Boost_LIBRARIES}
|
|
${CURL_LIBRARIES}
|
|
libjson
|
|
)
|