Debian Codegraph @

CMakeLists.txt

raw ◀ ▶
Source reconstructed at patch state 0 of 6 — not the installed (fully patched) source.
6 Debian patches touch this file
1 cmake_minimum_required(VERSION 3.5)
2
3 set(RAILCONTROL_VERSION "24")
4
5 project(CMakeTest)
6
7 add_executable(railcontrol
8 Storage/sqlite/sqlite3.c
9 Storage/sqlite/sqlite3.h
10 Storage/sqlite/sqlite3ext.h
11 Manager.cpp
12 Manager.h
13 Server/Web/WebClient.cpp
14 Server/Web/WebClient.h
15 ArgumentHandler.cpp
16 ArgumentHandler.h
17 Config.cpp
18 Config.h
19 ControlInterface.h
20 DataModel/Accessory.cpp
21 DataModel/Accessory.h
22 DataModel/AccessoryBase.cpp
23 DataModel/AccessoryBase.h
24 DataModel/AccessoryConfig.h
25 DataModel/Cluster.cpp
26 DataModel/Cluster.h
27 DataModel/DataModel.h
28 DataModel/Feedback.cpp
29 DataModel/Feedback.h
30 DataModel/FeedbackConfig.h
31 DataModel/HardwareHandle.cpp
32 DataModel/HardwareHandle.h
33 DataModel/Layer.h
34 DataModel/LayoutItem.cpp
35 DataModel/LayoutItem.h
36 DataModel/LockableItem.cpp
37 DataModel/LockableItem.h
38 DataModel/Loco.cpp
39 DataModel/Loco.h
40 DataModel/LocoBase.cpp
41 DataModel/LocoBase.h
42 DataModel/LocoConfig.h
43 DataModel/LocoFunctions.cpp
44 DataModel/LocoFunctions.h
45 DataModel/MultipleUnit.cpp
46 DataModel/MultipleUnit.h
47 DataModel/Object.cpp
48 DataModel/Object.h
49 DataModel/ObjectIdentifier.cpp
50 DataModel/ObjectIdentifier.h
51 DataModel/Relation.cpp
52 DataModel/Relation.h
53 DataModel/Route.cpp
54 DataModel/Route.h
55 DataModel/Serializable.cpp
56 DataModel/Serializable.h
57 DataModel/Signal.cpp
58 DataModel/Signal.h
59 DataModel/Switch.cpp
60 DataModel/Switch.h
61 DataModel/Text.cpp
62 DataModel/Text.h
63 DataModel/Track.cpp
64 DataModel/Track.h
65 DataTypes.h
66 Fallthrough.h
67 Hardware/AccessoryCache.cpp
68 Hardware/AccessoryCache.h
69 Hardware/CS1.h
70 Hardware/CS2Tcp.cpp
71 Hardware/CS2Tcp.h
72 Hardware/CS2Udp.cpp
73 Hardware/CS2Udp.h
74 Hardware/Capabilities.h
75 Hardware/CcSchnitte.cpp
76 Hardware/CcSchnitte.h
77 Hardware/DR5000.h
78 Hardware/DccPpExSerial.cpp
79 Hardware/DccPpExSerial.h
80 Hardware/DccPpExTcp.cpp
81 Hardware/DccPpExTcp.h
82 Hardware/Ecos.h
83 Hardware/FeedbackCache.cpp
84 Hardware/FeedbackCache.h
85 Hardware/HardwareHandler.cpp
86 Hardware/HardwareHandler.h
87 Hardware/HardwareInterface.h
88 Hardware/HardwareParams.h
89 Hardware/Hsi88.cpp
90 Hardware/Hsi88.h
91 Hardware/Intellibox.h
92 Hardware/Intellibox2.h
93 Hardware/LocoCache.cpp
94 Hardware/LocoCache.h
95 Hardware/LocoNetAdapter63120.h
96 Hardware/LocoNetAdapter63820.h
97 Hardware/M6051.cpp
98 Hardware/M6051.h
99 Hardware/MasterControl.h
100 Hardware/MasterControl2.h
101 Hardware/OpenDcc.h
102 Hardware/Protocols/DccPpEx.cpp
103 Hardware/Protocols/DccPpEx.h
104 Hardware/Protocols/EsuCAN.cpp
105 Hardware/Protocols/EsuCAN.h
106 Hardware/Protocols/LocoNet.cpp
107 Hardware/Protocols/LocoNet.h
108 Hardware/Protocols/LocoNetLocoCache.h
109 Hardware/Protocols/MaerklinCAN.h
110 Hardware/Protocols/MaerklinCANCommon.cpp
111 Hardware/Protocols/MaerklinCANCommon.h
112 Hardware/Protocols/P50x.cpp
113 Hardware/Protocols/P50x.h
114 Hardware/Protocols/P50xCache.h
115 Hardware/Protocols/P50xEthernet.h
116 Hardware/Protocols/P50xSerial.h
117 Hardware/Protocols/P50xUhlenbrock.h
118 Hardware/Protocols/Z21.cpp
119 Hardware/Protocols/Z21.h
120 Hardware/Protocols/Z21FeedbackCache.h
121 Hardware/Protocols/Z21LocoCache.h
122 Hardware/Protocols/Z21TurnoutCache.h
123 Hardware/RedBox.h
124 Hardware/Rektor.h
125 Hardware/TwinCenter.h
126 Hardware/Virtual.cpp
127 Hardware/Virtual.h
128 Hardware/Z21.h
129 Hardware/ZLib.cpp
130 Hardware/ZLib.h
131 Languages.cpp
132 Languages.h
133 Logger/Logger.cpp
134 Logger/Logger.h
135 Logger/LoggerClient.h
136 Logger/LoggerClientConsole.h
137 Logger/LoggerClientFile.h
138 Logger/LoggerClientTcp.h
139 Logger/LoggerServer.cpp
140 Logger/LoggerServer.h
141 Network/Select.h
142 Network/Serial.cpp
143 Network/Serial.h
144 Network/TcpClient.cpp
145 Network/TcpClient.h
146 Network/TcpConnection.cpp
147 Network/TcpConnection.h
148 Network/TcpServer.cpp
149 Network/TcpServer.h
150 Network/UdpClient.h
151 Network/UdpConnection.cpp
152 Network/UdpConnection.h
153 Network/UdpServer.cpp
154 Network/UdpServer.h
155 RailControl.cpp
156 RailControl.h
157 Server/CS2/CS2Client.cpp
158 Server/CS2/CS2Client.h
159 Server/CS2/CS2Server.cpp
160 Server/CS2/CS2Server.h
161 Server/Web/HtmlTag.cpp
162 Server/Web/HtmlTag.h
163 Server/Web/HtmlTagAccessory.cpp
164 Server/Web/HtmlTagAccessory.h
165 Server/Web/HtmlTagButton.cpp
166 Server/Web/HtmlTagButton.h
167 Server/Web/HtmlTagButtonCancel.h
168 Server/Web/HtmlTagButtonCommand.cpp
169 Server/Web/HtmlTagButtonCommand.h
170 Server/Web/HtmlTagButtonCommandFullScreen.cpp
171 Server/Web/HtmlTagButtonCommandFullScreen.h
172 Server/Web/HtmlTagButtonCommandPressRelease.cpp
173 Server/Web/HtmlTagButtonCommandPressRelease.h
174 Server/Web/HtmlTagButtonCommandToggle.cpp
175 Server/Web/HtmlTagButtonCommandToggle.h
176 Server/Web/HtmlTagButtonCommandWide.h
177 Server/Web/HtmlTagButtonMinus.h
178 Server/Web/HtmlTagButtonOK.h
179 Server/Web/HtmlTagButtonPlus.h
180 Server/Web/HtmlTagButtonPopup.cpp
181 Server/Web/HtmlTagButtonPopup.h
182 Server/Web/HtmlTagButtonPopupWide.h
183 Server/Web/HtmlTagFeedback.cpp
184 Server/Web/HtmlTagFeedback.h
185 Server/Web/HtmlTagInput.cpp
186 Server/Web/HtmlTagInput.h
187 Server/Web/HtmlTagInputCheckbox.h
188 Server/Web/HtmlTagInputCheckboxWithLabel.h
189 Server/Web/HtmlTagInputHidden.h
190 Server/Web/HtmlTagInputInteger.cpp
191 Server/Web/HtmlTagInputInteger.h
192 Server/Web/HtmlTagInputIntegerWithLabel.h
193 Server/Web/HtmlTagInputSlider.cpp
194 Server/Web/HtmlTagInputSlider.h
195 Server/Web/HtmlTagInputSliderLocoSpeed.cpp
196 Server/Web/HtmlTagInputSliderLocoSpeed.h
197 Server/Web/HtmlTagInputText.h
198 Server/Web/HtmlTagInputTextWithLabel.h
199 Server/Web/HtmlTagLabel.h
200 Server/Web/HtmlTagLayoutItem.cpp
201 Server/Web/HtmlTagLayoutItem.h
202 Server/Web/HtmlTagRoute.cpp
203 Server/Web/HtmlTagRoute.h
204 Server/Web/HtmlTagSelect.cpp
205 Server/Web/HtmlTagSelect.h
206 Server/Web/HtmlTagSelectMultiple.cpp
207 Server/Web/HtmlTagSelectMultiple.h
208 Server/Web/HtmlTagSelectMultipleWithLabel.cpp
209 Server/Web/HtmlTagSelectMultipleWithLabel.h
210 Server/Web/HtmlTagSelectOrientation.h
211 Server/Web/HtmlTagSelectOrientationWithLabel.h
212 Server/Web/HtmlTagSelectWithLabel.cpp
213 Server/Web/HtmlTagSelectWithLabel.h
214 Server/Web/HtmlTagSignal.cpp
215 Server/Web/HtmlTagSignal.h
216 Server/Web/HtmlTagSwitch.cpp
217 Server/Web/HtmlTagSwitch.h
218 Server/Web/HtmlTagText.cpp
219 Server/Web/HtmlTagText.h
220 Server/Web/HtmlTagTrack.cpp
221 Server/Web/HtmlTagTrack.h
222 Server/Web/Response.cpp
223 Server/Web/Response.h
224 Server/Web/ResponseCsv.cpp
225 Server/Web/ResponseCsv.h
226 Server/Web/ResponseHtml.cpp
227 Server/Web/ResponseHtml.h
228 Server/Web/ResponseHtmlFull.cpp
229 Server/Web/ResponseHtmlFull.h
230 Server/Web/ResponseHtmlNotFound.cpp
231 Server/Web/ResponseHtmlNotFound.h
232 Server/Web/ResponseHtmlNotImplemented.cpp
233 Server/Web/ResponseHtmlNotImplemented.h
234 Server/Web/WebClientCluster.cpp
235 Server/Web/WebClientCluster.h
236 Server/Web/WebClientRoute.cpp
237 Server/Web/WebClientRoute.h
238 Server/Web/WebClientSignal.cpp
239 Server/Web/WebClientSignal.h
240 Server/Web/WebClientStatic.cpp
241 Server/Web/WebClientStatic.h
242 Server/Web/WebClientText.cpp
243 Server/Web/WebClientText.h
244 Server/Web/WebClientTrack.cpp
245 Server/Web/WebClientTrack.h
246 Server/Web/WebServer.cpp
247 Server/Web/WebServer.h
248 Server/Z21/Z21Client.cpp
249 Server/Z21/Z21Client.h
250 Server/Z21/Z21Server.cpp
251 Server/Z21/Z21Server.h
252 Storage/Sqlite.cpp
253 Storage/Sqlite.h
254 Storage/StorageHandler.cpp
255 Storage/StorageHandler.h
256 Storage/StorageInterface.h
257 Storage/StorageParams.h
258 Storage/TransactionGuard.cpp
259 Storage/TransactionGuard.h
260 Utils/Integer.cpp
261 Utils/Integer.h
262 Utils/Network.cpp
263 Utils/Network.h
264 Utils/ThreadSafeQueue.h
265 Utils/Utils.cpp
266 Utils/Utils.h
267 Version.cpp
268 Version.cpp.dummy
269 Version.cpp.in
270 Version.h
271 Hardware/zlib/adler32.c
272 Hardware/zlib/compress.c
273 Hardware/zlib/crc32.c
274 Hardware/zlib/crc32.h
275 Hardware/zlib/deflate.c
276 Hardware/zlib/deflate.h
277 Hardware/zlib/gzclose.c
278 Hardware/zlib/gzguts.h
279 Hardware/zlib/gzlib.c
280 Hardware/zlib/gzread.c
281 Hardware/zlib/gzwrite.c
282 Hardware/zlib/infback.c
283 Hardware/zlib/inffast.c
284 Hardware/zlib/inffast.h
285 Hardware/zlib/inffixed.h
286 Hardware/zlib/inflate.c
287 Hardware/zlib/inflate.h
288 Hardware/zlib/inftrees.c
289 Hardware/zlib/inftrees.h
290 Hardware/zlib/trees.c
291 Hardware/zlib/trees.h
292 Hardware/zlib/uncompr.c
293 Hardware/zlib/zconf.h
294 Hardware/zlib/zlib.h
295 Hardware/zlib/zutil.c
296 Hardware/zlib/zutil.h
297 )
298
299 set(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "")
300 set(CMAKE_CXX_STANDARD 11)
301 set(CMAKE_CXX_STANDARD_REQUIRED True)
302 set(CMAKE_CXX_FLAGS_DEBUG "-O0")
303 set(CMAKE_CXX_FLAGS_RELEASE "-O2")
304 set(CMAKE_CXX_FLAGS "-g -Wall -Wextra -pedantic -Werror")
305 set(CMAKE_C_FLAGS "-g -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_RTREE -DHAVE_USLEEP -Wno-implicit-function-declaration -Wno-return-local-addr")
306
307 set(THREADS_PREFER_PTHREAD_FLAG ON)
308 find_package(Threads REQUIRED)
309 target_link_libraries(railcontrol PRIVATE Threads::Threads dl)
310
311 target_include_directories(railcontrol PRIVATE .)
312
313 add_custom_command(OUTPUT Version.cpp Version.cpp.dummy
314 DEPENDS Version.cpp.in
315 COMMAND git status -s| wc -l > ${CMAKE_CURRENT_SOURCE_DIR}/git_dirty.txt
316 COMMAND sed s/@COMPILE_TIMESTAMP@/`date +%s`/ < ${CMAKE_CURRENT_SOURCE_DIR}/Version.cpp.in | sed s/@GIT_HASH@/`git log -1 --format=%H`/ | sed s/@GIT_TIMESTAMP@/`git log -1 --format=%at`/ | sed s,@GIT_DIRTY@,`cat ${CMAKE_CURRENT_SOURCE_DIR}/git_dirty.txt`, | sed s/@RAILCONTROL_VERSION@/${RAILCONTROL_VERSION}/ > ${CMAKE_CURRENT_SOURCE_DIR}/Version.cpp
317 COMMAND rm ${CMAKE_CURRENT_SOURCE_DIR}/git_dirty.txt
318 COMMENT "Creating Version.cpp")
319