add_library(popup SHARED popup.cpp)

add_dependencies(popup blogidev)

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

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