source: pacpussensors/trunk/StdDbtPlayerComponents/CMakeLists.txt@ 108

Last change on this file since 108 was 108, checked in by ydroniou, 9 years ago

Add DbtPlyCPT and fix DbtPlyAlasca

File size: 3.3 KB
Line 
1#########################quick start############################################
2#cmake ../ -G "CodeBlocks - Unix Makefiles"
3#make
4#make install
5#make clean
6################################################################################
7project(StdDbtPlayerComponents)
8set(${PROJECT_NAME}_VERSION_MAJOR 0)
9set(${PROJECT_NAME}_VERSION_MINOR 1)
10add_definitions( -DSTDDBTPLAYERCOMPONENTS_EXPORTS )
11add_definitions( -DDBTPLYSICK_EXPORTS)
12add_definitions( -DDBTPLYSICK_EXPORTS)
13################################################################################
14create_export(EXPORT_HDR ${PROJECT_NAME})
15pacpus_plugin(PLUGIN_CPP PLUGIN_HDR ${PROJECT_NAME})
16add_definitions (${QT_DEFINITIONS})
17
18find_package(Qt5Network REQUIRED)
19################################################################################
20# DIRECTORIES
21include_directories(
22 ${PROJECT_BINARY_DIR}
23 ${QT_INCLUDE_DIR}
24 ${PACPUS_INCLUDE_DIR}
25 ${PACPUS_INCLUDE_DIR}/Pacpus/
26)
27
28# ========================================
29# Link directories
30# ========================================
31link_directories(
32 ${PACPUS_LIB_DIR}
33)
34
35
36################################################################################
37# FILES
38set(PROJECT_HDRS
39 ${EXPORT_HDR}
40 StdDbtPlayerComponentsConfig.h
41 DbtPlySickLMSManager.h
42 DbtPlySickLDMRSManager.h
43
44 DbtPlyAlascaManager.h
45 DbtPlyImageManager.h
46 DbtPlyCPTComponent.h
47
48 #${PROJECT_NAME}.xml
49 #${PROJECT_NAME}_d.xml
50)
51set(PROJECT_SRCS
52 ${PLUGIN_CPP}
53 DbtPlySickLMSManager.cpp
54 DbtPlySickLDMRSManager.cpp
55
56 DbtPlyAlascaManager.cpp
57 DbtPlyImageManager.cpp
58 DbtPlyCPTComponent.cpp
59)
60
61set(FILES_TO_MOC
62 ${PLUGIN_HDR}
63 DbtPlySickLMSManager.h
64 DbtPlySickLDMRSManager.h
65
66 DbtPlyAlascaManager.h
67 DbtPlyImageManager.h
68 DbtPlyCPTComponent.h
69)
70
71set(UI_FILES
72)
73
74################################################################################
75# Qt: call moc, uic
76qt_wrap_cpp(PROJECT_MOC_SRCS
77 ${FILES_TO_MOC}
78)
79
80qt_wrap_ui(PROJECT_UI_SRCS
81 ${UI_FILES}
82)
83
84################################################################################
85# BUILD and LINK
86pacpus_add_library(${PROJECT_NAME} SHARED
87 ${PROJECT_HDRS}
88 ${PROJECT_SRCS}
89 ${PROJECT_MOC_SRCS}
90 ${PROJECT_UI_SRCS}
91)
92
93
94# ========================================
95# Libraries
96# ========================================
97set(LIBS
98 optimized FileLib debug FileLib_d
99 optimized PacpusLib debug PacpusLib_d
100 optimized PacpusTools debug PacpusTools_d
101
102 optimized NMEA0183LIB debug NMEA0183LIB_d
103
104)
105if (WIN32)
106 list(APPEND LIBS
107 optimized ROAD_TIME debug ROAD_TIME_d
108 )
109endif()
110# LINK
111target_link_libraries(${PROJECT_NAME}
112 ${PACPUS_LIBRARIES}
113 ${PACPUS_DEPENDENCIES_LIB}
114 ${LIBS}
115 ${QT_LIBRARIES}
116
117 optimized NMEA0183LIB debug NMEA0183LIB_d
118 )
119qt5_use_modules(${PROJECT_NAME} Network)
120################################################################################
121# FOLDERS
122pacpus_folder(${PROJECT_NAME} "components")
123################################################################################
124# INSTALL
125pacpus_install(${PROJECT_NAME})
126
127# install headers
128install(
129 DIRECTORY
130 ${StdDbtPlayerComponents_SOURCE_DIR}
131 DESTINATION
132 ${PACPUS_INSTALL_DIR}/include
133 FILES_MATCHING PATTERN "*.h"
134)
Note: See TracBrowser for help on using the repository browser.