diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt index 43a492fa5..01fd08260 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt @@ -1,15 +1,33 @@ +INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_BINARY_DIR} + ${CMAKE_CURRENT_SOURCE_DIR} + ${LIBXML2_INCLUDE_DIR} + ${QT_INCLUDES}) + FILE(GLOB SRC *.cpp *.h) +SET(OVQT_EXT_SYS_SRC ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin.h + ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_manager.h + ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/plugin_spec.h + ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/plugin_spec.cpp) + +SET(OVQT_PLUG_EXAMPLE_HDR plugin1.h) + +SET(QT_USE_QTGUI TRUE) +SET(QT_USE_QTOPENGL TRUE) + +QT4_WRAP_CPP(OVQT_PLUG_EXAMPLE_MOC_SRC ${OVQT_PLUG_EXAMPLE_HDR}) -ADD_LIBRARY(ovqt_plugin_example SHARED ${SRC}) +SOURCE_GROUP(QtGeneratedMocSrc FILES ${OVQT_PLUG_EXAMPLE_MOC_SRC}) +SOURCE_GROUP("Example Plugin" FILES ${SRC}) +SOURCE_GROUP("OVQT Extension System" FILES ${OVQT_EXT_SYS_SRC}) -INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR}) +ADD_LIBRARY(ovqt_plugin_example SHARED ${SRC} ${OVQT_PLUG_EXAMPLE_MOC_SRC} ${OVQT_EXT_SYS_SRC}) -TARGET_LINK_LIBRARIES(ovqt_plugin_example nelmisc) +TARGET_LINK_LIBRARIES(ovqt_plugin_example nelmisc ${QT_LIBRARIES}) NL_DEFAULT_PROPS(ovqt_plugin_example "NeL, Tools, 3D: Object Viewer Qt Plugin: Example") NL_ADD_RUNTIME_FLAGS(ovqt_plugin_example) NL_ADD_LIB_SUFFIX(ovqt_plugin_example) -ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN) +ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) INSTALL(TARGETS ovqt_plugin_example LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d)