source: pacpusframework/branches/2.0-beta1/src/PacpusTools/CMakeLists.txt@ 113

Last change on this file since 113 was 111, checked in by morasjul, 11 years ago

Beta-2 : Add missing file inputOutputBase.cpp, et clean CMakeList

  • Property svn:executable set to *
File size: 3.1 KB
Line 
1#################################################
2# ___________ ____ ______ __ __ _____ #
3# \____ \__ \ _/ ___\\____ \| | \/ ___/ #
4# | |_> > __ \\ \___| |_> > | /\___ \ #
5# | __(____ /\___ > __/|____//____ > #
6# |__| \/ \/|__| \/ #
7# #
8#################################################
9project(PacpusTools)
10
11# ========================================
12# Compiler definitions
13# ========================================
14add_definitions(
15 ${QT_DEFINITIONS}
16)
17
18# ========================================
19# Include directories
20# ========================================
21include_directories(
22 ${QT_INCLUDE_DIR}
23)
24# ========================================
25# Link directories
26# ========================================
27link_directories(
28 ${PROJECT_BINARY_DIR}/../PacpusLib
29)
30
31# ========================================
32# List of sources
33# ========================================
34set(
35 PROJECT_SRCS
36 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/matrice.h
37 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/BinaryDecoder.h
38 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/PosixShMem.h
39 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/ShMem.h
40 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/geodesie.h
41 #${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/pacpusStruct.h
42 #${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/QSerialPort.h
43 ./src/matrice.cpp
44 ./src/geodesie.cpp
45 ./src/AsyncWorkerBase.cpp
46 ./src/PeriodicWorker.cpp
47 #./src/QSerialPort.cpp
48)
49
50# ========================================
51# Files to MOC
52# ========================================
53set(
54 FILES_TO_MOC
55 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/AsyncWorkerBase.h
56 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/PeriodicWorker.h
57 #${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/QSerialPort.h
58)
59
60# ========================================
61# Call MOC
62# ========================================
63qt5_wrap_cpp(
64 PROJECT_MOC_SRCS
65 ${FILES_TO_MOC}
66)
67
68# ========================================
69# Platform specific sources
70# ========================================
71# Unix
72if(UNIX)
73 list(
74 APPEND PROJECT_SRCS
75 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/PosixShMem.h
76 src/PosixShMem.cpp
77 )
78endif()
79# Windows
80if(WIN32)
81 list(
82 APPEND PROJECT_SRCS
83 ${PACPUS_INCLUDE_DIR}/Pacpus/PacpusTools/Win32ShMem.h
84 src/Win32ShMem.cpp
85 )
86endif()
87
88# ========================================
89# Build a library
90# ========================================
91pacpus_add_library(
92 ${PROJECT_NAME} SHARED
93 ${PROJECT_SRCS}
94 ${PROJECT_MOC_SRCS}
95)
96
97# ========================================
98# Libraries
99# ========================================
100target_link_libraries(
101 ${PROJECT_NAME}
102 ${QT_LIBRARIES}
103 ${PACPUS_DEPENDENCIES_LIB}
104 optimized PacpusLib debug PacpusLib_d
105)
106
107# ========================================
108# Install
109# ========================================
110pacpus_install(${PROJECT_NAME})
111
112# ========================================
113# Folder
114# ========================================
115pacpus_folder(${PROJECT_NAME} "libraries")
Note: See TracBrowser for help on using the repository browser.