Changeset 185 in pacpusframework for trunk/examples


Ignore:
Timestamp:
Oct 23, 2013, 10:32:21 AM (11 years ago)
Author:
morasjul
Message:

Fixed: dependencies.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/examples/ProducerConsumerExample/CMakeLists.txt

    r181 r185  
    11project(ProducerConsumerExample)
    22
    3 # ========================================
    4 # Basic Definitions
    5 # ========================================
    63set(${PROJECT_NAME}_VERSION_MAJOR 0)
    74set(${PROJECT_NAME}_VERSION_MINOR 1)
    85
     6################################################################################
    97create_export(EXPORT_HDR ${PROJECT_NAME})
    10 pacpus_plugin(PLUGIN_CPP PLUGIN_H ${PROJECT_NAME})
     8pacpus_plugin(PLUGIN_CPP PLUGIN_HDR ${PROJECT_NAME})
    119
    12 # ========================================
    13 # Compiler definitions
    14 # ========================================
    15 add_definitions(${QT_DEFINITIONS})
    16 
    17 # ========================================
    18 # Include directories
    19 # ========================================
     10################################################################################
     11# INCLUDES
    2012include_directories(
    2113    ${PACPUSCITYVIP_INCLUDE_DIR}
     
    2416)
    2517
    26 # ========================================
     18################################################################################
    2719# Link directories
    28 # ========================================
    2920set(SRC_BINARY_DIR "${PROJECT_BINARY_DIR}/../../src")
    3021get_filename_component(SRC_BINARY_DIR "${SRC_BINARY_DIR}" ABSOLUTE)
     
    3627)
    3728
    38 # ========================================
    39 # List of sources
    40 # ========================================
     29################################################################################
     30# FILES
    4131set(PROJECT_HDRS
     32    ${EXPORT_HDR}
    4233    ProducerExample.h
    4334    ConsumerExample.h
    44     ${PROJECT_NAME}.xml
    45     ${EXPORT_HDR}
     35    XML/${PROJECT_NAME}.xml
     36    XML/${PROJECT_NAME}_d.xml
    4637)
    4738set(PROJECT_SRCS
     
    5142)
    5243
    53 # ========================================
    54 # Files to MOC
    55 # ========================================
    5644set(FILES_TO_MOC
    57     ${PLUGIN_H}
     45    ${PLUGIN_HDR}
    5846    ProducerExample.h
    5947    ConsumerExample.h
     
    6351)
    6452
    65 # ========================================
    66 # Call MOC
    67 # ========================================
    68 qt_wrap_cpp(
    69     PROJECT_MOC_SRCS
     53################################################################################
     54# Qt: call moc, uic
     55qt_wrap_cpp(PROJECT_MOC_SRCS
    7056    ${FILES_TO_MOC}
    71  )
     57)
    7258
    73 qt_wrap_ui(
    74     PROJECT_UI_SRCS
     59qt_wrap_ui(PROJECT_UI_SRCS
    7560    ${UI_FILES}
    7661)
    7762
    78 # ========================================
    79 # Build a library
    80 # ========================================
    81 pacpus_add_library(
    82     ${PROJECT_NAME} SHARED
     63################################################################################
     64# BUILD and LINK
     65pacpus_add_library(${PROJECT_NAME} SHARED
    8366    ${PROJECT_HDRS}
    8467    ${PROJECT_SRCS}
     
    8669    ${PROJECT_UI_SRCS}
    8770)
     71
    8872list(APPEND PACPUS_LIBRARIES
    8973    optimized PacpusLib debug PacpusLib_d
    9074)
    91 if(WIN32)
    92     list(APPEND PACPUS_LIBRARIES
    93         optimized road_time debug road_time_d
    94     )
    95 endif()
    96 #message("\${PACPUS_LIBRARIES} = ${PACPUS_LIBRARIES}")
    97 #message("\${PACPUS_DEPENDENCIES_LIB} = ${PACPUS_DEPENDENCIES_LIB}")
    98 
    99 # ========================================
    100 # Libraries
    101 # ========================================
    102 # All the platform
    103 target_link_libraries(${PROJECT_NAME}
     75message(STATUS "\${PACPUS_LIBRARIES} = ${PACPUS_LIBRARIES}")
     76message(STATUS "\${PACPUS_DEPENDENCIES_LIB} = ${PACPUS_DEPENDENCIES_LIB}")
     77# LIBS
     78set(LIBS
    10479    ${PACPUS_LIBRARIES}
    10580        ${PACPUS_DEPENDENCIES_LIB}
     81    #${OpenCV_LIBRARIES}
    10682    ${QT_LIBRARIES}
    107     #${OpenCV_LIBRARIES}
    10883)
    10984
    110 # ========================================
    111 # Install
    112 # ========================================
     85# LINK
     86target_link_libraries(${PROJECT_NAME} ${LIBS})
     87
     88################################################################################
     89# FOLDERS
     90pacpus_folder(${PROJECT_NAME} "examples")
     91
     92################################################################################
     93# INSTALL
    11394pacpus_install(${PROJECT_NAME})
    11495
    11596# Installation of the headers
    11697#install(DIRECTORY ${PACPUSCITYVIP_INCLUDE_DIR} DESTINATION "${PACPUS_ROOT}")
    117 
    118 # ========================================
    119 # Folder
    120 # ========================================
    121 pacpus_folder(${PROJECT_NAME} "examples")
Note: See TracChangeset for help on using the changeset viewer.