project(pml2mmlOut)

if(MML_GENERATE_GUI)
    #set(CAMITK_QT_COMPONENTS Core Gui Widgets Xml UiTools Help OpenGL OpenGLExtensions)
    # List of Qt modules that are required in CamiTK
    set(CAMITK_QT_COMPONENTS Core Gui Widgets Xml UiTools)
    # list of namespace prefixed to use in target_link_libraries
    string(REGEX REPLACE "([^;]+)" "Qt::\\1" CAMITK_QT_LIBRARIES "${CAMITK_QT_COMPONENTS}")
    # Find Qt6
    find_package(Qt6 COMPONENTS ${CAMITK_QT_COMPONENTS} QUIET)
    if (NOT Qt6_FOUND)
        # Find Qt5
        find_package(Qt5 5.15 COMPONENTS ${CAMITK_QT_COMPONENTS} REQUIRED)
        if (NOT Qt5_FOUND)
            message(SEND_ERROR "Modeling application pml2mmlOut: Failed to find Qt 5.x/6.x. This is needed by ${LIBRARY_TARGET_NAME}.")
        endif()
    endif()
    message(STATUS "Modeling application pml2mmlOut: found Qt ${Qt_VERSION}.")
    add_definitions(-DMML_GENERATE_GUI)
endif()

set(pml2mmlOut_LIBRARIES
    ${MML_DEPENDENCY}
)

set(HEADERS
)

set(SRCS
  pml2mmlOut.cpp
  ${HEADERS}
)

include_directories(${MML_INCLUDE_DIRECTORIES})
link_directories(${MML_LINK_DIRECTORIES})
add_executable(pml2mmlOut ${SRCS})
target_link_libraries(pml2mmlOut ${CAMITK_QT_LIBRARIES} ${pml2mmlOut_LIBRARIES})
add_dependencies(pml2mmlOut ${MONITORING_DEPENDENCY})
