find_package(nlohmann_json 3 REQUIRED)

file(GLOB_RECURSE HTTP_SOURCES "./*.cpp")
add_library(http SHARED ${HTTP_SOURCES})
set(LIB_PATH "/usr/local/lib")
target_link_directories(http PUBLIC ${LIB_PATH})
if(WIN32)
    target_link_libraries(http ${LIB_PATH}/librum.dll.a ${LIB_PATH}/libflags-cpp.dll.a nlohmann_json::nlohmann_json)
else()
    target_link_libraries(http librum.so libflags-cpp.so nlohmann_json::nlohmann_json)
endif()
set_target_properties(http PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/plugins")