add_library(webedit_table SHARED table.cpp)

add_dependencies(webedit_table blogidev)

if(${CMAKE_HOST_SYSTEM_NAME} STREQUAL "Windows")
    target_link_libraries(webedit_table PUBLIC blogidev kernel32.lib uuidp::uuidp htmlpp::htmlpp json-c::json-c tinyxml2::tinyxml2)
else()
    target_link_libraries(webedit_table PUBLIC blogidev dl uuidp::uuidp htmlpp::htmlpp json-c::json-c tinyxml2::tinyxml2)
endif()

set_target_properties(webedit_table PROPERTIES OUTPUT_NAME "table")

install(TARGETS webedit_table DESTINATION lib/blogi/plugins/webedit)
