
SET(SRC_FILES
    main.cpp
)

SET(INCLUDE_DIRS
	${PROJECT_SOURCE_DIR}/utilite/include
	${PROJECT_SOURCE_DIR}/corelib/include
	${PROJECT_SOURCE_DIR}/guilib/include
    ${OpenCV_INCLUDE_DIRS}
)

INCLUDE(${QT_USE_FILE})

SET(LIBRARIES
	${OpenCV_LIBRARIES}
	${QT_LIBRARIES} 
)

INCLUDE_DIRECTORIES(${INCLUDE_DIRS})

IF(MINGW)
  ADD_EXECUTABLE(databaseViewer WIN32 ${SRC_FILES})
ELSE()
  ADD_EXECUTABLE(databaseViewer ${SRC_FILES})
ENDIF()

TARGET_LINK_LIBRARIES(databaseViewer rtabmap_core rtabmap_gui rtabmap_utilite ${LIBRARIES})

SET_TARGET_PROPERTIES( databaseViewer 
  PROPERTIES OUTPUT_NAME ${PROJECT_PREFIX}-databaseViewer)

INSTALL(TARGETS databaseViewer
		RUNTIME DESTINATION "${INSTALL_BIN_DIR}" COMPONENT runtime
		BUNDLE DESTINATION "${CMAKE_BUNDLE_LOCATION}" COMPONENT runtime)
