2023-11-21 22:19:08 +00:00
|
|
|
cmake_minimum_required(VERSION 3.5)
|
|
|
|
project(pica
|
|
|
|
VERSION 0.0.1
|
|
|
|
LANGUAGES CXX
|
|
|
|
)
|
2023-11-21 14:24:12 +00:00
|
|
|
|
2023-11-21 22:19:08 +00:00
|
|
|
cmake_policy(SET CMP0076 NEW)
|
|
|
|
|
|
|
|
set(CMAKE_CXX_STANDARD 17)
|
|
|
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
2023-11-29 13:09:11 +00:00
|
|
|
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake")
|
2023-11-21 22:19:08 +00:00
|
|
|
|
2023-11-23 19:57:32 +00:00
|
|
|
find_package(nlohmann_json REQUIRED)
|
2023-11-29 13:09:11 +00:00
|
|
|
find_package(FCGI REQUIRED)
|
2023-11-21 14:24:12 +00:00
|
|
|
|
|
|
|
add_executable(pica main.cpp)
|
2023-11-21 22:19:08 +00:00
|
|
|
target_include_directories(pica PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
|
|
|
|
|
add_subdirectory(server)
|
|
|
|
add_subdirectory(request)
|
|
|
|
add_subdirectory(response)
|
|
|
|
add_subdirectory(stream)
|
|
|
|
|
2023-11-23 19:57:32 +00:00
|
|
|
target_link_libraries(pica PRIVATE
|
2023-11-29 13:09:11 +00:00
|
|
|
FCGI::FCGI
|
|
|
|
FCGI::FCGI++
|
2023-11-23 19:57:32 +00:00
|
|
|
nlohmann_json::nlohmann_json
|
2023-11-21 22:19:08 +00:00
|
|
|
)
|
2023-11-21 14:24:12 +00:00
|
|
|
|
|
|
|
install(TARGETS pica RUNTIME DESTINATION bin)
|